|
[Sponsors] |
September 3, 2019, 10:53 |
how to get Varaible value by using TUI
|
#1 |
New Member
Layth
Join Date: Mar 2016
Posts: 5
Rep Power: 10 |
Hi all,
I am using VOF model and I want to get the surface tension value through the TUI by rpgetvar so I can use it in a udf. I wander if it is possibale. Regards, |
|
September 4, 2019, 01:39 |
|
#2 |
Senior Member
Alexander
Join Date: Apr 2013
Posts: 2,363
Rep Power: 34 |
using scheme file you may create any king of variable
Code:
(define (make-new-rpvar name default type) (if (not (rp-var-object name)) (rp-var-define name default type #f) ) ) (make-new-rpvar 'my_surface_tension 30.0 'real) Code:
surf_tension = RP_Get_Real("my_surface_tension"); //get parameter RP_Set_Real("my_surface_tension",60.0); //set parameter |
|
September 4, 2019, 08:25 |
|
#3 |
New Member
Layth
Join Date: Mar 2016
Posts: 5
Rep Power: 10 |
Thank you for your replay
I can use the GUI to set the surface tension coefficient by going to the phase interaction>surface tension>surface tension coefficient. how can I get this value through the TUI? i used the code (cx-send '(for-each (lambda (v) (pp v)) rp-variables)) to get the variable scheme list and the surface tension coefficient is part of the domains variable but I do not know how to use the rpgetvar to get the value of the surface tension coefficient. Best Regards |
|
September 4, 2019, 22:43 |
|
#4 |
Senior Member
Alexander
Join Date: Apr 2013
Posts: 2,363
Rep Power: 34 |
Code:
(rpgetvar 'variable_name) Code:
(rpgetvar 'mp/cvt/surface-tension) |
|
September 5, 2019, 07:19 |
|
#5 |
New Member
Layth
Join Date: Mar 2016
Posts: 5
Rep Power: 10 |
Thanks a lot.
|
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
TUI 'if' statement depending on Total Wallclock time? | bloodflow | FLUENT | 1 | August 25, 2019 23:21 |
Using the TUI to write/read profiles to update BC's? | bloodflow | FLUENT | 2 | August 22, 2019 08:51 |
Return a value from TUI | asal | FLUENT | 5 | March 3, 2016 16:04 |
TUI Commands from GUI? | Carlos | FLUENT | 6 | May 22, 2013 19:05 |
Define animate using TUI | Zurlugh | FLUENT | 1 | July 24, 2008 09:55 |