In[]:=
First[Values[ResourceFunction["GraphNeighborhoodVolumes"][NestGraph[n{n+4,n+7},0,30],{0}]]]
Out[]=
{1,3,6,10,15,21,28,35,42,49,56,63,70,77,84,91,98,105,112,119,126,133,140,147,154,161,168,175,182,189,196}
In[]:=
FindSequenceFunction[%32,t]
Out[]=
DifferenceRootFunction{y.,n.},7+7n.+(5-n.)y.[n.]+(-7+n.)y.[1+n.]0,y.[1]1,y.[2]3,y.[3]6,y.[4]10,y.[5]15,y.[6]21,y.[7]28,y.[8]35[t]
In[]:=
FullSimplify[%]
Out[]=
DifferenceRootFunction{y.,n.},7+7n.+(5-n.)y.[n.]+(-7+n.)y.[1+n.]0,y.[1]1,y.[2]3,y.[3]6,y.[4]10,y.[5]15,y.[6]21,y.[7]28,y.[8]35[t]
In[]:=
FindLinearRecurrence[%32]
Out[]=
FindLinearRecurrence[{1,3,6,10,15,21,28,35,42,49,56,63,70,77,84,91,98,105,112,119,126,133,140,147,154,161,168,175,182,189,196}]
In[]:=
Differences[%]
Out[]=
{2,3,4,5,6,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7}
LCM[4,7]
In[]:=
First[Values[ResourceFunction["GraphNeighborhoodVolumes"][NestGraph[n{n+11,n+7},0,30],{0}]]]
Out[]=
{1,3,6,10,15,21,28,36,45,55,66,77,88,99,110,121,132,143,154,165,176,187,198,209,220,231,242,253,264,275,286}
In[]:=
Differences[%]
Out[]=
{2,3,4,5,6,7,8,9,10,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11}
In[]:=
Sum[7,{i,t}]
Out[]=
7t
In[]:=
28-49
Out[]=
-21
In[]:=
Table[7t-21,{t,10}]
Out[]=
{-14,-7,0,7,14,21,28,35,42,49}
In[]:=
Table[4t-6,{t,10}]
Out[]=
{-2,2,6,10,14,18,22,26,30,34}
In[]:=
Table[Labeled[NestGraph[n{an,bn},1,5],{a,b}],{a,5},{b,5}]
In[]:=
Table[With[{a=RandomInteger[20],b=RandomInteger[20]},Labeled[NestGraph[n{an,bn},1,5],{a,b}]],30]
In[]:=
NestGraph[n{6n,2n},1,30]
Out[]=
In[]:=
NestGraph[n{8n,4n},1,30]
Out[]=
In[]:=
NestGraph[nIf[EvenQ[n],{n/2,n+1},{3n+1,n+1}],0,20]
Out[]=
In[]:=
First[Values[ResourceFunction["GraphNeighborhoodVolumes"][NestGraph[nIf[EvenQ[n],{n/2,n+1},{3n+1,n+1}],0,30],{0}]]]
Out[]=
{1,2,4,6,9,13,19,26,38,52,74,101,144,199,280,383,542,748,1056,1458,2054,2841,4002,5557,7818,10843,15261,21234,29867,41544,58389}
In[]:=
Ratios[%]//N
Out[]=
{2.,2.,1.5,1.5,1.44444,1.46154,1.36842,1.46154,1.36842,1.42308,1.36486,1.42574,1.38194,1.40704,1.36786,1.41514,1.38007,1.41176,1.38068,1.40878,1.38315,1.40866,1.38856,1.40687,1.38693,1.40745,1.39139,1.40656,1.39097,1.40547}
In[]:=
ListLinePlot[%]
Out[]=
In[]:=
NestGraph[n{If[EvenQ[n],n/2,2n],n+1},0,20]
Out[]=
In[]:=
NestGraph[n{If[EvenQ[n],n/2,3n],n+1},0,15]
Out[]=
In[]:=
NestGraph[n{If[EvenQ[n],n/2,n],n+1},0,30]
Out[]=
Causal Invariance
Causal Invariance