Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.javascript > #21921
| From | "Chris M. Thomasson" <no@spam.invalid> |
|---|---|
| Newsgroups | comp.lang.javascript |
| Subject | Re: An online circle intersection fractal... |
| Date | 2013-11-07 12:46 -0800 |
| Organization | Aioe.org NNTP Server |
| Message-ID | <l5gu6d$5r5$1@speranza.aioe.org> (permalink) |
| References | <l53o4o$5r5$1@speranza.aioe.org> <935bd61f-b8bd-456a-8813-3b00b2ebddb4@googlegroups.com> <l595fc$9de$1@speranza.aioe.org> <34ae1ec8-f301-4a46-bdc1-f2c2be3d7d4a@googlegroups.com> <+SUJPfoYtpeSFw0C@invalid.uk.co.demon.merlyn.invalid> |
> "Dr J R Stockton" wrote in message news:> > +SUJPfoYtpeSFw0C@invalid.uk.co.demon.merlyn.invalid... > In comp.lang.javascript message <34ae1ec8-f301-4a46-bdc1-f2c2be3d7d4a@go > oglegroups.com>, Mon, 4 Nov 2013 18:40:13, "Michael Haufe (TNO)" > <tno@thenewobjective.com> posted: > >On Monday, November 4, 2013 4:01:19 PM UTC-6, Chris M. Thomasson wrote: > >> > >> Do you happen have something in mind that can find the true > >> intersection(s) > >> of two circles that gets around any sqrt wrt polar coordinates? I am > >> all > >> ears if you have something to share! ;^) [...] > >when you draw the circle on the pixel array, you can look at the color > >of the current pixel before you plot the point. So if the default color > >of the canvas is white, and circles are black when plotted, the > >intersection of the current circle and ALL of the relevant circles in > >the region would be where the pixel is already black. > As I understand it, the desire is to show a fractal based on exact > circles positioned in the exact intersections of exact circles, which > would require infinite-length arithmetic. > The OP's code would replace exact arithmetic with IEEE Doubles > arithmetic, resolution about 1 in 7E15, which is likely to be good > enough. Yes, it is definitely good enough for the application at hand. :^) > Your idea rounds the points of intersection to be integers in pixel > units; and that may not be good enough. Its an interesting idea about finding intersections. I was thinking about encoding the circles with unique colors and extending the fractal based of of that information. The problem is, the "seed circles" might be off the viewport plane when I zoom. I need to calculate that information in order to get to the part that is within the viewport. So, there comes a point where using pixel information to determine intersections is more expensive than simply calculating them. In other words, when you do not have to draw, calculate the intersections. Humm... > Additionally, one must consider > the possible cases of tangency and of almost-parallel intersection, > where many pixels may "lie on" both lines. Exactly right. I was worried about two circles passing right through each other when the pixels are diagonal. I was thinking about encoding a unique color for each circle. Then this diagonal issue can be solved by doing a little search around the 8 pixels surrounding the current pixel. > I recall the esteemed Fred, Head of Workshop, consulting me about a cam- > shape calculation which was going astray. He prudently had tested it > using a graph-plotter before using the nice new numerically-controlled > milling-machine, and I was able to perceive that his code had > substantially that problem, easily enough avoided once realised. There will be errors in the pixel probing solution proportionate to rounding errors. AFAICT, the error should actually be visually represented in the fractal itself. Interesting to compare a rendering generated by the pixel probe vs. one generated by the actual circle intersection calculation... Fractals are _very_ sensitive to any errors... ;^) Thanks.
Back to comp.lang.javascript | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
An online circle intersection fractal... "Chris M. Thomasson" <no@spam.invalid> - 2013-11-02 13:43 -0700
Re: An online circle intersection fractal... "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2013-11-03 17:55 -0800
Re: An online circle intersection fractal... "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2013-11-03 18:55 -0800
Re: An online circle intersection fractal... "Chris M. Thomasson" <no@spam.invalid> - 2013-11-04 14:01 -0800
Re: An online circle intersection fractal... "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2013-11-04 18:40 -0800
Re: An online circle intersection fractal... "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2013-11-04 18:42 -0800
Re: An online circle intersection fractal... "Chris M. Thomasson" <no@spam.invalid> - 2013-11-05 13:05 -0800
Re: An online circle intersection fractal... "Chris M. Thomasson" <no@spam.invalid> - 2013-11-05 14:35 -0800
Re: An online circle intersection fractal... "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2013-11-10 23:48 -0800
Re: An online circle intersection fractal... Dr J R Stockton <reply1300@merlyn.demon.co.uk.invalid> - 2013-11-06 19:41 +0000
Re: An online circle intersection fractal... "Chris M. Thomasson" <no@spam.invalid> - 2013-11-07 12:46 -0800
Re: An online circle intersection fractal... "Chris M. Thomasson" <no@spam.invalid> - 2013-11-04 14:03 -0800
Re: An online circle intersection fractal... "Chris M. Thomasson" <no@spam.invalid> - 2013-11-05 22:19 -0800
csiph-web