|
[Sponsors] |
November 23, 2018, 03:55 |
Node and cell in cell centred system
|
#1 |
Senior Member
luca mirtanini
Join Date: Apr 2018
Posts: 165
Rep Power: 8 |
Hi all,
if I have a cell centred cfd software, are the number of node and number of cell coincident? |
|
November 23, 2018, 05:15 |
|
#2 |
Senior Member
|
They are not exactly coincident but scale similarly, thus they are roughly the same. For example, if along a direction you have N cells, there are N+1 nodes in 1D.
In contrast, the number of faces is typically a factor k higher (around 3 for hexaedral grids). |
|
November 23, 2018, 05:42 |
|
#3 |
Senior Member
luca mirtanini
Join Date: Apr 2018
Posts: 165
Rep Power: 8 |
Thanks a lot for the answer. In my case it is a cartesian grid. Why n+1?
If I consider I a face and * a node I*I*I*I*I*I*I I count 6 cell and 6 node. I am missing something? |
|
November 23, 2018, 06:11 |
|
#4 |
Senior Member
Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,865
Rep Power: 73 |
Start by constructing the 1D grid, for example on a domain [0,L] you have
x(i)=(i-1)*h i=1,2,...N+1 This way L=x(N+1)=N*h. Now you can define the centroid of the FV xc(i)=(x(i)+x(i+1))/2 i=1,2...N Now, should be clear also for a 2D case. Of course, some specific care on the boundaries can require to consider further nodes |
|
November 23, 2018, 06:25 |
|
#5 |
Senior Member
|
Actually, there are 7 I and 6 * ...
Let's first distinguish cells, from nodes and faces for a 3D grid as in 1D faces and nodes coincides. A 3D cartesian cell has 1 cell (center), 6 faces and 8 nodes. In 1D we have 1 cell (center) and 2 nodes. If I is a node and * is a cell, in 1D you have: I*I*I that is 3 nodes and 2 cells. Thus, in 1D, for N cells you get N+1 nodes. Basically, you have a cell for each node but, to close the last cell in the line you need an additional node. If we go to 3D, cells and nodes are trivial, you have Nx*Ny*Nz cells and (Nx+1)*(Ny+1)*(Nz+1) nodes. Faces are slightly more complex. You have 3 groups of faces. Those with x normal, y normal and z normal respectively. For those with x normal, there are Ny*Nz faces for each of the Nx+1 planes with x normal. As per nodes in 1D, faces bound the cells, thus we count also the last Nx+1 group of faces. Yet, in the x plane there are only Ny*Nz cells with a face. The same goes for faces with y normal, which are Nx*Nz*(Ny+1), and those with z-normal, which are Nx*Ny*(Nz+1). Summing up: Nx*Ny*Nz cells (Nx+1)*(Ny+1)*(Nz+1) nodes (Nx+1)*Ny*Nz+Nx*(Ny+1)*Nz+Nx*Ny*(Nz+1) faces thus you can see the original claim on number of nodes roughly equivalent to number of cells and number of faces approximatively 3 times higher. |
|
November 23, 2018, 06:29 |
|
#6 |
Senior Member
luca mirtanini
Join Date: Apr 2018
Posts: 165
Rep Power: 8 |
Thank u for your answer Paolo! So do I need to end always with a node at the boundary? Because I use fds ( a nist software) and there are not node at the boundaries (maybe not in the graphic interface). (I was sure that the boundary conditions in fds were placed at the faces of the cells)
|
|
November 23, 2018, 07:40 |
|
#7 |
Senior Member
luca mirtanini
Join Date: Apr 2018
Posts: 165
Rep Power: 8 |
If you see the file attached, in the software that I use some variables are stored in the centroid of the cell, other are stored at the boundary.
In this case do you think does it make sense to count the nodes? Sorry but maybe I am simply confused because of this. |
|
November 23, 2018, 11:25 |
|
#8 |
New Member
Join Date: Nov 2018
Posts: 10
Rep Power: 7 |
Hi guys,
If the cells are N and by assuming/by definition each cell has 1 node, there is no way that the nodes can be N+1. If we take a simle grid in 1D with N cells, we will have N nodes and N+1 faces. |
|
November 23, 2018, 11:34 |
|
#9 |
Senior Member
|
There is a confusion here between grid nodes and cells with their relative cell centers.
Of course we can use whatever nomenclature you want but, by convention in CFD literature on finite volume methods, the most used one is: cells -> actual cells and their respective cell centers (which, thus, are not referred to as nodes) faces -> the faces which make up the cells. E.g., 6 for hexaedra (3D), 4 for tetrahedra (3D), 4 for quadrilaterals (2D), 3 for triangles (2D), etc. nodes -> the actual geometrical points by which a finite volume mesh is usually described. E.g., 8 for hexaedra, 4 for tetrahedra, 4 for quadrilaterals, 3 for triangles, etc. To convince yourself on this nomenclature, try looking at the so called node centered finite volume method (in contrast to the cell centered one). In 1D, of course, faces and nodes collapse into the same thing, but that's a very specific corner case. In 1D I would argue that nodes don't actually exist, only faces and cell centers (unfortunately, in my previous post, I did the contrary, talking about nodes instead of faces in 1D, ignoring the difficulty with the nomenclature you have). |
|
November 23, 2018, 11:40 |
|
#10 | |
Senior Member
|
Quote:
Nodes (as defined by the typical nomenclature in CFD for finite volume methods) do not enter in any part of a cell centered finite volume method and you can basically forget about them (they actually enter in some exotic gradient discretizations, but that's not the point here). |
||
November 23, 2018, 11:58 |
|
#11 | |
Senior Member
Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,865
Rep Power: 73 |
Quote:
As Paolo wrote, the confusion is between the nodes in the grid generation and the construction of a FVs set over the grid. In practice the grid generation covers but the unknowns and the boundary nodes. As a further example of difference, consider a structured grid and a staggered colocation of the variables. |
||
November 23, 2018, 12:05 |
|
#12 |
Senior Member
Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,865
Rep Power: 73 |
For example, on a non-staggered and non-uniform grid I select the FVs and grid nodes this way
https://www.researchgate.net/publica...u47DBgIOBOsuhg |
|
November 23, 2018, 15:25 |
|
#13 | |
Senior Member
luca mirtanini
Join Date: Apr 2018
Posts: 165
Rep Power: 8 |
Quote:
Every CFD book that I ve read defines the nodes as the place where you calculate the solutions. In the software that I use the solution are calculated in different points, as I posted before. Does it make sense in this case talking about nodes? Btw I understood your explanation, but I am trying difficulties in comparing this explanation to the software that I use. |
||
November 23, 2018, 15:34 |
|
#14 | |
Senior Member
Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,865
Rep Power: 73 |
Quote:
From FDS guide: "The governing equations are approximated using second-order accurate finite differences on a collection of uniformly spaced three-dimensional grids. Multiple meshes can be processed in parallel using Message Passing Interface (MPI) libraries. Scalar quantities are assigned to the center of each grid cell; the velocity components at the appropriate cell faces; and vorticity components at cell edges. This is what is commonly referred to as a staggered grid [12, 13]. Its main purpose is to avoid “checker-boarding” in pressure-velocity coupling by naturally representing the pressure cell velocity divergence, a very important thermodynamic quantity in the model." so, your confusion is due to the fact that a staggered colocation is used. |
||
November 23, 2018, 15:35 |
|
#15 |
Senior Member
|
If we disregard the variables on edges (which are non standard), I see from the picture you linked that variables are just defined in cell and face centers.
Typically, finite difference and fem codes define variables at nodes (besides node centered finite volume codes) |
|
November 23, 2018, 16:04 |
|
#16 | |
Senior Member
luca mirtanini
Join Date: Apr 2018
Posts: 165
Rep Power: 8 |
Quote:
|
||
November 23, 2018, 16:06 |
|
#17 |
Senior Member
Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,865
Rep Power: 73 |
||
November 24, 2018, 04:59 |
|
#18 |
Senior Member
luca mirtanini
Join Date: Apr 2018
Posts: 165
Rep Power: 8 |
||
November 24, 2018, 05:39 |
|
#19 | |
Senior Member
Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,865
Rep Power: 73 |
Quote:
Not exactly. Consider the 2d case for example. |-------| |...i,j.. | | ........| |-------| At the center you colocate the pressure node, then you have the staggered velocities v_n, v_s, u_e, u_w that allows for the divergence-free constraint to be ensured in (i,j). Apparently, you have one cell (for the pressure ) and four unknown velocities (two different grids for vertical and horizontal components). Actually, the velocities have a own computational cell that is staggered, too. Thus, you must consider that each variable has its own FV. And if you consider for example the velocity u_e it is the same that you would write as u_w for the pressure cell i+1,j. Try by yourself to graphic the sketch and you will understand. |
||
November 24, 2018, 06:32 |
|
#20 | |
Senior Member
luca mirtanini
Join Date: Apr 2018
Posts: 165
Rep Power: 8 |
Quote:
|
||
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[ICEM] Error in mesh writing | helios | ANSYS Meshing & Geometry | 21 | August 19, 2021 15:18 |
Export velocity in node or in cell center | jpina | FLUENT | 2 | November 6, 2015 13:42 |
[Gmsh] Cell to node connectivity after 'gmshToFoam' | Jibran | OpenFOAM Meshing & Mesh Conversion | 1 | June 8, 2015 10:09 |
Partition: cell count = 0 | metmet | FLUENT | 1 | August 31, 2014 20:41 |
Cluster ID's not contiguous in compute-nodes domain. ??? | Shogan | FLUENT | 1 | May 28, 2014 16:03 |