发布网友 发布时间:2022-04-20 07:35
共5个回答
热心网友 时间:2023-09-22 21:17
(1 + x + x^2 + x^3 + x^4 + x^5 + x^6 + x^7 + x^8 + x^9)^7
=
1 + 7 x + 28 x^2 + 84 x^3 + 210 x^4 + 462 x^5 + 924 x^6 + 1716 x^7 + 3003 x^8 + 5005 x^9 + 8001 x^10 + 12327 x^11 + 18368 x^12 + 26544 x^13 + 37290 x^14 + 51030 x^15 + 68145 x^16 + 835 x^17 + 113575 x^18 + 142065 x^19 + 174195 x^20 + 209525 x^21 + 247380 x^22 + 286860 x^23 + 326865 x^24 + 366135 x^25 + 403305 x^26 + 436975 x^27 + 465795 x^28 + 488565 x^29 + 504315 x^30 + 512365 x^31 + 512365 x^32 + 504315 x^33 + 488565 x^34 + 465795 x^35 + 436975 x^36 + 403305 x^37 + 366135 x^38 + 326865 x^39 + 286860 x^40 + 247380 x^41 + 209525 x^42 + 174195 x^43 + 142065 x^44 + 113575 x^45 + 835 x^46 + 68145 x^47 + 51030 x^48 + 37290 x^49 + 26544 x^50 + 18368 x^51 + 12327 x^52 + 8001 x^53 + 5005 x^54 + 3003 x^55 + 1716 x^56 + 924 x^57 + 462 x^58 + 210 x^59 + 84 x^60 + 28 x^61 + 7 x^62 + x^63
其中504315 x^30系数为504315,也就是你需要的结果.
这是100000以内的所有数字的组合,不够7位的前面补零就是7位数字了,
总共3246个,如果是7位数的话至少10万以上的组合,我的机子没法运行的.
{3999, 49, 49, 4998, 5799, 58, 58, 5979, 5988, 5997, 6699,
67, 6798, 6879, 6888, 67, 6969, 6978, 6987, 6996, 7599, 76,
7698, 7779, 7788, 7797, 7869, 7878, 7887, 76, 7959, 7968, 7977,
7986, 7995, 8499, 85, 8598, 8679, 8688, 8697, 8769, 8778, 8787,
8796, 8859, 8868, 8877, 8886, 85, 49, 58, 67, 76, 85,
94, 9399, 94, 9498, 9579, 9588, 9597, 9669, 9678, 9687, 9696,
9759, 9768, 9777, 9786, 9795, 9849, 9858, 9867, 9876, 9885, 94,
9939, 9948, 9957, 9966, 9975, 9984, 9993, 12999, 139, 139, 13998,
14799, 148, 148, 14979, 14988, 14997, 15699, 157, 15798, 15879,
15888, 157, 15969, 15978, 15987, 15996, 16599, 166, 16698, 16779,
16788, 16797, 16869, 16878, 16887, 166, 16959, 16968, 16977, 16986,
16995, 17499, 175, 17598, 17679, 17688, 17697, 17769, 17778, 17787,
17796, 17859, 17868, 17877, 17886, 175, 17949, 17958, 17967, 17976,
17985, 17994, 18399, 184, 18498, 18579, 18588, 18597, 18669, 18678,
18687, 18696, 18759, 18768, 18777, 18786, 18795, 18849, 18858, 18867,
18876, 18885, 184, 139, 148, 157, 166, 175, 184, 193,
19299, 193, 19398, 19479, 19488, 19497, 19569, 19578, 19587, 19596,
19659, 19668, 19677, 19686, 19695, 19749, 19758, 19767, 19776, 19785,
19794, 19839, 19848, 19857, 19866, 19875, 19884, 193, 19929, 19938,
19947, 19956, 19965, 19974, 19983, 19992, 21999, 229, 229, 22998,
23799, 238, 238, 23979, 23988, 23997, 24699, 247, 24798, 24879,
24888, 247, 24969, 24978, 24987, 24996, 25599, 256, 25698, 25779,
25788, 25797, 25869, 25878, 25887, 256, 25959, 25968, 25977, 25986,
25995, 299, 265, 26598, 26679, 26688, 26697, 26769, 26778, 26787,
26796, 26859, 26868, 26877, 26886, 265, 26949, 26958, 26967, 26976,
26985, 26994, 27399, 274, 27498, 27579, 27588, 27597, 27669, 27678,
27687, 27696, 27759, 27768, 27777, 27786, 27795, 27849, 27858, 27867,
27876, 27885, 274, 27939, 27948, 27957, 27966, 27975, 27984, 27993,
28299, 283, 28398, 28479, 28488, 28497, 28569, 28578, 28587, 28596,
28659, 28668, 28677, 28686, 28695, 28749, 28758, 28767, 28776, 28785,
28794, 28839, 28848, 28857, 28866, 28875, 28884, 283, 229, 238,
247, 256, 265, 274, 283, 292, 29199, 292, 29298, 29379,
29388, 29397, 29469, 29478, 29487, 29496, 29559, 29568, 29577, 29586,
29595, 299, 29658, 29667, 29676, 29685, 29694, 29739, 29748, 29757,
29766, 29775, 29784, 29793, 29829, 29838, 29847, 29856, 29865, 29874,
29883, 292, 29919, 29928, 29937, 29946, 29955, 299, 29973, 29982,
29991, 30999, 319, 319, 31998, 32799, 328, 328, 32979, 32988,
32997, 33699, 337, 33798, 33879, 33888, 337, 33969, 33978, 33987,
33996, 34599, 346, 34698, 34779, 34788, 34797, 34869, 34878, 34887,
346, 34959, 34968, 34977, 34986, 34995, 35499, 355, 35598, 35679,
35688, 35697, 35769, 35778, 35787, 35796, 35859, 35868, 35877, 35886,
355, 35949, 35958, 35967, 35976, 35985, 35994, 36399, 3, 398,
36579, 36588, 36597, 36669, 36678, 36687, 36696, 36759, 36768, 36777,
36786, 36795, 36849, 36858, 36867, 36876, 36885, 364, 36939, 36948,
36957, 36966, 36975, 36984, 36993, 37299, 373, 37398, 37479, 37488,
37497, 37569, 37578, 37587, 37596, 37659, 37668, 37677, 37686, 37695,
37749, 37758, 37767, 37776, 37785, 37794, 37839, 37848, 37857, 37866,
37875, 37884, 373, 37929, 37938, 37947, 37956, 37965, 37974, 37983,
37992, 38199, 382, 38298, 38379, 38388, 38397, 38469, 38478, 38487,
38496, 38559, 38568, 38577, 38586, 38595, 3, 38658, 38667, 38676,
38685, 38694, 38739, 38748, 38757, 38766, 38775, 38784, 38793, 38829,
38838, 38847, 38856, 38865, 38874, 38883, 382, 319, 328, 337,
346, 355, 3, 373, 382, 391, 39099, 391, 39198, 39279,
39288, 39297, 39369, 39378, 39387, 39396, 39459, 39468, 39477, 39486,
39495, 39549, 39558, 39567, 39576, 39585, 39594, 39639, 398, 39657,
39666, 39675, 39684, 39693, 39729, 39738, 39747, 39756, 39765, 39774,
39783, 39792, 39819, 39828, 39837, 39846, 39855, 398, 39873, 39882,
391, 39909, 39918, 39927, 39936, 39945, 39954, 39963, 39972, 39981,
39990, 409, 409, 40998, 41799, 418, 418, 41979, 41988, 41997,
42699, 427, 42798, 42879, 42888, 427, 42969, 42978, 42987, 42996,
43599, 436, 43698, 43779, 43788, 43797, 43869, 43878, 43887, 436,
43959, 43968, 43977, 43986, 43995, 44499, 445, 44598, 44679, 44688,
44697, 44769, 44778, 44787, 44796, 44859, 44868, 44877, 44886, 445,
44949, 44958, 44967, 44976, 44985, 44994, 45399, 454, 45498, 45579,
45588, 45597, 45669, 45678, 45687, 45696, 45759, 45768, 45777, 45786,
45795, 45849, 45858, 45867, 45876, 45885, 454, 45939, 45948, 45957,
45966, 45975, 45984, 45993, 46299, 463, 46398, 479, 488, 497,
46569, 46578, 46587, 46596, 46659, 46668, 46677, 46686, 46695, 46749,
46758, 46767, 46776, 46785, 46794, 46839, 46848, 46857, 46866, 46875,
46884, 463, 46929, 46938, 46947, 46956, 46965, 46974, 46983, 46992,
47199, 472, 47298, 47379, 47388, 47397, 47469, 47478, 47487, 47496,
47559, 47568, 47577, 47586, 47595, 479, 47658, 47667, 47676, 47685,
47694, 47739, 47748, 47757, 47766, 47775, 47784, 47793, 47829, 47838,
47847, 47856, 47865, 47874, 47883, 472, 47919, 47928, 47937, 47946,
47955, 479, 47973, 47982, 47991, 48099, 481, 48198, 48279, 48288,
48297, 48369, 48378, 48387, 48396, 48459, 48468, 48477, 48486, 48495,
48549, 48558, 48567, 48576, 48585, 48594, 48639, 488, 48657, 48666,
48675, 48684, 48693, 48729, 48738, 48747, 48756, 48765, 48774, 48783,
48792, 48819, 48828, 48837, 48846, 48855, 488, 48873, 48882, 481,
409, 418, 427, 436, 445, 454, 463, 472, 481, 490,
490, 49098, 49179, 49188, 49197, 49269, 49278, 49287, 49296, 49359,
49368, 49377, 49386, 49395, 49449, 49458, 49467, 49476, 49485, 49494,
49539, 49548, 49557, 49566, 49575, 49584, 49593, 49629, 49638, 497,
49656, 49665, 49674, 49683, 49692, 49719, 49728, 49737, 49746, 49755,
497, 49773, 49782, 49791, 49809, 49818, 49827, 49836, 49845, 49854,
49863, 49872, 49881, 490, 49908, 49917, 49926, 49935, 49944, 49953,
49962, 49971, 49980, 50799, 508, 508, 50979, 50988, 50997, 51699,
517, 51798, 51879, 51888, 517, 51969, 51978, 51987, 51996, 52599,
526, 52698, 52779, 52788, 52797, 52869, 52878, 52887, 526, 52959,
52968, 52977, 52986, 52995, 53499, 535, 53598, 53679, 53688, 53697,
53769, 53778, 53787, 53796, 53859, 53868, 53877, 53886, 535, 53949,
53958, 53967, 53976, 53985, 53994, 54399, 544, 54498, 54579, 54588,
54597, 54669, 54678, 54687, 54696, 54759, 54768, 54777, 54786, 54795,
54849, 54858, 54867, 54876, 54885, 544, 54939, 54948, 54957, 54966,
54975, 54984, 54993, 55299, 553, 55398, 55479, 55488, 55497, 55569,
55578, 55587, 55596, 55659, 55668, 55677, 55686, 55695, 55749, 55758,
55767, 55776, 55785, 55794, 55839, 55848, 55857, 55866, 55875, 55884,
553, 55929, 55938, 55947, 55956, 55965, 55974, 55983, 55992, 56199,
562, 56298, 56379, 56388, 56397, 569, 578, 587, 596, 56559,
56568, 56577, 56586, 56595, 569, 56658, 56667, 56676, 56685, 56694,
56739, 56748, 56757, 56766, 56775, 56784, 56793, 56829, 56838, 56847,
56856, 56865, 56874, 56883, 562, 56919, 56928, 56937, 56946, 56955,
......
79752, 79761, 79770, 79806, 79815, 79824, 79833, 79842, 79851, 79860,
79905, 79914, 79923, 79932, 79941, 79950, 80499, 805, 80598, 80679,
80688, 80697, 80769, 80778, 80787, 80796, 80859, 80868, 80877, 80886,
805, 80949, 80958, 80967, 80976, 80985, 80994, 81399, 814, 81498,
81579, 81588, 81597, 81669, 81678, 81687, 81696, 81759, 81768, 81777,
81786, 81795, 81849, 81858, 81867, 81876, 81885, 814, 81939, 81948,
81957, 81966, 81975, 81984, 81993, 82299, 823, 82398, 82479, 82488,
82497, 82569, 82578, 82587, 82596, 82659, 82668, 82677, 82686, 82695,
82749, 82758, 82767, 82776, 82785, 82794, 82839, 82848, 82857, 82866,
82875, 82884, 823, 82929, 82938, 82947, 82956, 82965, 82974, 82983,
82992, 83199, 832, 83298, 83379, 83388, 83397, 83469, 83478, 83487,
83496, 83559, 83568, 83577, 83586, 83595, 839, 83658, 83667, 83676,
83685, 83694, 83739, 83748, 83757, 83766, 83775, 83784, 83793, 83829,
83838, 83847, 83856, 83865, 83874, 83883, 832, 83919, 83928, 83937,
83946, 83955, 839, 83973, 83982, 83991, 84099, 841, 84198, 84279,
84288, 84297, 84369, 84378, 84387, 84396, 84459, 84468, 84477, 84486,
84495, 84549, 84558, 84567, 84576, 84585, 84594, 84639, 848, 84657,
84666, 84675, 84684, 84693, 84729, 84738, 84747, 84756, 84765, 84774,
84783, 84792, 84819, 84828, 84837, 84846, 84855, 848, 84873, 84882,
841, 84909, 84918, 84927, 84936, 84945, 84954, 84963, 84972, 84981,
84990, 850, 85098, 85179, 85188, 85197, 85269, 85278, 85287, 85296,
85359, 85368, 85377, 85386, 85395, 85449, 85458, 85467, 85476, 85485,
85494, 85539, 85548, 85557, 85566, 85575, 85584, 85593, 85629, 85638,
857, 85656, 85665, 85674, 85683, 85692, 85719, 85728, 85737, 85746,
85755, 857, 85773, 85782, 85791, 85809, 85818, 85827, 85836, 85845,
85854, 85863, 85872, 85881, 850, 85908, 85917, 85926, 85935, 85944,
85953, 85962, 85971, 85980, 86079, 86088, 86097, 86169, 86178, 86187,
86196, 86259, 86268, 86277, 86286, 86295, 86349, 86358, 86367, 86376,
86385, 86394, 839, 848, 857, 866, 875, 884, 3, 86529,
86538, 86547, 86556, 86565, 86574, 86583, 86592, 86619, 86628, 86637,
866, 86655, 866, 86673, 86682, 86691, 86709, 86718, 86727, 86736,
86745, 86754, 86763, 86772, 86781, 86790, 86808, 86817, 86826, 86835,
86844, 86853, 86862, 86871, 86880, 86907, 86916, 86925, 86934, 86943,
86952, 86961, 86970, 87069, 87078, 87087, 87096, 87159, 87168, 87177,
87186, 87195, 87249, 87258, 87267, 87276, 87285, 87294, 87339, 87348,
87357, 87366, 87375, 87384, 87393, 87429, 87438, 87447, 87456, 87465,
87474, 87483, 87492, 87519, 87528, 87537, 87546, 87555, 875, 87573,
87582, 87591, 87609, 87618, 87627, 87636, 875, 87654, 87663, 87672,
87681, 87690, 87708, 87717, 87726, 87735, 87744, 87753, 87762, 87771,
87780, 87807, 87816, 87825, 87834, 87843, 87852, 87861, 87870, 87906,
87915, 87924, 87933, 87942, 87951, 87960, 88059, 88068, 88077, 88086,
88095, 88149, 88158, 88167, 88176, 88185, 88194, 88239, 88248, 88257,
88266, 88275, 88284, 88293, 88329, 88338, 88347, 88356, 88365, 88374,
88383, 88392, 88419, 88428, 88437, 88446, 88455, 884, 88473, 88482,
88491, 88509, 88518, 88527, 88536, 88545, 88554, 88563, 88572, 88581,
88590, 88608, 88617, 88626, 88635, 884, 88653, 88662, 88671, 88680,
88707, 88716, 88725, 88734, 88743, 88752, 88761, 88770, 88806, 88815,
88824, 88833, 88842, 88851, 88860, 805, 814, 823, 832, 841,
850, 049, 058, 067, 076, 085, 094, 139, 148, 157,
166, 175, 184, 193, 229, 238, 247, 256, 265, 274,
283, 292, 319, 328, 337, 346, 355, 3, 373, 382,
391, 409, 418, 427, 436, 445, 454, 463, 472, 481,
490, 508, 517, 526, 535, 544, 553, 562, 571, 580,
607, 616, 625, 634, 3, 652, 661, 670, 706, 715,
724, 733, 742, 751, 760, 805, 814, 823, 832, 841,
850, 904, 913, 922, 931, 940, 90399, 904, 90498, 90579,
90588, 90597, 90669, 90678, 90687, 90696, 90759, 90768, 90777, 90786,
90795, 90849, 90858, 90867, 90876, 90885, 904, 90939, 90948, 90957,
90966, 90975, 90984, 90993, 91299, 913, 91398, 91479, 91488, 91497,
91569, 91578, 91587, 91596, 91659, 91668, 91677, 91686, 91695, 91749,
91758, 91767, 91776, 91785, 91794, 91839, 91848, 91857, 91866, 91875,
91884, 913, 91929, 91938, 91947, 91956, 91965, 91974, 91983, 91992,
92199, 922, 92298, 92379, 92388, 92397, 92469, 92478, 92487, 92496,
92559, 92568, 92577, 92586, 92595, 929, 92658, 92667, 92676, 92685,
92694, 92739, 92748, 92757, 92766, 92775, 92784, 92793, 92829, 92838,
92847, 92856, 92865, 92874, 92883, 922, 92919, 92928, 92937, 92946,
92955, 929, 92973, 92982, 92991, 93099, 931, 93198, 93279, 93288,
93297, 93369, 93378, 93387, 93396, 93459, 93468, 93477, 93486, 93495,
93549, 93558, 93567, 93576, 93585, 93594, 93639, 938, 93657, 93666,
93675, 93684, 93693, 93729, 93738, 93747, 93756, 93765, 93774, 93783,
93792, 93819, 93828, 93837, 93846, 93855, 938, 93873, 93882, 931,
93909, 93918, 93927, 93936, 93945, 93954, 93963, 93972, 93981, 93990,
940, 94098, 94179, 94188, 94197, 94269, 94278, 94287, 94296, 94359,
94368, 94377, 94386, 94395, 94449, 94458, 94467, 94476, 94485, 94494,
94539, 94548, 94557, 94566, 94575, 94584, 94593, 94629, 94638, 947,
94656, 94665, 94674, 94683, 94692, 94719, 94728, 94737, 94746, 94755,
947, 94773, 94782, 94791, 94809, 94818, 94827, 94836, 94845, 94854,
94863, 94872, 94881, 940, 94908, 94917, 94926, 94935, 94944, 94953,
94962, 94971, 94980, 95079, 95088, 95097, 95169, 95178, 95187, 95196,
95259, 95268, 95277, 95286, 95295, 95349, 95358, 95367, 95376, 95385,
95394, 95439, 95448, 95457, 95466, 95475, 95484, 95493, 95529, 95538,
95547, 95556, 95565, 95574, 95583, 95592, 95619, 95628, 95637, 956,
95655, 956, 95673, 95682, 95691, 95709, 95718, 95727, 95736, 95745,
95754, 95763, 95772, 95781, 95790, 95808, 95817, 95826, 95835, 95844,
95853, 95862, 95871, 95880, 95907, 95916, 95925, 95934, 95943, 95952,
95961, 95970, 96069, 96078, 96087, 96096, 96159, 96168, 96177, 96186,
96195, 96249, 96258, 96267, 96276, 96285, 96294, 96339, 96348, 96357,
96366, 96375, 96384, 96393, 929, 938, 947, 956, 965, 974,
983, 992, 96519, 96528, 96537, 96546, 96555, 965, 96573, 96582,
96591, 96609, 96618, 96627, 96636, 965, 96654, 96663, 96672, 96681,
96690, 96708, 96717, 96726, 96735, 96744, 96753, 96762, 96771, 96780,
96807, 96816, 96825, 96834, 96843, 96852, 96861, 96870, 96906, 96915,
96924, 96933, 96942, 96951, 96960, 97059, 97068, 97077, 97086, 97095,
97149, 97158, 97167, 97176, 97185, 97194, 97239, 97248, 97257, 97266,
97275, 97284, 97293, 97329, 97338, 97347, 97356, 97365, 97374, 97383,
97392, 97419, 97428, 97437, 97446, 97455, 974, 97473, 97482, 97491,
97509, 97518, 97527, 97536, 97545, 97554, 97563, 97572, 97581, 97590,
97608, 97617, 97626, 97635, 974, 97653, 97662, 97671, 97680, 97707,
97716, 97725, 97734, 97743, 97752, 97761, 97770, 97806, 97815, 97824,
97833, 97842, 97851, 97860, 97905, 97914, 97923, 97932, 97941, 97950,
98049, 98058, 98067, 98076, 98085, 98094, 98139, 98148, 98157, 98166,
98175, 98184, 98193, 98229, 98238, 98247, 98256, 98265, 98274, 98283,
98292, 98319, 98328, 98337, 98346, 98355, 983, 98373, 98382, 98391,
98409, 98418, 98427, 98436, 98445, 98454, 98463, 98472, 98481, 98490,
98508, 98517, 98526, 98535, 98544, 98553, 98562, 98571, 98580, 98607,
98616, 98625, 98634, 983, 98652, 98661, 98670, 98706, 98715, 98724,
98733, 98742, 98751, 98760, 98805, 98814, 98823, 98832, 98841, 98850,
904, 913, 922, 931, 940, 99039, 99048, 99057, 99066, 99075,
99084, 99093, 99129, 99138, 99147, 99156, 99165, 99174, 99183, 99192,
99219, 99228, 99237, 99246, 99255, 992, 99273, 99282, 99291, 99309,
99318, 99327, 99336, 99345, 99354, 99363, 99372, 99381, 99390, 99408,
99417, 99426, 99435, 99444, 99453, 99462, 99471, 99480, 99507, 99516,
99525, 99534, 99543, 99552, 99561, 99570, 99606, 99615, 99624, 99633,
992, 99651, 99660, 99705, 99714, 99723, 99732, 99741, 99750, 99804,
99813, 99822, 99831, 99840, 99903, 99912, 99921, 99930}
热心网友 时间:2023-09-22 21:18
这题可以用母函数来做
设函数f(x)=(x^0+x^1+x^2+x^3+x^4+x^5+x^6+x^7+x^8+x^9)^7
则答案就应该是x^30前面的系数
对上式的理解是这样的:
括号中的项都是x^i的形式(0<=i<=9),我们可以选择x^i看做选择数i,那么在将括号的7次方展开时我们可以发现x^30前面的系数代表的意义是从7个括号中选数使得选出的7个数的乘积为x^30,又有前述可知可以把x^i看做数i,那么就是说x^30前的系数就是从0到9选出7个数相加等于30的组合数
至于算f(x)的展开式中x^30前的系数没有比较好的方法,我用电脑算了下答案是504315
C++的程序可以像下面这样来编:
#include<iostream>
const int n=7;
const int m=30;
int i,j,k;
int a[10][100];
int main()
{
a[0][0]=1;
for(i=1;i<=n;++i)
for(j=0;j<=9*(i-1);++j)
for(k=0;k<=9;++k)
a[i][j+k]+=a[i-1][j];
printf("%d\n",a[n][m]);
system("pause");
}
热心网友 时间:2023-09-22 21:18
(1+x+x2+x3+x4+x5+x6+x7+x8+x9)7
上面说的数字全是次方..和为30的,就是这个多项式展开中的x30的系数..
生成函数来解。
热心网友 时间:2023-09-22 21:19
令生成函数y=(1+t+t^2+t^3+t^4+t^5+t^6+t^7+t^8+t^9)^7=
∑Ai*t^i (0<=t<=63)
我们就是求A30,也就是t^30 的系数,
y=(1+t+t^2+t^3+t^4+t^5+t^6+t^7+t^8+t^9)^7
=[(1-t^10)/(1-t)]^7
A30=504315
热心网友 时间:2023-09-22 21:19
7的平方+6的平方+...+1的平方