%I #10 Dec 12 2023 08:45:10
%S 1,1,1,1,-2,1,1,1,1,-2,1,1,1,1,-2,1,1,1,1,-2,1,1,1,1,-2,1,1,1,1,-2,1,
%T 1,1,1,-2,1,1,1,1,-2,1,1,1,1,-2,1,1,1,1,-2,1,1,1,1,-2,1,1,1,1,-2,1,1,
%U 1,1,-2,1,1,1,1,-2,1,1,1,1,-2,1,1,1,1,-2,1,1,1,1,-2,1,1,1,1,-2,1,1,1,1,-2,1,1,1,1,-2,1,1,1,1,-2
%N a(n)=a(n-1)^2-a(n-2)-a(n-3)-a(n-4), a(1)=a(2)=a(3)=a(4)=1.
%C Periodic with period 5: 1,1,1,1,-2
%H <a href="/index/Rec#order_05">Index entries for linear recurrences with constant coefficients</a>, signature (0, 0, 0, 0, 1).
%F a(n)=a(n-1)^2-a(n-2)-a(n-3)-a(n-4), a(1)=a(2)=a(3)=a(4)=1
%e a(5)=1^2-1-1-1=-2
%t a[n_]:=a[n]=a[n-1]^2-a[n-2]-a[n-3]-a[a-4]; a[1]=a[2]=a[3]=a[4]=1
%t LinearRecurrence[{0, 0, 0, 0, 1},{1, 1, 1, 1, -2},105] (* _Ray Chandler_, Aug 25 2015 *)
%K sign
%O 1,5
%A _Ben Branman_, May 29 2008
%E Extended by _Ray Chandler_, Aug 25 2015
|