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.

User: k = [W]

k = [W]'s wiki page.

k = [W] has authored 2 sequences.

A078714 a(n) = smallest number m which can be obtained in n ways by subtracting twice a triangular number from a perfect square.

Original entry on oeis.org

1, 4, 16, 34, 142, 79, 1276, 289, 394, 709, 103336, 1024, 930022, 6379, 3544, 2599, 75331762, 5119, 677985856, 9214, 31894, 516679, 54916854316, 12994, 88594, 4650109, 30319, 82924, 40034386796182, 46069, 360309481165636, 33784, 2583394, 376658809, 797344
Offset: 1

Author

R. L. Coffman, K. W. McLaughlin and R. J. Dawson (robert.l.coffman(AT)uwrf.edu), Dec 19 2002

Keywords

Comments

The minimum number m (denoted by LSDT(n)) which can be represented in n different ways as a symmetric unimodal consecutive integer sequence (e.g., 6+7+8+7+6) that sums to the integer m. More precisely, n is the number of ways to arrange m objects into symmetrically-placed, congruent isosceles trapezoids adjoined at overlapping largest bases and m is the minimum number of objects that allows this number of arrangements.
a(23)-a(50) are ?, 12994, 88594, 4650109, 30319, 82924, ?, 46069, ?, 33784, 2583394, 376658809, 797344, 78829, ?, ?, 23250544, 148129, ?, 414619, ?, 6716824, 272869, ?, ?, 168919, 19933594, 1151719. - Robert G. Wilson v, Dec 24 2002

Examples

			Let SDT(n) = the number, k, of symmetric double trapezoidal arrangements of n objects, then SDT(34) = 4, since we have 34 or 11+12+11 or 6+7+8+7+6 or 2+3+4+5+6+5+4+3+2. For SDT(n) = 4, we have n = 34 or 49 or 58 or 64 ..., so that the least value of SDT(n)=4 is LSDT(4) = 34. Also 4*34 - 1 = 135 = (3^3)*(5^1) so that r1=3 and r2=1 (p1=3 and p2=5), resulting in SDT(34) = (3+1)*(1+1)/2 = 4 and 34 is the least value of n which satisfies 4*n-1 so that one half the number of odd divisors equals 4.
		

Crossrefs

Programs

  • Mathematica
    The following function determines the number of ways, SDT(n), of arranging n identical objects into symmetric double trapezoidal arrangements: SDT[n_] := (Times @@ Cases[FactorInteger[4 n - 1], {p_, r_} -> r + 1])/2 The program below computes the first few terms of the sequence LSDT(k)=min{n:SDT(n)=k}. The output is in the form {{1, LSDT(1)}, {2, LSDT(2)}, {3, LSDT(3)}, ...}: Union[Sort[{SDT[ # ], #} & /@ Range[1, 100000]], SameTest -> (#1[[1]] == #2[[1]] &)]

Formula

LSDT(k)={min n: SDT(n)=k}, where SDT(n)=((r1+1)*(r2+1)*...)/2 and ((p1^r1)*(p2^r2)*...) is the factorization of 4n-1 into (odd) primes.
a(n) = (A204086(n) + 1)/4. - Ray Chandler, Jan 10 2012
For odd prime p, a(p) = (3^(p-1)*7 + 1)/4.

Extensions

Missing terms noted in Comments and b-file from Ray Chandler, Jan 10 2012

A078703 Number of ways of subtracting twice a triangular number from a perfect square to obtain the integer n.

Original entry on oeis.org

1, 1, 1, 2, 1, 1, 2, 1, 2, 2, 1, 1, 2, 2, 1, 3, 1, 1, 3, 1, 1, 2, 2, 2, 3, 1, 1, 2, 2, 2, 2, 1, 1, 4, 1, 2, 3, 1, 2, 2, 1, 1, 3, 3, 1, 2, 2, 1, 4, 1, 2, 3, 1, 2, 2, 1, 1, 4, 2, 1, 3, 2, 1, 4, 2, 1, 2, 1, 3, 3, 1, 2, 2, 2, 2, 2, 1, 1, 6, 2, 2, 2, 1, 2, 2, 2, 1, 4, 2, 1, 3, 1, 2, 4, 1, 1, 3, 2, 2, 4, 2, 2, 2, 2, 1
Offset: 1

Author

R. L. Coffman, K. W. McLaughlin and R. J. Dawson (robert.l.coffman(AT)uwrf.edu), Dec 19 2002

Keywords

Comments

Also number of symmetric unimodal consecutive integer sequences that sum to the integer n (e.g., 4+5+6+5+4 = 24 = n). Also number of double trapezoidal arrangements of n objects, denoted SDT(n); i.e., the number of ways to arrange n objects into symmetrically-placed, congruent isosceles trapezoids adjoined at overlapping largest bases.
Also number of divisors of 4*n-1 of form 4*k+1 (or 4*k+3). - Vladeta Jovovic, Jan 05 2004. Therefore a(n) is one half of the number of divisors of A004767(n-1) (numbers 3 (mod 4)). - Wolfdieter Lang, Jul 29 2016

Examples

			SDT(34) = 4 since we have 34 or 11+12+11 or 6+7+8+7+6 or 2+3+4+5+6+5+4+3+2, Also 4*34 - 1 = 135 = (3^3)*(5^1) so that r1=3 and r2=1 (p1=3 and p2=5), resulting in SDT(34) = (3+1)*(1+1)/2 = 4.
a(4) = 2 since 4 = 2^2 - 2*0 = 4^2 - 2*6. Also A034178(4*4 - 1) = 2 since 15 = 4^2 - 1^2 = 8^2 - 7^2. - _Michael Somos_, May 11 2011
G.f. = x + x^2 + x^3 + 2*x^4 + x^5 + x^6 + 2*x^7 + x^8 + 2*x^9 + 2*x^10 + x^11 + ...
Number of divisors of numbers 3 (mod 4) (see the Jovovic Jan 05 2004 comment): a(16) = 3 from the 2*3 = 6 divisors [1, 3, 7, 9, 21, 63] of 63 = A004767(15), being 1, -1, -1, 1, 1, -1 (mod 4). - _Wolfdieter Lang_, Jul 29 2016
		

Programs

  • Mathematica
    (* This defines SDT(n): *)
    SDT[n_] := Length[Cases[Range[1, n], j_ /; Cases[Range[1, j], k_ /; Plus @@ Join[Range[k, j], Range[j - 1, k, -1]] == n] != {}]] The restricted factorization technique for obtaining SDT(n) is encoded as follows: SDT[n_] := (Times @@ Cases[FactorInteger[4 n - 1], {p_, r_} -> r + 1])/2
    Rest[ CoefficientList[ Series[ Sum[x^k/(1 - x^(4k - 1)), {k, 111}], {x, 0, 110}], x]] (* Robert G. Wilson v, Sep 20 2005 *)
    a[ n_] := If[ n < 1, 0, With[{m = 4 n - 1}, Sum[1 - Sign@Mod[m - k^2, 2 k], {k, Sqrt@m}]]]; (* Michael Somos, Aug 01 2016 *)
    a[n_] := DivisorSigma[0, 4*n - 1]/2; Array[a, 100] (* Amiram Eldar, Dec 26 2022 *)
  • PARI
    {a(n) = if( n<1, 0, n = 4*n-1; sum(k=1, sqrtint(n), 0 == (n - k^2) % (2*k)))}; /* Michael Somos, Aug 01 2016 */

Formula

a(n) = ((r1 + 1)*(r2 + 1)*...*(rk + 1))/2, where ((p1^r1)*(p2^r2)*...*(pk^rk)) is the factorization of 4*n - 1 into (odd) primes.
G.f.: Sum_{n>0} x^n/(1-x^(4*n-1)). - Vladeta Jovovic, Jan 05 2004
a(n) = A034178(4*n - 1). - Michael Somos, May 11 2011
G.f.: Sum_{n >= 1} x^(3*n-2)/(1 - x^(4*n-3)). - Peter Bala, Jan 08 2021
From Amiram Eldar, Dec 26 2022: (Start)
a(n) = A000005(A004767(n-1))/2.
Sum_{k=1..n} a(k) = (log(n) + 2*gamma - 1 + 4*log(2))*n/4 + O(n^(1/3)*log(n)), where gamma is Euler's constant (A001620). (End)
G.f.: Sum_{n >= 1} x^(n^2)/(1-x^(2*n-1)) (conjecture). - Joerg Arndt, Jan 04 2024