CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Programming & Development

Convergence criterion with runtime PostProcessing

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 29, 2012, 09:25
Default Convergence criterion with runtime PostProcessing
  #1
New Member
 
Simon Härdi
Join Date: Oct 2012
Location: Switzerland
Posts: 1
Rep Power: 0
shaerdi is on a distinguished road
Hello all

I am simulating a a non-newtonian fluid in a parallel plate rheometer. For this I am using a modified Version of the nonNewtonianIcoFoam-solver (OF Version 2.1.1). It works, but I cannot tell when the (steady-state) simulation is converged. The residuals from velocity and pressure rapidly drop at the beginning and then remain almost constant while the shear-rate depending viscosity still changes.

Now I want to program my own convergence criterion that checks for the resulting torque in the rheometer and stops the simulation if the (relative) change from the previous time step drops below a given value.

The problem is to calculate the torque at each time step. Until now I used the utility 'stressComponents' in combination with sampling the corresponding entry in the sigma matrix over a line and post-process (integral over a function of the samples) it with python after the simulation.

Now I want to implement these steps (Calculation of sigma, sampling, integral) into a function object, to store the torque (or write it to the terminal) in each time step and set the stopAt attribute according to the convergence criterion.
What is the best way to do so?

I managed to calculate and write sigma and I can sample fields using function objects, but I don't want to write these files at each time step as this really slows the computation down. Plus, I don't know how to access the sampled data to do the calculation that I did with python until now.

Any help is really appreciated!

Kind Regards,
Simon
shaerdi is offline   Reply With Quote

Reply

Tags
functionobjects, runtime postprocessing


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Convergence Centurion2011 FLUENT 48 June 15, 2022 00:29
problem with Min/max rho tH3f0rC3 OpenFOAM 8 July 31, 2019 10:48
Force can not converge colopolo CFX 13 October 4, 2011 23:03
convergence criterion Dominique FLUENT 5 November 24, 2006 03:36
Setting convergence criterion Vidya FLUENT 5 August 6, 2006 17:46


All times are GMT -4. The time now is 17:06.