Jump to content

Sturmian word: Difference between revisions

m
Line 27:
 
== {{header|Phix}} ==
Rational part translated from Python, quadratic part a modified fromcopy of the [[Continued fraction convergents]] task.
<!--(phixonline)-->
<syntaxhighlight lang="Phix">
Line 67:
sequence p = {0, 1},
q = {1, 0}
atom rrem = (sqrt(a)*b + m) / n,
rem = r
for i=1 to k do
integer whole = trunc(rem),
7,820

edits

Cookies help us deliver our services. By using our services, you agree to our use of cookies.