6 votes
Accepted

Can Julia be used to create a large-scale CFD software like OpenFOAM?

I think the question is just too subjective to answer. In the end, there are excellent C++ libraries for nearly everything that has to do with the solution of PDEs, whereas they are largely missing in ...
Wolfgang Bangerth's user avatar
4 votes

How are dimension units on openFoam?

Units on the brackets follow the figure: Accordingly, [0 1 -1 0 0 0 0] = m/s
Vitor Abella's user avatar
4 votes
Accepted

CFD: Can one calculate the dimensionless wall distance $y^+$ a priori?

The White-Christoph formula can be used to estimate the skin-friction coefficient as: $$C_f\approx\frac{0.455}{\ln^2(0.06Re_x)}$$ From this correlation, one can relate $C_f$ to $y^+/y_1$. Assuming ...
Wes's user avatar
  • 270
4 votes
Accepted

Flux sign and face normal confusion in finite volume method

When dealing with conservation laws like your case, you can often make use of the divergence theorem (as you did). You can then express the fact that the total mass within your integration region is ...
MPIchael's user avatar
  • 2,935
4 votes

Why OpenFOAM uses its own data structures and linear solvers?

In the light of more recent information: OpenFOAM follows the C++11 standard without any exception at the time of writing. Therefore, you can use any C++ containers of this standard within OpenFOAM. ...
Herpes Free Engineer's user avatar
3 votes

Differences between openfoam and freefem/fenics

The fundamental difference between OpenFOAM and FreeFEM/FEniCs is the underlying approach in discretizing PDEs. OpenFOAM uses a finite volume method whereas FreeFEM and FEniCs employ the finite ...
zhanga's user avatar
  • 31
3 votes
Accepted

How to calculate skewness for a mesh?

From the discussions and the paper, OpenFOAM seems to have implemented a measure of skewness. This answer is not an explanation why the different definitions of skewness might be equivalent, I am just ...
Abdullah Ali Sivas's user avatar
3 votes
Accepted

Why OpenFOAM uses its own data structures and linear solvers?

Straight from Henry's finger tips: a comment which goes in the general direction of the OP's question. As Wolfgang pointed out, OpenFOAM predates many developments we're used to, including the STL ...
Dohn Joe's user avatar
  • 559
3 votes
Accepted

How is central difference scheme second-order accurate?

The expression with $g=1/2$ is second order if and only if f is the midpoint of P and N.The expression with $g\in[0,1]$ is second order if f is on PN and$fN/Pf=g$. If f is anywhere else you need to ...
Philip Roe's user avatar
  • 1,154
3 votes

Getting adjacent cells map for an unstructured polyhedral mesh

Using a hash map adds a log(n) complexity to all accesses (then traversing the whole mesh will cost n log(n) in general), so clearly it is not the best solution. Now your question is how you can ...
BrunoLevy's user avatar
  • 2,315
2 votes

A Simple Standard Test Case for Pipe Flow

As it was discussed in the comments, the fluid density is most likely the culprit. If you are using an incompressible solver, such as icoFoam, ...
Dohn Joe's user avatar
  • 559
2 votes
Accepted

a reverse of foamToVTK tool?

As of today, there is no officially released functionality in OpenFOAM versions that converts VTK data to OpenFOAM grid data. Yet, a heuristically written python script was provided for such purposes: ...
Herpes Free Engineer's user avatar
2 votes

Demo example for OpenFOAM with CUDA

I suggest to start form this page, where you can find different project related to OpenFoam that use GPU. Keep in mind that OpenFoam was born with the intent to resolve practical case in applied ...
Mauro Vanzetto's user avatar
2 votes
Accepted

How to let OpenFOAM write output at fixed time intervals _and_ keep the last few steps?

While the OpenFOAM Forum is the proper place to ask, I will give it a shot. Write control can be set to follow only one rule: either write every time step, or write every 100 ms. There is no way ...
Dohn Joe's user avatar
  • 559
2 votes

Is "Gradient Computation" in Finite Volume Discretization Really 2nd order accurate?

Not strictly no. They will reconstruct only linear functions on simple meshes exactly. You can get a better approximation (for non stretched meshes) using weighted least squares gradient ...
EMP's user avatar
  • 2,089
2 votes
Accepted

Can OpenFoam be used for interactive simulations (flying a plane)?

OpenFOAM doesn't have the degree of prescribed mesh motion you are looking for. It has 6 DOF, but thats not sufficient. What you need is a CFD tool which is: A) 3D B) Unsteady C) Has strong mesh ...
EMP's user avatar
  • 2,089
2 votes
Accepted

Getting adjacent cells map for an unstructured polyhedral mesh

I'm assuming you are starting with a list of cell definitions, say, as a list of vertices defining the cell and a "type" defining the topology of each cell. As part of the topology definition for each ...
Bill Greene's user avatar
  • 6,064
2 votes

Flux sign and face normal confusion in finite volume method

Normal direction depends on the cell that you are writing equation for. the word outward is relative to the cell under study. In order to write equation for each of cells, i.e. $\Sigma \nabla T.n S_f=...
Naghi's user avatar
  • 235
2 votes

Flux sign and face normal confusion in finite volume method

An extended answer. For more arbitrary meshes you have to consider that generally CFD/FEM solvers rely on generic data-structures with element and side lists: Element list Side list Consider the ...
ConvexHull's user avatar
  • 1,286
1 vote

Aerofoil study using CFD, struggling to find aerofoil coordinates

The NACA 6 series is obtained by conformal transformation (starting from a circle, you can find a reference here for example, but there are plenty), so there is not an easy and straight forward ...
albiremo's user avatar
  • 410
1 vote

Can I use periodic boundary conditions for `U` but not for `p`?

As far we are in an Incompressible Navier Stokes formulation, The velocity field and the pressure field are related in the domain and on the boundary (I suppose you are using the incompressible solver ...
albiremo's user avatar
  • 410
1 vote

Getting streamline for a lid driven cavity flow in openFoam/ParaView

Your initial and end points for the line are the same, thus you only have one line that "emanates" from it. To have multiple streamlines you need multiple seed points. You need to have a ...
nicoguaro's user avatar
  • 8,510
1 vote

How is central difference scheme second-order accurate?

Assuming $F (not f)$ as the face center, we have the following taylor expansions for $\phi$: $$\phi_p = \phi_F + \nabla\phi_F.(r_P-r_F)+O(2)→×|r_N-r_F|$$ $$\phi_N=\phi_F + \nabla\phi_F.(r_N-r_F)+O(2)→×...
Naghi's user avatar
  • 235
1 vote
Accepted

SnappyHexMesh and multi stl geometry

Did you try to merge the three STLs to create one, closed STL. OpenFOAM brings with it a toolsurfaceAdd to join STLs. Apart from the problems you encountered in the ...
Dohn Joe's user avatar
  • 559
1 vote
Accepted

OpenFoam Mapped Boundary condition

This is specified in the blockMeshDict. So it is a property of the patch itself. For pitzDailyMapped we have the following in ...
tiam's user avatar
  • 864
1 vote

Is OPENFOAM a good idea for direction/operator splitting in parabolic equation

OpenFoam will definitely satisfy your needs. Though you may feel some restrictions of solvers,still it mostly resolves all the domains. Also Open Source platform has its advantage of large user-base ...
vraj chauhan's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible