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!)
A199923 a(n) = Sum_{k=0..3^(n-1)} gcd(k,3^(n-1)) for n > 0 and a(0) = 1. 6
1, 2, 8, 30, 108, 378, 1296, 4374, 14580, 48114, 157464, 511758, 1653372, 5314410, 17006112, 54206982, 172186884, 545258466, 1721868840, 5423886846, 17046501516, 53464027482, 167365651248, 523017660150, 1631815099668, 5083731656658, 15816054042936 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,2
LINKS
FORMULA
a(n) = 2 * (n+2) * 3^(n-2), n > 0. - Sean A. Irvine, Jun 27 2022
From G. C. Greubel, Nov 24 2023: (Start)
a(n) = (2*(n+2)*3^n + 5*[n=0])/9.
G.f.: (9 - 6*x))/(9*(1 - 3*x)^2).
E.g.f.: (1/9)*( 5 + 2*(2 + 3*x)*exp(3*x) ). (End)
EXAMPLE
a(3) = 9 + 1 + 1 + 3 + 1 + 1 + 3 + 1 + 1 + 9.
MATHEMATICA
LinearRecurrence[{6, -9}, {1, 2, 8}, 41] (* G. C. Greubel, Nov 24 2023 *)
PROG
(Magma) [1] cat [n le 2 select 2^(2*n-1) else 6*Self(n-1) -9*Self(n-2): n in [1..40]]; // G. C. Greubel, Nov 24 2023
(SageMath) [(2*(n+2)*3^n + 5*int(n==0))//9 for n in range(41)] # G. C. Greubel, Nov 24 2023
CROSSREFS
First differences of A086972.
Row sums of A199922.
Sequence in context: A365693 A168605 A127865 * A230269 A278023 A077839
KEYWORD
nonn
AUTHOR
Peter Luschny, Nov 12 2011
EXTENSIONS
More terms from Sean A. Irvine, Jun 27 2022
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 April 19 19:02 EDT 2024. Contains 371798 sequences. (Running on oeis4.)