login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A367246 a(n) is the number of n-digit numbers whose difference between the largest and smallest digits is equal to 5. 7
0, 9, 139, 1419, 12079, 92859, 669319, 4617699, 30878959, 201792939, 1295974999, 8212422579, 51499341439, 320287850619, 1978857202279, 12161478061059, 74421280021519, 453832688077899, 2759692966903159, 16742329188365139, 101377580843991199, 612894508749226779, 3700556151386869639 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
a(n) is the number of n-digit numbers in A366962.
LINKS
FORMULA
a(n) = 29*6^(n-1) - 49*5^(n-1) + 5*4^n.
a(n) = 15*a(n-1) - 74*a(n-2) + 120*a(n-3) for n > 3.
O.g.f.: x^2*(9 + 4*x)/((1 - 4*x)*(1 - 5*x)*(1 - 6*x)).
E.g.f.: (145*exp(6*x) - 294*exp(5*x) + 150*exp(4*x) - 1)/30.
MATHEMATICA
LinearRecurrence[{15, -74, 120}, {0, 9, 139}, 23]
CROSSREFS
Cf. A366962.
Sequence in context: A112702 A367426 A296394 * A322576 A350925 A243673
KEYWORD
nonn,base,easy
AUTHOR
Stefano Spezia, Nov 11 2023
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified June 28 02:17 EDT 2024. Contains 373761 sequences. (Running on oeis4.)