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.

A204457 Odd numbers not divisible by 13.

This page as a plain text file.
%I A204457 #30 Oct 20 2020 21:31:29
%S A204457 1,3,5,7,9,11,15,17,19,21,23,25,27,29,31,33,35,37,41,43,45,47,49,51,
%T A204457 53,55,57,59,61,63,67,69,71,73,75,77,79,81,83,85,87,89,93,95,97,99,
%U A204457 101,103,105,107,109
%N A204457 Odd numbers not divisible by 13.
%C A204457 For the general case of odd numbers not divisible by primes see a comment on A204454, where the o.g.f.s and the formulas in terms of floor functions are given.
%C A204457 The numerator polynomial of the o.g.f. given in the formula section has coefficients 1,2,2,2,2,2,4,2,2,2,2,2,1, see row no. 6 of A204456. The first seven numbers are the first differences of the sequence, starting with a(0)=0. The other numbers are obtained by mirroring around the center.
%C A204457 Numbers coprime to 26. The asymptotic density of this sequence is 6/13. - _Amiram Eldar_, Oct 20 2020
%H A204457 Reinhard Zumkeller, <a href="/A204457/b204457.txt">Table of n, a(n) for n = 1..10000</a>
%H A204457 <a href="/index/Rec#order_13">Index entries for linear recurrences with constant coefficients</a>, signature (1,0,0,0,0,0,0,0,0,0,0,1,-1).
%F A204457 O.g.f.: x*(1 + 2*(x+x^6)*(1+x+x^2+x^3+x^4) + 4*x^6 + x^12)/((1-x^12)*(1-x)). The denominator can be factored.
%F A204457 a(n) = 2*n-1 + 2*floor((n+5)/12) = 2*n+1 + 2*floor((n-7)/12), n>=1. Note that this is -1 for n=0, but the o.g.f. starting with x^0 has a(0)=0.
%t A204457 Select[Range[1,111,2],!Divisible[#,13]&] (* or *) With[{nn=111}, Complement[ Range[1,nn,2],13*Range[Floor[nn/13]]]] (* _Harvey P. Dale_, Jul 23 2013 *)
%o A204457 (Haskell)
%o A204457 a204457 n = a204457_list !! (n-1)
%o A204457 a204457_list = [x | x <- [1, 3 ..], mod x 13 > 0]
%o A204457 -- _Reinhard Zumkeller_, Feb 08 2012
%o A204457 (PARI) a(n) = 2*n-1+(n+5)\12*2 \\ _Charles R Greathouse IV_, Feb 08 2012
%Y A204457 Cf. A204454 and cross-references there; A204458.
%K A204457 nonn,easy
%O A204457 1,2
%A A204457 _Wolfdieter Lang_, Feb 07 2012