Short & Sweet Math Challenge #21: Powers that be
|
11-09-2016, 05:45 PM
Post: #22
|
|||
|
|||
RE: Short & Sweet Math Challenge #21: Powers that be
Following Paul's approach, I modified my Emu71 program to explore these solutions.
I kept the possibility for the least parameter a0 to be +/-1. Results: Order 2 1.61803398875 ok x^2-x-1 Order 3 1.83928675521 ok x^3-x^2-x-1 1.46557123188 ok x^3-x^2-1 1.32471795724 ok x^3-x-1 Order 4 1.92756197548 ok x^4-x^3-x^2-x-1 1.38027756910 ok x^4-x^3-1 Order 5 1.96594823665 ok x^5-x^4-x^3-x^2-x-1 1.88851884548 ok x^5-x^4-x^3-x^2-1 1.77847961614 ok x^5-x^4-x^3-x^2+1 1.81240361927 ok x^5-x^4-x^3-x-1 1.70490277604 ok x^5-x^4-x^3-1 1.44326879127 ok x^5-x^4-x^3+x^2-1 1.57014731220 ok x^5-x^4-x^2-1 1.53415774491 ok x^5-x^3-x^2-x-1 Order 6 1.98358284342 ok x^6-x^5-x^4-x^3-x^2-x-1 1.91118343669 ok x^6-x^5-x^4-x^3-x-1 1.80750202302 ok x^6-x^5-x^4-x^3+1 1.71428532914 ok x^6-x^5-x^4-x^2+1 1.74370016590 ok x^6-x^5-x^4-x-1 1.50159480354 ok x^6-x^5-x^4+x^2-1 1.66040772247 ok x^6-x^5-x^3-x^2-1 Order 7 1.99196419661 ok x^7-x^6-x^5-x^4-x^3-x^2-x-1 1.97504243425 ok x^7-x^6-x^5-x^4-x^3-x^2-1 1.92212800436 ok x^7-x^6-x^5-x^4-x^2-x-1 1.88004410997 ok x^7-x^6-x^5-x^4-x-1 1.85454747658 ok x^7-x^6-x^5-x^4-1 1.74745742449 ok x^7-x^6-x^5-x^4+x^3-1 1.77452005864 ok x^7-x^6-x^5-x^3-1 1.67752174784 ok x^7-x^6-x^5-x^2+1 1.65363458677 ok x^7-x^6-x^5-1 1.54521564973 ok x^7-x^6-x^5+x^2-1 1.60134733379 ok x^7-x^6-x^4-x^2-1 1.59000537390 ok x^7-x^5-x^4-x^3-x^2-x-1 Order 8 1.99603117974 ok x^8-x^7-x^6-x^5-x^4-x^3-x^2-x-1 1.97061782036 ok x^8-x^7-x^6-x^5-x^4-x^3-1 1.96113576083 ok x^8-x^7-x^6-x^5-x^4-x^3+1 1.92172206590 ok x^8-x^7-x^6-x^5-x^4+1 1.90988759678 ok x^8-x^7-x^6-x^5-x^4+x+1 1.88166942009 ok x^8-x^7-x^6-x^5-x^3+1 1.88670294847 ok x^8-x^7-x^6-x^5-x^2-x-1 1.86221396917 ok x^8-x^7-x^6-x^5-x-1 1.84771602509 ok x^8-x^7-x^6-x^5-1 1.83032136835 ok x^8-x^7-x^6-x^5+1 1.83524591514 ok x^8-x^7-x^6-x^4-x^3-x-1 1.74243322086 ok x^8-x^7-x^6-x^4+1 1.65524582449 ok x^8-x^7-x^6-x^2+1 1.57367896839 ok x^8-x^7-x^6+x^2-1 1.72778030821 ok x^8-x^7-x^5-x^4-x^3-x^2-1 1971 candidates (1<root<2) 48 candidates (dominant root) An interesting point is that solutions with the last parameter a0=+1 are found. If solutions are restricted to a0=-1, there are only 37 candidates. Another open point is that some solutions found by my pure numerical method are not there, for instance: 1.75487766625 ok x^4-x^3-x^2-1 My HP71 program (actually close to Gerson's program, but I explored all roots): 10 ! --- SSMC21 --- 20 OPTION BASE 0 @ DIM A(10) 30 C=0 @ C2=0 40 FOR D=2 TO 8 50 DISP "Order";D 60 DIM A(D) @ COMPLEX R(D-1) 70 A(0)=1 80 ! A(D)=-1 ! a0=-1 assumed... 90 K=3^(D-1) ! numbers of coefficient combinaisons 100 K=K*2 ! for a0=+/-1 110 FOR J=0 TO K-1 120 L=J 130 ! build the coefficients 140 IF MOD(L,2) THEN A(D)=1 ELSE A(D)=-1 ! for a0=+/-1 150 L=L DIV 2 ! for a0=+/-1 160 FOR I=D-1 TO 1 STEP -1 170 A(I)=MOD(L,3)-1 @ L=L DIV 3 180 NEXT I 190 ! find roots of polynomial A 200 MAT R=PROOT(A) 210 FOR K=0 TO D-1 220 X=REPT(R(K)) 230 IF IMPT(R(K))=0 AND X>1.000001 AND X<2 THEN GOSUB 300 240 NEXT K 250 NEXT J ! next polynomial of order D 260 NEXT D ! next order polynomials 270 DISP C;"candidates (1<root<2)" 280 DISP C2;"candidates (dominant root)" 290 END 300 'T': ! evaluate candidate 310 C=C+1 320 F=1 330 FOR I=0 TO D-1 340 IF I<>K AND ABS(R(I))>=1 THEN F=0 350 NEXT I 360 IF F=0 THEN 480 370 C2=C2+1 380 FIX 11 @ DISP X;"ok"; @ STD 390 DISP " x^";STR$(D); 400 FOR I=1 TO D-1 410 IF A(I)=1 THEN DISP "+"; 420 IF A(I)=-1 THEN DISP "-"; 430 IF A(I)<>0 THEN DISP "x"; 440 IF A(I)<>0 AND D-I<>1 THEN DISP "^";STR$(D-I); 450 NEXT I 460 IF A(D)>0 THEN DISP "+"; 470 DISP STR$(A(D)) 480 RETURN J-F |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 2 Guest(s)