   CFD - MAC staggered grid vs. centered grid
  Hi,When implementing a fluid solver in 2D or 3D one has the choise, where to specify the velocities u,v(,w). In the MAG staggered grid velocities are defined at the cell faces, where in the centered grid approach, velocities are defined at the cell centers.I read several papers, that use the MAC grid, but it's not yet clear to me where the advantages are?Cheers,  Oliver<SPAN CLASS=editedby>[edited by - pilarsor &#111;n August 1, 2003 6:28:08 AM]</SPAN>   
  >I read several papers, that use the MAC grid, but it''s not >yet clear to me where the advantages are?One of the advantages is the ease of including boundary conditions. Other is increased accuracy, which can be seen in more turbulent motion. Jos Stam told me some additional good point in an e-mail (it had something to do with vorticity confinement). I don''t know too much of the theory behind the difference between cell-centered and staggered velocities (error orders etc.), though. Perhaps someone does?I wonder where this sudden flow of CFD posts originates from  Could be the GDC2k3 paper. - Mikko Kauppila ;  > One of the advantages is the ease of including boundary  >conditions.In my case, the staggered grid implementation caused significantly more code to set the velocity boundaries. For example, if you have an inflow velocity at the left border it's very easy to define the velocity in x direction, because it's just already defined there. The other two velocity vectors however have to be interpolated to the same boundary position. (must be done bilinearly). And the most annoying thing is that the velocity field in x,y and z have each their own dimensions, resulting in an own loop for each velocity field for x,y and z.> I wonder where this sudden flow of CFD posts originates from  > Could be the GDC2k3 paperI also read his GDC2k3 paper, that gave me further motivation in implementing a 3D-fluid solver. Cheers,  Oliver   [edited by - pilarsor on August 1, 2003 8:54:44 AM]