login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A278311 Numbers n such that n-1 and n+1 have the same number of prime factors as n (with multiplicity). 1
34, 86, 94, 122, 142, 171, 202, 214, 218, 245, 285, 302, 394, 429, 435, 446, 507, 603, 604, 605, 634, 638, 698, 842, 922, 963, 1042, 1075, 1084, 1085, 1131, 1138, 1245, 1262, 1275, 1310, 1346, 1402, 1413, 1431, 1435, 1449, 1491, 1533, 1557, 1587, 1605, 1635, 1642, 1676, 1762, 1772, 1838, 1886, 1894, 1925, 1942 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

LINKS

Ely Golden, Table of n, a(n) for n = 1..10000

EXAMPLE

a(1) = 34, as 33, 34, and 35 all have 2 prime factors.

a(2) = 86, as 85, 86, and 87 all have 2 prime factors.

PROG

(Java) public class A278311{

public static void main(String[] args)throws Exception{

    long dim0=numberOfPrimeFactors(2); //note that this method must be manually implemented by the user

    long dim1=numberOfPrimeFactors(3);

    long dim2;

    long counter=4;

    long index=1;

    while(index<=10000){

      dim2=numberOfPrimeFactors(counter);

      if(dim2==dim1&&dim1==dim0){System.out.println(index+" "+(counter-1)); index++; }

      dim0=dim1;

      dim1=dim2;

      counter++;

    }

  }

}

(SageMath)

def bigomega(x):

    s=0;

    f=list(factor(x));

    for c in range(len(f)):

        s+=f[c][1]

    return s;

dim0=bigomega(2);

dim1=bigomega(3);

counter=4

index=1

while(index<=10000):

    dim2=bigomega(counter);

    if(dim2==dim1&dim1==dim0):

        print(str(index)+" "+str(counter-1))

        index+=1;

    dim0=dim1;

    dim1=dim2;

    counter+=1;

(PARI) isok(n) = (bigomega(n-1) == bigomega(n)) && (bigomega(n) == bigomega(n+1)); \\ Michel Marcus, Nov 17 2016

CROSSREFS

Intersection of A045920 and A278291.

a(n) = A045939(n) + 1.

Sequence in context: A092223 A046764 A260276 * A213025 A086005 A169834

Adjacent sequences:  A278308 A278309 A278310 * A278312 A278313 A278314

KEYWORD

nonn

AUTHOR

Ely Golden, Nov 17 2016

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.

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 17 12:45 EDT 2019. Contains 327131 sequences. (Running on oeis4.)