|
[Sponsors] |
February 11, 2017, 15:53 |
"cx-interrupt" not Interrupting
|
#1 |
Member
Join Date: Jun 2016
Posts: 64
Rep Power: 10 |
Hello all.
I have defined a SCHEME variable using the following TUI command: Code:
(rp-var-define 'interrupt/flag 0 'interger #f) However, when the value of ""interrupt/flag" is changed to 1, the following text appears in the console but the simulation continues without stopping. Does anyone have any idea why the simulation is not properly being interrupted? There is remarkably little documentation on the SCHEME language and even less on cx-interrupt. Last edited by Baden; February 15, 2017 at 23:12. |
|
February 13, 2017, 05:28 |
|
#2 |
Senior Member
Join Date: Nov 2013
Posts: 1,965
Rep Power: 27 |
I think you made a typo in your scheme command, it should be integer and not interger.
On the question you asked: I have no idea, but I am interested in this way of working, it looks useful if it works. Do you get the same behavior when you manually press control-C? I see the command (cx-interrupt-client) also exists, maybe this could be what you need? |
|
February 13, 2017, 21:38 |
|
#3 | |
Member
Join Date: Jun 2016
Posts: 64
Rep Power: 10 |
Quote:
Pressing control-C results in the same problem: the simulation says "Interrupting" but does not stop. However, pressing control-C twice properly stops the simulation. I also tried the "cx-interrupt-client" command, but it appeared to have no effect (the "Interrupting" text did not appear in the command window). |
||
February 14, 2017, 03:45 |
|
#4 |
Senior Member
Join Date: Nov 2013
Posts: 1,965
Rep Power: 27 |
If control-C twice works, did you try to put (cx-interrupt) twice?
Code:
(if (> (rpgetvar 'interrupt/flag) 0) (begin (cx-interrupt) (cx-interrupt))) |
|
February 15, 2017, 23:25 |
|
#5 | |
Member
Join Date: Jun 2016
Posts: 64
Rep Power: 10 |
Quote:
Code:
(if (> (rpgetvar 'interrupt/flag) 0) (begin (cx-interrupt) (cx-interrupt))) Code:
(if (> (rpgetvar 'interrupt/flag) 0) (begin (cx-interrupt) (cx-interrupt-client))) |
||
February 16, 2017, 04:42 |
|
#6 |
Senior Member
Kevin
Join Date: Dec 2016
Posts: 138
Rep Power: 10 |
I've got little to no experience using the SCHEME language, but to me it almost seems like you need to interrupt twice because the first time it interrupts the iteration loop within the current time step and the second time it interrupts the time step loop. So perhaps there are different commands for that.
Did you consult the following website to get more information: http://www.scheme.com/tspl4/ |
|
February 16, 2017, 12:18 |
|
#7 | |
Senior Member
Join Date: Nov 2013
Posts: 1,965
Rep Power: 27 |
Quote:
My conclusion: I don't know how to do this, and don't know how to find out. |
||
February 16, 2017, 16:06 |
|
#8 | |
Member
Join Date: Jun 2016
Posts: 64
Rep Power: 10 |
Quote:
|
||
February 17, 2017, 04:53 |
|
#9 |
Senior Member
Join Date: Nov 2013
Posts: 1,965
Rep Power: 27 |
If you can go to Fluent support, it might not be a dead end.
|
|
February 27, 2017, 22:27 |
|
#10 |
Member
Join Date: Jun 2016
Posts: 64
Rep Power: 10 |
||
September 12, 2022, 09:14 |
|
#11 | |
Member
Odisha
Join Date: Jan 2020
Posts: 59
Rep Power: 6 |
Quote:
I wrote this command in the 'Execute Command' dialog box to stop a transient simulation. (I initially took the value of 'interrupt/flag' as 5). Code:
(if(>(rpgetvar 'interrupt/flag) 0) (set! mstop? #t)) Also, if possible, could you guide me on the UDF part. I'm encountering some problem with the DEFINE_ADJUST UDF I wrote. |
||
September 13, 2022, 03:02 |
|
#12 |
Senior Member
Alexander
Join Date: Apr 2013
Posts: 2,363
Rep Power: 34 |
I believe that instead of
Code:
rpgetvar Code:
%rpgetvar
__________________
best regards ****************************** press LIKE if this message was helpful |
|
October 12, 2023, 10:49 |
|
#13 |
New Member
Join Date: Oct 2023
Posts: 3
Rep Power: 3 |
[QUOTE=Siba11;835714]Hi,
I wrote this command in the 'Execute Command' dialog box to stop a transient simulation. (I initially took the value of 'interrupt/flag' as 5). Hey friend, have you solved this problem yet? Currently, I am experiencing this issue. I am looking for help to solve the problem, here is my code. Run the code but FLUENT does not stop running. [CODE](rp-var-define 'interrupt/flag 0 'integer #f) (define (interrupt) (if (> (%rpgetvar 'interrupt/flag) 0) (cx-interrupt))) |
|
Tags |
cx-interrupt, scheme |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Interrupting calculation at value | aalansari | FLUENT | 0 | August 22, 2014 09:03 |
Interrupting a run in progress | austin.m | SU2 | 4 | October 4, 2013 10:55 |
Interrupting a Journal File | svp | FLUENT | 2 | February 16, 2011 09:00 |
Interrupting Gambit w/o leaving CPU busy? | Chris Bailey | FLUENT | 0 | January 26, 2005 17:29 |