|
[Sponsors] |
Interrupt Control Conditions for Coefficient Loops |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
August 28, 2018, 18:01 |
Interrupt Control Conditions for Coefficient Loops
|
#1 |
New Member
Lloyd A. Sullivan
Join Date: Jun 2018
Location: UK
Posts: 9
Rep Power: 8 |
Hi There,
I want to create a logical stop criteria expression that reads if(1.1*abs(CEL value from current coefficient loop)>abs(CEL value from previous coefficient loop), 1, 0) However, there are two issues. 1. the stopping criteria only works for time steps and not coefficient loops 2. I can't call back the previous coefficient loop, nor use a derived variable as they only can only calculate things from time steps (i.e. standard deviation, etc) not coefficient loops Is there any way to get around these problems without using a Fortran Junction Box routine, and if a junction box is the only way, then can anyone give some sort of idea of how to monitor a variable from a coefficient loop and implement a stop criterion for the solver. I've had a look at the example User Fortran files, but they're a little bit vague. Thanks in advance for any help on the matter. Best regards, Lloyd |
|
August 28, 2018, 19:42 |
|
#2 |
Super Moderator
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,864
Rep Power: 144 |
There is no supported way of doing this in CEL. You will need User Fortran.
But do a search on the forum for TRANS_LOOP. That is the only way I know to recall values from previous, and it is a bit unreliable (which is why it is not supported).
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum. |
|
August 30, 2018, 10:34 |
|
#3 |
New Member
Lloyd A. Sullivan
Join Date: Jun 2018
Location: UK
Posts: 9
Rep Power: 8 |
Hi Glenn,
Thanks for the reply. I guess User fortran is the only way forward then. Do you know have any experience with User Fortran scripting, or possibly any useful examples besides those in the examples folder? |
|
August 30, 2018, 20:02 |
|
#4 |
Super Moderator
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,864
Rep Power: 144 |
Your resources for user fortran are the documentation, anything you can find on the web (there is a little bit) and ANSYS support. They have examples of many cases of user fortran so they are a good resource as well.
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum. |
|
August 31, 2018, 05:16 |
|
#5 |
Senior Member
urosgrivc
Join Date: Dec 2015
Location: Slovenija
Posts: 365
Rep Power: 12 |
if I understand you want to have a steady state solution but trans_loop only works in transient.
why not do a transient analysis with the same parameters, it would be like using a fixed timescale in steady state. The solution should be the same. So your trans_loop would run probably every 3 or so iterations when timestep is converged. |
|
Tags |
fortran code, interrupt control, stop criteria |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Centrifugal fan | j0hnny | CFX | 13 | October 1, 2019 14:55 |
Using Windkessel model to control outlet boundary conditions | meganstevens | ANSYS | 1 | September 9, 2019 19:01 |
Centrifugal fan-reverse flow in outlet lesds to a mass in flow field | xiexing | CFX | 3 | March 29, 2017 11:00 |
Overflow Error in Multiphase Modelling with Two Continuous Fluids | ashtonJ | CFX | 6 | August 11, 2014 15:32 |
logical expression for cfx interrupt control | wjy-c | CFX | 0 | November 29, 2013 05:30 |