372 HISTORY OF THE THEORY OF NUMBERS. [CHAP, xn 



Dirichlet 115 noted that while k = gfp is positive, the determination of 

 the sign of h presents difficulties. He showed that h has the same sign as 



(kjph\ r- ,(n\i 



log I p- I = - A/p S I - I -, 

 \k-vp hj \p/n 



where n ranges over the positive integers not divisible by the prime p, and 

 the symbol (n/p) is Legendre's. 



C. d' Andrea 116 proved by use of continued fractions that x~ Dw 2 = l 

 is solvable. 



Dirichlet 117 noted that, if P is an integer > 1 not necessarily a prime, 



where & ranges over the integers <P and prime to P for which (&/P) = 1, 

 and F, Z are polynomials in x with integral coefficients. For x = l, let 

 Y and Z become the integers F x , Z\. Then, if e = 1 or VP according as the 

 number of prime factors of P is > 1 or = 1, 



where h is the number of classes of binary quadratic forms of determinant 

 P, and T, U give the least positive solutions of Z 2 Pw 2 = l. For example, 

 if P = 17, 



Zi = 8, e = 2, T = 33, 7 = 8, whence h = l. 

 G. W. Tenner 118 gave a convenient method to convert Va into a continued 

 fraction. Let a 2 be the largest square <a. Then proceed as for 

 o = 113 = 10 2 +13. 



I II III IV V VI 



10 X 10 113 13 



1, 7, 3, 9, 104, 8 



1, 5, 5, 25, 88, 11 



1, 4, 6, 36, 77, 7 



2, 2, 8, 64, 49, 7. 



Divide 10+10 by 13 and write the quotient 1 in column I and the re- 

 mainder 7 in II in the second line. Subtract 7 from a = 10 and write the 

 remainder 3 in III, and its square 9 in IV. Write the difference a 9 = 104 

 in V. Divide 104 by 13 (under VI in the preceding line) and write the 

 quotient 8 in VI. Similarly, to form the third row divide a +3 (3 of III) 

 by 8 (of VI) and write the quotient 1 in I and the remainder 5 in II ; sub- 

 tract it from a and write the remainder 5 in III, its square in IV, a 25 = 88 

 in V, and its quotient 11 by 8 (of VI) in VI. Continue until we find in VI 



116 Jour, fur Math., 18, 1838, 270; Wcrke, I, 371-2. 



116 Trattato elementare di aritmetica e d'algebra, II, 1840, 671, Naples. 



117 Jour, fiir Math., 21, 1840, 153-5; Werke, I, 493-G. 



118 Einige Bemerkungen iiber die Gleichung ax 2 1 = y-, Progr., Merseburg, 1841. 



