cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-5 of 5 results.

A001412 Number of n-step self-avoiding walks on cubic lattice.

Original entry on oeis.org

1, 6, 30, 150, 726, 3534, 16926, 81390, 387966, 1853886, 8809878, 41934150, 198842742, 943974510, 4468911678, 21175146054, 100121875974, 473730252102, 2237723684094, 10576033219614, 49917327838734, 235710090502158, 1111781983442406, 5245988215191414, 24730180885580790, 116618841700433358, 549493796867100942, 2589874864863200574, 12198184788179866902, 57466913094951837030, 270569905525454674614
Offset: 0

Views

Author

Keywords

References

  • Steven R. Finch, Mathematical Constants, Cambridge, 2003, section 5.10, pp. 331-339.
  • B. D. Hughes, Random Walks and Random Environments, Oxford 1995, vol. 1, p. 462.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • Mathematica
    mo = {{1, 0, 0}, {-1, 0, 0}, {0, 1, 0}, {0, -1, 0}, {0, 0, 1}, {0, 0, -1}}; a[0] = 1;
    a[tg_, p_: {{0, 0, 0}}] := Block[{e, mv = Complement[Last[p] + # & /@ mo, p]},
    If[tg == 1, Return[Length@mv],Sum[a[tg - 1, Append[p, e]], {e, mv}]]];
    a /@ Range[0, 8]
    (* Robert FERREOL, Nov 30 2018, after the program of Giovanni Resta in A001411 *)
  • Python
    def add(L,x):
        M=[y for y in L];M.append(x)
        return(M)
    plus=lambda L,M : [x+y for x,y in zip(L,M)]
    mo=[[1,0,0],[-1,0,0],[0,1,0],[0,-1,0],[0,0,1],[0,0,-1]]
    def a(n,P=[[0,0,0]]):
        if n==0: return(1)
        mv1 = [plus(P[-1],x) for x in mo]
        mv2=[x for x in mv1 if x not in P]
        if n==1: return(len(mv2))
        else: return(sum(a(n-1,add(P,x)) for x in mv2))
    [a(n) for n in range(8)]
    # Robert FERREOL, Nov 30 2018

A078717 Number of n-step self-avoiding walks on cubic lattice with first step specified.

Original entry on oeis.org

1, 5, 25, 121, 589, 2821, 13565, 64661, 308981, 1468313, 6989025, 33140457, 157329085, 744818613, 3529191009, 16686979329, 78955042017, 372953947349, 1762672203269, 8319554639789, 39285015083693, 185296997240401, 874331369198569
Offset: 1

Views

Author

Hugo Pfoertner, Dec 18 2002

Keywords

References

Crossrefs

Equals A001412/6. Cf. A001411, A046661, A002902.

A140476 Number of self-avoiding walks on cubic lattice with no more than n steps.

Original entry on oeis.org

1, 7, 37, 187, 913, 4447, 21373, 102763, 490729, 2344615, 11154493, 53088643, 251931385, 1195905895, 5664817573, 26839963627, 126961839601, 600692091703, 2838415775797, 13414448995411, 63331776834145, 299041867336303
Offset: 0

Views

Author

Jonathan Vos Post, Jun 29 2008

Keywords

Comments

Primes include a(1) = 7, a(2) = 37, a(5) = 4447, a(8) = 102763, a(15) = 26839963627.

Examples

			a(9) = 1 + 6 + 30 + 150 + 726 + 3534 + 16926 + 81390 + 387966 + 1853886 = 2344615.
		

Crossrefs

Partial sums of A001412.

A107069 Number of self-avoiding walks of length n on an infinite triangular prism starting at the origin.

Original entry on oeis.org

1, 4, 12, 34, 90, 222, 542, 1302, 3058, 7186, 16714, 38670, 89358, 205710, 472906, 1086138, 2491666, 5713318, 13094950, 30003190, 68731010, 157423986, 360530346, 825626942, 1890615518, 4329196974, 9912914314, 22698017834, 51972012258, 119000208806
Offset: 0

Views

Author

Jonathan Vos Post, May 10 2005

Keywords

Comments

The discrete space in which the walking happens is a triangular prism infinite in both directions along the x-axis. One vertex is the root, the origin. The basis is the set of single-step vectors, which we abbreviate as l (left), r (right), c (one step "clockwise" around the triangle) and c- (one step counterclockwise, more properly denoted c^-1).

Examples

			a(0) = 1, as there is one self-avoiding walk of length 0, namely the null-walk (the walk whose steps are the null set).
a(1) = 4 because (using the terminology in the Comment), the 4 possible 1-step walks are W_1 = {l,r,c,c-}.
a(2) = 12 because the set of legal 2-step walks are {l^2, lc, lc-, r^2, rc, rc-, c^2, cl, cr, c^-2, c-l, c-r}.
a(3) = 34 because we have every W_2 concatenated with {l,r,c,c-} except for those with immediate violations (lr etc.) and those two which go in a triangle {c^3, c^-3}; hence a(3) = 3*a(2) - 2 = 3*12 - 2 = 36 - 2 = 34.
		

Crossrefs

Programs

  • Python
    w = [[[(0, 0)]]]
    for n in range(1, 15):
        nw = []
        for walk in w[-1]:
            (x, t) = walk[-1]
            nss = [(x-1, t), (x+1, t), (x, (t+1)%3), (x, (t-1)%3)]
            for ns in nss:
                if ns not in walk:
                    nw.append(walk[:] + [ns])
        w.append(nw)
    print([len(x) for x in w])
    # Andrey Zabolotskiy, Sep 19 2019

Extensions

a(4) and a(5) corrected, a(6)-a(14) added by Andrey Zabolotskiy, Sep 19 2019
More terms from Andrey Zabolotskiy, Dec 04 2023

A213453 Self-avoiding walks on the f.c.c. lattice.

Original entry on oeis.org

1, 6, 66, 702, 7350, 76266, 786858, 8086074, 82848522, 846886962, 8640964782
Offset: 1

Views

Author

N. J. A. Sloane, Jun 12 2012

Keywords

References

  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).

Crossrefs

Formula

Apparently a(n) = A001336(n-1)/2 for n > 1. - Andrey Zabolotskiy, Dec 29 2018
Showing 1-5 of 5 results.