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.

A066308 a(n) = (sum of digits of n) * (product of digits of n).

This page as a plain text file.
%I A066308 #34 Dec 04 2024 17:51:20
%S A066308 1,4,9,16,25,36,49,64,81,0,2,6,12,20,30,42,56,72,90,0,6,16,30,48,70,
%T A066308 96,126,160,198,0,12,30,54,84,120,162,210,264,324,0,20,48,84,128,180,
%U A066308 240,308,384,468,0,30,70,120,180,250,330,420,520,630,0,42,96,162,240,330
%N A066308 a(n) = (sum of digits of n) * (product of digits of n).
%C A066308 a(n) can be greater than, less than, or equal to n; see Example section.
%H A066308 Harry J. Smith, <a href="/A066308/b066308.txt">Table of n, a(n) for n = 1..1000</a>
%e A066308 For n = 12, a(12) = (1 + 2)*(1*2) = 3*2 = 6 < n;
%e A066308 for n = 19, a(19) = (1 + 9)*(1*9) = 90 > n;
%e A066308 for n = 135, a(135) =(1 + 3 + 5)*(1*3*5) = 135 = n.
%t A066308 asum[x_] := Apply[Plus, IntegerDigits[x]] apro[x_] := Apply[Times, IntegerDigits[x]] a[n]=asum[n]*apro[n]
%t A066308 sdpd[n_]:=Module[{idn=IntegerDigits[n]},Total[idn]Times@@idn]; Array[ sdpd,70] (* _Harvey P. Dale_, Dec 31 2011 *)
%o A066308 (PARI) a(n) = my(d = digits(n)); vecsum(d) * vecprod(d); \\ _Michel Marcus_, Feb 24 2017
%Y A066308 Cf. A007953, A007954.
%Y A066308 Cf. A038369 (fixed points), A034710, A061672.
%Y A066308 Cf. A049101, A049102, A049103, A049104, A049105, A049106.
%K A066308 base,easy,nonn
%O A066308 1,2
%A A066308 _Labos Elemer_, Dec 13 2001
%E A066308 Edited by _Jon E. Schoenfield_, Jul 09 2018