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.

A214746 Numbers n such that (sum of the square of the decimal digits of n) + (product of the square of decimal digits of n) is prime.

This page as a plain text file.
%I A214746 #16 Sep 08 2022 08:46:02
%S A214746 1,11,13,16,19,29,31,37,59,61,73,79,91,92,95,97,101,102,104,106,110,
%T A214746 120,140,160,201,203,205,207,210,225,230,238,250,252,270,283,302,308,
%U A214746 320,328,380,382,401,405,409,410,449,450,490,494,502,504,506,508,520
%N A214746 Numbers n such that (sum of the square of the decimal digits of n) + (product of the square of decimal digits of n) is prime.
%H A214746 Charles R Greathouse IV, <a href="/A214746/b214746.txt">Table of n, a(n) for n = 1..10000</a>
%e A214746 283 is in the sequence because 2^2+8^2+3^2 + 2^2*8^2*3^2 = 77 + 2304 = 2381 is prime.
%p A214746 A:= proc(n) add(d^2, d=convert(n, base, 10)) ; end proc:
%p A214746 B:= proc(n) mul(d^2, d=convert(n, base, 10)) ; end proc:
%p A214746 isA:= proc(n) isprime(A(n)+B(n)) ; end proc:
%p A214746 for n from 1 to 1000 do if isA(n) then printf("%a, ", n) ; end if; end do:
%o A214746 (PARI) is(n)=my(v=eval(Vec(Str(n))));isprime(sum(i=1,#v,v[i]^2)+prod(i=1,#v,v[i]^2)) \\ _Charles R Greathouse IV_, Aug 02 2012
%o A214746 (Magma) dd:=func<n | [d^2: d in Intseq(n)]>; [n: n in [1..520] | IsPrime(&+dd(n)+&*dd(n))]; // _Bruno Berselli_, Aug 02 2012
%Y A214746 Cf. A185300.
%K A214746 nonn,base,easy
%O A214746 1,2
%A A214746 _Michel Lagneau_, Aug 01 2012