# pouët.net

## Fibonacci

category: general [glöplog]
Fibonacci does your __int64s. Go make a demo about it.
added on the 2010-04-09 08:20:58 by kbi
the formula is this:

N = B*1.44042 + 2.1399

B = number of bits
N = number in which the overflow happens

B = 32 -> N = 48
B = 64 -> N = 94
B = 128 -> N = 186
added on the 2010-04-09 09:30:20 by iq
[0] 0
[1] 1
[2] 1
[3] 2
[4] 3
[5] 5
[6] 8
[7] 13
[8] 21
[9] 34
[10] 55
[11] 89
[12] 144
[13] 233
[14] 377
[15] 610
[16] 987
[17] 1597
[18] 2584
[19] 4181
[20] 6765
[21] 10946
[22] 17711
[23] 28657
[24] 46368
[25] 75025
[26] 121393
[27] 196418
[28] 317811
[29] 514229
[30] 832040
[31] 1346269
[32] 2178309
[33] 3524578
[34] 5702887
[35] 9227465
[36] 14930352
[37] 24157817
[38] 39088169
[39] 63245986
[40] 102334155
[41] 165580141
[42] 267914296
[43] 433494437
[44] 701408733
[45] 1134903170
[46] 1836311903
[47] 2971215073
[48] 4807526976
[49] 7778742049
[50] 12586269025
[51] 20365011074
[52] 32951280099
[53] 53316291173
[54] 86267571272
[55] 139583862445
[56] 225851433717
[57] 365435296162
[58] 591286729879
[59] 956722026041
[60] 1548008755920
[61] 2504730781961
[62] 4052739537881
[63] 6557470319842
[64] 10610209857723
[65] 17167680177565
[66] 27777890035288
[67] 44945570212853
[68] 72723460248141
[69] 117669030460994
[70] 190392490709135
[71] 308061521170129
[72] 498454011879264
[73] 806515533049393
[74] 1304969544928657
[75] 2111485077978050
[76] 3416454622906707
[77] 5527939700884757
[78] 8944394323791464
[79] 14472334024676221
[80] 23416728348467685
[81] 37889062373143906
[82] 61305790721611591
[83] 99194853094755497
[84] 160500643816367088
[85] 259695496911122585
[86] 420196140727489673
[87] 679891637638612258
[88] 1100087778366101931
[89] 1779979416004714189
[90] 2880067194370816120
[91] 4660046610375530309
[92] 7540113804746346429
[93] 12200160415121876738
[94] 19740274219868223167
[95] 31940434634990099905
[96] 51680708854858323072
[97] 83621143489848422977
[98] 135301852344706746049
[99] 218922995834555169026
[100] 354224848179261915075
[101] 573147844013817084101
[102] 927372692193078999176
[103] 1500520536206896083277
[104] 2427893228399975082453
[105] 3928413764606871165730
[106] 6356306993006846248183
[107] 10284720757613717413913
[108] 16641027750620563662096
[109] 26925748508234281076009
[110] 43566776258854844738105
[111] 70492524767089125814114
[112] 114059301025943970552219
[113] 184551825793033096366333
[114] 298611126818977066918552
[115] 483162952612010163284885
[116] 781774079430987230203437
[117] 1264937032042997393488322
[118] 2046711111473984623691759
[119] 3311648143516982017180081
[120] 5358359254990966640871840
[121] 8670007398507948658051921
[122] 14028366653498915298923761
[123] 22698374052006863956975682
[124] 36726740705505779255899443
[125] 59425114757512643212875125
[126] 96151855463018422468774568
[127] 155576970220531065681649693
[128] 251728825683549488150424261
[129] 407305795904080553832073954
[130] 659034621587630041982498215
[131] 1066340417491710595814572169
[132] 1725375039079340637797070384
[133] 2791715456571051233611642553
[134] 4517090495650391871408712937
[135] 7308805952221443105020355490
[136] 11825896447871834976429068427
[137] 19134702400093278081449423917
[138] 30960598847965113057878492344
[139] 50095301248058391139327916261
[140] 81055900096023504197206408605
[141] 131151201344081895336534324866
[142] 212207101440105399533740733471
[143] 343358302784187294870275058337
[144] 555565404224292694404015791808
[145] 898923707008479989274290850145
[146] 1454489111232772683678306641953
[147] 2353412818241252672952597492098
[148] 3807901929474025356630904134051
[149] 6161314747715278029583501626149
[150] 9969216677189303386214405760200
[151] 16130531424904581415797907386349
[152] 26099748102093884802012313146549
[153] 42230279526998466217810220532898
[154] 68330027629092351019822533679447
[155] 110560307156090817237632754212345
[156] 178890334785183168257455287891792
[157] 289450641941273985495088042104137
[158] 468340976726457153752543329995929
[159] 757791618667731139247631372100066
[160] 1226132595394188293000174702095995
[161] 1983924214061919432247806074196061
[162] 3210056809456107725247980776292056
[163] 5193981023518027157495786850488117
[164] 8404037832974134882743767626780173
[165] 13598018856492162040239554477268290
[166] 22002056689466296922983322104048463
[167] 35600075545958458963222876581316753
[168] 57602132235424755886206198685365216
[169] 93202207781383214849429075266681969
[170] 150804340016807970735635273952047185
[171] 244006547798191185585064349218729154
[172] 394810887814999156320699623170776339
[173] 638817435613190341905763972389505493
[174] 1033628323428189498226463595560281832
[175] 1672445759041379840132227567949787325
[176] 2706074082469569338358691163510069157
[177] 4378519841510949178490918731459856482
[178] 7084593923980518516849609894969925639
[179] 11463113765491467695340528626429782121
[180] 18547707689471986212190138521399707760
[181] 30010821454963453907530667147829489881
[182] 48558529144435440119720805669229197641
[183] 78569350599398894027251472817058687522
[184] 127127879743834334146972278486287885163
[185] 205697230343233228174223751303346572685
[186] 332825110087067562321196029789634457848
[187] 538522340430300790495419781092981030533
[188] 871347450517368352816615810882615488381
[189] 1409869790947669143312035591975596518914
[190] 2281217241465037496128651402858212007295
[191] 3691087032412706639440686994833808526209
[192] 5972304273877744135569338397692020533504
[193] 9663391306290450775010025392525829059713
[194] 15635695580168194910579363790217849593217
[195] 25299086886458645685589389182743678652930
[196] 40934782466626840596168752972961528246147
[197] 66233869353085486281758142155705206899077
[198] 107168651819712326877926895128666735145224
[199] 173402521172797813159685037284371942044301
[200] 280571172992510140037611932413038677189525
[201] 453973694165307953197296969697410619233826
[202] 734544867157818093234908902110449296423351
[203] 1188518561323126046432205871807859915657177
[204] 1923063428480944139667114773918309212080528
[205] 3111581989804070186099320645726169127737705
[206] 5034645418285014325766435419644478339818233
[207] 8146227408089084511865756065370647467555938
[208] 13180872826374098837632191485015125807374171
[209] 21327100234463183349497947550385773274930109
[210] 34507973060837282187130139035400899082304280
[211] 55835073295300465536628086585786672357234389
[212] 90343046356137747723758225621187571439538669
[213] 146178119651438213260386312206974243796773058
[214] 236521166007575960984144537828161815236311727
[215] 382699285659014174244530850035136059033084785
[216] 619220451666590135228675387863297874269396512
[217] 1001919737325604309473206237898433933302481297
[218] 1621140188992194444701881625761731807571877809
[219] 2623059926317798754175087863660165740874359106
[220] 4244200115309993198876969489421897548446236915
[221] 6867260041627791953052057353082063289320596021
[222] 11111460156937785151929026842503960837766832936
[223] 17978720198565577104981084195586024127087428957
[224] 29090180355503362256910111038089984964854261893
[225] 47068900554068939361891195233676009091941690850
[226] 76159080909572301618801306271765994056795952743
[227] 123227981463641240980692501505442003148737643593
[228] 199387062373213542599493807777207997205533596336
[229] 322615043836854783580186309282650000354271239929
[230] 522002106210068326179680117059857997559804836265
[231] 844617150046923109759866426342507997914076076194
[232] 1366619256256991435939546543402365995473880912459
[233] 2211236406303914545699412969744873993387956988653
[234] 3577855662560905981638959513147239988861837901112
[235] 5789092068864820527338372482892113982249794889765
[236] 9366947731425726508977331996039353971111632790877
[237] 15156039800290547036315704478931467953361427680642
[238] 24522987531716273545293036474970821924473060471519
[239] 39679027332006820581608740953902289877834488152161
[240] 64202014863723094126901777428873111802307548623680
[241] 103881042195729914708510518382775401680142036775841
[242] 168083057059453008835412295811648513482449585399521
[243] 271964099255182923543922814194423915162591622175362
[244] 440047156314635932379335110006072428645041207574883
[245] 712011255569818855923257924200496343807632829750245
[246] 1152058411884454788302593034206568772452674037325128
[247] 1864069667454273644225850958407065116260306867075373
[248] 3016128079338728432528443992613633888712980904400501
[249] 4880197746793002076754294951020699004973287771475874
[250] 7896325826131730509282738943634332893686268675876375
[251] 12776523572924732586037033894655031898659556447352249
[252] 20672849399056463095319772838289364792345825123228624
[253] 33449372971981195681356806732944396691005381570580873
[254] 54122222371037658776676579571233761483351206693809497
[255] 87571595343018854458033386304178158174356588264390370
[256] 141693817714056513234709965875411919657707794958199867
[257] 229265413057075367692743352179590077832064383222590237
[258] 370959230771131880927453318055001997489772178180790104
[259] 600224643828207248620196670234592075321836561403380341
[260] 971183874599339129547649988289594072811608739584170445
[261] 1571408518427546378167846658524186148133445300987550786
[262] 2542592393026885507715496646813780220945054040571721231
[263] 4114000911454431885883343305337966369078499341559272017
[264] 6656593304481317393598839952151746590023553382130993248
[265] 10770594215935749279482183257489712959102052723690265265
[266] 17427187520417066673081023209641459549125606105821258513
[267] 28197781736352815952563206467131172508227658829511523778
[268] 45624969256769882625644229676772632057353264935332782291
[269] 73822750993122698578207436143903804565580923764844306069
[270] 119447720249892581203851665820676436622934188700177088360
[271] 193270471243015279782059101964580241188515112465021394429
[272] 312718191492907860985910767785256677811449301165198482789
[273] 505988662735923140767969869749836918999964413630219877218
[274] 818706854228831001753880637535093596811413714795418360007
[275] 1324695516964754142521850507284930515811378128425638237225
[276] 2143402371193585144275731144820024112622791843221056597232
[277] 3468097888158339286797581652104954628434169971646694834457
[278] 5611500259351924431073312796924978741056961814867751431689
[279] 9079598147510263717870894449029933369491131786514446266146
[280] 14691098406862188148944207245954912110548093601382197697835
[281] 23770696554372451866815101694984845480039225387896643963981
[282] 38461794961234640015759308940939757590587318989278841661816
[283] 62232491515607091882574410635924603070626544377175485625797
[284] 100694286476841731898333719576864360661213863366454327287613
[285] 162926777992448823780908130212788963731840407743629812913410
[286] 263621064469290555679241849789653324393054271110084140201023
[287] 426547842461739379460149980002442288124894678853713953114433
[288] 690168906931029935139391829792095612517948949963798093315456
[289] 1116716749392769314599541809794537900642843628817512046429889
[290] 1806885656323799249738933639586633513160792578781310139745345
[291] 2923602405716568564338475449381171413803636207598822186175234
[292] 4730488062040367814077409088967804926964428786380132325920579
[293] 7654090467756936378415884538348976340768064993978954512095813
[294] 12384578529797304192493293627316781267732493780359086838016392
[295] 20038668997554240570909178165665757608500558774338041350112205
[296] 32423247527351544763402471792982538876233052554697128188128597
[297] 52461916524905785334311649958648296484733611329035169538240802
[298] 84885164052257330097714121751630835360966663883732297726369399
[299] 137347080577163115432025771710279131845700275212767467264610201
[300] 222232244629420445529739893461909967206666939096499764990979600
[301] 359579325206583560961765665172189099052367214309267232255589801
[302] 581811569836004006491505558634099066259034153405766997246569401
[303] 941390895042587567453271223806288165311401367715034229502159202
[304] 1523202464878591573944776782440387231570435521120801226748728603
[305] 2464593359921179141398048006246675396881836888835835456250887805
[306] 3987795824799770715342824788687062628452272409956636682999616408
[307] 6452389184720949856740872794933738025334109298792472139250504213
[308] 10440185009520720572083697583620800653786381708749108822250120621
[309] 16892574194241670428824570378554538679120491007541580961500624834
[310] 27332759203762391000908267962175339332906872716290689783750745455
[311] 44225333398004061429732838340729878012027363723832270745251370289
[312] 71558092601766452430641106302905217344934236440122960529002115744
[313] 115783425999770513860373944643635095356961600163955231274253486033
[314] 187341518601536966291015050946540312701895836604078191803255601777
[315] 303124944601307480151388995590175408058857436768033423077509087810
[316] 490466463202844446442404046536715720760753273372111614880764689587
[317] 793591407804151926593793042126891128819610710140145037958273777397
[318] 1284057871006996373036197088663606849580363983512256652839038466984
[319] 2077649278811148299629990130790497978399974693652401690797312244381
[320] 3361707149818144672666187219454104827980338677164658343636350711365
[321] 5439356428629292972296177350244602806380313370817060034433662955746
[322] 8801063578447437644962364569698707634360652047981718378070013667111
[323] 14240420007076730617258541919943310440740965418798778412503676622857
[324] 23041483585524168262220906489642018075101617466780496790573690289968
[325] 37281903592600898879479448409585328515842582885579275203077366912825
[326] 60323387178125067141700354899227346590944200352359771993651057202793
[327] 97605290770725966021179803308812675106786783237939047196728424115618
[328] 157928677948851033162880158208040021697730983590298819190379481318411
[329] 255533968719576999184059961516852696804517766828237866387107905434029
[330] 413462646668428032346940119724892718502248750418536685577487386752440
[331] 668996615388005031531000081241745415306766517246774551964595292186469
[332] 1082459262056433063877940200966638133809015267665311237542082678938909
[333] 1751455877444438095408940282208383549115781784912085789506677971125378
[334] 2833915139500871159286880483175021682924797052577397027048760650064287
[335] 4585371016945309254695820765383405232040578837489482816555438621189665
[336] 7419286156446180413982701248558426914965375890066879843604199271253952
[337] 12004657173391489668678522013941832147005954727556362660159637892443617
[338] 19423943329837670082661223262500259061971330617623242503763837163697569
[339] 31428600503229159751339745276442091208977285345179605163923475056141186
[340] 50852543833066829834000968538942350270948615962802847667687312219838755
[341] 82281144336295989585340713815384441479925901307982452831610787275979941
[342] 133133688169362819419341682354326791750874517270785300499298099495818696
[343] 215414832505658809004682396169711233230800418578767753330908886771798637
[344] 348548520675021628424024078524038024981674935849553053830206986267617333
[345] 563963353180680437428706474693749258212475354428320807161115873039415970
[346] 912511873855702065852730553217787283194150290277873860991322859307033303
[347] 1476475227036382503281437027911536541406625644706194668152438732346449273
[348] 2388987100892084569134167581129323824600775934984068529143761591653482576
[349] 3865462327928467072415604609040860366007401579690263197296200323999931849
[350] 6254449428820551641549772190170184190608177514674331726439961915653414425
[351] 10119911756749018713965376799211044556615579094364594923736162239653346274
[352] 16374361185569570355515148989381228747223756609038926650176124155306760699
[353] 26494272942318589069480525788592273303839335703403521573912286394960106973
[354] 42868634127888159424995674777973502051063092312442448224088410550266867672
[355] 69362907070206748494476200566565775354902428015845969798000696945226974645
[356] 112231541198094907919471875344539277405965520328288418022089107495493842317
[357] 181594448268301656413948075911105052760867948344134387820089804440720816962
[358] 293825989466396564333419951255644330166833468672422805842178911936214659279
[359] 475420437734698220747368027166749382927701417016557193662268716376935476241
[360] 769246427201094785080787978422393713094534885688979999504447628313150135520
[361] 1244666864935793005828156005589143096022236302705537193166716344690085611761
[362] 2013913292136887790908943984011536809116771188394517192671163973003235747281
[363] 3258580157072680796737099989600679905139007491100054385837880317693321359042
[364] 5272493449209568587646043973612216714255778679494571578509044290696557106323
[365] 8531073606282249384383143963212896619394786170594625964346924608389878465365
[366] 13803567055491817972029187936825113333650564850089197542855968899086435571688
[367] 22334640661774067356412331900038009953045351020683823507202893507476314037053
[368] 36138207717265885328441519836863123286695915870773021050058862406562749608741
[369] 58472848379039952684853851736901133239741266891456844557261755914039063645794
[370] 94611056096305838013295371573764256526437182762229865607320618320601813254535
[371] 153083904475345790698149223310665389766178449653686710164582374234640876900329
[372] 247694960571651628711444594884429646292615632415916575771902992555242690154864
[373] 400778865046997419409593818195095036058794082069603285936485366789883567055193
[374] 648473825618649048121038413079524682351409714485519861708388359345126257210057
[375] 1049252690665646467530632231274619718410203796555123147644873726135009824265250
[376] 1697726516284295515651670644354144400761613511040643009353262085480136081475307
[377] 2746979206949941983182302875628764119171817307595766156998135811615145905740557
[378] 4444705723234237498833973519982908519933430818636409166351397897095281987215864
[379] 7191684930184179482016276395611672639105248126232175323349533708710427892956421
[380] 11636390653418416980850249915594581159038678944868584489700931605805709880172285
[381] 18828075583602596462866526311206253798143927071100759813050465314516137773128706
[382] 30464466237021013443716776226800834957182606015969344302751396920321847653300991
[383] 49292541820623609906583302538007088755326533087070104115801862234837985426429697
[384] 79757008057644623350300078764807923712509139103039448418553259155159833079730688
[385] 12904954987826823325688338130281501246783567219010955253435512138999781850616038 5
[386] 20880655793591285660718346006762293618034481129314900095290838054515765158589107 3
[387] 33785610781418108986406684137043794864818048348325855348726350193515547009205145 8
[388] 54666266575009394647125030143806088482852529477640755444017188248031312167794253 1
[389] 88451877356427503633531714280849883347670577825966610792743538441546859176999398 9
[390] 14311814393143689828065674442465597183052310730360736623676072668957817134479365 20
[391] 23157002128786440191418845870550585517819368512957397702950426513112503052179305 09
[392] 37468816521930130019484520313016182700871679243318134326626499182070320186658670 29
[393] 60625818650716570210903366183566768218691047756275532029576925695182823238837975 38
[394] 98094635172646700230387886496582950919562726999593666356203424877253143425496645 67
[395] 15872045382336327044129125268014971913825377475586919838578035057243596666433462 105
[396] 25681508899600997067167913917673267005781650175546286474198377544968911008983126 672
[397] 41553554281937324111297039185688238919607027651133206312776412602212507675416588 777
[398] 67235063181538321178464953103361505925388677826679492786974790147181418684399715 449
[399] 10878861746347564528976199228904974484499570547781269909975120274939392635981630 4226
[400] 17602368064501396646822694539241125077038438330449219188672599289657534504421601 9675
[401] 28481229810848961175798893768146099561538008878230489098647719564596927140403232 3901
[402] 46083597875350357822621588307387224638576447208679708287320318854254461644824834 3576
[403] 74564827686199318998420482075533324200114456086910197385968038418851388785228066 7477
[404] 12064842556154967682104207038292054883869090329558990567328835727310585043005290 11053
[405] 19521325324774899581946255245845387303880535938250010305925639569195723921528096 78530
[406] 31586167880929867264050462284137442187749626267809000873254475296506308964533386 89583
[407] 51107493205704766845996717529982829491630162206059011179180114865702032886061483 68113
[408] 82693661086634634110047179814120271679379788473868012052434590162208341850594870 57696
[409] 13380115429233940095604389734410310117100995067992702323161470502791037473665635 425809
[410] 21649481537897403506609107715822337285038973915379503528404929519011871658725122 483505
[411] 35029596967131343602213497450232647402139968983372205851566400021802909132390757 909314
[412] 56679078505028747108822605166054984687178942898751709379971329540814780791115880 392819
[413] 91708675472160090711036102616287632089318911882123915231537729562617689923506638 302133
[414] 14838775397718883781985870778234261677649785478087562461150905910343247071462251 8694952
[415] 24009642944934892853089481039863024886581676666299953984304678866605016063812915 6997085
[416] 38848418342653776635075351818097286564231462144387516445455584776948263135275167 5692037
[417] 62858061287588669488164832857960311450813138810687470429760263643553279199088083 2689122
[418] 10170647963024244612324018467605759801504460095507498687521584842050154233436325 08381159
[419] 16456454091783111561140501753401790946585773976576245730497611206405482153345133 41070281
[420] 26627102054807356173464520221007550748090234072083744418019196048455636386781458 49451440
[421] 43083556146590467734605021974409341694676008048659990148516807254861118540126591 90521721
[422] 69710658201397823908069542195416892442766242120743734566536003303316754926908050 39973161
[423] 11279421434798829164267456416982623413744225016940372471505281055817787346703464 230494882
[424] 18250487254938611555074410636524312658020849229014745928158881386149462839394269 270468043
[425] 29529908689737440719341867053506936071765074245955118399664162441967250186097733 500962925
[426] 47780395944676052274416277690031248729785923474969864327823043828116713025492002 771430968
[427] 77310304634413492993758144743538184801550997720924982727487206270083963211589736 272393893
[428] 12509070057908954526817442243356943353133692119589484705531025009820067623708173 9043824861
[429] 20240100521350303826193256717710761833288791891681982978279745636828463944867147 5316218754
[430] 32749170579259258353010698961067705186422484011271467683810770646648531568575321 4360043615
[431] 52989271100609562179203955678778467019711275902953450662090516283476995513442468 9676262369
[432] 85738441679868820532214654639846172206133759914224918345901286930125527082017790 4036305984
[433] 13872771278047838271141861031862463922584503581717836900799180321360252259546025 93712568353
[434] 22446615446034720324363326495847081143197879573140328735389309014372804967747804 97748874337
[435] 36319386724082558595505187527709545065782383154858165636188489335733057227293830 91461442690
[436] 58766002170117278919868514023556626208980262727998494371577798350105862195041635 89210317027
[437] 95085388894199837515373701551266171274762645882856660007766287685838919422335466 80671759717
[438] 15385139106431711643524221557482279748374290861085515437934408603594478161737710 269882076744
[439] 24893677995851695395061591712608896875850555449371181438711037372178370103971256 950553836461
[440] 40278817102283407038585813270091176624224846310456696876645445975772848265708967 220435913205
[441] 65172495098135102433647404982700073500075401759827878315356483347951218369680224 170989749666
[442] 10545131220041850947223321825279125012430024807028457519200192932372406663538919 1391425662871
[443] 17062380729855361190588062323549132362437564983011245350735841267167528500506941 5562415412537
[444] 27607511949897212137811384148828257374867589790039702869936034199539935164045860 6953841075408
[445] 44669892679752573328399446472377389737305154773050948220671875466707463664552802 2516256487945
[446] 72277404629649785466210830621205647112172744563090651090607909666247398828598662 9470097563353
[447] 11694729730940235879461027709358303684947789933614159931127978513295486249315146 51986354051298
[448] 18922470193905214426082110771478868396165064389923225040188769479920226132175012 81456451614651
[449] 30617199924845450305543138480837172081112854323537384971316747993215712381490159 33442805665949
[450] 49539670118750664731625249252316040477277918713460610011505517473135938513665172 14899257280600
[451] 80156870043596115037168387733153212558390773036997994982822265466351650895155331 48342062946549
[452] 12969654016234677976879363698546925303566869175045860499432778293948758940882050 363241320227149
[453] 20985341020594289480596202471862246559405946478745659997715004840583924030397583 511583383173698
[454] 33954995036828967457475566170409171862972815653791520497147783134532682971279633 874824703400847
[455] 54940336057423256938071768642271418422378762132537180494862787975116607001677217 386408086574545
[456] 88895331094252224395547334812680590285351577786328700992010571109649289972956851 261232789975392
[457] 14383566715167548133361910345495200870773033991886588148687335908476589697463406 8647640876549937
[458] 23273099824592770572916643826763259899308191770519458247888393019441518694759091 9908873666525329
[459] 37656666539760318706278554172258460770081225762406046396575728927918108392222498 8556514543075266
[460] 60929766364353089279195197999021720669389417532925504644464121947359627086981590 8465388209600595
[461] 98586432904113407985473752171280181439470643295331551041039850875277735479204089 7021902752675861
[462] 15951619926846649726466895017030190210886006082825705568550397282263736256618568 05487290962276456
[463] 25810263217257990525014270234158208354833070412358860672654382369791509804538977 02509193714952317
[464] 41761883144104640251481165251188398565719076495184566241204779652055246061157545 07996484677228773
[465] 67572146361362630776495435485346606920552146907543426913859162021846755865696522 10505678392181090
[466] 10933402950546727102797660073653500548627122340272799315506394167390200192685406 718502163069409863
[467] 17690617586682990180447203622188161240682337031027142006892310369574875779255058 929007841461590953
[468] 28624020537229717283244863695841661789309459371299941322398704536965075971940465 647510004531000816
[469] 46314638123912707463692067318029823029991796402327083329291014906539951751195524 576517845992591769
[470] 74938658661142424746936931013871484819301255773627024651689719443505027723135990 224027850523592585
[471] 12125329678505513221062899833190130784929305217595410798098073435004497947433151 4800545696516184354
[472] 19619195544619755695756592934577279266859430794958113263267045379355000719746750 5024573547039776939
[473] 31744525223125268916819492767767410051788736012553524061365118814359498667179901 9825119243555961293
[474] 51363720767745024612576085702344689318648166807511637324632164193714499386926652 4849692790595738232
[475] 83108245990870293529395578470112099370436902820065161385997283008073998054106554 4674812034151699525
[476] 13447196675861531814197166417245678868908506962757679871062944720178849744103320 69524504824747437757
[477] 21758021274948561167136724264256888805952197244764196009662673020986249549513976 14199316858899137282
[478] 35205217950810092981333890681502567674860704207521875880725617741165099293617296 83723821683646575039
[479] 56963239225758654148470614945759456480812901452286071890388290762151348843131272 97923138542545712321
[480] 92168457176568747129804505627262024155673605659807947771113908503316448136748569 81646960226192287360
[481] 14913169640232740127827512057302148063648650711209401966150219926546779697987984 279570098768737999681
[482] 24130015357889614840807962620028350479216011277190196743261610776878424511662841 261217058994930287041
[483] 39043184998122354968635474677330498542864661988399598709411830703425204209650825 540787157763668286722
[484] 63173200356011969809443437297358849022080673265589795452673441480303628721313666 802004216758598573763
[485] 10221638535413432477807891197468934756494533525398939416208527218372883293096449 2342791374522266860485
[486] 16538958571014629458752234927204819658702600851957918961475871366403246165227815 9144795591280865434248
[487] 26760597106428061936560126124673754415197134377356858377684398584776129458324265 1487586965803132294733
[488] 43299555677442691395312361051878574073899735229314777339160269951179375623552081 0632382557083997728981
[489] 70060152783870753331872487176552328489096869606671635716844668535955505081876346 2119969522887130023714
[490] 11335970846131344472718484822843090256299660483598641305600493848713488070542842 72752352079971127752695
[491] 18341986124518419805905733540498323105209347444265804877284960702309038578730477 34872321602858257776409
[492] 29677956970649764278624218363341413361509007927864446182885454551022526649273320 07624673682829385529104
[493] 48019943095168184084529951903839736466718355372130251060170415253331565228003797 42496995285687643305513
[494] 77697900065817948363154170267181149828227363299994697243055869804354091877277117 50121668968517028834617
[495] 12571784316098613244768412217102088629494571867212494830322628505768565710528091 492618664254204672140130
[496] 20341574322680408081083829243820203612317308197211964554628215486203974898255803 242740333222721700974747
[497] 32913358638779021325852241460922292241811880064424459384950843991972540608783894 735358997476926373114877
[498] 53254932961459429406936070704742495854129188261636423939579059478176515507039697 978099330699648074089624
[499] 86168291600238450732788312165664788095941068326060883324529903470149056115823592 713458328176574447204501
[500] 13942322456169788013972438287040728395007025658769730726410896294832557162286329 0691557658876222521294125
added on the 2010-04-09 10:15:20 by Skate
Someone please make a graph out of the ratios of each consecutive number pair:

0,1
1,2
3,5
8,13
21,34
55,89
144,233

That's the real magic behind this pattern ;)
added on the 2010-04-09 10:25:50 by d0DgE
Quote:
Who is going for GMP now ?

Why use GMP when you can use SockZ?

Code: 1 0 1 ;f(n) f(n-1) n .loop COPY "f(" PRINT ")=" 3 OVER PRINT CR 3 SWAP ;n f(n-1) f(n) SWAP2 ;n f(n) f(n-1) OVER2 ;n f(n) f(n-1) f(n) + ;n f(n) f(n+1)=f(n-1)+f(n) 3 SWAP ;f(n+1) f(n) n 1 + ;f(n+1) f(n) n+1 COPY 502 SKIP= loop END

And then:
f(500)=13942322456169788013972438287040728395007025658769730726410896294832557 1622863290691557658876222521294125
f(501)=22559151616193633087251269503607207204601132491375819058863886641847462 7738686883405015987052796968498626
added on the 2010-04-09 11:57:55 by baah
Quote:
Go make a demo about it

I did ;D
added on the 2010-04-09 14:19:15 by d0DgE
I'll take your sweaty sockz and raise you with some erlang. (Obviously tail call recursive)

fibseq() ->
fibout(0,0),
fibseq(1,1,0).

fibseq(Num,Cur,Prev) when Num=<505 ->
fibout(Num,Cur),
Next=Cur+Prev,
fibseq(Num+1,Next,Cur);
fibseq(_,_,_) ->
done.

fibout(Num,Cur) ->
io:format("fib(~b)=~b~n",[Num,Cur]).

---------------------------------------------------------
46> test:fibseq().
fib(0)=0
fib(1)=1
fib(2)=1
fib(3)=2
fib(4)=3
fib(5)=5
........
........
fib(501)=225591516161936330872512695036072072046011324913758190588638866418474 627738686883405015987052796968498626
fib(502)=365014740723634211012237077906479355996081581501455497852747829366800 199361550174096573645929019489792751
fib(503)=590606256885570541884749772942551428042092906415213688441386695785274 827100237057501589632981816458291377
fib(504)=955620997609204752896986850849030784038174487916669186294134525152075 026461787231598163278910835948084128
fib(505)=154622725449477529478173662379158221208026739433188287473552122093734 9853562024289099752911892652406375505
done
47>
added on the 2010-04-09 16:47:13 by whizzter
Hit me with some bbcode to get the erlang code to look right.

Code:fibseq() -> fibout(0,0), fibseq(1,1,0). fibseq(Num,Cur,Prev) when Num=<505 -> fibout(Num,Cur), Next=Cur+Prev, fibseq(Num+1,Next,Cur); fibseq(_,_, _) -> done. fibout(Num,Cur) -> io:format("fib(~b)=~b~n",[Num,Cur]).

added on the 2010-04-09 16:49:46 by whizzter
bah, humbug

mov ch, 2
mov di, cx
rep stosb
inc ax
mov ch, 120
loop1:
stosb
mov al, [di-160]
aaa
loop loop1
mov ch, 120
loop2:
dec di
mov dl, [di]
mov ah, 2
int 21h
loop loop2
ret
added on the 2010-04-09 17:17:13 by 216
funny trick.. tmdc next?
added on the 2010-04-09 17:48:02 by whizzter
Skate pwns.
added on the 2010-04-09 19:56:04 by ferris
8bit always wins ;)
added on the 2010-04-09 20:24:18 by Skate
Code: def number2bin(x): out = [] while x: out.append( x%2 ) x /= 2 out.reverse() return out def jump( p, c ): return p*p+c*c, (2*p+c)*c def step( p, c ): return c, p+c def fibTravel(n): marsenNumber = 2**4423-1 #quite large finite field path = number2bin(n) p,c = 1,0 #starting point for i in path[:-1]: #print "wow %s"%i if i: p,c = step( p,c ) p,c = jump( p,c ) p = p % marsenNumber c = c % marsenNumber if path[-1]: p,c = step( p,c ) return c

f[506]=25018482521039800476787234746406129961184418822485520610296557460894248 80023811520697916190803488354459633
f[507]=40480755065987553424604600984321952081987092765804349357651769670267747 33585835809797669102696140760835138
f[508]=65499237587027353901391835730728082043171511588289869967948327131161996 13609647330495585293499629115294771

and now... PANTS OFF (klękać do miecza)
f[47239817523981479281579218712460998291842112345432721649875243104932184651324] mod 2^4423 -1 =

12421344184931198544648601830917502493347503327608706306208969624803310191061042 7635944517630958231376181716158561902062371516742409767758834435441405570893269249 0450602561259903718779120441488253197926869095617763067514184727515884334112637230 1332139037829937841399389493728786442506164088168436229947622714856297347877591038 6785676258243180956427734699057184286328519447284384469511322517622057287637919668 7179969776761633888679024534385879272154396327315389970242206854673859370383360956 8295923864859224156151628458160448924962262721644912936906109989282355041651432354 4641692378708504640765043123163318928255548543957067332112463484216126702609406073 3111437620260628275611461203963739404373873986784156436983702426219753220521916385 4493584674351754290230455587980879436793113744179632757308427035131520713129243878 2293490185898684059165752267235422780507663341695583588502263319754618902661335400 7743940748039459367543417437090547746720915720587514089119330045914605529015694643 5448714961965466771621316243285186319537841741760056960409498747943724703107115611 0463537773293271210539186992574788335622957102826912974617335683942840251069600758 3385513613993134535252801139055443666499729922007030017328919033784701582189055741 6477899013650450238951963246330501173919043388156791084545260750846723881929165956 2069131629834756078711

time computing < 1[s] :)
added on the 2010-04-11 12:33:53 by krzyzan
Ok, lets play with Fibonacci numbers and... intros 256b. :)
Intro 256 is just a sequence of bits, isn't it? - so, it could be turn into natural number. Quick and easy code:
Code: import fib #his is the file from my last post def introNumber(): f = open("puls.com","rb") #yeah.. this is THIS pulse 256b intro try: byte = f.read(1) index=0 sum=0 while byte != "": val = int(byte.encode('hex'), 16) sum += val*(256**index) byte = f.read(1) index += 1 finally: f.close() return sum print introNumber() print "--------------------------" print fib.fibTravel( introNumber() )

I took famous "puls.com" (by Rrrola), and this is its 'cardinal' number:
N=2469066419087757786373502614320482942840063612361618401365743633092392975980716 931289154898584132083843060634660070159716017606765894694095208131048764404130139 942571676241809237194399250376629592309875008358710542603558782111031400672802546 117382261399669615450098592659706089658407702494890996101367487468793340551556134 825585437760144779323403259868470521353246187388228713190065278567989763666020761 283917678223841400495559945352701439865389866933194185225205378629088776087016048 476331103894423173121806237457217143499801543356329984589245455574920863745359711 7970206952510950529863791439474064675977657075307440

And this is N'th Fibonacci number:
F[N] mod 2^4423-1= 24934934979773231435855155903385566495897265280710132185371732542822244291118091 690594232299977572177856995945482118932543297661468983441335244250572588721294086 937997244973047284321224484684635939144750580344526207529424432372120433937301353 523998801576635501092341687935113678939361731519762004714799398766132480726421555 781366785934479233742661761579983242561681764760501048306293467544704640094062734 901421980825204232608077131504263714792811109621053803296261557157548899890964050 387681563673205772767371229018187268798144407531831519604895342213946489955881001 874737816112860061658908058904682764989452078344906255336880224684099987226622173 240109400948335395168497753886287815721628952066595233043886197715090161214898096 007477875471681662012859952960038448846634419979258468615094333201491365569048005 539564692527018320561863588156715323534617748375393231923706879410655074332631047 290044220097602130262988012616582020880527350869955408170032028798424607781956523 128766011956502398012510964982177901927013108676860483313634232282650311400386646 865160824415794480324373744922120946050073632514584634958529285596890409985606492 951254709829361892636244058464988136928843294733049098774080249837639527790569206 046281906011689166780182852547160615279461533060761214783369920211847090560416223 5159752114477201234865669171370024546

Or.. we can note it as follows
F( ) mod 2^4423-1 =
249349349797732314358551559033855664958972652807101321853717325428222442911180 916905942322999775721778569959454821189325432976614689834413352442505725887212940 869379972449730472843212244846846359391447505803445262075294244323721204339373013 535239988015766355010923416879351136789393617315197620047147993987661324807264215 557813667859344792337426617615799832425616817647605010483062934675447046400940627 349014219808252042326080771315042637147928111096210538032962615571575488998909640 503876815636732057727673712290181872687981444075318315196048953422139464899558810 018747378161128600616589080589046827649894520783449062553368802246840999872266221 732401094009483353951684977538862878157216289520665952330438861977150901612148980 960074778754716816620128599529600384488466344199792584686150943332014913655690480 055395646925270183205618635881567153235346177483753932319237068794106550743326310 472900442200976021302629880126165820208805273508699554081700320287984246077819565 231287660119565023980125109649821779019270131086768604833136342322826503114003866 468651608244157944803243737449221209460500736325145846349585292855968904099856064 929512547098293618926362440584649881369288432947330490987740802498376395277905692 060462819060116891667801828525471606152794615330607612147833699202118470905604162 235159752114477201234865669171370024546

So... equation:
F[ intro256 ] mod q = x
is easy to solve... what about
F[x] mod q = intro256 ? :)

Another question is, how set q number (finite filed)? I have just taken 2**4423-1, which is prime number.

Aha, there is one mistake in my fibTravel function - there should be:
Code: if path[-1]: p,c = step( p,c ) p = p % marsenNumber c = c % marsenNumber return c

bye!
added on the 2010-04-11 15:25:09 by krzyzan
Quote:

So... equation:
F[ intro256 ] mod q = x
is easy to solve... what about
F[x] mod q = intro256 ? :)

We are not sure that g(x)=(fib(x) mod q) is an injection (and i see no simple reason why it would be so). We shall check if there exist two numbers N, M such that g(N)=g(M)...
Also in the second part, shall not q be 2^256 to have a 256b intro as a result?
added on the 2010-04-11 16:37:31 by baah
Quote:

Also in the second part, shall not q be 2^256 to have a 256b intro as a result?

Yeah, if want 256b intro it should be 256^256 = 2^8*256 =2^2048 but... I think that it will be better if it will be prime number. Ex.16'th Mearsenn number 2^2203-1
http://en.wikipedia.org/wiki/Mersenne_prime
Why? I don't know - but if there is prime number, every formula is smarter. :P

And one small point. If q is prime, it is called 'finite filed' and there is a lot of webpages about its properties
added on the 2010-04-12 09:03:49 by krzyzan
'finite field'. Once is a typo, twice a coincidence?

fib(x) mod 11 repeats the sequence 1,1,2,3,5,8,2,10,1,0. There's no solution for 4, 6, 7 and 9. Considering that 11 is a prime I doubt 2^2203-1 works any better than 2^2048.
added on the 2010-04-12 09:46:54 by 216
Quote:
...should be 256^256 = 2^8*256 =2^2048

Ooops... You're right, i forgot a byte has 8 bits! Shame on me! ;p
added on the 2010-04-12 12:09:40 by baah
Quote:

'finite field'. Once is a typo, twice a coincidence?

It was just a typo - finite field is correct of course
Quote:

fib(x) mod 11 repeats the sequence 1,1,2,3,5,8,2,10,1,0. There's no solution for 4, 6, 7 and 9. Considering that 11 is a prime I doubt 2^2203-1 works any better than 2^2048.

Yes, it is absolutely true. I found that such sequences are called Pisano periods

But...
On the other hand, not all numbers from 0...256^256 are properly constructed binaries for x86
added on the 2010-04-12 12:20:02 by krzyzan