This preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
Unformatted text preview: SECTION 2.3 Functions 2. a) This is not a function because the rule is not welldefined. We do not know whether f(3) : 3 or f(3) : —3.
For a function, it cannot be both. at the same time. b) This is a function. For all integers n, Vim—T is a well—deﬁned real number. :3) This is not a function with domain Z, since for n = 2 {and also for n : *2) the value of ﬂu) is not
deﬁned by the given rule. In other words, f(2) and f(—2) are not speciﬁed since division by 0 makes no
sense. . a) The domain is the set of nonnegative integers, and the range is the set of digits (0 through 9). b) The domain is the set of positive integers, and the range is the set of integers greater than 1. c) The domain is the set of all bit strings, and the range is the set of nonnegative integers. d) The domain is the set of all bit strings, and the range is the set of nonnegative integers (a bit string can
have length 0). a) The domain is Z+ x Z+ and the range is Z+. b) Since the largest decimal digit of a strictly positive integer cannot be 0, we have domain Z+ and range
{1,2,3,4,5,6,7,s,9}. c) The domain is the set of all bit strings. The number of 1’s minus number of 0’s can be any positive or
negative integer or 0, so the range is Z. d) The domain is given as Z+. Clear];r the range is Z+ as well. 9) The domain is the set of bit strings. The range is the set of Strings of 1’s, i.e., {)1, 1, 11, 111, . . .}, where /\
is the empty string (containing no symbols). Section 2.3 10. 12. 14. 16. 18. 20. 22. Functions 41 . \Ve simply round up or down in each case. a)1 b)2 e)»1 g)_%+1):[%j21 h) [0+1+§i=[%l=2 d)0 e)3 r)—2 a) This is oneto—one. b) This is not oneto—one, since b is the hnage of both a and b. c) This is not onetoone, since (I. is the image of both a and d. a) This is one—toone, since if 711 — 1 : 112 e I, then m = 722. b) This is not oneto—one, since, for example, f(3) : f(*3) : 10. c) This is onetoone, since if : 71%, then m : up, (take the cube root of each side).
d) This is not onetoone, since, for example, = f(4) : 2. a) This is clearly onto, since f(0, en) : n. for every integer n. H b) This is not onto, since, for example, 2 is not in the range. To see this, if 1712 ~ 71.2 (m — n)(m + n) : 2,
then m and n must have same parity (both even or both odd). In either case, both m e n and in +17. are
then even, so this expression is divisible by 4 and hence cannot. equal 2. c) This is clearly onto, since f(0, n.  1) :71. for every integer n. d) This is onto. To achieve negative values we set or = 0, and to achieve nonnegative values we set It : D.
e) This is not onto, for the same reason as in part (b). In fact, the range here is clearly a subset of the range
in that part. a) f(n) = n + 1? b) ﬁn) = [11/2] e) We let f(u) : n —* 1 for even values of n, and 1(a) 2 n + 1 for odd values of n. Thus we have f(1) : 2,
f(2) = 1, 1(3) : 4, f(4) = 3, and so on. Note that this is just one function, even though its deﬁnitiOn used
two formulae, depending on the the parity of n. d) f(n) = 17 If we can ﬁnd an inverse, the function is a bijection. Otherwise we must explain why the function is not
0114300118 or not onto. a) This is a injection since the inverse function is f’l(ri:) = (d — b) This is not onetoone since f(17) = f(—17), for instance. It is also not onto, since the range is the interval
(00, 7]. For example, 42548 is not in the range. c) This function is a bijection, but not from R to R. To see that the domain and range are not R, note
that .1: = —2 is not in the domain, and :c z 1 is not in the range. On the other hand, f is a bijection from
R — {~2} to R —— {1}, since its inverse is f“‘(1r):(1—21:)/(:c — 1). d) It is clear that this continuous function is increasing throughout its entire domain (R) and it takes on both
arbitrarily large values and arbitrarin small (large negative) ones. So it is a bijection. Its inverse is clearly .f"1(:L')= The key,r here is that larger denominators make smaller fractions, and smaller denominators make larger
fractions. \\’e have two things to prove, since this is an "if and only if” statement. First, suppose that f is
strictly increasing. This means that < ﬂy) wl‘ienever :r < 7). To show that g is strictly decreasing,
suppose that :7; < Then g(:r) : 1/f(;r) > 1./f(y) = 9(1)). Conversely, suppose that g is strictly decreasing.
This means that g(;’c) > g(y) whenever .1: < To show that f is strictl}.r increasing, suppose that :c < y.
Then flrr) : I/gt'ni < we) : full We need to make the function increasing, but not strictly increasing, so, for example, we could take the trivial
function = 17. If we want the range to be all of R, we could deﬁne f in parts this way: f(.cr) : :i: for
:1: <0; ﬁg?) :0 for 0 $1: 5 1; and f(:r) = :5—1 for ;c >1. 42 24. 26. 28. 30. 32. 34. 36. 38. 40. Chapter 2 Basic Structures: Sets, Functions, Sequences, and Sums
For the function to be invertible, it must be a one—to—one correspondence. This means that it has to be
Onetoone, which it is, and onto, which it is not, because, its range is the set of positive real numbers, rather
than the set of all real numbers. When we restrict the codomain to be the set of positive real numbers, we get
an invertible function. In fact, there is a well—known name for the inverse function in this case—the natural
logarithm function (g(:r:) = Inst). In all parts, we simply need to compute the values “71), f(0), f(2), f(4), and f(7) and collect the values
into a set.
b) {—1,1,5,s,15} c) {0,1,2} a) (all ﬁve values are the same) d) {0,1,5,16} a) the set of even integers b) the set of positive even integers c) the set of real numbers
To clarify the setting, suppose that g : A E: B and f : B e C, so that f o g: A —» C. We will prove that if
f o g is one—toone, then 9 is also onctoone, so not 011]}r is the answer to the question “yes,” but part of the
hypothesis is not even needed. Suppose that g were not onetoone. By deﬁnition this means that there are
distinct. elements 0.1 and 02 in A such that 51(0)) 2 9(a2). Then certainly f(g(a1)) : f(g(o.2)), which is the
same statement as (f o g)(a1) : (f o g)(a.2). By definition this means that f o g is not onetoone, and our proof is complete. We have (f o = f(g(:t)) 2 He: + 2) = (:t + 2)? +1 2 2:2 + 4:1: + 5, whereas (9 0 f)(:i;) = g(f(:r;)) =
9(12 + 1) : 11:2 + 1 + 2 2 .1:2 + 3. Note that they are not equal. Forming the compositions we have (f og)(.1:) : acre + ad + b and {g of)(rr) = can: +cb +d. These are equal if
and only if ad+b :— cb+d. In other words, equality holds for all 4tuples (a, b, c,d) for which ad+ b = cb+d. a) This really has two parts. First suppose that b is in f(SUT). Thus 5 = f(c.) for some a E SUT. Either
a E S, in which case b E HS), or a. E T, in which case b E f(T). Thus in either case b E HS) U f(T). This
shows that f(SUT) C; f(S)Uf(T). Conversely, suppose b E f(.S')Uf(T). Then either 6 E f(5‘) or b E f(T).
This means either that b 2 Ha) for some a E S or that b = f(a) for some a E T. In either case, b : No)
for some a E S U T, so I) E f(.S' U T). This shows that f(S) U HT) Q f(SU T), and our proof is complete.
b) Suppose I) E f(3 OT). Then b 2 ﬂat) for some a E SﬂT. This implies that a. E S and a E T, so we
have b E MS) and b E Therefore 1') E f(S)l’1f(T), as desired. a) The answer is the set of all solutions to 3:2 = 1, namely {1, 1}. b) In order for .122 to be strictly between 0 and 1, we need 3: to be either strictly between 0 and 1 or strictly
between —1 and 0. Therefore the answer is {:6 l —1 < .1: < 0 V 0 < :13 < 1 c) In order for .722 to be greater than 4, we need either a: > 2 or a: < #2.
{:rl$>2Va:<~2}. Therefore the answer is a) We need to preve two things. First supp05e (E E f“(S U T). This means that f(:1:) E S U T. Therefore
either ﬂat) E S or f(:t) E T. In the first case a: E f‘1(.5'), and in the second case .1: E f’l(T). In either case,
then, :1: E f‘1(S) U f"(T). Thus we have shown that f‘KSUT) (_: f"(S) Uf_'(T). Conversely, suppose
that .1: E j"I (S)Uf‘l(T)._ Then either a: E f’l(S) or .1: E f’l(T), so either f(a:) E S or f(:!:) E T. Thus we
know that f(;t) E SUT, so by deﬁnition 1 E f’1(SUT). This shows that f’1(S) U f”l(T) g ,f*l(5'UT),
as desired. b) This is similar to part (a). We have a: E f‘1(S ['1 T) if and only if E 5' (1 T, if and only if f(:t) E .S'
and E T, if and only if .1: E f’l(S) and .1; E f_l(T), if and only if .1: E f"l(S)ﬂf”'l(T). ' Section 2.3 42. 44. 46. 48. 52. 56. 58. Functions 43
There are three cases. Deﬁne the “fractional part“ of :3 to be 2 a: 2 . Clearly ﬁx) is always between 0 and 1 (inclusive at 0, exclusive at I), and :r 2 [1:] +f(:i:). If is less than then .1:+% will have a value slightly less than + 1, so when we round down, we get In other words, in this case [re + 2 [at], and indeed that is the integer closest to If f(.’13) is greater than %, then 2: + will have a value slightl)r greater than + i, so when we round down, we get is] +1. In other words, in this case [cr + 2 + 1, and indeed that is the integer closest to .T in this case. Finally, if the fractional part is exactly %, then a: is midway between two integers, and is: + 2 [1:] + i, which is the larger of these two integers. If a: is not an integer, then is the integer just larger than 3:, and is the integer just smaller than 3:.
Clearly they differ by 1. If :4: is an integer, then {mi 2 [3:] 2 a: — 1' 2 0. write a: 2 n2 e, where n. is an integer and 0 g e < I; thus [at] 2 n. Then [3: +171] 2 in —E +131] 2 n+7n 2
[xi + in. Alternatively, we could proceed along the lines of the proof of property 4a of Table 1, shown in the text. a) The “if” direction is trivial, since :5 S For the other direction, suppose that a: 11. Since '1? is an I/\ l/'\ integer no smaller than :5, and [3;] is by deﬁnition the smallest such integer, clearly [it] b) The “if” direction is trivial, since S :L‘. For the other direction, suppose that 'n :7. Since it is an M integer not exceeding 3:, and is by deﬁnition the largest such integer, clearly a, S . . To prove the ﬁrst equality, write a: 2 n — e, where n is an integer and 0 S E < 1; thus [at] 2 n. Therefore, [—32] 2 L—n + e] 2 2n 2 The second equality is proved in the same manner, writing a: 2 n + e, where
n is an integer and 0 S c < i. This time 2 n, and 2 [—n — El 2 2n 2 ~i:1:_[. In some sense this question is its own answer—the number of integers between a and b, inclusive, is the
number of integers between a. and b, inclusive. Presumabl;r we seek an expression involving a, b, and the
floor and/0r ceiling function to answer this question. If we round a up and round b down to integers, then
we will be looking at the smallest and largest integers just inside the range of integers we want to count,
respectively. These values are of course [a] and Lb], respectively. Then the answer is [b] — in] + 1 (just
think of counting all the integers between these two values, including both ends—if a row of fenceposts one
feet apart extends for 3.: feet, then there are i: + l fenceposts). Note that this even works when, for example,
a 2 0.3 and b 2 0.7. Since a byte is eight bits, all we are asking for in each case is , where n is the number of bits.
a) [4/8] : 1 b) [10/8] : 2 c) [500/8] : 63 d) [3000/8] = 375 From Example 26 we know that one ATlVI cell is .53 bytes, or 53  8 2 424 bits long. Thus in each case we
need to divide the number of bits transmitted in 10 seconds by 424 and round down. a) In 10 seconds, this link can transmit 128,00010 2 1,280,000 hits. Therefore the answer is [1,280,000/424J 2
3018. b) In 10 seconds, this link can transmit 300,00010 2 3,000,000 hits. So the answer is [3,000,000/42!” 2 7075. c) In 10 seconds, this link can transmit 1,000,000 10 2 10,000,000 bits. So the answer is L10,000,000/424j 2
23,584. The graph consists of the points (11,1 2 :12) for all n E Z. The picture shows part of the graph on the usual
coordinate axes. 44 Chapter 2 Basic Structures: Sets, Fimctions, Sequences, and Sums 62. The function values for this step function change only at integer values of 3:, and different things happen for
odd .1: and for even .7; because of the ar/2 term. Whatever jump pattern is established on the closed intcrval
[0,2] must repeat indeﬁnitter in both directions. A thoughtful analysis then yields the following graph. 64. a) We can rewrite this as : i The graph will therefore look look exactly like the graph of the
function f(:r:) = [—3.1‘) , except that the picture will be shifted to the right by unit, since I has been replaced
by :1: —— The graph of f(:r;) : is just like the graph shown in Figure 10b, except that the Insaxis needs
to be rescaled by a factor of 3 (the ﬁrst jump on the positive sisaxis occurs at .1: = % here). Putting this all
together yields the following picture. (Alternatively, we can think of this as the graph of : [33:] shifted
down ‘2 units, since — 2) 2 ~ 2.) b) The graph will look exactly like the graph shown in Figure 10]), except that the m—qxis needs to be rescaled
by a factor of 5 (the ﬁrst jump on the positive LEaxis occurs at a; 2 5 here). Section 2.3 Functions 45 0) Since [el/zt'j : —[1/:1:i [see Exercise 50), the picture is just the picture for Exercise 63d flipped upside
down. d) The basic shape is the parabola, y = 3:2. However, because of the greatest integer function, the curve is broken into steps, with jumps at .’L' : :tl, :h/j, iﬁ, . . .. Note the symmetry around the 1132115.
0 9 0
0 3 to
O. 7‘ .0
0. 6 .0
0‘0 5 to
00 4 w
0. 3 00
00 2 00
00 00 e) The basic shape is the parabola, y : reg/4. However= because of the step functions the curve is broken
into steps. For .7: an even integer, : 3:"/4, since the terms inside the ﬂoor and ceiling function symbols
are integers. Note how these are isolated point, as in Exercise 63f. f) \Vhen a: is an even integer, this is just :5. When .1: is between two even integers, however, this has the
value of the odd integer between them. The graph is therefore as shown here. 46 Chapter 2 Basic Structures: Sets, Functions, Sequences, and Sums g) Despite the complicatedlooking formula, this is not too hard. Note that the expression inside the outer floor function symbols is always going to be an integer plus % ; therefore we can tell exactly what its rounded—down value will be, namely Else/‘2] . This is just the graph in Figure 10b, rescaled on both axes. 66. This follows immediately from the definition. We want to show that ((f o g) o (9“ o f“))(z) = z for all
z E Z and that ((g’1 of’1)o(fog))(:u) = a: for all 3; E X. For the first we have ((fogloly‘lof‘llhz) : (f09)((9‘10f")(z)) The second equality is similar. 68. If f is oneto—one, then every element of A gets sent to a different element. of B. If in addition to the range
of A there were another element in B, then [Bl would be at least one greater than A. This cannot happen,
so we conclude that f is onto. Conversely, suppose that f is onto, so that every element of B is the image
of some element of A. In particular, there is an element of A for each element of B. If two or more elements
of A were sent to the same element of B, then [Al would be at. least one greater than the This cannot
happen, so we conclude that f is onetoone. 70. a) This is true. Since {girl is already an integer, : b) A little experimentation shows that. this is not always true. To disprove it we need only produce a.
counterexample, such as :1: 2 y = In this case the left—hand side is [3/2] :— 1, while the righthand side is
0 + U = 0. c) A little trial and error fails to produce a counterexample, so maybe this is true. We look for a proof.
Since we are dividing by 4, let us write a: = 411+ is, where O S is < 4. In other words, write 1' in terms of
how much it exceeds the largest multiple of 4 not. exceeding it. There are three cases. If k = 0, then a: is
already a multiple of 4, so both sides equal n. If 0 < k g 2, then [re/2] : 2n. + 1, so the lefthand side is
[n + = n + 1. Of course the right—hand side is n. + 1 as well, so again the two sides agree. Finally, suppose
that 2 < is < 4. Then lac/2] : 2n + 2, and the left—hand side is [11 +1] : n + 1; of course the righthand
side is still 11+ 1 , as well. Since we proved that the two sides are equal in all cases, the proof is complete. Section 2, 3 72. 74. 76. Functions 47 d) For a: = 8.5, the leftshand side is 3, whereas the righthand side is 2.
e) This is true. Write .1; 2 n + e and y 2 m. + (5, where n and m are integers and e and [5 are nonnegative
real numbers less than 1. The lefthand side is n. + m + (n. +111) or n + m + (n + m + I), the latter occurring if and only if e + 6 2 l. The righthand side is the sum of two quantities. The ﬁrst is either 2n. (if e < or 211+ 1 (if e 2 é). The second is either 2m (if 6 < or 2171+ 1 (if 6 2 The only way, then, for the leftshand side to exceed the righthand side is to have the lefthand side be 277. + 2772 + 1 and the righthand
side be 2n. + 2711. This can occur only if c + 6 2 1 while 6 < % and :5 < But that is an impossibility, since
the sum of two numbers less than £— cannot be as large as 1. Therefore the right.~hand side is always at least as large as the lefthand side. A straightforward way to do this problem is to Consider the three cases determined by where in the interval
between two consecutive integers the real number it lies. Certainly every real number .r lies in an interval
in, n + 1) for some integer n, indeed, it = [:3]. (Recall that [8, t) is the notation for the set of real numbers
greater than or equal to s and less than t.) If .1; G [n,n + g), then 33'; lies in the interval [Suﬁu + 1),
so [31".] = 3n. Moreover in this case a: + is still less than n + 1, and :r. —I is still less than 11+ 1, so
(:5) + (:1; + + [at + 2 71+ 11 +17, : 31:. as well. For the second case, we assume that :c E [n + in + g).
This time 3.1; E [3n + 1,371. + 2), so (33:) = 3n + l. r\'loreover in this case :r. + é is in (n + gm + l), and
.1: + is in [71+ l,n + so (sci + _:i: + + + = n + n + (n + l) : 311+ l as well. The third case,
1‘ E [21+ %, n + l), is similar, with both sides equaling 3n + 2. a) We merely have to remark that J” is well‘deﬁned by the rule given here. For each a. 6 A, either a is in the
domain of deﬁnition of f or it is not. If it is, then f"(e) is the well—deﬁned element f(a) E B, and otherwise
f"(a.) : n. In either case f"(a.) is a well—defined element of B U {u}. b) we simply need to set f"’(e.) = u for each a not in the domain of deﬁnition of f. In part (a), then,
f'(n) : 1/71 for n at 0, and f“(0) : u. In part (b) we have a. total function already, so f*(n.) = (ii/2] for all
n E Z. In part (c) f”(1n,n) : m/n if n 7/: 0, and _f"‘(m,0) = u for all 1'71 E Z. In part ((1) we have a total
function already, so f“(m, n) : nm for all values of m and n. in part (e) the rule only applies if m. > n, so
f”(rn, n.) : m — n if m. > n, and f*(m,n) : u. if in g n. For the “if” direction, we simply need to note that if 5' is a ﬁnite set, with cardinality in, then every proper
subset of S has cardinality strictly smaller than in, so there is no possible onetoone correspondence between
the elements of S and the elements of the proper subset. (This is essentially the pigeonhole principle, to be
discussed in Section 5.2.) The “only if" direction is much deeper. Let S be the given inﬁnite set. Clearly .S' is not empty, because
by deﬁnition, the empty set has cardinality 0, a nonnegative integer. Let an be one element of S, and let
A : S — {(10}. Clearly A is also inﬁnite (because if it \vere ﬁnite, then we would have : [Al + 1, making
8 ﬁnite). We will now construct a one—toone correspondence between 5' and A; think of this as a oneto—one
and onto function f from S’ to A. (This construction is an inﬁnite process; technically we are using something
called the Axiom of Choice.) In order to deﬁne f(00), we choose an arbitrary element 0.1 in A (which is
possible because A is inﬁnite) and set f(00) : 0.1. Next we deﬁne f at (11. To do so, we choose an arbitrary
clement (L2 in A e {(21} (which is pessible because A e {(11} is necesSarily inﬁnite) and set f(ul) : (12. Next
we deﬁne f at (22. To do so, we choose an arbitrary element (13 in A 7 {(11,612} (which is possible because
A — {01,02} is necessarily inﬁnite) and set f((1.2) : 03. We continue this process forever. Finally, we let f
be the identity function on S — {a0,a1,uQ, . . .}. The function thus deﬁned has f(ei) = ci+1 for all natural
numbers 17 and = :12 for all :r E S — {00,el,e2, . . Our construction forced f to he onetoone and
onto. 48 Chapter 2 Basic Structures: Sets, Functions, Sequences, and Sums 78. We saw in Exercise 77 that
(H? + n — 2)(rn + n. u i.) is a onetoone function with domain Z"' x Z+. We want to expand the domain to be Z x Z, so things need f(m,n) : n. to be spread out a iittle if we are to keep it 0ne~toone. If we can ﬁnd a one—toone function g from Z x Z to
Z+ x Z+ , then composing these two functions will be our desired oneto—one function from Z x Z to Z (we
know from Exercise 29 that the composition of one—to—one functions is one—toone). The function suggested
here is g(m, n) 2 ((37)? + 1)2,(15n + 1V); so that the composed function is (f og)(m, n) 2 ((3m+ 1)2 + (3n+
1)2 — 2)((3m +1)2 + (371 +1)"2 — l)/2 +(3m+1)2. To see that g is one—to—one, ﬁrst note that it is enough to
show that the behavior in each coordinate is oneto—one; that is, the function that sends integer k to positive
integer (3k+ 1)'2 is onetoone. To see this, first note that if in! 3:5 kg and is] and [:2 are both positive or both
negative, then (3k1 + 1)?‘ 5x9 (3kg + l)2. And if one is nonnegative and the other is negative, then they cannot
have the same irnages under this function because the nonnegative integers are sent to squares of numbers
that leave a remainder of 1 when divided by 3 (0 —> 12, 1 —> 42, 2 a 72, but negative integers are sent
to squares of numbers that leave a remainder of 2 when divided by 3 (—1 —> 22, —2 —> 52, —3 i) 82, .. . ...
View
Full Document
 Spring '09
 Ming

Click to edit the document details