Skip to content

Instantly share code, notes, and snippets.

@ericabell
ericabell / gist:6186ba9a1f6ed99cbaaf
Created November 14, 2014 21:34
plot sin and cos from 0 to 360 degrees with nice tick labels
x = var('x')
f(x) = sin((x*pi)/180)
g(x) = cos((x*pi)/180)
p1 = plot([f,g],
(x,0,360),
ticks=[[30,45,60,90,120,135,150,180,270,360],
[-1,
-sqrt(3)/2,
-sqrt(2)/2,