Home › Forums › Daily Usage › Archiving cases and sol2refresco for unsteady cases with deform grid › Reply To: Archiving cases and sol2refresco for unsteady cases with deform grid
Archiving solution is indeed tricky when it comes to restarting the solution.
In general here is what I would advise:
If you want to restart, using the same grid, then you should export the CGNS file as a NFACE-n file (refresco2cgns with option -e=exportNFACE_n).
Then you can use this file with cgns2refresco to re-create the .geo and .topo file.
Finally you can use sol2refresco to create the .data files.
If you want to restart using a different grid, then you must make sure that this new grid is at the same position as the original grid.
Then use that grid to create the .geo and .topo (cgns2refesco)
And, finally, run sol2refresco to get the .data
cgns2refresco creates only .geo and .topo files.
sol2refesco creates only .data files.
Then now specifically for calm-water free-surface simulation, where the dynamic trim and sinkage was changed during the simulation:
Either you generate the new grid directly at the proper trim and sinkage, then you do not have geometry problems.
Or, you have to apply it. In this case:
– run one iteration of the user code, with the target trim and sinkage values in the control file
– Run refresco2cgns with the -e=exportNFACE_n option
– use the generated CGNS file to run cgns2refresco
Now the .geo and .topo you have have the proper geometry, at the target trim and sinkage.
– run sol2refresco to interpolate the old grid (at updated trim and sinkage) on the new grid (also with correct trim and sinkage)
To run the final simulation, you have two choices regarding the trim and sinkage values:
– set them to zero and then, add the original values to obtain the correct values.
– set them to what they actually are, and set the flag /controls/userCode/dynamicTrimAndSinkage/general/zeroOnRestart to true. This will not trigger a deformation at the first time-step after the restart.
I hope what I wrote is clear because it is quite dense in terms of information and step to follow.