View Issue Details

IDProjectCategoryView StatusLast Update
0003364OpenFOAMContributionpublic2019-10-14 10:00
Reporterniklas.wikstrom Assigned Tohenry  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionno change required 
Platformx86_64OSFedoraOS Version29
Product Versiondev 
Fixed in Versiondev 
Summary0003364: buoyant{S,P}impleFoam pressure initialisation improvement?
DescriptionThe heatTransfer/buoyant solvers seem to initiate pressure fields a bit backward. The current implementation reads on line 71 in createFields.H:

// Force p_rgh to be consistent with p
p_rgh = p - rho*gh;

I suggest that it is reasonable to force p to be consistent with p_rgh instead (since p is the hydrostatic pressure and should have a gradient along the gravity vector):

// Force p to be consistent with p_rgh
p = p_rgh + rho*gh;

This implementation seems better to me and leads to smaller fluctuations in the initial iterations/time steps. The current implementation may lead to a crash due to negative density for tall domains.
TagsNo tags attached.

Activities

henry

2019-10-09 12:07

manager   ~0010821

Neither approach is a general solution to the problem, there is no reason to suppose the user knows how to specify p_rgh given that it is a numerical construct and is trivial only in the case of a uniform density.

I implemented a more general initialisation approach in fireFoam in which the a hydrostatic balance is computed with the density field calculated from the temperature field but it is quite complex and relatively expensive. In the longer term we would like to generalise this and the concept of p_rgh to handle other body forces but we need to secure funding for this substantial effort.

henry

2019-10-14 10:00

manager   ~0010843

Generalization of the initialization of p_rgh requires funding. In the meantime pre-processing utilities can be used to initialize p appropriately for the case.

Issue History

Date Modified Username Field Change
2019-10-09 11:56 niklas.wikstrom New Issue
2019-10-09 12:07 henry Note Added: 0010821
2019-10-14 10:00 henry Assigned To => henry
2019-10-14 10:00 henry Status new => closed
2019-10-14 10:00 henry Resolution open => no change required
2019-10-14 10:00 henry Fixed in Version => dev
2019-10-14 10:00 henry Note Added: 0010843