<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="wordpress/2.0.4" -->
<rss version="2.0" 
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>

<channel>
	<title>Tomcat, J2Ee, Hibernate Programming, Shared Web Hosting, Comcast Web Hosting Java Blog</title>
	<link>http://j2ee.smartwebsitehosting.net</link>
	<description>Blog about Php5, MySQL, Java, JSP, Servlet, Tomcat, SSH web site hosting</description>
	<pubDate>Fri, 28 Mar 2008 10:16:55 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.0.4</generator>
	<language>en</language>
			<item>
		<title>3.4.2 ANSWERS TO EXERCISES 555  (Ftp web hosting) 11. Arguing as</title>
		<link>http://j2ee.smartwebsitehosting.net/j2ee/342-answers-to-exercises-555-ftp-web-hosting-11-arguing-as/</link>
		<comments>http://j2ee.smartwebsitehosting.net/j2ee/342-answers-to-exercises-555-ftp-web-hosting-11-arguing-as/#comments</comments>
		<pubDate>Fri, 28 Mar 2008 10:16:55 +0000</pubDate>
		<dc:creator>humphreyblogart</dc:creator>
		
	<category>J2EE</category>
		<guid isPermaLink="false">http://j2ee.smartwebsitehosting.net/j2ee/342-answers-to-exercises-555-ftp-web-hosting-11-arguing-as/</guid>
		<description><![CDATA[3.4.2 ANSWERS TO EXERCISES 555  11. Arguing as in Section 1.2.10, which considers the special case n = 1, we see that  the generating function is  >(   The mean is n + znctcN (n/t) = n(1 + H,v -Hn); and the variance turns out to be  n(HN -If,) -n2(H~)-Ha)). [...]]]></description>
			<content:encoded><![CDATA[<p>3.4.2 ANSWERS TO EXERCISES 555  11. Arguing as in Section 1.2.10, which considers the special case n = 1, we see that  the generating function is  >(   The mean is n + znctcN (n/t) = n(1 + H,v -Hn); and the variance turns out to be  n(HN -If,) -n2(H~)-Ha)).   12. (Note that ~-l = (btt). . (bs3)(&#038;2), so we seek an algorithm that goes from the  representation of VT to that for r-l.) Set b, + j for 1 5 j 2 t. Then for j = 2, 3,  t (in this order) interchange b, c) ba3. Finally for j = t, , 3, 2 (in this order)  sei baJ + b,. (The algorithm is based on the fact that (att)nl = nl(btt).)   13. Renumbering the deck 0, 1, . , 2n -2, we find that s takes card number z into  card number (22) mod (2n -I), while c takes card z into (zz f 1) mod (2n -1). We have  (c followed by s) = cs = sc2. Therefore any product of c s and s s can be transformed  into the form sZck. Also 2 p(2n-1) = 1 (modulo (2n -1)); since .s~( ~- ) and c2n-1  are the identity permutation, at most (2n -l)p(2n -1) arrangements are possible.  (The exact number of different arrangements is (2n -1)/c, where k is the order of 2  modulo (2n -1). For if sk = c3, then c3 fixes the card 0, so sk = c3 = identity.) For  further details, see SIAM Review 3 (1961), 293-297.  14. Set Y, +-j for t -n < j 2 t. Then for j = t, t -1, . . , t -n f 1 do the  following operations: Set k + Lju] + 1. If k > t -n then set X, + Yk and Yk + Y,;  otherwise if Ic = X, for some i > j (a symbol table algorithm could be used), then  set X, + Y, and Yi + Y3; otherwise set X, + k. (The idea is to let Ytpn+l, , Yj  represent Xt&#8211;n+l, . . . , X,, and if i > j and X, 2 t -n also to let Y, represent Xx,,  in the execution of Algorithm P.)  15. We may assume that n 5 iN, otherwise it suffices to find the N-n elements not  in the sample. Using a hash table of size 2n, the idea is to generate random numbers  between 1 and N, storing them in the table and discarding duplicates, until n distinct  numbers have been generated. The average number of random numbers generated is  N/N+N/(N-l)+&#8230;+N/(N-n+l) < 2n, by exercise 3.3.2-10, and the average  time to process each number is O(1). We want to output the results in increasing  order, and this can be done as follows: Using an ordered hash table (exercise 6.4-66)  with linear probing, the hash table will appear as if the values had been inserted in  increasing order. Thus if we use a monotonic hash address such as [nlc/iV] for the  key k, it will be a simple matter to output the keys in sorted order by making at most  two passes over the table.  16. In most cases it will be best simply to select n records one at a time by Walker s  alias method, with probabilities proportional to their weights, rejecting an element that  occurs more than once. But if some weights are significantly larger than others, the  following algorithm will sometimes be better [cf. Wong and Easton, SIAM J. Cornput.  9 (1980), ill-1131. Begin with a  complete binary tree  of weights x2, where x2 =  ~2~ + zzi+l for 1 5 i < N and z,Afz-l = w, for 1 5 i 2 N; then do the following  operation n times:  Set j + 1, and generate X = Uxl. If X < XZ~, set j +--2j,  otherwise set X + X -2~~ and j + 2j f 1; repeat this until j > N. Then select  elementj-N+l, seti + [j/2], and while i 2 1 set x2 +- zz -x3 and i +-[i/ZJ.  Finally set q + 0.    <br />We would like to recommend you tested and proved <a href="http://jboss.smartwebsitehosting.net">virtual web hosting</a> services, which you will surely find to be of great quality.
</p>
]]></content:encoded>
			<wfw:commentRSS>http://j2ee.smartwebsitehosting.net/j2ee/342-answers-to-exercises-555-ftp-web-hosting-11-arguing-as/feed/</wfw:commentRSS>
		</item>
		<item>
		<title>Frontpage web hosting - 554 ANSWERS TO EXERCISES 3.4.1 29. Let Xn+l</title>
		<link>http://j2ee.smartwebsitehosting.net/j2ee/frontpage-web-hosting-554-answers-to-exercises-341-29-let-xnl/</link>
		<comments>http://j2ee.smartwebsitehosting.net/j2ee/frontpage-web-hosting-554-answers-to-exercises-341-29-let-xnl/#comments</comments>
		<pubDate>Fri, 28 Mar 2008 00:33:47 +0000</pubDate>
		<dc:creator>humphreyblogart</dc:creator>
		
	<category>J2EE</category>
		<guid isPermaLink="false">http://j2ee.smartwebsitehosting.net/j2ee/frontpage-web-hosting-554-answers-to-exercises-341-29-let-xnl/</guid>
		<description><![CDATA[554 ANSWERS TO EXERCISES 3.4.1   29. Let Xn+l = 1, then set Xk + Xk+lUi k or Xk + Xk+tlePYklk for k = n,  n-l, . . . . 1, where uk is uniform or Yk is exponential. [ACM Trans. Math. Software,  to appear.]  SECTION 3.4.2   1. There [...]]]></description>
			<content:encoded><![CDATA[<p>554 ANSWERS TO EXERCISES 3.4.1   29. Let Xn+l = 1, then set Xk + Xk+lUi k or Xk + Xk+tlePYklk for k = n,  n-l, . . . . 1, where uk is uniform or Yk is exponential. [ACM Trans. Math. Software,  to appear.]  SECTION 3.4.2   1. There are (rr$) ways to pick n -m records from the last N -t; (:!,I:) ways  to pick n -m -1 from N -t -1 after selecting the (t + 1)st item.  2. Step S3 will never go to step S5 when the number of records left to be examined  is equal to n -m.  3. We should not confuse  conditional  and  unconditional  probabilities. The  quantity m depends randomly on the selections that took place among the first t  elements; if we take the average over all possible choices that could have occurred  among these elements, we will find that (n -m)/(N -t) is exactly n/N on the  average. For example, consider the second element; if the first element was selected in  the sample (this happens with probability n/N), the second element is selected with  probability (n -l)/(N -1); if the first element was not selected, the second is selected  with probability n/(N -1). The overall probability of selecting the second element is  (nlN)((n -l)l(N -1)) i- (1 -nlN)(nlW -1)) = n/N.   4. From the algorithm,  p(m,t + 1) = (1 - E) p(m,  t) + n -i ,  ) dm - 1, t),   The desired formula can be proved by induction on t. In particular, p(n, N) = 1.   5. In the notation of exercise 4, the probability that t = k at termination is qk =  p(n, k) -p(n, k -1) = (:I:)/(:). The average is ~,,,,, kqk = (N $- l)n/(n f 1).  6. Similarly, co,,,, k(k + l)qk = (N + 2)(N $-l)n/(n + 2); the variance is  therefore (N + l)(N -n)n/(n + 2)(n + 1) .   7. Suppose the choice is 1 5 ~1 < 22 < ... < zn 2 N. Let 20 = 0, zn+l = N+l.  The choice is obtained with probability p = n,,,,N--pt, where  p = N-((t-1)-n+m   t for xm < t < xm+l;  N -(t -1)    n-m   pt = N-@-l)  for t = zm+l.   The denominator of the product p is N!; the numerator contains the terms N -n,  N-n -1, , 1 for those t s that are not z s, and the terms n, n -1, . . , 1 for those  t s that are z s. Hence p = (N -n)!n!/N!. Example: n = 3, N = 8, (~1~22,~s) =  (2,3,7); p = i$$$$$++.   9. The reservoir gets seven records: 1, 2, 3, 5, 9, 13, 16. The final sample consists of  records 2, 5, 16.  10. Delete step R6 and the variable m. Replace the I table by a table of records,  initialized to the first n records in step Rl, and with the new record replacing the Mth  table entry in step R4.   <br />Note: If you are looking for cheap and reliable webhost to host and run your mysql application check <a href="http://mysql.g5websitehosting.com">mysql web server</a> services.
</p>
]]></content:encoded>
			<wfw:commentRSS>http://j2ee.smartwebsitehosting.net/j2ee/frontpage-web-hosting-554-answers-to-exercises-341-29-let-xnl/feed/</wfw:commentRSS>
		</item>
		<item>
		<title>Free web hosting with ftp - 3.4.1 ANSWERS TO EXERCISES 553 This approach applies</title>
		<link>http://j2ee.smartwebsitehosting.net/j2ee/free-web-hosting-with-ftp-341-answers-to-exercises-553-this-approach-applies/</link>
		<comments>http://j2ee.smartwebsitehosting.net/j2ee/free-web-hosting-with-ftp-341-answers-to-exercises-553-this-approach-applies/#comments</comments>
		<pubDate>Thu, 27 Mar 2008 09:14:51 +0000</pubDate>
		<dc:creator>humphreyblogart</dc:creator>
		
	<category>J2EE</category>
		<guid isPermaLink="false">http://j2ee.smartwebsitehosting.net/j2ee/free-web-hosting-with-ftp-341-answers-to-exercises-553-this-approach-applies/</guid>
		<description><![CDATA[3.4.1  ANSWERS TO EXERCISES 553  This approach applies also to the binomial distribution, with   1   G(x) = U=- (l -U)n&#8211;2 dur(t + l)/r(z)r(t + 1 -x),  s P   since [G- (U)] is binomial with parameters (t, p) and G is approximately normal.  [See also the [...]]]></description>
			<content:encoded><![CDATA[<p>3.4.1  ANSWERS TO EXERCISES 553  This approach applies also to the binomial distribution, with   1   G(x) = U=- (l -U)n&#8211;2 dur(t + l)/r(z)r(t + 1 -x),  s P   since [G- (U)] is binomial with parameters (t, p) and G is approximately normal.  [See also the alternative method proposed by Ahrens and Dieter in Computing  (1980), to appear.]   23. Yes. The second method calculates Icos201, where 0 is uniformly distributed  between 0 and 7rf 2. (Let U = r cos 0, V = r sin 0.)  25. #&#038; = (.10101)2. In general, the binary representation is formed by using 1 for V  and 0 for A, from left to right, then suffixing 1. This technique [cf. K. D. Tocher, J.  Roy. Stat. Sot El6 (1954), 491 can lead to efficient generation of independent bits  having a given probability p, and it can also be applied to the geometric and binomial  distributions.  26. (a) True, c, Pr(N1 = k)Pr(Nz = 12 - k) = e-p1-@2(p1 + pz) /n!. (b) False,  unless ~2 = 0; otherwise iV1 -N2 might be negative.  27. Let the binary representation of p be (&#038;lb&#038;.. .)2, and proceed according to the  following rules:  Bl.  [Initialize.] Set m t t, N + 0, j + 1. (During this algorithm, m represents  the number of simulated uniform deviates whose relation to p is still unknown,  since they match p in their leading j-l bits; and N is the number of simulated  deviates known to be less than p.)   B2.  [Look at next column of bits.] Generate a random integer M with the  binomial distribution (m, a). (Now M represents the number of unknown  deviates that fail to match b3.) Set m t m -M, and if b3 = 1 set N +   N+M.   B3.  [Done?] If m = 0, or if the remaining bits (.b3+lb3+2.. .)z of p are all zero,  the algorithm terminates. Otherwise, set j + j f 1 and return to step B2. 1   [When bJ = 1 for infinitely many j, the average number of iterations At satisfies   A,, = 0; An=l+&#038;~ ; Ak, for n 2 1.   0  k   LettingA = zAnzn/n!, we haveA = e -l+A(~z)e /2. ThereforeA(z)e-  =   1  -  e-  + A( $z)e-Z/2 = Ck,0(l-e-Z/2 ) = 1-e-Z-C,,1(-z)n/(7z!(2n -l)),   and   A,=l+C ; E =1+t  V   0  n+l  k>l   in the notation of exercise 5.2.2.-48.1   28.  Generate a random point (~1,. . . , yn) on the unit sphere, and let p = dm.  Generate an independent uniform deviate U, and if pn+  U < K dm, output the   point (yl/p, . . . , y,/p); otherwise start over. Here K2 = min{ (c aky~) + /(~ a:~:) 1   Cy&#038;l}=a;--l f I nan >_ al, ((n + l)/(al f a7L))n+1(ulan/n)n otherwise.    <br />Please visit <a href="http://domain.g5websitehosting.com">Domain Name Hosting</a> services for high quality webhost to host and run your jsp applications.
</p>
]]></content:encoded>
			<wfw:commentRSS>http://j2ee.smartwebsitehosting.net/j2ee/free-web-hosting-with-ftp-341-answers-to-exercises-553-this-approach-applies/feed/</wfw:commentRSS>
		</item>
		<item>
		<title>552 ANSWERS TO EXERCISES 3.4.1 Bl. [Initialize.] Set  (Web site design)</title>
		<link>http://j2ee.smartwebsitehosting.net/j2ee/552-answers-to-exercises-341-bl-initialize-set-web-site-design/</link>
		<comments>http://j2ee.smartwebsitehosting.net/j2ee/552-answers-to-exercises-341-bl-initialize-set-web-site-design/#comments</comments>
		<pubDate>Wed, 26 Mar 2008 23:22:02 +0000</pubDate>
		<dc:creator>humphreyblogart</dc:creator>
		
	<category>J2EE</category>
		<guid isPermaLink="false">http://j2ee.smartwebsitehosting.net/j2ee/552-answers-to-exercises-341-bl-initialize-set-web-site-design/</guid>
		<description><![CDATA[552 ANSWERS TO EXERCISES  3.4.1   Bl.  [Initialize.] Set N +-0, q + pt, r +-q, and generate a random uniform  deviate U. (We will have q = pN and r = po + . . . + pN during this  algorithm, which stops as soon as U < r.) [...]]]></description>
			<content:encoded><![CDATA[<p>552 ANSWERS TO EXERCISES  3.4.1   Bl.  [Initialize.] Set N +-0, q + pt, r +-q, and generate a random uniform  deviate U. (We will have q = pN and r = po + . . . + pN during this  algorithm, which stops as soon as U < r.)   B2.  [Search.] If ZJ 2 r, set N +-- N + 1, q t q(l -p)(t -1 $ N)/iV, r +-r $ q,  and repeat this step. m   [An interesting technique for the negative binomial distribution, for arbitrarily  large real values of t, has been suggested by R. L6ger: First generate a random gamma  deviate X of order t, then let iV be a random Poisson deviate of mean X(1 -p)/p.]   20. Rl = 1 + (1 -A/R) . Rl. When R2 is performed, the algorithm terminates with  probability I/R; when R3 is performed, it goes to Rl with probability E/R. We have  Rl RIA RIA RIA WA  R2 0 WA 0 RIA  R3 0 0 WA R/A -I/A  R4 WA R/A -I/A R/A-E/A R/A -I/A -E/A   21. R = fi z 1.71153; A = fl F=Z1.25331. Since  Ju&#038;=&#038;i du = (a -b~)~ ( $(a -bu) -3)/b2,   we have I = soaib ud= du = =a 5f2/b2 where a = 4(1 + In c) and b =  4  4c; when   c = e114, I has its maximum value g fi Z=Z 1.13020. Finally the following integration  formulas are needed for E:   JJbu--au2du = ib2a-3/2arcsin(2ua/b -1) + $ba- dn(2ua/b -l),  Jdwdu= -&#038;b2a-3f21n(~~+u&#038;+b/2JSi)   + +ba- dv(2ua/b + l),   where a, b > 0. Let the test in step R3 be  X2 2 4e - /U -4x ; then the  exterior region hits the top of the rectangle when u = T(X) = (eZ -de2= -2es)/2ez.  (Incidentally, T(Z) reaches its maximum value at z = l/2, a point where it is not,   differentiable!) We have E = ~~   (~ -m) du where b = 4eZe1 and  a = 4x. The maximum value of E occurs near x = &#8211;.35, where we have E FZ .29410.   22. (Solution by G. Marsaglia.) Consider the  continuous Poisson distribution  de- fined by G(s) = s,  emttz-  dt/r(z), for z > 0; if X has this distribution then  1&#215;1 is Poisson distributed, since G(z + 1) -G(z) = e-  @Z/s!. If p is large, G is  approximately normal, hence G-l(F,(x)) is approximately linear, where F,(Z) is the  distribution function for a normal deviate with mean and variance p; i.e., Fp(z) =  F((x -~)ldF), w here F(z) is the normal distribution function (10). Let g(x) be an  efficiently computable function such that IG- (F,(x)) -g(x)/ < 6 for -co < 3: < 00;  we can now generate Poisson deviates efficiently as follows: Generate a normal deviate  X,andset~tg(~++X),Nt~YJ,M~~Y+~~.If(Y-~~>~,outputN;  otherwise output M -1 or M, according as G- (F(X)) < M or not.    <br />Check <a href="http://domain.tomcatjavahosting.com">Tomcat Web Hosting</a> services for best quality webspace to host your web application.
</p>
]]></content:encoded>
			<wfw:commentRSS>http://j2ee.smartwebsitehosting.net/j2ee/552-answers-to-exercises-341-bl-initialize-set-web-site-design/feed/</wfw:commentRSS>
		</item>
		<item>
		<title>3.4.1 ANSWERS TO EXERCISES 551 13.  (Web server application) Take b,</title>
		<link>http://j2ee.smartwebsitehosting.net/j2ee/341-answers-to-exercises-551-13-web-server-application-take-b/</link>
		<comments>http://j2ee.smartwebsitehosting.net/j2ee/341-answers-to-exercises-551-13-web-server-application-take-b/#comments</comments>
		<pubDate>Wed, 26 Mar 2008 14:20:22 +0000</pubDate>
		<dc:creator>humphreyblogart</dc:creator>
		
	<category>J2EE</category>
		<guid isPermaLink="false">http://j2ee.smartwebsitehosting.net/j2ee/341-answers-to-exercises-551-13-web-server-application-take-b/</guid>
		<description><![CDATA[3.4.1  ANSWERS TO EXERCISES 551  13. Take b, = p3; consider now the problem with pL3 = 0 for each j. In matrix  notation, if Y = AX, where A = (a,,), we need AAT = C = (ct3). (In other  notation, if Y3 = c alkXk, then the average value [...]]]></description>
			<content:encoded><![CDATA[<p>3.4.1  ANSWERS TO EXERCISES 551  13. Take b, = p3; consider now the problem with pL3 = 0 for each j. In matrix  notation, if Y = AX, where A = (a,,), we need AAT = C = (ct3). (In other  notation, if Y3 = c alkXk, then the average value of YiY3 is c a,kajk.) If this matrix  equation can be solved for A, it can be solved when A is triangular, since A = BU  for some orthogonal matrix U and some triangular B, and BBT = C. The desired  triangular solution can be obtained by solving the equations ufl = ~11, alla21 = c12,  a21  2  + a22  2  = c22, alla31 = c13, a21a31 $-a22a32 = c23, . . , successively for all, a21,   ~22, ~31, ~32, etc. [Note: The covariance matrix must be positive semidefinite, since  the average value of (c y,Y,)  is c c%,y,yj, which must be nonnegative. And there is  always a solution when C is positive semidefinite, since C = U- diag(Al, . . . , X,)U,  where the eigenvalues X, are nonnegative, and U- diag(&#038;, . . . , &#038;)U is a solution.]   14. F(s/c) if c > 0, a step function if c = 0, and 1 -F(z/c) if c < 0.  15. Distribution s- , Fl(z -t) &#038;72(t). Density s- , fl(l: -t)fi(t) dt. This is called  the convolution of the given distributions.  16. It is clear that f(t) 2 cg(t) f or all t as required. Since sooo g(t) dt = 1 we have  g(t) = CtaP1 for 0 5 t < 1, Cc-t for t 2 1, where C = ue/(u + e). A random  variable with density g is easy to obtain as a mixture of two distributions, Gl(z) = za  for 0 5 z < 1, and Gz(s) = 1 -e -% for 5 2 1:  Gl.  [Initialize.] Set p +-e/(u + e). (This is the probability that G1 should be  used.)   G2.  [Generate G deviate.] Generate independent uniform deviates U, V, where  V # 0. If U < p, set X +-V lfa and q + ePX; otherwise set X + 1 -In V  and q + X - . (Now X has density g, and q = f(X)/cg(X).)   G3.  [Reject?] Generate a new uniform deviate U. If U 2 q, return to G2. m   The  average number of iterations is c = (a + e)/(er(a + 1)) < 1.4.   It is possible to streamline this procedure in several ways. First, we can replace  V by an exponential deviate Y of mean 1, generated by Algorithm S, say, and then  we set X + ePy  or X + 1 + Y in the two cases. Moreover, if we set q t pe-*  in the first case and q t p + (1 -p)X -  in the second, we can use the original U  instead of a newly generated one in step G3. Finally if U < p/e we can accept V la  immediately, avoiding the calculation of q about 30 percent of the time.   17. (a) F(z) = 1 -(1 -p)   , for z 2 0. (b) G(z) = pz/(l -(1 -p)z). (c)  Mean l/p, standard deviation m/p. To do the latter calculation, observe that if  H(z) = q + (1 -q)z, then H (1) = 1 -q and H (1) + H (1) -(H (1))2 = q(l -q),  so the mean and variance of l/H(z) are q -1 and q(q -l), respectively. (See Section   1.2.10.) In this case, q = l/p; the extra factor z in the numerator of G(z) increases  the mean by one.   18. Set N c Nl + NZ -1, where N1 and NZ independently have the geometric  distribution for probability p. (Consider the generating function.)  19. Set N + N1 +. . . + Nt -t, where the Nj have the geometric distribution for p.  (This is the number of failures before the tth success, when a sequence of independent  trials are made each of which succeeds with probability p.)  Fort=p= f, and in general when the mean value (namely t(1 -p)/p) of the  distribution is small, we can simply evaluate the probabilities pn = ( -iWn)p (l -p)   consecutively for n = 0, 1, 2, . . . as in the following algorithm:    <br />Please visit <a href="http://domain.g5websitehosting.com">Domain Name Hosting</a> services for high quality webhost to host and run your jsp applications.
</p>
]]></content:encoded>
			<wfw:commentRSS>http://j2ee.smartwebsitehosting.net/j2ee/341-answers-to-exercises-551-13-web-server-application-take-b/feed/</wfw:commentRSS>
		</item>
		<item>
		<title>550 ANSWERS  (Free web hosts) TO EXERCISES 3.4.1 7. If Ic</title>
		<link>http://j2ee.smartwebsitehosting.net/j2ee/550-answers-free-web-hosts-to-exercises-341-7-if-ic/</link>
		<comments>http://j2ee.smartwebsitehosting.net/j2ee/550-answers-free-web-hosts-to-exercises-341-7-if-ic/#comments</comments>
		<pubDate>Wed, 26 Mar 2008 04:14:40 +0000</pubDate>
		<dc:creator>humphreyblogart</dc:creator>
		
	<category>J2EE</category>
		<guid isPermaLink="false">http://j2ee.smartwebsitehosting.net/j2ee/550-answers-free-web-hosts-to-exercises-341-7-if-ic/</guid>
		<description><![CDATA[550 ANSWERS TO EXERCISES 3.4.1   7. If Ic = 1, then nl = n and the problem is trivial. Otherwise it is always possible  to find i # j such that n, 5 n 5 nj. Fill Bi with n, cubes of color Ci and n -n2  of color Cj, then [...]]]></description>
			<content:encoded><![CDATA[<p>550 ANSWERS TO EXERCISES 3.4.1   7. If Ic = 1, then nl = n and the problem is trivial. Otherwise it is always possible  to find i # j such that n, 5 n 5 nj. Fill Bi with n, cubes of color Ci and n -n2  of color Cj, then decrease n3 by n -ni and eliminate color C,. We are left with the  same sort of problem but with k reduced by 1; by induction, it s possible.  The following algorithm can be used to compute the P and Y tables: Form a list of  pairs (pi, 1). . . (pk, Ic) and sort it by first components, obtaining a list (91, al). (qk, ak)  where q1 2 &#8230; 2 qk and n = k. Repeat the following operation until n = 0: Set  P[al -l] t kql and Y[ai -l] + za,. Delete (41, ai) and (qn, a,), then insert the  new entry (q,, -(l/k -ql), a,) into its proper place in the list and decrease n by 1.   (If p, 5 l/k the algorithm will never put xj in the Y table; this fact is used  implicitly in Algorithm M. The algorithm attempts to maximize the probability that  V < PK in (3), by always robbing from the richest remaining element and giving it  to the poorest. However, it is very difficult to determine the absolute minimum of this  probability, since such a task is at least as difficult as the  bin-packing problem ; cf.  Chapter 7.)   8. Replace P3 by (j + Pj)/k for 0 5 j < k.  9. Consider the sign of f (s) = m (x2 -l)e-Z2/2.  10. Let S j = (j -1)/5 for 1 2 j 2 16 and pj+ls = F(S,+i) -F(Sj) -p, for  1 < j 5 15; also let ps1 = 1 -F(3) and psz = 0. (Eq. (15) defines pl, . . . , ~~5.) The  algorithm of exercise 7 can now be used with k = 32 to compute P3 and Yj, after which  we will have 1 5 Y3 2 15 for 1 < j 2 32. Set PO + P32 (which is 0) and Yc + Y32.  Then set 2, + l/(5 -5Pj) and Yj + SYj -2, for 0 < j < 32; Q3 + 1/(5Pj) for  1 2 j 5 15.  Let h = 3 and f3+15(x) = ~(~--za 2-~-jz 50)/pj+~~ for S j 5 x 5 S,+h.  Then let a3 = f3+is(SJ) for 1 5 j 5 5, bj = fJ+ls(Sj) for 6 2 j 2 15; also b, =  44+,5 (Sj +h) for 1 5 j 5 5, and o3 = fj+15(xJ)+(xj-Sj)bj/h for 6 5 j 2 15,  where x3 is the root of the equation f:+ls(Zj) = -b,lh. Finally set D3+15 t ajlbj   for 1 5 j 5 15 and &#038;+ls + 25/j for 1 5 j 5 5, E3+i5 t l/(e(2j-1)/50 -1) for  6 5 j 5 15.   Table 1 was computed while making use of the following intermediate values:  (PI,. . . ,psi) = (.156, .147, .133, .116, .097, .078, .060, .044, .032, .022, .014, ,009, .005,  .003, .002, .002, .005, .007, .009, .OlO, .009, .009, .008, .006, .005, ,004, .002, .002, .OOl,  .OOl, .003); (X6,. . . ,x15) = (1.115, 1.304, 1.502, 1.700, 1.899, 2.099, 2.298, 2.497, 2.697,  2.896); (al,. . . ,u15) = (7.5, 9.1, 9.5, 9.8, 9.9, 10.0, 10.0, 10.1, 10.1, 10.1, 10.1, 10.2,  10.2, 10.2, 10.2); bl,..., bls) = (14.9, 11.7, 10.9, 10.4, 10.1, 10.1, 10.2, 10.3, 10.4, 10.5,  10.6, 10.7, 10.7, 10.8, 10.9).   11. Let g(t) = eg12te-t2/2 for t > 3. Since G(x) = 1: g(t) dt = 1 -e-(22-g)/2, a  random variable X with density g-can be computed by setting X + G- (1 -V) =  49 -21nV. Now e- /  2 (t/3)e-t2/2 for t > 3, so we obtain a valid rejection  method if we accept X with probability f(X)/cg(k) = 3/X.   12. We have f (x) = xf(x)-1 < 0 for x 2 0, since f(x) = x-1-e22/2 ~zme-t2/2 dt/t2  for z > 0. Let x = u3-l and y2 = x2 + 2ln2; then  fiSyo0 e-t2/2 dt = 3 fie-z 12f(y) < 3fie-Z2/2f(x) = 2-j,   hence y > oj.    <br />We recommend high quality webhost to host and run your jsp application: <a href="http://jsp.tomcatjavahosting.com">christian web host</a> services.
</p>
]]></content:encoded>
			<wfw:commentRSS>http://j2ee.smartwebsitehosting.net/j2ee/550-answers-free-web-hosts-to-exercises-341-7-if-ic/feed/</wfw:commentRSS>
		</item>
		<item>
		<title>3.4.1 ANSWERS TO EXERCISES 549 Circle U2+ V2=  (Web server info)</title>
		<link>http://j2ee.smartwebsitehosting.net/j2ee/341-answers-to-exercises-549-circle-u2-v2-web-server-info/</link>
		<comments>http://j2ee.smartwebsitehosting.net/j2ee/341-answers-to-exercises-549-circle-u2-v2-web-server-info/#comments</comments>
		<pubDate>Tue, 25 Mar 2008 17:19:54 +0000</pubDate>
		<dc:creator>humphreyblogart</dc:creator>
		
	<category>J2EE</category>
		<guid isPermaLink="false">http://j2ee.smartwebsitehosting.net/j2ee/341-answers-to-exercises-549-circle-u2-v2-web-server-info/</guid>
		<description><![CDATA[3.4.1 ANSWERS TO EXERCISES 549  Circle U2+ V2= 1  Fig. A-4. Region of  acceptance   for the algorithm of exercise 6.    SECTION 3.4.1   1. Q: + (p -cx)U.  2.LetU=Xlm;~kU]=riffr~kX/m]]></description>
			<content:encoded><![CDATA[<p>3.4.1 ANSWERS TO EXERCISES 549  Circle U2+ V2= 1  Fig. A-4. Region of  acceptance   for the algorithm of exercise 6.    SECTION 3.4.1   1. Q: + (p -cx)U.  2.LetU=Xlm;~kU]=riffr~kX/m<r+liffmr/k~X<m(r+l)/k  iff [mr/kl 5 X < [rn(r + 1)/k]. Th e exact probability is given by the formula  (l/m)([m(r + l)/kl -[mr/kl) = l/k + E, where 1~1 < l/m.   3. If full-word random numbers are given, the result will be sufficiently random as in  exercise 2. But if a linear congruential sequence is used, k must be relatively prime to  the modulus m, lest the numbers have a very short period, by the results of Section  3.2.1.1. For example, if k = 2 and m is even, the numbers will at best be alternately 0  and 1. The method is slower than (1) in nearly every case, so it is not recommended.  4. max(Xr , Xz) 5 5 if and only if Xi 5 z and Xz 5 Z; min(Xr, X2) 2 z if and  only if Xr 2 x and Xz 2 x. The probability that two independent events both happen  is the product of the individual probabilities.  5. Obtain independent uniform deviates Ui, Uz. Set X +-UZ. If Ur 2 p, set  X + max(X, Us), where U3 is a third uniform deviate. If U1 2 p + q, also set  X +-max(X, Ud), where U4 is a fourth uniform deviate. This method can obviously  be generalized to any polynomial, and indeed even to infinite power series (as shown  for example in Algorithm S, which uses minimization instead of maximization).  We could also proceed as follows (suggested by M. D. MacLaren): If U1 < p, set  X + Ul/p; otherwise if UI < p + q, set X t max((Ui -p)/q, Uz); otherwise set  X + max((Ur -p -q)/r, Us, Us). This method requires less time than the other to  obtain the uniform deviates, although it involves further arithmetical operations and  it is slightly less stable numerically.   6. F(x)  = Al/(Al -+-AZ), where A1 and  A2 are the areas in Fig. A-4; so  F(x) = So  G dy = 2 arcsin x  +  ?xdg.  lr   so1 di=-ihy T   The probability of termination at step 2 is p = 7r/4, each time step 2 is encountered, so  the number of executions of step 2 has the geometric distribution. The characteristics  of this number are (min 1, ave 4/7r, max co, dev (4/7r)Jm), by exercise 17.    <br />If you are looking for cheap and quality webhost to host and run your website check <a href="http://php5.g5websitehosting.com">Jboss Web Hosting</a> services.
</p>
]]></content:encoded>
			<wfw:commentRSS>http://j2ee.smartwebsitehosting.net/j2ee/341-answers-to-exercises-549-circle-u2-v2-web-server-info/feed/</wfw:commentRSS>
		</item>
		<item>
		<title>548 ANSWERS TO EXERCISES 3.3.4 28. Let 5  (Web hosting billing)</title>
		<link>http://j2ee.smartwebsitehosting.net/j2ee/548-answers-to-exercises-334-28-let-5-web-hosting-billing/</link>
		<comments>http://j2ee.smartwebsitehosting.net/j2ee/548-answers-to-exercises-334-28-let-5-web-hosting-billing/#comments</comments>
		<pubDate>Tue, 25 Mar 2008 07:11:55 +0000</pubDate>
		<dc:creator>humphreyblogart</dc:creator>
		
	<category>J2EE</category>
		<guid isPermaLink="false">http://j2ee.smartwebsitehosting.net/j2ee/548-answers-to-exercises-334-28-let-5-web-hosting-billing/</guid>
		<description><![CDATA[548 ANSWERS TO EXERCISES 3.3.4   28. Let 5 = ezrz (m-l) and let Ski = CO]]></description>
			<content:encoded><![CDATA[<p>548 ANSWERS TO EXERCISES 3.3.4   28. Let 5 = ezrz (m-l) and let Ski = CO<j<m--l w~J+~<~~. The analog of (51) is  ]Ske] = &#038;ii, hence the analog of (53) is ]N-  CO<n<N~Zn] = O((filogm)/N). -  The analogous theorem now states that   D(t) = 0 fi(logm)t+  + o((l g )  ) D(t)   N 0 m rmax , m-l = O((logm)t rmax).  N  ( >   In fact, DEL1 5 H c T(ZL~, , Ut) [summed over nonzero solutions of (15)] +   G&#038;C?-(Ul,&#8230;, ut) [summed over all nonzero (pi, . . . , ut)]. The latter sum is O(log m)t  by exercise 25 with d = 1, and the former sum is treated as in exercise 27.   Let us now consider the quantity R(a) = cr(~l,. . . , ut) summed over nonzero  solutions of (15). Since m is prime, each (~1,. , ut) can be a solution to (15) for at  most t -1 values of a, hence xO<a<m R(a) 5 (t -1) C T(zLi, . . , Ut) = O(t(logm)t).  It follows that the average value of R(a) taken over all cp(m -1) primitive roots is   O(Qxm)tl(o(m -1)).   Note: In general l/p(n) = O(loglogn/n); we have therefore proved that for all  prime m and for all T there exists a primitive root a modulo m such that the linear  congruential sequence (1, a, 0, m) has discrepancy DE)-1 = O(m- T(log m)  log log m)  for 1 5 t 5 T. This method of proof does not extend to a similar result for linear con- gruential generators of period 2e modulo 2e, since for example the vector (1, -3,3, -1)  solves (15) for about 22 /3 values of a.   29. u: + ... + u,  2 V: 2 2(t -1) implies that p(ul). . . p(ut) 2 4-j 2  ut/fi, in the notation of exercise 27.  30. We wish to minimize qlaq-mp] for 1 5 q < m and 0 5 p < a. In the notation of  exercise 4.5.3-42, we have aq, -mp, = (-l)nQ,-,-l(an+z,. . , a,) for 0 < n < s.  In the range q,-1 5 q < qn we have ]aq -mp] 2 ]aq,-i -mp,-11; con&#038;que%ly  qlaq -mpl 2 qn--l]aqn---l-mp+i], and the minimum is minsln<a qnlaqn-mp,l =  minosn<s Q,(al,. . . , an)&#038;++-l(an+z,. , a,). By exercise 4.5.3-32 we have m =  an)an+lQs--n--l(an+2,. , a,) + Q,(al, . , an)Qs-+-2(an+3,. . ,a,) +  ::,!rlyci;;. . . , an-i)Qs-n-ljan+z,. . , as); and our problem is essentially that of max-  imizmg the quantity m/Q,(al, . . . , a,)&#038;,-,-r(n+2, . . . , as), which lies between a,+l  and anfl + 2.   31. Equivalently, the conjecture is that all large m can be written m = Q,(ai, . , a,)  for some n and some a, E {1,2,3}. For fixed n the 3  numbers Q,(ai, . . . , a,) have an  average value of order (1 + &#038;? ) , and their standard deviation is of order (2.51527)n;  so the conjecture is almost surely true. S. K. Zaremba conjectured in 1972 that all m  can be represent,ed with a, 5 5; T. W. Cusick made some progress on this problem in  Mathematika 24 (1977), 1666172. It appears that only the cases m = 54 and m = 150  require az = 5, and the largest m s that require 4 s are 2052, 2370, 5052, and 6234; at  least, the author has found representations with a, 5 3 for all other integers less than  2000000. When we require ai 2 2, the average of Qn(ai, . , a,) is + 2  + &#038;(-2)- ,  while the standard deviation grows as (2.04033) . The density of such numbers in the  author s experiments (which considered 26 blocks of 214 numbers each, for m 5 2 )  appears to vary between .50 and .65.  [See I. Borosh and H. Niederreiter, to appear, for a computational method that  finds multipliers with small partial quotients. They have found 2-bounded solutions  with m = 2  for 25 5 e 5 35.1    <br />From our experience, we are can tell you that you can find a reliable and cheap webhost service at <a href="http://www.tomcatjavahosting.com">Java Web Hosting</a> services.
</p>
]]></content:encoded>
			<wfw:commentRSS>http://j2ee.smartwebsitehosting.net/j2ee/548-answers-to-exercises-334-28-let-5-web-hosting-billing/feed/</wfw:commentRSS>
		</item>
		<item>
		<title>3.3.4 ANSWERS TO EXERCISES 547 S4  . [Advance  (Christian web host)</title>
		<link>http://j2ee.smartwebsitehosting.net/j2ee/334-answers-to-exercises-547-s4-advance-christian-web-host/</link>
		<comments>http://j2ee.smartwebsitehosting.net/j2ee/334-answers-to-exercises-547-s4-advance-christian-web-host/#comments</comments>
		<pubDate>Mon, 24 Mar 2008 19:13:30 +0000</pubDate>
		<dc:creator>humphreyblogart</dc:creator>
		
	<category>J2EE</category>
		<guid isPermaLink="false">http://j2ee.smartwebsitehosting.net/j2ee/334-answers-to-exercises-547-s4-advance-christian-web-host/</guid>
		<description><![CDATA[3.3.4  ANSWERS TO EXERCISES 547  S4  .  [Advance t.] If t = T, the algorithm terminates. Otherwise set t c t + 1 and R t  R( T i)modm. Set Ut to the new row (-Qz, -r22,0,. . . ,0, 1) of t elements, and  set uZt e 0 [...]]]></description>
			<content:encoded><![CDATA[<p>3.3.4  ANSWERS TO EXERCISES 547  S4  .  [Advance t.] If t = T, the algorithm terminates. Otherwise set t c t + 1 and R t  R( T i)modm. Set Ut to the new row (-Qz, -r22,0,. . . ,0, 1) of t elements, and  set uZt e 0 for 1 2 i < t. Set Vt to the new row (0,. . . ,O, m). For 1 5 i < t, set  q + round((v,lrls + v,m2)/m), vat + 0~1~2 + ~~2~22 -qm, and Ut + Ut + qJX.   Finally set s + min(s, Ut Ut), Jc + t, j + 1.   [A similar generalization applies to all sequences of length pk -1 defined by Eq.  3.2.2-8. Additional numerical examples have been given by A. Grube, Zeitschrift fiir  angewandte Math. und Mechanik 53 (1973), T223-T225.1   25.  The given sum is at most two times the quantity ~O<k<m,zdr(dk) = 1 +  a f(m/d), where   f(m) = i C csc(nk/m)   l<k<m/2   =- 1 Jml2  csc(rz/m)dz+O(~)= ~lntan(&#038;x)l:/ +O(~).   m  I   [When d = 1, we have COCk<,,, r(k) = (2/7r) In  m  + 1 + (2/7r) ln(2e/r) + 0(1/m).]  -  26. When m = 1, we cannot use (52) since k will be zero. If gcd(q, m) = d, the same  derivation goes through with m replaced by m/d. Suppose we have m = pi . . p:   and gcd(a -1, m) = pf . . .pfi and d = pf . . p,  . If m is replaced by m/d, then s is  replaced by p~ax(O.el-fl-dl), ,p,m=(O,e~-f~--dv).   27. It is convenient to use the following functions: p(x) = 1 if x = 0, p(x) = x if  0 < x 2 m/2, p(x) = m -x if m/2 < x < m; trunc(x) = 1x/2] if 0 5 x 2 m/2,  trunc(x) = m -L(m -x)/2] if m/2 < 5 < m; L(x) = 0 if x = 0, L(x) = ]lg x] + 1 if  0 < x 5 m/2, L(x) = -([lg(m-x)J+l) if m/2 < x < m; and J(x) = max(1, 21Z1-l).  Note that J(L(x)) < p(x) < 2J(L(x)) and p(x) 5 msin(Tx/m) < rip(x) for 0 < x < m.  Say that a vector (~1,. . . , ut) is bad if it is nonzero and satisfies (15); and let pmax  be the maximum value of p(ul) . . . p( ut ) over all bad (~1,. . . , ut). The vector (~1,. , ut)  is said to be in class (L(ui), . . . , L(ut)). Thus there are at most (2 lg m+ l)t classes, and  class (L1 , . . . , Lt) contains at most J(Lr) . . . J(L t ) vectors. Our proof is based on showing  that the bad vectors in each fixed class contribute only 0(1/p,,,) to c ~(ui, . . , it);  this proves even more than was asked, since l/p,,, 2 rrtrmaX.   Let p = ]lgp,,,J. The p-fold truncation operator on a vector is defined to be  the following operation repeated p times:  Let j be minimal such that p(u3) > 1,  and replace uj by trunc(u,); but do nothing if p(u3) = 1 for all j.  (This operation  essentially throws away one bit of information about (~1, . . . , it).) If (u:, . . . , u:) and  (u:, . . , uy) are two vectors of the same class having the same p-fold truncation, we say  they are similar; in this case it follows that p(u: -Us). . . p(u: -u:) < 2   < pmax. For  example, any two vectors of the form ((lxzxr)z, 0, m -(1x3)2, (lOlxsx4)2, (1101)~) are  similar when m is large and p = 5; the p-fold truncation operator successively removes  xi, x2, xs, x4, 5s. Since the difference of two bad vectors satisfies (15), it is impossible  for two unequal bad vectors to be similar. Therefore class (Li, . , Lt) can contain  at most max(1, J(L1). J(Lt)/2P) bad vectors. If class (Li, . . . , Lt) contains exactly  one bad vector (ul,. . . , Q), we have r(ul,. . ,~t) 5 rmax 5 l/pmax; if it contains  5 J(L1). . . J(Lt)/2* bad vectors, each of them has T(u~, . . . ,ut) 5 l/p(~i). . .p(ut) 5  l/J&#038;l). J&#038;t).    <br />We recommend cheap and reliable webhost to host and run your web applications: <a href="http://coldfusion.tomcatjavahosting.com">Coldfusion Web Hosting</a> services.
</p>
]]></content:encoded>
			<wfw:commentRSS>http://j2ee.smartwebsitehosting.net/j2ee/334-answers-to-exercises-547-s4-advance-christian-web-host/feed/</wfw:commentRSS>
		</item>
		<item>
		<title>Web domain - 546 ANSWERS TO EXERCISES 3.3.4 matrices; thus the</title>
		<link>http://j2ee.smartwebsitehosting.net/j2ee/web-domain-546-answers-to-exercises-334-matrices-thus-the/</link>
		<comments>http://j2ee.smartwebsitehosting.net/j2ee/web-domain-546-answers-to-exercises-334-matrices-thus-the/#comments</comments>
		<pubDate>Mon, 24 Mar 2008 08:14:57 +0000</pubDate>
		<dc:creator>humphreyblogart</dc:creator>
		
	<category>J2EE</category>
		<guid isPermaLink="false">http://j2ee.smartwebsitehosting.net/j2ee/web-domain-546-answers-to-exercises-334-matrices-thus-the/</guid>
		<description><![CDATA[546 ANSWERS TO EXERCISES  3.3.4   matrices; thus the two-dimensional case will be handled by the general method. A  special procedure for t = 2 could, of course, be devised.) In steps S4 and S8, set  s + min(s, ]Uk]). In step S8, set zk + lmaxl~j~t IwkjIs/m]. In step slo, [...]]]></description>
			<content:encoded><![CDATA[<p>546 ANSWERS TO EXERCISES  3.3.4   matrices; thus the two-dimensional case will be handled by the general method. A  special procedure for t = 2 could, of course, be devised.) In steps S4 and S8, set  s + min(s, ]Uk]). In step S8, set zk + lmaxl~j~t IwkjIs/m]. In step slo, set s +  min(s, ]Y( -6); and in step Sll, output s = Nt. Otherwise leave the algorithm as  it stands, since it already produces suitably short vectors. [Math. Comp. 29 (1975)  827-833.1   17. When k > t in SlO, and if Y .Y 2 s, output Y and -Y; furthermore if Y .Y < s,  take back the previous output of vectors for this t. [In the author s experience preparing  Table 1, there was exactly one vector (and its negative) output for each vt, except when  yl = 0 or yt = 0.1  18.  (a)  Let 5 = m, y = (1 -m)/3, vZj = y + x&#038;j, uij = -y + 6ii. Then V, . Vj =  *(m  -1) for j # Ic, vk. vk = $(m2 + JJ), u, . u, = $(m  + 2), zk M Am. (This  example satisfies (28) with a = 1 and works for all m G 1 (modulo 3).)   (b) Interchange the roles of U and V in step S5. Also set s + min(s, Ui. Vi) for all  U, that change. For example, when m = 64 this transformation with j = 1, applied  to the matrices of (a), reduces  v=  -21  y: 2; Z), u=(f :; Z)  (  to   v=  (  -21 l 4: -2q, u=g  ;  p).  -21 -21 43   [Since the transformation can increase the length of V,, an algorithm that incorporates  both transformations must be careful to avoid infinite looping. See also exercise 23.1   19. No, since a product of non-identity matrices with all off-diagonal elements non- negative and all diagonal elements 1 cannot be the identity.  [However, looping would be possible if a subsequent transformation with CJ = -1  were performed when -2V,. V, = V, . V.; the rounding rule must be asymmetric with  respect to sign if non-shortening transformations are allowed.]   20. Use the ordinary spectral test for a and m = 2e-2; cf. exercise 3.2.1.2-9. [On  intuitive grounds, the same answer should apply also when a mod 8 = 3.1  21. Xdn+4 E X4, (modulo 4) so it is now appropriate to let VI = (4, 4a2, 4a3)/m,  V2 = (0, 1, 0), V3 = (0, 0,l) define the corresponding lattice LO.  24. Let m = p; an analysis paralleling the text can be given. For example, when  t = 4 we have Xn+s = ((u  + b)Xn+l + abX,)modn, and we want to minimize  uf + uz + uz + ui # 0 such that ui + bug + abud E u2 + aus + (a  + b)uq = 0  (modulo m).  Replace steps Sl through S3 by the operations of setting   and outputting ~2 = m. Replace step S4 by    <br />Looking for affordable and reliable webhost to host and run your business application? Then look no more and go to <a href="http://mysql5.smartwebsitehosting.net">servlet web hosting</a> services.
</p>
]]></content:encoded>
			<wfw:commentRSS>http://j2ee.smartwebsitehosting.net/j2ee/web-domain-546-answers-to-exercises-334-matrices-thus-the/feed/</wfw:commentRSS>
		</item>
	</channel>
</rss>
