Virtual Polywell

Discuss how polywell fusion works; share theoretical questions and answers.

Moderators: tonybarry, MSimon

Post Reply
Indrek
Posts: 113
Joined: Wed Jul 04, 2007 1:51 pm
Location: Estonia
Contact:

Post by Indrek »

I started building an octree for 3D field interpolations and on the way worked out the symmetries in the cube polywell:

http://www.mare.ee/indrek/ephi/symmetry/

More geometric mayhem and megabytes of animated gifs.

- Indrek

drmike
Posts: 825
Joined: Sat Jul 14, 2007 11:54 pm
Contact:

Post by drmike »

Given the speed of processor and memory bus, the trade off of space for time makes a lot of sense. Reducing the tables by a factor of 8 is one way of looking at it, the other way is to keep the table size the same but increase the accuracy by a factor of 2 in all directions.

Nice pictures too!! That really helps to understand the symmetry.

Indrek
Posts: 113
Joined: Wed Jul 04, 2007 1:51 pm
Location: Estonia
Contact:

Post by Indrek »

It seems I'm geometrically challenged as well. I had made an error in my original divisions. Instead one can reduce it to 1/48 as the triangular prism splits into three parts.

- Indrek

Indrek
Posts: 113
Joined: Wed Jul 04, 2007 1:51 pm
Location: Estonia
Contact:

Post by Indrek »

I tried another approach:

http://www.mare.ee/indrek/ephi/symmetry/intersect.png
http://www.mare.ee/indrek/ephi/symmetry/intersect.gif

Long live POV-Ray and ImageMagick, they're perfect for this kind of stuff.

- Indrek

drmike
Posts: 825
Joined: Sat Jul 14, 2007 11:54 pm
Contact:

Post by drmike »

Gorgeous! I was trying to figure out the factor of three, but the picture just shows it! Of course!

I guess I'd go for a reduction in file size rather than try to double the point density. I can reduce my file size by a factor of 6, and that will help me to bring both the E and B fields into ram simultaneously.

I think I'll look at brute force particle tracking when I get a chance. trying to solve the stuff analytically is getting a touch thick!

Indrek
Posts: 113
Joined: Wed Jul 04, 2007 1:51 pm
Location: Estonia
Contact:

Post by Indrek »

I worked out the transformation matrices and the code to do the mapping. You might find it useful:

http://www.mare.ee/indrek/ephi/symmetry ... rs.cpp.txt

- Indrek

drmike
Posts: 825
Joined: Sat Jul 14, 2007 11:54 pm
Contact:

Post by drmike »

I think I see what you are doing, but I'll have to study it a bit! Is each transform a 3x3 matrix so input is a vector and output is a transformed vector?

Indrek
Posts: 113
Joined: Wed Jul 04, 2007 1:51 pm
Location: Estonia
Contact:

Post by Indrek »

That's right. You just multiply it with a vector to get a transformed vector. See this for more information:

http://en.wikipedia.org/wiki/Transformation_matrix

What I'm doing is, have a point in space, I run it through the cube_polywell_transform() - the function itself already transforms the point, search the field value at the transformed point (only 1/48 of the space now needed), and then finally apply the inversion matrix (the second of the returned pair of matrices) to the field values to transform them to the original point. Works perfectly.

- Indrek

drmike
Posts: 825
Joined: Sat Jul 14, 2007 11:54 pm
Contact:

Post by drmike »

And since all the "multiplies" are +1 or -1 it's a pretty simple operation too! Excellent!

Indrek
Posts: 113
Joined: Wed Jul 04, 2007 1:51 pm
Location: Estonia
Contact:

Post by Indrek »

Here's another piece of technology to use: tricubic interpolation. It comes with some implementation overhead but is doable. This website comes with info and code:

http://www.lekien.com/~francois/papers/LeMa05/

Though be careful, the code there is less than efficient, so look only, write your own (I got ~10x speed improvement over the original).

You don't need a big grid with this method. With 80MB grid (52K cells) I get accuracy to 6 digits. With simple one step numeric differentiation that requires about 28 field evaluations per grid cell if one is not to support shared points (so total 1.4M evaluations). Quite a lot so takes a bit over a minute to calculate here :( I'll be able to quarter that though once I make it run on all 4 of my CPU cores :)

- Indrek

drmike
Posts: 825
Joined: Sat Jul 14, 2007 11:54 pm
Contact:

Post by drmike »

Definitly related to fluid flow. I'll have to check it out when I get a chance!

Indrek
Posts: 113
Joined: Wed Jul 04, 2007 1:51 pm
Location: Estonia
Contact:

Post by Indrek »

I made another release, ephi-0.14, this one has tricubic interpolation and sector based data division. See "otree.cpp" for a test application.

http://www.mare.ee/indrek/ephi/#download

- Indrek

drmike
Posts: 825
Joined: Sat Jul 14, 2007 11:54 pm
Contact:

Post by drmike »

Wow! Hopefully I can get to the physics so you can do the visualizations of it!
(I'm not exactly an amatur, but I try not to take life too seriously :) )

Solo
Posts: 261
Joined: Fri Jun 29, 2007 12:12 pm
Location: Wisconsin

Post by Solo »

That's amazing! :shock: Nice work.

JohnP
Posts: 296
Joined: Mon Jul 09, 2007 3:29 am
Location: Chicago

Post by JohnP »

Indrek wrote:I made another release, ephi-0.14, this one has tricubic interpolation and sector based data division. See "otree.cpp" for a test application.

http://www.mare.ee/indrek/ephi/#download

- Indrek
Indrek, I've been enjoying the pretty pictures and I'm impressed with your work. As a soon to be physics grad with a long history of software dev, I would be hard pressed to duplicate it.

One thing though. Though I have a half dozen (windows based) video player programs & editors, none of them can open polywell.avi.

On a separate note, I'm not entirely following why such high currents (1000A?) are needed thru the coils. Is the goal to create a multi-kilogauss field?

Post Reply