对于每一种情况,可以根据连通情况,将其分成k个部分,每个部分内部都是连通的,与其他部分都不连通。
比如 (2,2,4) 代表N=8,分成三个部分,每个部分都是连通的。
(2,2,4)情况的概率记做 T(2,2,4)
---------------------------
当N所有情况的概率都知道的情况下,可以递推出N+1的所有情况的概率。
这样根据初始条件
T(2)=P 记做(0,1) 表示0+1*P (多项式系数表示法)
T(1,1)=1-P 记做(1,-1) 表示1-1*P (多项式系数表示法)
可依次递推。
以下是结果。
T(2)=(0,1)
T(1,1)=(1,-1)
T(3)=(0,0,3,-2)
T(1,2)=(0,3,-6,3)
T(1,1,1)=(1,-3,3,-1)
T(4)=(0,0,0,16,-33,24,-6)
T(1,3)=(0,0,12,-44,60,-36,8)
T(2,2)=(0,0,3,-12,18,-12,3)
T(1,1,2)=(0,6,-30,60,-60,30,-6)
T(1,1,1,1)=(1,-6,15,-20,15,-6,1)
T(5)=(0,0,0,0,125,-528,970,-980,570,-180,24)
T(1,4)=(0,0,0,80,-485,1260,-1820,1580,-825,240,-30)
T(2,3)=(0,0,0,30,-200,570,-900,850,-480,150,-20)
T(1,1,3)=(0,0,30,-230,770,-1470,1750,-1330,630,-170,20)
T(1,2,2)=(0,0,15,-120,420,-840,1050,-840,420,-120,15)
T(1,1,1,2)=(0,10,-90,360,-840,1260,-1260,840,-360,90,-10)
T(1,1,1,1,1)=(1,-10,45,-120,210,-252,210,-120,45,-10,1)
T(6)=(0,0,0,0,0,1296,-9300,31080,-63195,86110,-81840,54780,-25440,7830,-1440,120)
T(1,5)=(0,0,0,0,750,-6918,29160,-74160,126450,-151770,130812,-80940,35220,-10260,1800,-144)
T(2,4)=(0,0,0,0,240,-2415,11040,-30270,55320,-70770,64680,-42240,19320,-5895,1080,-90)
T(1,1,4)=(0,0,0,240,-2655,13455,-41310,85590,-126090,135450,-106920,61560,-25215,6975,-1170,90)
T(3,3)=(0,0,0,0,90,-930,4360,-12240,22860,-29820,27720,-18360,8490,-2610,480,-40)
T(1,2,3)=(0,0,0,180,-2100,11220,-36300,79200,-122760,138600,-114840,69300,-29700,8580,-1500,120)
T(1,1,1,3)=(0,0,60,-760,4440,-15840,38500,-67320,87120,-84480,61380,-33000,12760,-3360,540,-40)
T(2,2,2)=(0,0,0,15,-180,990,-3300,7425,-11880,13860,-11880,7425,-3300,990,-180,15)
T(1,1,2,2)=(0,0,45,-585,3510,-12870,32175,-57915,77220,-77220,57915,-32175,12870,-3510,585,-45)
T(1,1,1,1,2)=(0,15,-210,1365,-5460,15015,-30030,45045,-51480,45045,-30030,15015,-5460,1365,-210,15)
T(1,1,1,1,1,1)=(1,-15,105,-455,1365,-3003,5005,-6435,6435,-5005,3003,-1365,455,-105,15,-1)
T(7)=(0,0,0,0,0,0,16807,-183810,965160,-3209430,7527471,-13150032,17633945,-18448710,15159120,-9770810,4894680,-1869840,526890,-103320,12600,-720)
T(1,6)=(0,0,0,0,0,9072,-119532,744240,-2905665,7958440,-16207107,25372662,-31133375,30246090,-23331525,14237020,-6797280,2488290,-674940,127890,-15120,840)
T(2,5)=(0,0,0,0,0,2625,-37338,249375,-1038240,3016230,-6483960,10669680,-13710060,13902525,-11162130,7071855,-3498096,1324260,-370860,72450,-8820,504)
T(1,1,5)=(0,0,0,0,2625,-39963,286713,-1287615,4054470,-9500190,17153640,-24379740,27612585,-25064655,18233985,-10569951,4822356,-1695120,443310,-81270,9324,-504)
T(3,4)=(0,0,0,0,0,1680,-24745,170730,-732480,2187220,-4820235,8110410,-10628310,10963260,-8931615,5728030,-2861460,1091580,-307405,60270,-7350,420)
T(1,2,4)=(0,0,0,0,1680,-26985,203910,-962745,3181080,-7806435,14733810,-21846825,25765740,-24309285,18348330,-11016915,5197920,-1886745,508830,-96075,11340,-630)
T(1,1,1,4)=(0,0,0,560,-9555,76965,-388885,1381275,-3662505,7513415,-12193545,15870855,-16691675,14219205,-9788415,5404945,-2361555,798525,-201635,35805,-3990,210)
T(1,3,3)=(0,0,0,0,630,-10290,79030,-379050,1271550,-3165890,6057870,-9099090,10860850,-10360350,7897890,-4783870,2274090,-830550,225050,-42630,5040,-280)
T(2,2,3)=(0,0,0,0,315,-5250,41160,-201600,690900,-1758120,3439800,-5285280,6456450,-6306300,4924920,-3057600,1490580,-558600,155400,-30240,3675,-210)
T(1,1,2,3)=(0,0,0,630,-11130,92820,-485520,1785000,-4898040,10395840,-17450160,23483460,-25525500,22462440,-15965040,9096360,-4098360,1428000,-371280,67830,-7770,420)
T(1,1,1,1,3)=(0,0,105,-1960,17325,-96390,378420,-1113840,2548980,-4641000,6822270,-8168160,7997990,-6404580,4176900,-2199120,921060,-299880,73185,-12600,1365,-70)
T(1,2,2,2)=(0,0,0,105,-1890,16065,-85680,321300,-899640,1949220,-3341520,4594590,-5105100,4594590,-3341520,1949220,-899640,321300,-85680,16065,-1890,105)
T(1,1,1,2,2)=(0,0,105,-1995,17955,-101745,406980,-1220940,2848860,-5290740,7936110,-9699690,9699690,-7936110,5290740,-2848860,1220940,-406980,101745,-17955,1995,-105)
T(1,1,1,1,1,2)=(0,21,-420,3990,-23940,101745,-325584,813960,-1627920,2645370,-3527160,3879876,-3527160,2645370,-1627920,813960,-325584,101745,-23940,3990,-420,21)
T(1,1,1,1,1,1,1)=(1,-21,210,-1330,5985,-20349,54264,-116280,203490,-293930,352716,-352716,293930,-203490,116280,-54264,20349,-5985,1330,-210,21,-1) |