login
A120323
Periodic sequence 0, 3, 1, 0, 1, 3.
0
0, 3, 1, 0, 1, 3, 0, 3, 1, 0, 1, 3, 0, 3, 1, 0, 1, 3, 0, 3, 1, 0, 1, 3, 0, 3, 1, 0, 1, 3, 0, 3, 1, 0, 1, 3, 0, 3, 1, 0, 1, 3, 0, 3, 1, 0, 1, 3, 0, 3, 1, 0, 1, 3, 0, 3, 1, 0, 1, 3, 0, 3, 1, 0, 1, 3, 0, 3, 1, 0, 1, 3, 0, 3, 1, 0, 1, 3, 0
OFFSET
0,2
FORMULA
a(n) = (4/3)*(sin(n*Pi/6)+sin(n*Pi/2))^2.
EXAMPLE
n=0 (4/3)*(sin(0)+sin(0))^2 = 0.
n=1 (4/3)*(sin(Pi/6)+sin(Pi/2))^2 = (4/3)*(1/2+1)^2 = (4/3)*(9/4) = 3.
n=2 (4/3)*(sin(Pi/3)+sin(Pi))^2 = (4/3)*(((3)^.5)/2+0)^2 = (4/3)*(3/4) = 1.
n=3 (4/3)*(sin(Pi/2)+sin(3*Pi/2))^2 = (4/3)*(1-1)^2 = 0.
n=4 (4/3)*(sin(2*Pi/3)+sin(2*Pi))^2 = (4/3)*(((3)^.5)/2+0)^2 = (4/3)*(3/4) = 1.
n=5 (4/3)*(sin(5*Pi/6)+sin(5*Pi/2))^2 = (4/3)*(1/2+1)^2 = (4/3)*(9/4) = 3.
MAPLE
P:=proc(n) local i, j; for i from 0 by 1 to n do j:=4/3*(sin(i*Pi/6)+sin(i*Pi/2))^2; print(j); od; end: P(20);
CROSSREFS
Sequence in context: A308243 A268386 A122779 * A320476 A304326 A099905
KEYWORD
easy,nonn
AUTHOR
STATUS
approved