|
[Sponsors] |
dynamic Mesh, correct fluxes, surfaceScalarFields |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
June 26, 2020, 05:43 |
dynamic Mesh, correct fluxes, surfaceScalarFields
|
#1 |
Member
Al
Join Date: May 2019
Posts: 37
Rep Power: 6 |
Dear Foamers
I got this warning when I am using dynamic mesh in a self extended solver. Code:
--> FOAM Warning : From function Foam::autoPtr<Foam::mapPolyMesh> Foam::dynamicRefineFvMesh2D::refine(const labelList&) in file dynamicRefineFvMesh2D/dynamicRefineFvMesh2D.C at line 321 Cannot find surfaceScalarField ((interpolate(grad(psi))|(mag(interpolate(grad(psi)))+(1e-06|dimChange)))&S) in user-provided flux mapping table 5 ( rhoPhi none phi none alphaPhi0.water none ghf none nHatf none ) The flux mapping table is used to recreate the flux on newly created faces. Either add the entry if it is a flux or use (((interpolate(grad(psi))|(mag(interpolate(grad(psi)))+(1e-06|dimChange)))&S) none) to suppress this warning. Code:
correctFluxes ( (phi none) (nHatf none) (rhoPhi none) (alphaPhi0.water none) (ghf none) (((interpolate(grad(psi))|(mag(interpolate(grad(psi)))+(1e-06|dimChange)))&S) none) ); Code:
wrong token type - expected word, found on line 0 the punctuation token '(' Code:
// calculate normal vector volVectorField gradPsi(fvc::grad(psi)); surfaceVectorField gradPsif(fvc::interpolate(gradPsi)); surfaceVectorField nVecfv(gradPsif/(mag(gradPsif)+scalar(1.0e-6)/dimChange)); surfaceScalarField nVecf(nVecfv & mesh.Sf()); But nothing changed and still I can see the warning. So what do you suggest to solve this warning? Thanks |
|
February 2, 2021, 09:52 |
|
#2 |
Member
Lorenzo
Join Date: Apr 2020
Location: Italy
Posts: 35
Rep Power: 6 |
Hi, maybe it is a bit late to try solving it.
Try writing the option in correctFluxes without a pair of brackets. So, you wrote "(((interpolate(grad(psi))|(mag(interpolate(grad(p si)))+(1e-06|dimChange)))&S) none)", try with "((interpolate(grad(psi))|(mag(interpolate(grad(ps i)))+(1e-06|dimChange)))&S none)". |
|
October 12, 2022, 12:53 |
|
#3 |
New Member
Joshua Christopher
Join Date: Jul 2022
Posts: 7
Rep Power: 3 |
Hello aliyah,
Did you find a solution to your question? I am having essentially the same issue with my solver. Thank you, Joshua |
|
October 12, 2022, 14:42 |
|
#4 | |
Member
Al
Join Date: May 2019
Posts: 37
Rep Power: 6 |
Quote:
Sure, I could figure it out. First and foremost, I think this message is only a warning and has no effect on the simulation. However, the solution is usually visible in the warning. So it will be simpler to discuss the solution if you put the warning you get in the log file here. Best, |
||
October 13, 2022, 11:25 |
|
#5 | |
New Member
Joshua Christopher
Join Date: Jul 2022
Posts: 7
Rep Power: 3 |
Quote:
Hi Aliyah, I am getting the same warning but with a different flux: Code:
--> FOAM Warning : From function Foam::autoPtr<Foam::mapPolyMesh> Foam::dynamicRefineFvMesh::refine(const labelList&) in file dynamicRefineFvMesh/dynamicRefineFvMesh.C at line 308 Cannot find surfaceScalarField ((interpolate(eps)*magSf)*snGradCorr(Ue)) in user-provided flux mapping table 12 ( rhoPhi none phi none nHatf none alphaPhi0.phase1 none alphaPhiUn none rhoEFlux none rho*phi none Ue none ghf none phiAbs none rhoE none alphaPhi none ) The flux mapping table is used to recreate the flux on newly created faces. Either add the entry if it is a flux or use (((interpolate(eps)*magSf)*snGradCorr(Ue)) none) to suppress this warning. I am getting some oscillations in the solution at the AMR boundary so I was wondering if this warning was related and wanted to resolve it. I suspect I actually need to correct the flux at the refinement boundary. I made a post before I thought of replying to this thread and seeing if you fixed it: Warning in flux mapping table with dynamicRefineFvMesh I also had another thread that shows the oscillations of solution values (made before I thought the warning might be connected): New volScalarField incorrect values with dynamicRefineFvMesh Thank you for your attention on this! Regards, Joshua |
||
October 18, 2022, 15:19 |
|
#6 |
New Member
Joshua Christopher
Join Date: Jul 2022
Posts: 7
Rep Power: 3 |
Hi Aliyah,
I figured out how to suppress warnings of this type. I had to put the flux into createFields.H and update that at every step. I documented my fix in more detail in the other thread: Warning in flux mapping table with dynamicRefineFvMesh Thank you again, Joshua |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[snappyHexMesh] SnappyHexMesh/splitMeshRegion : region1 in zone "-1" | GuiMagyar | OpenFOAM Meshing & Mesh Conversion | 3 | August 4, 2023 12:38 |
Gambit problems | Althea | FLUENT | 22 | January 4, 2017 03:19 |
[snappyHexMesh] No layers in a small gap | bobburnquist | OpenFOAM Meshing & Mesh Conversion | 6 | August 26, 2015 09:38 |
[ICEM] Dynamic mesh setup with ICEM | David121284 | ANSYS Meshing & Geometry | 0 | April 11, 2014 04:19 |
[Gmsh] 2D Mesh Generation Tutorial for GMSH | aeroslacker | OpenFOAM Meshing & Mesh Conversion | 12 | January 19, 2012 03:52 |