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

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A126433 Class+ number of prime(n) according to the Erdős-Selfridge classification of primes. 8
1, 1, 1, 1, 1, 2, 1, 2, 1, 2, 1, 3, 2, 2, 1, 1, 2, 2, 2, 1, 4, 2, 2, 2, 2, 2, 3, 1, 2, 3, 1, 2, 2, 2, 2, 3, 3, 3, 2, 3, 2, 3, 1, 3, 2, 2, 2, 2, 3, 2, 3, 2, 2, 2, 3, 2, 2, 2, 3, 2, 2, 2, 2, 3, 4, 2, 3, 3, 3, 2, 3, 2, 2, 2, 3, 1, 3, 3, 3, 3, 2, 3, 1, 2, 2, 4, 2, 3, 2, 3, 3, 2, 3, 3, 2, 2, 2, 3, 3, 3, 3, 2, 2, 3, 3 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,6

COMMENTS

a(n)=1 if A000040(n) is in A005105. a(n)=2 if A000040(n) is in A005106, a(n)=3 if in A005107 etc. The locations of records are implicit in A005113.

LINKS

M. F. Hasler, Table of n, a(n) for n = 1..1000

MAPLE

a := proc(n) option remember; local p, pf, e, res; if isprime(n) then pf := ifactors(n+1)[2]; res := 1; for e from 1 to nops(pf) do p := op(1, op(e, pf)); if p > 3 then res := max(res, a(p)+1); fi; od; RETURN(res); else -1; fi; end: for n from 1 to 180 do printf("%d, ", a(ithprime(n))); end:

A126433 := n -> if n>0 then A126433(-ithprime(n)) else numtheory[factorset](1-n); if % subset{2, 3} then 1 else 1+max(seq(A126433(-i), i=%)) fi fi; map(%, [$1..999]); # M. F. Hasler, Apr 02 2007

MATHEMATICA

classPlus[p_] := classPlus[p] = If[f = FactorInteger[p + 1][[All, 1]]; q = Last[f]; q == 2 || q == 3, 1, Max[classPlus /@ f] + 1]; classPlus /@ Prime /@ Range[105] (* Jean-François Alcover, Jun 24 2013 *)

PROG

(PARI) A126433(n) = { if( n>0, n=-prime(n)); n=factor(1-n)[, 1]; if( n[ #n]>3, vecsort( vector( #n, i, A126433(-n[i]) ))[ #n]+1, 1) }; vector(999, i, A126433(i))

CROSSREFS

Cf. A005105-A005108, A005113, A081633-A081639, A084071, A090468, A101253, A126805.

Sequence in context: A023124 A023120 A167970 * A237271 A176725 A085029

Adjacent sequences:  A126430 A126431 A126432 * A126434 A126435 A126436

KEYWORD

nonn

AUTHOR

R. J. Mathar, Mar 23 2007

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 April 26 04:04 EDT 2019. Contains 322469 sequences. (Running on oeis4.)