This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A231471 #24 Nov 02 2024 16:09:15 %S A231471 10,9,10,9,9,7,10,9,10,9,10,7,10,9,8,9,10,7,10,9,10,9,10,7,9,9,10,9, %T A231471 10,7,10,9,10,9,9,7,10,9,10,9,10,5,10,9,8,9,10,7,10,9,10,9,10,7,9,9, %U A231471 10,9,10,7,10,9,10,9,9,7,10,9,10,9,10,7,10,9,8,9,10,7,10,9 %N A231471 Largest integer less than 11 and coprime to n. %C A231471 Motivated by the m = 10 analog A231470 which in turn was motivated by A231155, simply a repetition of (n-1) times the same digit A231470(n). %C A231471 Periodic with period 210. Possible values are 1, 5, 7, 8, 9, 10. - _Robert Israel_, Jul 03 2020 %H A231471 Robert Israel, <a href="/A231471/b231471.txt">Table of n, a(n) for n = 1..10000</a> %e A231471 a(1) = 10 because 10 is the largest integer less than 11 and it's coprime to 1. %e A231471 a(2) = 9 because 10 is not coprime to 2 but 9 is. %e A231471 a(6) = 7 because 10, 9 and 8 are not coprime to 6 = 2*3. %e A231471 a(210) = 1 because 210 = 2*3*5*7 is not coprime to any number n > 1, n < 11. %p A231471 f:= proc(n) local k; %p A231471 for k from 10 by -1 do if igcd(n,k)=1 then return k fi od %p A231471 end proc: %p A231471 map(f, [$1..210]); # _Robert Israel_, Jul 03 2020 %t A231471 Table[m = 10; While[GCD[m, n] != 1, m--]; m, {n, 75}] (* _Alonso del Arte_, Nov 09 2013 *) %o A231471 (PARI) a(n,m=11)=for(k=1,m,gcd(n,m-k)==1&&return(m-k)) %Y A231471 Cf. A231475 (analog for 5), A231470 (analog for 10), A231155. %K A231471 nonn,easy %O A231471 1,1 %A A231471 _M. F. Hasler_, Nov 09 2013