Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
11
Task/Yellowstone-sequence/Zkl/yellowstone-sequence-1.zkl
Normal file
11
Task/Yellowstone-sequence/Zkl/yellowstone-sequence-1.zkl
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
fcn yellowstoneW{ // --> iterator
|
||||
Walker.zero().tweak(fcn(a,b){
|
||||
foreach i in ([1..]){
|
||||
if(not b.holds(i) and i.gcd(a[-1])==1 and i.gcd(a[-2]) >1){
|
||||
a.del(0).append(i); // only keep last two terms
|
||||
b[i]=True;
|
||||
return(i);
|
||||
}
|
||||
}
|
||||
}.fp(List(2,3), Dictionary(1,True, 2,True, 3,True))).push(1,2,3);
|
||||
}
|
||||
2
Task/Yellowstone-sequence/Zkl/yellowstone-sequence-2.zkl
Normal file
2
Task/Yellowstone-sequence/Zkl/yellowstone-sequence-2.zkl
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
println("The first 30 entries of the Yellowstone permutation:");
|
||||
yellowstoneW().walk(30).concat(", ").println();
|
||||
6
Task/Yellowstone-sequence/Zkl/yellowstone-sequence-3.zkl
Normal file
6
Task/Yellowstone-sequence/Zkl/yellowstone-sequence-3.zkl
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
gnuplot:=System.popen("gnuplot","w");
|
||||
gnuplot.writeln("unset key; plot '-'");
|
||||
yellowstoneW().pump(1_000, gnuplot.writeln.fp(" ")); // " 1\n", " 2\n", ...
|
||||
gnuplot.writeln("e");
|
||||
gnuplot.flush();
|
||||
ask("Hit return to finish"); gnuplot.close();
|
||||
Loading…
Add table
Add a link
Reference in a new issue