## Google summer of code. make \$4500!

General discussion about the development of the open source Blender

Moderators: jesterKing, stiv

Koba
Posts: 0
Joined: Thu Apr 15, 2004 9:48 am

Fluid dynamics is something I've been dreaming of for years...I have several posts floating around with suggestions on using particles and metaballs to do this sort of thing in a very rudimentary way.

I cannot emphasise how much I hope you succeed with this fluid solver. Actually, I would love to help. I'm going to have a look into this out of my own interest no matter what happens.

I am a second year (undergraduate) physicist so hopefully I'll understand some of those papers. This is the sort of thing I am REALLY interested in.

So n_t, I am behind you 100% on this one and I'll do my best to help in any way I can.

Thank you,

Koba

n_t
Posts: 0
Joined: Tue Jun 28, 2005 2:07 pm
Bellorum, kakapo, Koba - glad to hear you like it, I'm working on this stuff for almost 2 years now, so I'm getting used to it

I'll let you know once there's a preview version, the Summer-of-Code CVS repositories are currently being set up...

Koba
Posts: 0
Joined: Thu Apr 15, 2004 9:48 am
Hi again...

n_t, would you be kind enough to answer a couple of questions about LBM? I've read the paper through a couple of times and I find it fascinating! I've started to write a Python script proof-of-concept of the method for my own satisfaction.

I would PM you but it is disabled, so I hope no one minds if I ask here - (perhaps you could suggest a better way for me to contact you)

Firstly, how is it possible to advect all the DFs at each time step with their respective velocities when not all the 19 velocity vectors are of unit magnitude? In particular, what do you do with the DFs that have a length of root 2? What is the point of the first DF vector (0,0,0) if it stays constant?

Secondly, just to confirm my understanding, is the "speed of light" in this Cellular Automata Universe is just one cell per time step giving rise to the need of an adaptive time step for higher velocities? Do I really need adaptive time steps for a proof-of-concept script?

Thirdly, how do you add gravity to the simulation? Do you simply keep incrementing the downwards DF vector by 9.8 for all fluid cells at each time step?

Finally, this business about reconstructing DFs along interface normals - is this simply approximating partially filled interface cells to atmospheric pressure along with the cells that have been marked as void?

Thank you very much! I would love to help you in this project but it is clear from your website that you know exactly what you are doing by now.

Koba

n_t
Posts: 0
Joined: Tue Jun 28, 2005 2:07 pm
Hi koba, sure. Btw. you can also send me a mail to nils at thuerey dot de ...

About your questions: you're right - the velocities do not all have unit magnitude, you have one DF of length 0, 6 DFs with length one, the rest has sqrt(2). Due to these length the particles (=DF values) are moving directly to the neighboring cell along the velocity direction, and the particles with length 0 stay at the current cell. These values are modified during the collision step, though, so you can't leave them away.

With "speed of light" you probably meant "speed of sound" ? The max. velocity (and speed of sound) for this model (D3Q19) is 1/3, so if you make sure for your test cases that the velocities stay below that, you dont need adaptive time steps (you can add those later on if needed).

Acceleration due to gravity is done by adding a value to the (y-) velocity before collision - but as the max. velocity is 1/3, it should be much lower, and definitely less than 9.81, more like -1e-04 ,..

My master thesis also has a LBM introduction chapter, on p. 21 there's also some pseudo code, that should be working and might be a good place to start:
http://www10.informatik.uni-erlangen.de ... 602_da.pdf

Btw. the articles you mentioned before use this SPH method - I've never really used it, but I think both LBM and SPH have similar properties. LBM might be a bit easier to get into though

Koba
Posts: 0
Joined: Thu Apr 15, 2004 9:48 am
Thanks n_t!

You have certainly answered my question about adding gravity to the simulation as well as the importance of the DF with zero velocity (I don't know what I was thinking...the number of particles remaining in each cell *clearly* gets modified by the collision step ).

Still a little confused at how after a given number of time steps the DFs of root 2 velocity will have been advected across the same number of cells as the DFs of unit velocity. But nevermind explaining that to me...I'll probably find the answers I require once I've read your thesis. As for you, you'll be needing to concentrate on this wonderful project of yours for the benefit of us Blenderheads.

Anyway, I have a lot to read now (72 pages as opposed to the 9 pages I was using before:
http://www10.informatik.uni-erlangen.de ... 1rtlbm.pdf)
If I have any questions after that, I may e-mail you.

Oh, and thanks again.

Koba

wavk
Posts: 126
Joined: Wed Oct 16, 2002 9:58 am
Location: The Netherlands
Contact:
Good to see so many good submissions from the Google summer, it turns out to be a very good initiative. I saw the fluid video's, I'm amazed, it's VERY good. I can picture myself playing with it forever.

I'm particularly interested in the PyTexture project. I can agree with the whole thinking behind it, I was also scared by the c++ plugin writing thing. If this is a success, we could do all kinds of semi-procedural effects. I'm just wondering how fast it will be, I imagine calling a Python script for each pixel in a scene can be very slow. Or is there some way of semi-compiling a script?

Good luck to you all!

bfvietnam
Posts: 0
Joined: Wed Apr 21, 2004 8:54 pm

### Idea

Why not make steps toward completing the collaborative 3D environment, like Verse.. But have some students work on it.. Then later you could do projects within the collaborative environment..

After that find funding for cheap head tracking systems, and cheap 3D

MAke the initiative of creating collaborative 3D modelling environments..

theeth
Posts: 500
Joined: Wed Oct 16, 2002 5:47 am
Location: Montreal
Contact:

### Re: Idea

bfvietnam wrote:Why not make steps toward completing the collaborative 3D environment, like Verse.. But have some students work on it.. Then later you could do projects within the collaborative environment..
You'll be happy to learn that Jiri is already doing that as part as SOC.

Martin
Life is what happens to you when you're busy making other plans.
- John Lennon