Still thinking about how to word the specification. It comes in two
layers, the vector field and the logic for the interactions between
particles and attractors in said field. The logic layer shows how a
particle gets cast from a point and computes its vector field line,
segment by segment, until it hits an attractor or runs out of
iterations. If it hits, the segment from attractor to previous point in
the field line is drawn, and the previous point becomes a new attracting
agent. Well, this can get very computationally intensive! It will burn CPU.
I need to code it a different way wrt:
https://groups.google.com/d/topic/comp.lang.javascript/dgakiMzhgv0/discussion
The garbage collector is going crazy here.
>>> Anyway, it's running in my (up to date) Google Chrome, the only weird thing
>>> I have noticed (running it for few minutes only) is that it seems to get
>>> stuck at the points created manually, i.e. it seems to almost stop growing
>>> as soon as I add points: but maybe I should have waited for longer? Again,
>>> I just cannot say what exact outcome is expected.
>>
>> Can you please let it run for around a minute then click a couple of
>> points in the square, let it run for around 10 more minutes, take a
>> simple screenshot and post the image? The points you clicked should have
>> clusters by then. This would really help me out!
>
> Sorry again, it seems to work fine, actually. Here is the screenshot of a
> run, where I have let it run for 1 minute, then I have added 4 points and
> let it run for 5 more minutes (then stopped as my CPU was over-heating:-):
> <
https://drive.google.com/file/d/0BxPmJcnnbWOTZVdKYlJ5NEh0em8/view>
Very nice: Your screenshot is excellent information for me. Thank you so
much for giving it more time. I really do appreciate it Julio.
>> One more point, your computer is probably faster than mine, so one
>> minute of growth might be different. ;^)
>
> I am on a high-end laptop with an AMD Radeon on board, nothing more than
> that. The browser is not taking advantage of the AMD GPU anyway, but
> right away I wouldn't know how to improve on that (or maybe force the
> canvas to use the GPU?). To be investigated...
Well, unfortunately, if I do not add some method to allow attractors to
"die off" during the simulation, it will eventually overwhelm a GPU
and/or CPU.
Wrt, implementing on GPU, I was thinking of a limited form using/abusing
Uniform variables where the GPU can perform the critical vector field
summation function. Need to think about how to implement the DLA hit
logic in GPU. I am not sure its going to like it...