Hacker News new | ask | show | jobs
by jreimers 4570 days ago
Cool! I made half a sphere with 0.5+sqrt(0.2-((x-0.5)^2+(y-0.5)^2)). If there was a way to do a mirroring on the xy plane (as in a +/- z value) it could be a full one.
2 comments

I managed to modify yours to make a full sphere with a bad hack: http://vicapow.github.io/equation-plot-webgl/index.html#0.5%...

There's probably a better way to choose which points go above and below than random(), but it works.

Edit: Got it to work non-randomly. Adjacent dots alternate above and below: http://vicapow.github.io/equation-plot-webgl/index.html#0.5%...

It seems the result is a complex number. Fiddled around with it a bit until I got lucky and got the plane to disappear.

http://vicapow.github.io/equation-plot-webgl/index.html#0.48...)

that's so cool! btw, you can link to your equation here

    http://vicapow.github.io/equation-plot-webgl/index.html#0.5%2Bsqrt(0.2-((x-0.5)%5E2%2B(y-0.5)%5E2))
edit: but HN seems to be messing up the urls :(