

A000265


Remove 2's from n; or largest odd divisor of n; or odd part of n.
(Formerly M2222 N0881)


195



1, 1, 3, 1, 5, 3, 7, 1, 9, 5, 11, 3, 13, 7, 15, 1, 17, 9, 19, 5, 21, 11, 23, 3, 25, 13, 27, 7, 29, 15, 31, 1, 33, 17, 35, 9, 37, 19, 39, 5, 41, 21, 43, 11, 45, 23, 47, 3, 49, 25, 51, 13, 53, 27, 55, 7, 57, 29, 59, 15, 61, 31, 63, 1, 65, 33, 67, 17, 69, 35, 71, 9, 73, 37, 75, 19, 77
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

1,3


COMMENTS

When n > 0 is written as k*2^j with k odd then k = A000265(n) and j = A007814(n), so: when n is written as k*2^j  1 with k odd then k = A000265(n+1) and j = A007814(n+1), when n > 1 is written as k*2^j + 1 with k odd then k = A000265(n1) and j = A007814(n1).
Also denominator of 2^n/n (numerator is A075101(n)).  Reinhard Zumkeller, Sep 01 2002
Slope of line connecting (o, a(o)) where o = (2^k)(n1) + 1 is 2^k and (by design) starts at (1, 1).  Josh Locker (joshlocker(AT)macfora.com), Apr 17 2004
Numerator of n/2^(n1).  Alexander Adamchuk, Feb 11 2005
From Marco Matosic, Jun 29 2005: (Start)
"The sequence can be arranged in a table:
...................................1
................................1..3..1
............................1...5..3..7...1
....................1...9...5..11..3..13..7...15..1
......1..17..9..19..5..21..11..23..3..25..13..27..7..29..15..31..1
Every new row is the previous row interspaced with the continuation of the odd numbers.
Except for the ones; the terms (t) in each column are t+t+/s = t_+1. Starting from the center column of threes and working to the left the values of s are given by A000265 and working to the right by A000265." (End)
(a(k), a(2k), a(3k), ...) = a(k)*(a(1), a(2), a(3), ...) In general, a(n*m) = a(n)*a(m).  Josh Locker (jlocker(AT)mail.rochester.edu), Oct 04 2005
This is a fractal sequence. The oddnumbered elements give the odd natural numbers. If these elements are removed, the original sequence is recovered.  Kerry Mitchell, Dec 07 2005
2k + 1 is the kth and largest of the subsequence of k terms separating two successive equal entries in a(n).  Lekraj Beedassy, Dec 30 2005
It's not difficult to show that the sum of the first 2^n terms is (4^n + 2)/3.  Nick Hobson, Jan 14 2005
a(A132739(n)) = A132739(a(n)) = A132740(n).  Reinhard Zumkeller, Aug 27 2007
In the table, for each row, (sum of terms between 3 and 1)  (sum of terms between 1 and 3) = A020988.  Eric Desbiaux, May 27 2009
This sequence appears in the analysis of the "lookalikes" of the numerator and denominator of the Taylor series for tan(x), i.e., A160469(n) and A156769(n).  Johannes W. Meijer, May 24 2009
a(n) = n/gcd(2^n,n). (This also shows that the true offset is 0 and a(0) = 0.)  Peter Luschny, Nov 14 2009
A182469(n, k) = A027750(a(n), k), k = 1..A001227(n); a(n) = A182469(n, A001227(n)).  Reinhard Zumkeller, May 01 2012
Indices n such that a(n) divides 2^n  1 are listed in A068563.  Max Alekseyev, Aug 25 2013
From Alexander R. Povolotsky, Dec 17 2014: (Start)
With regard to the tabular presentation described in the comment by Marco Matosic: in his drawing, starting with the 3rd row, the first term in the row, which is equal to 1 (or, alternatively the last term in the row, which is also equal to 1), is not in the actual sequence and is added to the drawing as a fictitious term (for the sake of symmetry); an actual A000265(n) could be considered to be a(j,k) (where j>=1 is the row number and k>=1 is the column subscript), such that a(j,1) = 1:
1
1...3
1...5...3..7
1...9...5..11..3..13..7...15
1...17..9..19..5..21..11..23..3..25..13..27..7..29..15..31
and so on ... .
The relationship between k and j for each row is 1 <= k <= 2^(j1). In this corrected tabular representation, Marco's notion that "every new row is the previous row interspaced with the continuation of the odd numbers" remains true. (End)


REFERENCES

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).


LINKS

T. D. Noe and Daniel Forgues, Table of n, a(n) for n = 1..100000 (first 10000 terms from T. D. Noe)
V. Daiev & J. L. Brown, Problem H81, Fib. Quart., 6 (1968), 52.
R. Stephan, Some divideandconquer sequences ...
R. Stephan, Table of generating functions
Eric Weisstein's World of Mathematics, Odd Part
Eric Weisstein's World of Mathematics, Trigonometry Angles
Eric Weisstein's World of Mathematics, Sphere Line Picking


FORMULA

a(n) = if n is odd then n, else a(n/2).  Reinhard Zumkeller, Sep 01 2002
a(n) = n/A006519(n) = 2*A025480(n1) + 1.
Multiplicative with a(p^e) = 1 if p = 2, p^e if p > 2.  David W. Wilson, Aug 01 2001
a(n) = Sum_{d divides n and d is odd} phi(d).  Vladeta Jovovic, Dec 04 2002
G.f.: x/(1x) + sum(k >= 0, 2*x^(2^k)/(12*x^(2^(k+1))+x^(2^(k+2))) ).  Ralf Stephan, Sep 05 2003
Dirichlet g.f.: zeta(s1)*(2^s2)/(2^s1).  Ralf Stephan, Jun 18 2007
a(n) = sum{k = 0..n, A127793(n, k)*floor((k+2)/2)} (conjecture).  Paul Barry, Jan 29 2007
a(n) = 2*A003602(n)  1.  Franklin T. AdamsWatters, Jul 02 2009
a(n) = a(n) for all n in Z.  Michael Somos, Sep 19 2011
a((2*n1)*2^p) = 2*n  1, p >= 0 and n >= 1.  Johannes W. Meijer, Feb 05 2013
G.f.: G(0)/(12*x^2 + x^4)  1/(1x), where G(k)= 1 + 1/( 1  (x^(2^k))*(1  2*(x^(2^(k+1))) + x^(2^(k+2)) )/( (x^(2^k))*(1  2*(x^(2^(k+1))) + x^(2^(k+2)) ) + (1  2*x^(2^(k+2)) + x^(2^(k+3))) /G(k+1) )); (continued fraction).  Sergei N. Gladkovskii, Aug 06 2013


EXAMPLE

G.f. = x + x^2 + 3*x^3 + x^4 + 5*x^5 + 3*x^6 + 7*x^7 + x^8 + 9*x^9 + 5*x^10 + 11*x^11 + ...


MAPLE

A000265:=proc(n) local t1, d; t1:=1; for d from 1 by 2 to n do if n mod d = 0 then t1:=d; fi; od; t1; end: seq(A000265(n), n=1..77);
A000265 := n > n/2^padic[ordp](n, 2): seq(A000265(n), n=1..77); # Peter Luschny, Nov 26 2010


MATHEMATICA

Table[Times@@(#[[1]]^#[[2]]&/@Select[FactorInteger[i], #[[1]] != 2 &]), {i, 90}] (* Harvey P. Dale *)
a[n_Integer /; n > 0] := n/2^IntegerExponent[n, 2]; Array[a, 77] (* Josh Locker *)
f[n_] := Denominator[2^n/n]; Array[f, 100] (* Vladimir Joseph Stephan Orlovsky, Feb 16 2011 *)
f[n_] := NestWhile[#/2 &, n, EvenQ]; Array[f, 72] (* Arkadiusz Wesolowski, Jan 18 2013 *)
a[ n_] := If[ n == 0, 0, n / 2^IntegerExponent[ n, 2]]; (* Michael Somos, Dec 17 2014 *)


PROG

(PARI) {a(n) = n >> valuation(n, 2)}; /* Michael Somos, Aug 09 2006, edited by M. F. Hasler, Dec 18 2014 */
(Haskell)
a000265 = until odd (`div` 2)
 Reinhard Zumkeller, Jan 08 2013, Apr 08 2011, Oct 14 2010


CROSSREFS

Cf. A000004, A000225, A006516, A069834, A111929, A111930, A111918, A111919, A111920, A111921, A111922, A111923, A038502, A065330, A125650, A135013, A209308, A213671, A220466, A236999, A242603.
Sequence in context: A098985 A072963 A161955 * A227140 A106617 A040026
Adjacent sequences: A000262 A000263 A000264 * A000266 A000267 A000268


KEYWORD

mult,nonn,easy,nice


AUTHOR

N. J. A. Sloane


EXTENSIONS

Additional comments from Henry Bottomley, Mar 02 2000
More terms from Larry Reeves (larryr(AT)acm.org), Mar 14 2000


STATUS

approved



