Search: id:A138308 Results 1-1 of 1 results found. %I A138308 %S A138308 1,3,4,5,6,7,8,11,13,17,18,19,20,23,26,27,28,29,30,31,32,35,36,37,39,41, %T A138308 43,45,46,47,48,49,50,53,54,55,56,59,61,67,68,71,72,73,77,79,80,83,85, %U A138308 87,88,89,90,91,92,95,97,99,100,101,102,103,107,109,111,113,114,115,116 %N A138308 a(1)=1. a(n) = smallest integer > a(n-1) that is coprime to n and is coprime to every (nonzero) exponent in the prime factorization of n. %H A138308 Leroy Quet, Home Page (listed in lieu of email address) %e A138308 8 has the prime-factorization of 2^3. The smallest integer > a(7)=8 that is coprime to both 8 and 3 is 11. (9 is not coprime to 3. 10 is not coprime to 8.) So a(8)=11. %p A138308 A138308 := proc(n) option remember; local pfs,a,p,works ; if n = 1 then 1; else pfs := ifactors(n)[2] ; for a from procname(n-1)+1 do works := true ; if gcd(a,n) > 1 then works := false; else for p in pfs do if gcd(a,op(2,p)) > 1 then works := false; fi; end do ; end if; if works then return a; end if ; end do; end if; end: seq(A138308(n), n=1..120) ; [From R. J. Mathar (mathar(AT)strw.leidenuniv.nl), Oct 24 2009] %Y A138308 Cf. A138309, A138310. %Y A138308 Sequence in context: A120561 A051016 A044951 this_sequence A039084 A085627 A057825 %Y A138308 Adjacent sequences: A138305 A138306 A138307 this_sequence A138309 A138310 A138311 %K A138308 nonn %O A138308 1,2 %A A138308 Leroy Quet Mar 13 2008 %E A138308 Extended beyond a(14) by R. J. Mathar (mathar(AT)strw.leidenuniv.nl), Oct 24 2009 Search completed in 0.001 seconds