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!)
A181059 a(n) = floor(sin(n) - cos(n)). 1

%I #24 Apr 06 2021 20:15:56

%S -1,0,1,1,-1,-2,-2,-1,1,1,0,-2,-2,-1,0,1,0,-1,-2,-1,0,1,0,-1,-2,-2,0,

%T 1,1,0,-2,-2,-1,1,1,0,-1,-2,-1,0,1,0,-1,-2,-1,0,1,1,-1,-2,-2,-1,1,1,0,

%U -2,-2,-1,0,1,0,-1,-2,-1,0,1,0,-1,-2,-2,0,1,1,0,-2,-2,-1,1,1,0,-1,-2,-1,0

%N a(n) = floor(sin(n) - cos(n)).

%H G. C. Greubel, <a href="/A181059/b181059.txt">Table of n, a(n) for n = 0..500</a>

%F a(n) = floor( -sqrt(2)*cos(n + Pi/4) ). - _R. J. Mathar_, Oct 03 2010

%p A181059 := proc(n) -sqrt(2)*cos(n+Pi/4) ; floor(%) ; end proc: seq(A181059(n), n=0..120) ; # _R. J. Mathar_, Oct 03 2010

%t Table[Floor[Sin[n]-Cos[n]],{n,0,120}] (* _Harvey P. Dale_, Jun 01 2018 *)

%o (Magma) [Floor(Sin(n) - Cos(n)): n in [0..120]]; // _G. C. Greubel_, Apr 05 2021

%o (Sage) [floor(-sqrt(2)*cos(n+pi/4)) for n in (0..120)] # _G. C. Greubel_, Apr 05 2021

%Y Cf. A126564 (floor sin(n)*cos(n)).

%K sign,easy

%O 0,6

%A _Jonathan D. B. Hodgson_, Oct 01 2010

%E More terms from _R. J. Mathar_, Oct 03 2010

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 25 11:39 EDT 2024. Contains 371969 sequences. (Running on oeis4.)