| 数据
|
0, 1, 2, 9, 64, 625, 7776, 117649, 2097144, 43046136, 999970020, 25936053990, 742947675624, 23295384644532, 793591829158128, 29187143427692250, 1152639088016576160, 48646833059722978080, 2185150741063924810176, 104085328898784937079376, 5240461483486301616704160
|
| 黄体脂酮素
|
(Python)
#打印序列中的第一个num_entries条目
导入数学,sympy;x=症状符号('x')
k=6;num_entries=64
P=范围(k+1);eP=总和(P]中d的[x**d/math.阶乘(d));r=[0,1];curr_pow=eP
对于范围(1,num_entries-1)中的术语:
…curr_pow=(curr_pow*eP).expand()
…r.append(curr_pow.coeff(x**项)*math.factorial(项))
打印(r)
|