This site is supported by donations to The OEIS Foundation. Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A174863 Little omega analog to Liouville's function L(n). 5
 1, 0, -1, -2, -3, -2, -3, -4, -5, -4, -5, -4, -5, -4, -3, -4, -5, -4, -5, -4, -3, -2, -3, -2, -3, -2, -3, -2, -3, -4, -5, -6, -5, -4, -3, -2, -3, -2, -1, 0, -1, -2, -3, -2, -1, 0, -1, 0, -1, 0, 1, 2, 1, 2, 3, 4, 5, 6, 5, 4, 3, 4, 5, 4, 5, 4, 3, 4, 5, 4, 3, 4, 3, 4, 5, 6, 7 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,4 COMMENTS Instead of using the Omega function, number of prime factors counted with multiplicity, this is using the omega function, number of distinct prime factors. Except for the two zeros and the intervening foray into negative territory shown here, the first thousand terms are all positive. The next zero occurs at term 7960. After the zero at term 12100, the function stays negative until term 22395666. This sequence and the Liouville sequence have some terms up to a(43) exactly the same. I don't know at what higher point (if any) that is the case again. [del Arte] It appears certain that this sequence and the Liouville sequence are equal infinitely often. Because they have the same parity and always change by one, they cannot cross without meeting. Both change signs infinitely often, and at apparently unrelated points. - Franklin T. Adams-Watters, Aug 05 2011 Partial sums of A076479. - Reinhard Zumkeller, Jun 01 2013 LINKS Reinhard Zumkeller, Table of n, a(n) for n = 1..10000 Michael J. Mossinghoff, Timothy S. Trudgian, A tale of two omegas, arXiv:1906.02847 [math.NT], 2019. FORMULA a(n) = Sum_{i = 1..n} (-1)^omega(i). A275547(a(n)) = 0. - Alois P. Heinz, Aug 03 2016 EXAMPLE a(4) = -2 because: a(1) = 1, as 1 has an even number of prime factors; then 2 and 3 being prime, bring the running sum down to -1; and then 4, which has one distinct prime factor, brings the sum down to -2. (This is the first term that differs from the Mertens function and Liouville's function.) MATHEMATICA s=0; Table[s=s+(-1)^PrimeNu[n]; s, {n, 100}] (* PrimeNu is new in Mathematica 7.0 *) PROG (PARI) a(n)=sum(k=1, n, (-1)^omega(k)) \\ Charles R Greathouse IV, Mar 27 2012 (PARI) a(n)=my(v=vectorsmall(n, i, 1)); forprime(p=2, n, forstep(i=p, n, p, v[i]*=-1)); sum(i=1, #v, v[i]) \\ Charles R Greathouse IV, Aug 21 2016 (Haskell) a174863 n = a174863_list !! (n-1) a174863_list = scanl1 (+) a076479_list -- Reinhard Zumkeller, Jun 01 2013 (Python) from sympy import primefactors def omega(n): return 0 if n==1 else len(primefactors(n)) def a(n): return sum([(-1)**omega(i) for i in xrange(1, n + 1)]) # Indranil Ghosh, May 20 2017 CROSSREFS Cf. A002819 (Liouville's function), A002321 (Mertens's function), A275547 (where a(n) is zero). Sequence in context: A063772 A209302 A205122 * A064289 A078759 A276439 Adjacent sequences:  A174860 A174861 A174862 * A174864 A174865 A174866 KEYWORD sign AUTHOR Alonso del Arte, Dec 01 2010 STATUS approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

Last modified October 14 07:06 EDT 2019. Contains 327995 sequences. (Running on oeis4.)