|
|
A361350
|
|
A variant of A359143 which includes the intermediate terms before digits are deleted (see Comments for precise definition).
|
|
3
|
|
|
11, 112, 1124, 11248, 1124816, 2486, 248620, 4860, 486018, 48601827, 4860182736, 486018273645, 8601827365, 860182736546, 86018273654656, 8601827365465667, 860182736546566780, 601273654656670, 60127365465667064, -1273545704, -127354570438, -12735457043849, -1273545704384962, -127354570438496270, 1273545743849627, 127354574384962777, 12735457438496277791, 273545743849627779
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,1
|
|
COMMENTS
|
This is essentially the same sequence as A359143 (so this too is a finite sequence), the difference being that it includes the terms before any digits are cancelled. Let S be the digit string of a(n), replacing a minus sign if present by 0.
Let T = S concatenated with the digit-sum of S.
If the leading digit of T is not present in the digit-sum of S, then a(n+1) = A359142(T), as in A359143.
If the leading digit of T is present in the digit-sum of S, then we add two new terms instead of one: a(n+1) = a(n) concatenated with the digit-sum of S, and a(n+2) = A359142(T), as in A359143.
|
|
LINKS
|
|
|
EXAMPLE
|
The digit strings for the initial terms are:
11,
112,
1124,
11248,
1124816,
2486,
248620,
4860,
486018,
48601827,
4860182736,
486018273645,
8601827365,
860182736546,
86018273654656,
8601827365465667,
860182736546566780,
601273654656670,
60127365465667064,
01273545704,
0127354570438,
012735457043849,
01273545704384962,
0127354570438496270,
1273545743849627,
127354574384962777,
12735457438496277791,
273545743849627779, ...
The sequence itself is obtained by replacing the leading zeros by minus signs.
For example, after the term 601273654656670, we first append its digit-sum 64, getting 60127365465667064. Since the leading digit 6 is present in 64, we cancel all the 6's, getting 01273545704. The corresponding term in the sequence is -1273545704.
|
|
MATHEMATICA
|
a[1] = {1, 1}; nn = 28;
Do[Which[ListQ[m], k = m; Clear[m],
FreeQ[#3, #2], Set[k, #1~Join~#3],
True, Set[k, #1~Join~#3];
Set[m, DeleteCases[#1~Join~#3, #2]]] & @@
{#, First[#], IntegerDigits@ Total[#]} &[a[n - 1]];
Set[a[n], k], {n, 2, nn}];
Array[(1 - 2 Boole[First[#] == 0])*FromDigits@ # &@ a[#] &, nn] (* Michael De Vlieger, Mar 16 2023 *)
|
|
CROSSREFS
|
|
|
KEYWORD
|
sign,base,fini
|
|
AUTHOR
|
|
|
EXTENSIONS
|
More than the usual number of terms are shown in order to clarify the differences from A359143.
|
|
STATUS
|
approved
|
|
|
|