RosettaCodeData/Task/Pells-equation/00-TASK.txt

16 lines
701 B
Text
Raw Permalink Normal View History

2023-07-01 11:58:00 -04:00
'''Pell's equation''' &nbsp; (also called the '''PellFermat''' equation) &nbsp; is a &nbsp; [https://en.wikipedia.org/wiki/Diophantine_equation <u>Diophantine equation</u>] &nbsp; of the form:
:::::: <big> <b> x<sup>2</sup> &nbsp; - &nbsp; ny<sup>2</sup> &nbsp; = &nbsp; 1 </b> </big>
with integer solutions for &nbsp; '''x''' &nbsp; and &nbsp; '''y''', &nbsp; where &nbsp; '''n''' &nbsp; is a given non-square positive integer.
;Task requirements:
:* &nbsp; find the smallest solution in positive integers to Pell's equation for &nbsp; '''n''' = {61, 109, 181, 277}.
;See also:
:* &nbsp; Wikipedia entry: [https://en.wikipedia.org/wiki/Pell%27s_equation <u>Pell's equation</u>].
<br><br>