Pell numbers: Difference between revisions

Content added Content deleted
(Added Oberon-07)
(→‎{{header|ALGOL W}}: Correct output)
Line 321: Line 321:
<pre style="height:40ex;overflow:scroll;">
<pre style="height:40ex;overflow:scroll;">
First 10 Pell numbers: 0 1 2 5 12 29 70 169 408 985
First 10 Pell numbers: 0 1 2 5 12 29 70 169 408 985
First 10 Pell-Lucas numbers: 2 2 6 14 34 82 198 478 1154 2786


First 10 Pell-Lucas numbers: 2 2 6 14 34 82 198 478 1154 2786
First 10 rational approximations of sqrt(2) (1.414213):
First 10 rational approximations of sqrt(2) (1.414214):
1/1 ~= 1.000000
1/1 ~= 1.000000
3/2 ~= 1.500000
3/2 ~= 1.500000
7/5 ~= 1.400000
7/5 ~= 1.400000
17/12 ~= 1.416666
17/12 ~= 1.416667
41/29 ~= 1.413793
41/29 ~= 1.413793
99/70 ~= 1.414285
99/70 ~= 1.414286
239/169 ~= 1.414201
239/169 ~= 1.414201
577/408 ~= 1.414215
577/408 ~= 1.414216
1393/985 ~= 1.414213
1393/985 ~= 1.414213


Line 346: Line 346:


First 10 near isosceles right triangles:
First 10 near isosceles right triangles:
[2, 3, 5]
[3, 4, 5]
[12, 13, 29]
[20, 21, 29]
[70, 71, 169]
[119, 120, 169]
[408, 409, 985]
[696, 697, 985]
[2378, 2379, 5741]
[4059, 4060, 5741]
[13860, 13861, 33461]
[23660, 23661, 33461]
[80782, 80783, 195025]
[137903, 137904, 195025]
[470832, 470833, 1136689]
[803760, 803761, 1136689]
[2744210, 2744211, 6625109]
[4684659, 4684660, 6625109]
[15994428, 15994429, 38613965]
[27304196, 27304197, 38613965]
</pre>
</pre>