Log In  
Follow
feoh

Hi all!

Based on my embryonic understanding of polar coordinates, you can draw a spiral by incrementing R and THETA in lock step.

So I put together this little blob of code:

-- draw a spiral
-- in polar coordinates, you
-- do this by incrementing r
-- and theta at the same time.

for r = 1,99 do
    theta = r / 100
    x = r * cos(theta)
    y = r * sin(theta)
    pset(x,y)
end

And that almost yields a spiral! At least it yields a curve. Yay curves!

Is it possible that I'm drawing my spiral, I just need to somehow scale it down so that the dots are contiguous and maybe the angle of turn is sharper?

Any clues are appreciated. I'm just trying to gain an understanding of the basics and build from there.

Thanks!

P#64225 2019-05-07 14:01

Follow Lexaloffle:        
Generated 2020-11-23 19:29 | 0.089s | 4194k | Q:10