|
|
A063720
|
|
Number of segments lit in a 7-segment display (as on a calculator) to represent the number n, variant 0: '6', '7' and '9' use 5, 3 and 5 segments, respectively.
|
|
19
|
|
|
6, 2, 5, 5, 4, 5, 5, 3, 7, 5, 8, 4, 7, 7, 6, 7, 7, 5, 9, 7, 11, 7, 10, 10, 9, 10, 10, 8, 12, 10, 11, 7, 10, 10, 9, 10, 10, 8, 12, 10, 10, 6, 9, 9, 8, 9, 9, 7, 11, 9, 11, 7, 10, 10, 9, 10, 10, 8, 12, 10, 11, 7, 10, 10, 9, 10, 10, 8, 12, 10, 9, 5, 8, 8, 7, 8, 8, 6, 10, 8, 13, 9, 12, 12, 11, 12
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,1
|
|
COMMENTS
|
If we mark with * resp. ' the glyph variants (graphical representations) which use more resp. less segments, we have the following variants:
A063720 (this: 6', 7', 9'), A277116 (6*, 7', 9'), A074458 (6*, 7*, 9'), ___________________________ A006942 (6*, 7', 9*), A010371 (6*, 7*, 9*). Sequences A234691, A234692 and variants make precise which segments are lit in each digit. These are related through the Hamming weight function A000120, e.g., A010371(n) = A000120(A234691(n)) = A000120(A234692(n)). - M. F. Hasler, Jun 17 2020
|
|
LINKS
|
Reinhard Zumkeller, Table of n, a(n) for n = 0..10000
Index entries for sequences related to calculator display
|
|
FORMULA
|
a(n) = a(floor(n/10)) + a(n mod 10) for n > 9. - Reinhard Zumkeller, Mar 15 2013
a(n) <= A277116(n) <= min{A006942(n), A074458(n)} <= A010371(n); differences between these are given, e.g., by A102677(n) - A102679(n) (= number of digits 7 in n). - M. F. Hasler, Jun 17 2020
|
|
EXAMPLE
|
The number 8 on a digital readout (e.g., on a calculator display) can be represented as
-
| |
-
| |
-
which uses all 7 segments. Therefore a(8) = 7.
From M. F. Hasler, Jun 17 2020: (Start)
This sequence uses the following representations:
_ _ _ _ _ _ _
| | | _| _| |_| |_ |_ | |_| |_|
|_| | |_ _| | _| |_| | |_| |
.
See crossrefs for other variants. (End)
|
|
MATHEMATICA
|
a[n_ /; n <= 9] := a[n] = {6, 2, 5, 5, 4, 5, 5, 3, 7, 5}[[n+1]]; a[n_] := a[n] = a[Quotient[n, 10]] + a[Mod[n, 10]]; Table[a[n], {n, 0, 85}] (* Jean-François Alcover, Aug 12 2013, after Reinhard Zumkeller *)
Table[Total[IntegerDigits[n]/.{0->6, 1->2, 2->5, 3->5, 6->5, 7->3, 8->7, 9->5}], {n, 0, 90}] (* Harvey P. Dale, Mar 27 2021 *)
|
|
PROG
|
(Haskell)
a063720 n = a063720_list !! n
a063720_list = [6, 2, 5, 5, 4, 5, 5, 3, 7, 5] ++ f 10 where
f x = (a063720 x' + a063720 d) : f (x + 1)
where (x', d) = divMod x 10
-- Reinhard Zumkeller, Mar 15 2013
(PARI) apply( {A063720(n)=digits(6255455375)[n%10+1]+if(n>9, self()(n\10))}, [0..99]) \\ M. F. Hasler, Jun 17 2020
|
|
CROSSREFS
|
For variants see A006942, A010371, A074458, A277116 (cf. comments).
Other related sequences: A018846, A018847, A018849, A038136, A053701.
Sequence in context: A124457 A258102 A309449 * A277116 A006942 A074458
Adjacent sequences: A063717 A063718 A063719 * A063721 A063722 A063723
|
|
KEYWORD
|
nonn,base,nice
|
|
AUTHOR
|
Deepan Majmudar (deepan.majmudar(AT)compaq.com), Aug 23 2001
|
|
EXTENSIONS
|
More terms from Matthew Conroy, Sep 13 2001
Definition clarified by M. F. Hasler, Jun 17 2020
|
|
STATUS
|
approved
|
|
|
|