Skip to content

Instantly share code, notes, and snippets.

@alogic0

alogic0/sinPlot.hs

Created Jul 10, 2018
Embed
What would you like to do?
sinus & cosinus
program = drawingOf(sinPlot & cosPlot & coordinatePlane)
rmax = 2 * 180
k = rmax / 10
ymax = 5
sinPlot = trigLine sin
cosPlot = trigLine cos
trigLine f = curve([(x, y) | p <- [-10 .. 10], d <- [0 .. 9], let x = p + d/10, let y = ymax * f (x * k)])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment