
www.Usenet.com
| <-- __Chronological__ --> | <-- __Thread__ --> |
"Jesper Taxbøl" <[EMAIL PROTECTED]> wrote in message news:<[EMAIL PROTECTED]>... > I am currently working on a project for computergraphics where I want to > implement fluid dynamics in a 3d grid. > > I have made a prototype, that is a direct 3d extension to the system > described in "Real-time fluid dynamics for games" and "Stable fluids" by jos > stam. > > Stable fluids: > http://www.dgp.toronto.edu/people/stam/reality/Research/pdf/ns.pdf > > Real-time fluid dynamics for games: > http://www.dgp.toronto.edu/people/stam/reality/Research/pdf/GDC03.pdf > > The method used by Jos has a problem handling internal boundries. The grid > has defined densities and velocities at the center of each cell. > > This is a problem because it makes it impossible to handle boundries thinner > than 2 cells. > > If a cell is solid, one sets the velocity of the cell to inverse of the > neighbour, so an interpolation between them will result in a velocity of 0 > on their boundry. But one can only do this on one side at the time. > > Because the system has to be used in realtime I am using a very coarse grid. > ~15^3 cells, and that makes thick boundries very inconvinient. > > Therefore I want to redesign the grid design, so each cell has a variable > for the flow through each of the sides instead of just a velocity vector in > the center. > > I am not sure how exactly to implement this, because I am new in the CFD > area. I will have to update each velocity in every cellside in the system. > But will it be possible to do the projection step described in "Real-time > fluid dynamics for games"?? Jesper, You might want to look at some papers by Nick Foster here: http://www.cis.upenn.edu/~fostern/ In particular, "Realistic Animation of Liquids" has a very readable description of a discretization that places velocities at the faces of cells, rather than the cell center. The method in that paper also performs a "projection" step. The technique is based on the Marker-and-Cell method. (By the way, I believe that Nick Foster was largely responsible for the fluid simulations scenes in the movies "Antz" and "Shrek" from PDI.) The grid in Nick Foster's paper is known in CFD as a "staggered" grid. Note that, in that scheme, not all velocities are defined on every face. For example, the fluid velocity in the x-direction is defined on the faces of the computational cell pointing in the positive and negative x-axis directions. The grid in Jos Stam's paper is "colocated." (Note that there are some other variations in the CFD literature as well.) CFD can be (and is) performed with both types of grids. The choice can affect things like the specification of boundary conditions, the accuracy of the solution, and the stability and speed of the algorithm. I haven't looked at Jos Stam's method closely enough to tell you how difficult it would be to change it to a staggered grid. If you are interested in learning more, I would recommend "Computational Fluid Dynamics - The Basics with Applications" by John D. Anderson Jr. Hope this helps, Jeremy Furtek Delphi Research mailto: jeremy at delphiresearch dot com
| <-- __Chronological__ --> | <-- __Thread__ --> |