A241477
Triangle read by rows, number of orbitals classified with respect to the first zero crossing, n>=1, 1<=k<=n.
Original entry on oeis.org
1, 0, 2, 2, 2, 2, 0, 4, 0, 2, 6, 12, 4, 2, 6, 0, 12, 0, 4, 0, 4, 20, 60, 12, 12, 12, 4, 20, 0, 40, 0, 12, 0, 8, 0, 10, 70, 280, 40, 60, 36, 24, 40, 10, 70, 0, 140, 0, 40, 0, 24, 0, 20, 0, 28, 252, 1260, 140, 280, 120, 120, 120, 60, 140, 28, 252, 0, 504, 0
Offset: 1
[1], [ 1]
[2], [ 0, 2]
[3], [ 2, 2, 2]
[4], [ 0, 4, 0, 2]
[5], [ 6, 12, 4, 2, 6]
[6], [ 0, 12, 0, 4, 0, 4]
[7], [20, 60, 12, 12, 12, 4, 20]
-
A241477 := proc(n, k)
if n = 0 then 1
elif k = 0 then 0
elif irem(n, 2) = 0 and irem(k, 2) = 1 then 0
elif k = 1 then (n-1)!/iquo(n-1,2)!^2
else 2*(n-k)!*(k-2)!/iquo(k,2)/(iquo(k-2,2)!*iquo(n-k,2)!)^2
fi end:
for n from 1 to 9 do seq(A241477(n, k), k=1..n) od;
-
T[n_, k_] := Which[n == 0, 1, k == 0, 0, Mod[n, 2] == 0 && Mod[k, 2] == 1, 0, k == 1, (n-1)!/Quotient[n-1, 2]!^2, True, 2*(n-k)!*(k-2)!/Quotient[k, 2]/(Quotient[k-2, 2]!*Quotient[n-k, 2]!)^2];
Table[T[n, k], {n, 1, 12}, {k, 1, n}] // Flatten (* Jean-François Alcover, Jun 20 2018, from Maple *)
-
def A241477_row(n):
if n == 0: return [1]
Z = [0]*n; T = [0] if is_odd(n) else []
for i in (1..n//2): T.append(-1); T.append(1)
for p in Permutations(T):
i = 0; s = p[0]
while s != 0: i += 1; s += p[i];
Z[i] += 1
return Z
for n in (1..9): A241477_row(n)
A274879
A statistic on orbital systems over n sectors: the number of orbitals with k returns.
Original entry on oeis.org
1, 1, 2, 2, 4, 2, 4, 6, 12, 12, 4, 8, 8, 20, 40, 48, 32, 10, 20, 24, 16, 70, 140, 180, 160, 80, 28, 56, 72, 64, 32, 252, 504, 672, 672, 480, 192, 84, 168, 224, 224, 160, 64, 924, 1848, 2520, 2688, 2240, 1344, 448, 264, 528, 720, 768, 640, 384, 128
Offset: 0
Triangle read by rows, n>=0. The length of row n is floor((n+1)/2) for n>=1.
[ n] [k=0,1,2,...] [row sum]
[ 0] [1] 1
[ 1] [1] 1
[ 2] [2] 2
[ 3] [2, 4] 6
[ 4] [2, 4] 6
[ 5] [6, 12, 12] 30
[ 6] [4, 8, 8] 20
[ 7] [20, 40, 48, 32] 140
[ 8] [10, 20, 24, 16] 70
[ 9] [70, 140, 180, 160, 80] 630
[10] [28, 56, 72, 64, 32] 252
[11] [252, 504, 672, 672, 480, 192] 2772
T(6,0) = 4 because the following 4 orbitals stay above or below the central
circle: [-1, -1, -1, 1, 1, 1], [-1, -1, 1, -1, 1, 1], [1, 1, -1, 1, -1, -1],
[1, 1, 1, -1, -1, -1].
-
# uses[unit_orbitals from A274709]
from itertools import accumulate
# Brute force counting
def orbital_returns(n):
if n == 0: return [1]
S = [0]*((n+1)//2)
for u in unit_orbitals(n):
L = list(accumulate(u))
Z = len(list(filter(lambda z: z == 0, L)))
S[Z-1] += 1 # exclude origin
return S
for n in (0..10): print(orbital_returns(n))
A275325
Triangle read by rows: number of orbitals over n sectors which have a Catalan decomposition into k parts.
Original entry on oeis.org
1, 0, 1, 0, 2, 0, 6, 0, 4, 2, 0, 20, 10, 0, 10, 8, 2, 0, 70, 56, 14, 0, 28, 28, 12, 2, 0, 252, 252, 108, 18, 0, 84, 96, 54, 16, 2, 0, 924, 1056, 594, 176, 22, 0, 264, 330, 220, 88, 20, 2, 0, 3432, 4290, 2860, 1144, 260, 26, 0, 858, 1144, 858, 416, 130, 24, 2
Offset: 0
Table starts:
[ n] [k=0,1,2,...] [row sum]
[ 0] [1] 1
[ 1] [0, 1] 1
[ 2] [0, 2] 2
[ 3] [0, 6] 6
[ 4] [0, 4, 2] 6
[ 5] [0, 20, 10] 30
[ 6] [0, 10, 8, 2] 20
[ 7] [0, 70, 56, 14] 140
[ 8] [0, 28, 28, 12, 2] 70
[ 9] [0, 252, 252, 108, 18] 630
[10] [0, 84, 96, 54, 16, 2] 252
[11] [0, 924, 1056, 594, 176, 22] 2772
[12] [0, 264, 330, 220, 88, 20, 2] 924
For example T(2*n, n) = 2 counts the Catalan decompositions
[[-1, 1], [1, -1], [-1, 1], ..., [(-1)^n, (-1)^(n+1)]] and
[[1, -1], [-1, 1], [1, -1], ..., [(-1)^(n+1), (-1)^n]].
-
# uses[unit_orbitals from A274709]
# Brute force counting
from itertools import accumulate
def catalan_factors(P):
def bisect(orb):
i = 1
A = list(accumulate(orb))
if orb[1] > 0 if orb[0] == 0 else orb[0] > 0:
while i < len(A) and A[i] >= 0: i += 1
else:
while i < len(A) and A[i] <= 0: i += 1
return i
R = []
while P:
i = bisect(P)
R.append(P[:i])
P = P[i:]
return R
def orbital_factors(n):
if n == 0: return [1]
if n == 1: return [0, 1]
S = [0]*(n//2 + 1)
for o in unit_orbitals(n):
S[len(catalan_factors(o))] += 1
return S
for n in (0..9): print(orbital_factors(n))
Showing 1-3 of 3 results.
Comments