- Clear["Global`*"];
- F[n_,m_]:=1/m DivisorSum[m, (-1)^(m-#)EulerPhi[m/#] Binomial[\[LeftFloor]# n/m\[RightFloor], #]&]
- Table[{{n,25},F[n,25]}, {n, 25, 100}]//MatrixForm
复制代码
运行结果:
{
{{25, 25}, 1},
{{26, 25}, 2},
{{27, 25}, 15},
{{28, 25}, 132},
{{29, 25}, 951},
{{30, 25}, 5702},
{{31, 25}, 29453},
{{32, 25}, 134636},
{{33, 25}, 555368},
{{34, 25}, 2098052},
{{35, 25}, 7343180},
{{36, 25}, 24032216},
{{37, 25}, 74099324},
{{38, 25}, 216598016},
{{39, 25}, 603380180},
{{40, 25}, 1609013812},
{{41, 25}, 4123097878},
{{42, 25}, 10186477096},
{{43, 25}, 24334361938},
{{44, 25}, 56353259212},
{{45, 25}, 126794833226},
{{46, 25}, 277741063232},
{{47, 25}, 593355907790},
{{48, 25}, 1238307981452},
{{49, 25}, 2528212128776},
{{50, 25}, 5056424257552},
{{51, 25}, 9918370659004},
{{52, 25}, 19102047195080},
{{53, 25}, 36157446476364},
{{54, 25}, 67327658955952},
{{55, 25}, 123434041419244},
{{56, 25}, 222977623208896},
{{57, 25}, 397178891340787},
{{58, 25}, 698071990841326},
{{59, 25}, 1211360219401069},
{{60, 25}, 2076617518973260},
{{61, 25}, 3518713018260157},
{{62, 25}, 5896221814381798},
{{63, 25}, 9775315113317107},
{{64, 25}, 16041542750058760},
{{65, 25}, 26067506968845484},
{{66, 25}, 41962328291312116},
{{67, 25}, 66939904655188252},
{{68, 25}, 105858453873320836},
{{69, 25}, 166005302664980284},
{{70, 25}, 258230470812191552},
{{71, 25}, 398573117992730264},
{{72, 25}, 610580095648437680},
{{73, 25}, 928590562131998804},
{{74, 25}, 1402361257097304152},
{{75, 25}, 2103541885645956228},
{{76, 25}, 3134689868805738456},
{{77, 25}, 4641752305731574020},
{{78, 25}, 6831258110321938896},
{{79, 25}, 9993877605841354828},
{{80, 25}, 14536549244860152476},
{{81, 25}, 21026080157744148804},
{{82, 25}, 30248045139210880428},
{{83, 25}, 43285995630250052724},
{{84, 25}, 61627519202389905276},
{{85, 25}, 87305652203385699140},
{{86, 25}, 123086657204773280348},
{{87, 25}, 172718373819601215572},
{{88, 25}, 241257411049601697548},
{{89, 25}, 335498587240852360265},
{{90, 25}, 464536505410410960366},
{{91, 25}, 640497302914354505439},
{{92, 25}, 879488833852546484568},
{{93, 25}, 1202830316886570926919},
{{94, 25}, 1638638402715038653566},
{{95, 25}, 2223866403684695315553},
{{96, 25}, 3006917954277897890796},
{{97, 25}, 4050986688402167991120},
{{98, 25}, 5438310896759074836756},
{{99, 25}, 7275578091610113632328},
{{100, 25}, 9700770788813484843104}
}
有了 mathe 的这个通用公式,随便你要什么数据都不是问题。 |