The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A322272 Smallest multiplication factors f, prime or 1, for all a (mod 120), coprime to 120, so that b*f is a nonzero square mod 8, mod 3, and mod 5. 6
1, 7, 11, 13, 17, 19, 23, 29, 31, 13, 41, 43, 23, 1, 53, 11, 61, 43, 71, 73, 53, 31, 83, 41, 19, 73, 29, 7, 83, 61, 17, 71 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
See sequence A322269 for further explanations. This sequence is related to A322269(3).
The sequence is periodic, repeating itself after phi(120) terms. Its largest term is 83, which is A322269(3). In order to satisfy the conditions, both f and b must be coprime to 120. Otherwise, the product would be zero mod a prime <= 5.
The b(n) corresponding to each a(n) is A007775(n).
LINKS
EXAMPLE
The 10th number coprime to 120 is 37. a(10) is 13, because 13 is the smallest prime by which we can multiply 37, so that the product (37*13 = 481) is a square mod 8, mod 3 and mod 5.
PROG
(PARI)
QresCode(n, nPrimes) = {
code = bitand(n, 7)>>1;
for (j=2, nPrimes,
x = Mod(n, prime(j));
if (issquare(x), code += (1<<j));
);
return (code);
}
QCodeArray(n) = {
totalEntries = 1<<(n+1);
f = vector(totalEntries);
f[totalEntries-3] = 1; \\ 1 always has the same code: ...111100
counter = 1;
forprime(p=prime(n+1), +oo,
code = QresCode(p, n);
if (f[code+1]==0,
f[code+1]=p;
counter += 1;
if (counter==totalEntries, return(f));
)
)
}
sequence(n) = {
f = QCodeArray(n);
primorial = prod(i=1, n, prime(i));
entries = eulerphi(4*primorial);
a = vector(entries);
i = 1;
forstep (x=1, 4*primorial-1, 2,
if (gcd(x, primorial)==1,
a[i] = f[QresCode(x, n)+1];
i += 1;
);
);
return(a);
}
sequence(3)
CROSSREFS
Sequence in context: A128974 A286609 A005776 * A161850 A007775 A070884
KEYWORD
nonn,fini,full
AUTHOR
Hans Ruegg, Dec 01 2018
STATUS
approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 19 19:45 EDT 2024. Contains 372703 sequences. (Running on oeis4.)