OFFSET
1,2
COMMENTS
By convention 1 is included as the first term, in order to simplify the statement of certain results involving this sequence.
LINKS
Douglas Latimer, Table of n, a(n) for n = 1..1000
EXAMPLE
6 is included, as its canonical prime factorization (2^1)*(3^1) contains an even number of exponents, all of which are congruent to 1 modulo 3.
MATHEMATICA
pfQ[n_]:=Module[{f=Transpose[FactorInteger[n]][[2]]}, EvenQ[Length[f]] && Union[ Mod[f, 3]]=={1}]; Join[{1}, Select[Range[200], pfQ]] (* Harvey P. Dale, Mar 24 2016 *)
PROG
(PARI) {plnt=1; k=1; print1(k, ", "); plnt++;
mxind=76 ; mxind++ ; for(k=2, 10^6,
M=factor(k); passes=1;
sz = matsize(M)[1];
for(k=1, sz, if(sz%2 != 0, passes=0; break()); if( M[k, 2] % 3 != 1, passes=0));
if( passes == 1 , print1(k, ", "); plnt++) ; if(mxind == plnt, break() ))}
(PARI) is(n, f=factor(n))=omega(f)%2==0 && factorback(f[, 2]%3)==1 \\ Charles R Greathouse IV, Sep 07 2017
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Douglas Latimer, Apr 12 2012
STATUS
approved