|
[Sponsors] |
NearWallFields functionObject too slow for large meshes |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
February 21, 2023, 22:00 |
NearWallFields functionObject too slow for large meshes
|
#1 | |
New Member
pisharoti05
Join Date: Feb 2020
Posts: 10
Rep Power: 6 |
Hello Foamers,
I was looking for a function that helps me sample pressure, velocity and wall-shear stress around my moving wall so that I can calculate the boundary layer properties for multiple time instances. My case involves an overset simulation of a propeller with very fine resolution near the propeller surface for good boundary layer resolution. I fortunately found the function: nearWallFields which gives me exactly what I am looking for. I copied the sub-dictionary from the tutorial case: $FOAM_TUTORIALS/incompressible/pisoFoam/RAS/cavity/system/FOs/FOnearWallFields and modified it for my case: Code:
nearWallFields1 { // Mandatory entries type nearWallFields; libs (fieldFunctionObjects); fields ( (U UNear) (p pNear) ); patches (Propeller); distance 1e-3; // Optional (inherited) entries log true; timeStart 0.44998; timeEnd 0.457499; executeControl timeStep; executeInterval 20; writeControl timeStep; writeInterval 40; } Quote:
Does the functionObject not scale well for larger meshes? Scaling down the mesh size is not an option for me. So any other suggestions to speed this post-processing utitlity would be greatly appreciated. Regards, Naina. |
||
February 22, 2023, 17:19 |
Update on Implementation of NearWallRegions for Overset Meshes
|
#2 | |||
New Member
pisharoti05
Join Date: Feb 2020
Posts: 10
Rep Power: 6 |
I have an update on the above issue. Looks like I need to specify the right region for the function object. Earlier, the solver was taking region0 as the default which is my background mesh (region0), while I want the operation to take place in my moving mesh region (region1).
So now my sub-dictionary input includes the following (bold portion indicating the new addition): Quote:
Quote:
One thing I tried was to create cellZones for my two regions and then use splitMeshRegions to separate the regions. But that seems to be mixing up the zoneIDs for the background and moving mesh regions, which is something I do not want. My topoSetDict looks like this: Code:
actions ( { name c0; type cellSet; action new; source regionToCell; insidePoints ( (0 0 -1) ); } { name c1; type cellSet; action new; source cellToCell; set c0; } { name c1; type cellSet; action invert; } { name BackgroundMesh; type cellZoneSet; action new; source setToCellZone; set c0; } { name movingMesh; type cellZoneSet; action new; source setToCellZone; set c1; } ); Quote:
So my new question is: Is there a better way of defining the region for NearWallFields and how? |
||||
February 23, 2023, 14:55 |
|
#3 |
Senior Member
Yann
Join Date: Apr 2012
Location: France
Posts: 1,238
Rep Power: 29 |
Hello Naina,
I never used the nearWallFields function object on overset cases, so I do not know how the function behaves with overset meshes. I don't think you can use the region parameter in your case, because this is initially meant to be used with multi-region cases where each region as its own mesh located in a different directory. This is how chtMultiRegionFoam works. The mesh structure on overset cases is different: there is one single polyMesh directory containing all mesh data and the overlapping meshes are identified by their zoneID value. Basically, you only have one region in your case (region0) and this is what OpenFOAM tells you when you try to define another region: Code:
--> FOAM Warning : request for objectRegistry region1 from objectRegistry simpleRotor failed available objects of type objectRegistry are 1(region0) Since this is not possible to select a cellZone when using nearWallFields, a trick could be to use a first function to filter the data, and then use the filtered data as an input in nearWallFields. This is only an idea, but the expressions function object seems to have a fieldMask functionality which might be used to retrieve data based on their zoneID. Another idea, maybe simpler, would be to use the volFieldValue function object, something like this: Code:
UMovingMesh { type volFieldValue; libs (fieldFunctionObjects); fields (U); operation none; regionType cellZone; name movingMesh; writeFields true; } Please note I have no idea if this would do the job, as I never used it myself, but hopefully it can give you some leads to find a solution. Regards, Yann |
|
February 23, 2023, 15:16 |
|
#4 |
New Member
pisharoti05
Join Date: Feb 2020
Posts: 10
Rep Power: 6 |
Hello Yann!
Thank you very much for the suggestions. I am actually trying out the volFields option. However, the issue currently is that I am using OF-v2006 and when I implement the functionObject, it returns an empty field. This issue was also discussed in the thread here: Sample a volume field So for now, I am updating my OF version to try that option out. Will post an update on the thread once I get it working. T Thanks again. Really appreciate your help. Regards, Naina. |
|
Tags |
nearwallfields, overset mesh, postprocess function, postprocessing, sampling function object |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Preserve meshes in Fluent parametric run | hwerner2014 | FLUENT | 2 | February 28, 2022 17:29 |
Cannot find functionObject file residuals | vava10 | OpenFOAM Pre-Processing | 2 | November 14, 2020 13:21 |
nearWallFields error in postProcessing | wilove | OpenFOAM Post-Processing | 4 | April 11, 2019 04:37 |
Fluent running increadibly slow | MayTheFlowBeWithYou | FLUENT | 12 | May 22, 2018 03:04 |
[Salome] IdeasUnvToFoam is very slow when converting meshes | armitatz | OpenFOAM Meshing & Mesh Conversion | 1 | May 2, 2017 13:48 |