Ruby
eta products の線形結合
eta products の線形結合
E_6 をeta products の線形結合で表してみた。
def s(k, n)
s = 0
(1..n).each{|i| s += i if n % i == 0 && i % k == 0}
s
end
def A0(n)
ary = [1]
a = [0] + (1..n).map{|i| 24 * s(1, i) - 12 * s(2, i)}
(1..n).each{|i| ary << (1..i).inject(0){|s, j| s - a[j] * ary[-j]} / i}
ary
end
def A1(n)
ary = [1]
a = [0] + (1..n).map{|i| 12 * s(2, i)}
(1..n).each{|i| ary << (1..i).inject(0){|s, j| s - a[j] * ary[-j]} / i}
ary
end
def A2(n)
ary = [1]
a = [0] + (1..n).map{|i| 12 * s(2, i) + 8 * s(4, i) - 8 * s(1, i)}
(1..n).each{|i| ary << (1..i).inject(0){|s, j| s - a[j] * ary[-j]} / i}
ary
end
def A3(n)
ary = [1]
a = [0] + (1..n).map{|i| 24 * s(4, i) - 12 * s(2, i)}
(1..n).each{|i| ary << (1..i).inject(0){|s, j| s - a[j] * ary[-j]} / i}
ary
end
n = 200
p ary0 = A0(n)
p ary1 = [0] + A1(n)
p ary2 = [0] * 2 + A2(n)
p ary3 = [0] * 3 + A3(n)
p (0..n).map{|i| ary0[i] - 480 * ary1[i] - 16896 * ary2[i] + 8192 * ary3[i]}
出力結果
[1, -24, 264, -1760, 7944, -25872, 64416, -133056, 253704, -472760, 825264, -1297056, 1938336, -2963664, 4437312, -6091584, 8118024, -11368368, 15653352, -19822176, 24832944, -32826112, 42517728, -51425088, 61903776, -78146664, 98021616, -115331264, 133522752, -164079696, 201364416, -229101312, 259776264, -314269824, 374842512, -420258432, 471023592, -554746896, 653690400, -724846144, 793078704, -927125232, 1082704128, -1175873952, 1279397088, -1482713808, 1699194816, -1834739328, 1980797856, -2259791448, 2578950264, -2771448768, 2949559536, -3345875856, 3803764800, -4028054976, 4264256832, -4833186688, 5414943600, -5719271712, 6059238336, -6756214608, 7558096128, -7972913344, 8312839944, -9284959200, 10374325632, -10801349856, 11279351952, -12564531456, 13871037312, -14433084864, 15042871272, -16585653744, 18306804912, -19068642080, 19670138400, -21654935808, 23917274304, -24615220608, 25376943024, -28009137752, 30586037328, -31513408608, 32579551488, -35508322080, 38810229216, -40037878848, 40859536608, -44672951664, 48932378352, -49926264960, 51130316736, -55883287552, 60547082112, -61923031104, 63385408416, -68696763696, 74577903048, -76393194528, 77602957944, -84080984592, 91461572928, -92741489856, 94198772976, -102562521600, 110403610416, -112206096288, 114458740800, -123091514832, 132910417728, -135359463232, 136447747392, -147394340016, 159500457600, -160956544896, 162940575600, -176121743248, 188740015200, -190918949760, 193511203776, -207502774008, 222973423728, -226147998912, 227429983488, -244215894432, 263101540416, -264312339456, 266010877704, -286962805888, 306415571616, -308637532896, 312172889472, -332945133312, 356433028512, -360323811456, 360223654032, -386088721392, 414603535104, -415108384416, 417392122752, -447681704448, 476316548928, -478377518784, 481341997032, -512942325984, 547290900816, -551426235360, 550868402352, -587521351824, 629263864416, -628022995776, 628196474400, -673500182256, 714637972224, -715961510400, 719692526784, -763113874512, 812342889600, -816313861440, 812060601264, -865462338048, 924314846664, -920507154912, 920361668688, -982725974784, 1039906730016, -1039128015552, 1040478667008, -1102867760040, 1171757692512, -1174521854176, 1167835079136, -1239722456016, 1321246238400, -1313545628736, 1307424001248, -1395533705856, 1474191694800, -1470135873888, 1472419748592, -1554105008016, 1647547321728, -1648658651200, 1632926218176, -1734153444192, 1844175455232, -1829372897088, 1821916743552, -1937378426368, 2043436190400, -2033547631104, 2028332946336, -2142281587248, 2267057828112, -2265622499712, 2244116900808, -2373665758992, 2521003646304, -2496637706688, 2478371203704]
[0, 1, 0, -12, 0, 54, 0, -88, 0, -99, 0, 540, 0, -418, 0, -648, 0, 594, 0, 836, 0, 1056, 0, -4104, 0, -209, 0, 4104, 0, -594, 0, 4256, 0, -6480, 0, -4752, 0, -298, 0, 5016, 0, 17226, 0, -12100, 0, -5346, 0, -1296, 0, -9063, 0, -7128, 0, 19494, 0, 29160, 0, -10032, 0, -7668, 0, -34738, 0, 8712, 0, -22572, 0, 21812, 0, 49248, 0, -46872, 0, 67562, 0, 2508, 0, -47520, 0, -76912, 0, -25191, 0, 67716, 0, 32076, 0, 7128, 0, 29754, 0, 36784, 0, -51072, 0, 45144, 0, -122398, 0, -53460, 0, 11286, 0, -27256, 0, 57024, 0, 122364, 0, 99902, 0, 3576, 0, -29646, 0, -221616, 0, 41382, 0, -52272, 0, 130549, 0, -206712, 0, -180036, 0, 336512, 0, 145200, 0, 100980, 0, -73568, 0, 221616, 0, -317142, 0, -148324, 0, 15552, 0, -225720, 0, -32076, 0, 108756, 0, 196614, 0, 74360, 0, -58806, 0, 229824, 0, 120878, 0, -233928, 0, 361152, 0, -111340, 0, -349920, 0, -491832, 0, -196569, 0, -82764, 0, 707454, 0, 18392, 0, 92016, 0, 493668, 0, -559450, 0, 416856, 0, -16092, 0, 320760, 0, -361152, 0, -724032, 0, 7106, 0, 270864, 0, -530442, 0, 56168, 0, -261744]
[0, 0, 1, 8, 32, 96, 244, 528, 1024, 1856, 3126, 5016, 7808, 11616, 16808, 23856, 32768, 44352, 59293, 77352, 100032, 128128, 161052, 201264, 249856, 305280, 371294, 450128, 537856, 640992, 762744, 894528, 1048576, 1228224, 1419858, 1642080, 1897376, 2167008, 2476100, 2830960, 3201024, 3619968, 4101152, 4594392, 5153664, 5792352, 6436344, 7167072, 7995392, 8828160, 9768751, 10826640, 11881408, 13068000, 14408200, 15731856, 17211392, 18880576, 20511150, 22341624, 24407808, 26394720, 28629152, 31143376, 33554432, 36271488, 39296688, 42190728, 45435456, 49075584, 52541808, 56383632, 60716032, 64781376, 69343958, 74486648, 79235200, 84594048, 90595736, 96160416, 102432768, 109413056, 115856202, 123092904, 131236864, 138701376, 147008444, 156397296, 164917248, 174500928, 185349918, 195021024, 205963008, 218298880, 229345008, 241882608, 255852544, 268358208, 282492057, 298415928, 312600032, 328440288, 346445352, 362274000, 380205056, 400629504, 418195494, 438293592, 461062400, 480816864, 503448552, 528747568, 550764544, 575761920, 604168400, 628757280, 656356800, 687971680, 714924300, 745782048, 781049856, 810545472, 844596302, 883410000, 916132864, 953985216, 996596744, 1032438528, 1073741824, 1120934848, 1160665044, 1205605896, 1257494016, 1300573824, 1350125108, 1407494112, 1453934592, 1508188800, 1570467936, 1621531032, 1681337856, 1748755200, 1804229352, 1868683344, 1942913024, 2003683968, 2073071594, 2153998536, 2219006656, 2294986848, 2383575244, 2453207856, 2535526400, 2630865600, 2706962016, 2796703104, 2899063552, 2980902240, 3077056400, 3188747952, 3277848576, 3380678400, 3501192601, 3595741512, 3707398464, 3838806144, 3939040644, 4059139920, 4199579648, 4308095616, 4438476108, 4587983752, 4704270208, 4842599520, 5004720600, 5131035888, 5277351936, 5451294912, 5584059450, 5742671976, 5931197376, 6070775136, 6240709552, 6440033776, 6590816256, 6774038400, 6985513088, 7145957808, 7339040256, 7567918336, 7740288600, 7943613312, 8187281408, 8368286784, 8587340258, 8850062496, 9039745824, 9272181600, 9549256236, 9752485776, 10003201024, 10294712128, 10510100502]
[0, 0, 0, 1, 0, 12, 0, 66, 0, 232, 0, 627, 0, 1452, 0, 2982, 0, 5544, 0, 9669, 0, 16016, 0, 25158, 0, 38160, 0, 56266, 0, 80124, 0, 111816, 0, 153528, 0, 205260, 0, 270876, 0, 353870, 0, 452496, 0, 574299, 0, 724044, 0, 895884, 0, 1103520, 0, 1353330, 0, 1633500, 0, 1966482, 0, 2360072, 0, 2792703, 0, 3299340, 0, 3892922, 0, 4533936, 0, 5273841, 0, 6134448, 0, 7047954, 0, 8097672, 0, 9310831, 0, 10574256, 0, 12020052, 0, 13676632, 0, 15386613, 0, 17337672, 0, 19549662, 0, 21812616, 0, 24377628, 0, 27287360, 0, 30235326, 0, 33544776, 0, 37301991, 0, 41055036, 0, 45284250, 0, 50078688, 0, 54786699, 0, 60102108, 0, 66093446, 0, 71970240, 0, 78594660, 0, 85996460, 0, 93222756, 0, 101318184, 0, 110426250, 0, 119248152, 0, 129054816, 0, 140116856, 0, 150700737, 0, 162571728, 0, 175936764, 0, 188523600, 0, 202691379, 0, 218594400, 0, 233585418, 0, 250460496, 0, 269249817, 0, 286873356, 0, 306650982, 0, 328858200, 0, 349587888, 0, 372612780, 0, 398593494, 0, 422584800, 0, 449467689, 0, 479850768, 0, 507392490, 0, 538511952, 0, 573497969, 0, 605324940, 0, 641379486, 0, 681411864, 0, 717833997, 0, 758846892, 0, 805004222, 0, 846754800, 0, 893244726, 0, 945989792, 0, 992951664, 0, 1046035848, 0, 1106257812, 0, 1159022700, 0, 1219060722, 0, 1286839016, 0, 1346684988]
[1, -504, -16632, -122976, -532728, -1575504, -4058208, -8471232, -17047800, -29883672, -51991632, -81170208, -129985632, -187132176, -279550656, -384422976, -545530104, -715608432, -986161176, -1247954400, -1665307728, -2066980608, -2678616864, -3243917376, -4159663200, -4923450504, -6175361808, -7261732800, -8954092224, -10337619600, -12685958208, -14429092608, -17456963832, -19805530752, -23615078256, -26481071232, -31587041304, -34949354832, -41182495200, -45660250944, -53291422800, -58391525808, -68210360064, -74092255776, -85796909856, -93416358672, -107049273408, -115589884032, -133109345376, -142375996728, -162473866632, -174608457408, -197798710032, -210770528976, -239637182400, -253738070208, -286539422400, -304500873600, -341141446800, -360321847200, -406335085632, -425676536208, -476160056064, -502284758976, -558622843128, -584975182176, -653582514816, -680463054432, -756398112624, -791515839744, -873875350656, -909331593408, -1010815205400, -1044828083376, -1153328709456, -1201321922976, -1319087800800, -1364308856064, -1506788281152, -1550836425600, -1705327105104, -1764601070904, -1926920351664, -1985276484576, -2184798502656, -2236991958432, -2445044440608, -2522379182400, -2745582285600, -2814365962800, -3082739836176, -3145317614208, -3428820666432, -3520698596352, -3814466173056, -3901105454400, -4259499175008, -4328019490032, -4698407892024, -4812825142944, -5204087182728, -5297090653008, -5762079094464, -5842741334976, -6329745853200, -6461381380608, -6955427456208, -7068860723232, -7675651569600, -7754664733200, -8373356316864, -8527642579008, -9169269988032, -9285873304176, -10048528828800, -10140485717376, -10926863917200, -11095628111568, -11890620957600, -12027946525056, -13003107163200, -13072543169112, -14047325694864, -14247532297152, -15251550886656, -15385782825504, -16575397046208, -16651338181632, -17875930980600, -18078510409344, -19304181011808, -19444062784608, -20934446004864, -20975617555200, -22455280796256, -22700176732800, -24205455212400, -24323909126832, -26120022711552, -26151977728800, -27990492292224, -28203931703808, -30007942582464, -30138011209152, -32346116456472, -32315398869600, -34479326751408, -34739743201632, -36941468057424, -37013646978000, -39643623458208, -39565373779008, -42212057580000, -42430570758576, -45022192250112, -45105343492608, -48262885247808, -48076052249232, -51177602044800, -51428009070144, -54570468938832, -54523763255808, -58231835339832, -57992062990176, -61719842779056, -61912089130752, -65514123991008, -65465560746432, -69915619065600, -69480867024072, -73820734628256, -73994960239200, -78315514355232, -78101801615376, -83238513019200, -82753356071232, -87858714309408, -87918530716800, -92874076772400, -92618062437600, -98741091116304, -97909179430608, -103795481268864, -103865074834752, -109725505243200, -109251683204832, -116183053679616, -115250169190464, -122178507421824, -122055204902400, -128736479995200, -128114230583808, -136303973723232, -134963732833776, -142824643171056, -142733944450944, -150491428541496, -149541477502032, -158823229717152, -157288118904000, -166535713297800]
http://oeis.org/A013973
返信削除の公式
E6(q) = eta(q)^24 / eta(q^2)^12 - 480 * eta(q^2)^12 - 16896 * eta(q^2)^12 * eta(q^4)^8 / eta(q)^8 + 8192 * eta(q^4)^24 / eta(q^2)^12
はこのままでは結果が一致しませんよね。
E6(q) = eta(q)^24 / eta(q^2)^12 - 480 * q* eta(q^2)^12 - 16896 * q^2* eta(q^2)^12 * eta(q^4)^8 / eta(q)^8 + 8192 *q^3* eta(q^4)^24 / eta(q^2)^12
と変更しておかないと一致しないような・・・
GAI
eta(q^2)^12 = q * Product_{n>=1} (1-q^(2*n)} なので、OEIS の公式は正しいです。
削除ちなみに、この公式はGunter Kohler のEta Products and Theta Series Identities のp.151 にも載っています。