|
[Sponsors] |
How to have only some field print in time steps folders? |
![]() |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
![]() |
![]() |
#1 |
New Member
Lucie Recurt
Join Date: Jun 2020
Posts: 17
Rep Power: 6 ![]() |
Hello foamies!!!
I'm working on a particles track case using OpenFOAM 20.06. My case is running but I would like to have only the positions file in my time's folders. I tried to do that by adding those line in the controlDict file: functions { writeObjects1 { type writeObjects; libs ("libutilityFunctionObjects.so"); objects ( U boundary cellZones data epsilon faceZones faces fvSchemes fvSolution k kinematicCloud kinematicCloud:UCoeff kinematicCloud:UTrans kinematicCloudOutputProperties kinematicCloudProperties mu neighbour nu nut owner phi pointConstraints pointMesh pointZones points rho tetBasePtIs transportProperties turbulenceProperties volPointInterpolate(U) volPointInterpolation );// i.e fields you don't want writeOption noWrite;//anyWrite;autoWrite } writeObjects1 { type writeObjects; libs ("libutilityFunctionObjects.so"); objects ( kinematicCloudPositions ); writeOption autoWrite; } } but it's not working, I got every field write in every time step folder... Does someone know how to do that? Thanks in advance! |
|
![]() |
![]() |
![]() |
![]() |
#2 |
Senior Member
anonymous
Join Date: Jan 2016
Posts: 416
Rep Power: 14 ![]() |
Hi!
I shouldn't do this. Instead try to increase the writeInterval in the controlDict, to make sure at least sometimes you write your fields (thus you can restart the run if needed). Then you could write the needed fields more frequently with this functionObject. |
|
![]() |
![]() |
![]() |
![]() |
#3 |
New Member
Lucie Recurt
Join Date: Jun 2020
Posts: 17
Rep Power: 6 ![]() |
Thanks you so much for your answer. I decided to write it like that:
functions {writeObjects1 { type writeObjects; libs ("libutilityFunctionObjects.so"); objects ( kinematicCloud );// i.e fields you don't want writeOption autoWrite;//anyWrite;autoWrite writeControl timeStep; writeInterval 1; } writeObjects2 { type writeObjects; libs ("libutilityFunctionObjects.so"); objects ( kinematicCloud );// i.e fields you don't want writeOption noWrite;//anyWrite;autoWrite } it prints just the folder lagrangian |
|
![]() |
![]() |
![]() |
![]() |
#4 |
Senior Member
anonymous
Join Date: Jan 2016
Posts: 416
Rep Power: 14 ![]() |
So is it working now or not? I'm not sure.
I just modified the aachenbomb tutorial and it's working properly for me. It writes everything at every 5e-5 seconds, but it will write the sprayCloud object for every timestep. (it is OF v1912, but I guess it should be fine with the foundation version too) You can change the writeControl and the objects entries as you wish. And make sure that you have only one setting for a field. In your post you set autoWrite, then noWrite in the second functionObject. You should decide if you need the fields or not. ![]() |
|
![]() |
![]() |
![]() |
Tags |
fields, positions, postprocessing, print |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
laplacianFoam with source term | Herwig | OpenFOAM Running, Solving & CFD | 17 | November 19, 2019 13:47 |
[Other] dynamicTopoFVMesh and pointDisplacement | RandomUser | OpenFOAM Meshing & Mesh Conversion | 6 | April 26, 2018 07:30 |
Stuck in a Rut- interDyMFoam! | xoitx | OpenFOAM Running, Solving & CFD | 14 | March 25, 2016 07:09 |
[blockMesh] Another cylinder question | bendel_boy | OpenFOAM Meshing & Mesh Conversion | 5 | January 6, 2015 05:09 |
same geometry,structured and unstructured mesh,different behaviour. | sharonyue | OpenFOAM Running, Solving & CFD | 13 | January 2, 2013 22:40 |