cp's OEIS Frontend

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.

A057125 Numbers n such that 3 is a square mod n.

This page as a plain text file.
%I A057125 #26 Sep 08 2022 08:45:02
%S A057125 1,2,3,6,11,13,22,23,26,33,37,39,46,47,59,61,66,69,71,73,74,78,83,94,
%T A057125 97,107,109,111,118,121,122,131,138,141,142,143,146,157,166,167,169,
%U A057125 177,179,181,183,191,193,194,213,214,218,219,222,227,229,239,241,242
%N A057125 Numbers n such that 3 is a square mod n.
%C A057125 Numbers that are not multiples of 4 or 9 and for which all prime factors greater than 3 are congruent to +/- 1 mod 12. - _Eric M. Schmidt_, Apr 21 2013
%H A057125 T. D. Noe, <a href="/A057125/b057125.txt">Table of n, a(n) for n=1..1000</a>
%e A057125 3^2==3 (mod 6), so 6 is a member.
%p A057125 # Beware: Since 2007 at least and up to Maple 16 at least, the following Maple code returns the wrong answer for n = 6:
%p A057125 with(numtheory): [seq(`if`(mroot(3,2,n)=FAIL,NULL,n), n=1..400)];
%p A057125 # second Maple program:
%p A057125 with(numtheory): mroot(3, 2, 6):=3:
%p A057125 a:= proc(n) option remember; local m;
%p A057125       for m from 1+`if`(n=1, 0, a(n-1))
%p A057125       while mroot(3, 2, m)=FAIL do od; m
%p A057125     end:
%p A057125 seq(a(n), n=1..80);  # _Alois P. Heinz_, Feb 24 2017
%t A057125 Prepend[ Select[ Range[300], Reduce[Mod[3 - k^2, #] == 0, k, Integers] =!= False &], 1]  (* _Jean-François Alcover_, Sep 20 2012 *)
%o A057125 (PARI) isok(n) = issquare(Mod(3,n)); \\ _Michel Marcus_, Feb 19 2016
%o A057125 (Magma) [n: n in [1..300] | exists(t){x : x in ResidueClassRing(n) | x^2 eq 3}]; // _Vincenzo Librandi_, Feb 20 2016
%Y A057125 Includes the primes in A038874 and these (primes congruent to {1, 2, 3, 11} mod 12) are the prime factors of the terms in this sequence. Cf. A008784, A057126, A057127, A057128, A057129.
%Y A057125 Cf. A057759.
%K A057125 nonn
%O A057125 1,2
%A A057125 _Henry Bottomley_, Aug 10 2000
%E A057125 Edited by _N. J. A. Sloane_, Oct 25 2008 at the suggestion of _R. J. Mathar_.