|
[Sponsors] |
Iterative evaluation of expression in CFX-pre |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
May 20, 2014, 07:19 |
Iterative evaluation of expression in CFX-pre
|
#1 |
New Member
Vasilis
Join Date: May 2014
Posts: 2
Rep Power: 0 |
Hello,
I'm wondering if there is a function (or anything else) which enables me to use the calculated value of an expression at the previous timestep in order to evaluate the value at the current timestep. To make it more clear, the concept is that a coefficient "k" derives from a "Temperature" (among others) and is used at next for a new estimation of the "Temperature". The "Temperature" is an opening temp. at a specific boundary. Thanks in advance! |
|
May 20, 2014, 07:35 |
|
#2 |
Super Moderator
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,862
Rep Power: 144 |
No there is no CEL expression to do this. I wish there was as it would make things much easier.
You can do it using user fortran of course. You can also use some undocumented features to make additional variables carry over from last time step. And a final thing is that the CEL functions areaAve, massflow, count etc are all calculated based on the values from the previous iteration. In a steady state run that is the previous iteration, in a transient simulation it is the previous coefficient loop. Sometimes that can be useful. |
|
March 24, 2017, 04:32 |
|
#3 |
New Member
Join Date: May 2011
Posts: 21
Rep Power: 0 |
I have been struggling with variable definitions to keep the value of the previous timestep, e.g. if(mod(atstep,2)==0, <recalculate>, <keep>) but I don't know how to keep the variable unchanged, or to store its original value in another variable without cyclic issues. Is there an undocummented means like suggested or otherwise to do this? You also mention Fortran for the solver to do this but I am lost on that. Thanks.
|
|
March 24, 2017, 07:15 |
|
#4 |
Super Moderator
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,862
Rep Power: 144 |
Search the forum for "trans_loop", that is the undocumented feature to do this. The alternate way of doing it is using fortran.
|
|
Tags |
cfx, cyclic dependency, evaluation, expression, iterative |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
CFX Pre not importing Mesh | ajhunte | CFX | 10 | October 31, 2022 17:52 |
only 1 of many named selections not showing up in cfx pre | mihirbhagat | CFX | 2 | April 26, 2019 05:56 |
Setting Pressure Boundary Conditions in ANSYS CFX Pre | saisanthoshm88 | CFX | 21 | February 22, 2017 17:50 |
logical expression for cfx interrupt control | wjy-c | CFX | 0 | November 29, 2013 05:30 |
Defining a domain in CFX Pre | ashtonJ | CFX | 1 | June 13, 2011 03:34 |