CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT

Fluent scripting question

Register Blogs Members List Search Today's Posts Mark Forums Read

Like Tree7Likes
  • 6 Post By LuckyTran
  • 1 Post By YorkshireTea

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   May 7, 2012, 14:33
Default Fluent scripting question
  #1
Senior Member
 
Join Date: Nov 2010
Location: USA
Posts: 1,232
Rep Power: 24
me3840 is on a distinguished road
I'm trying to get fluent to output a projected area into the terminal window, but without user intervention. The problem is the projected area function requires you to enter in wall zones you want and hit enter when you're done defining them. Is there some command I can put in the input script that will do this? I couldn't find anything about it in the TUI manual.
me3840 is offline   Reply With Quote

Old   May 10, 2012, 12:12
Default
  #2
New Member
 
Join Date: May 2012
Posts: 3
Rep Power: 13
olybeast is on a distinguished road
start recording journal

do all that manual stuff you just mentioned

stop recording journal



there you have a file with all the code you need in it to write your own journals
olybeast is offline   Reply With Quote

Old   May 11, 2012, 00:37
Default
  #3
Senior Member
 
Lucky
Join Date: Apr 2011
Location: Orlando, FL USA
Posts: 5,649
Rep Power: 65
LuckyTran has a spectacular aura aboutLuckyTran has a spectacular aura aboutLuckyTran has a spectacular aura about
Quote:
Originally Posted by me3840 View Post
I'm trying to get fluent to output a projected area into the terminal window, but without user intervention. The problem is the projected area function requires you to enter in wall zones you want and hit enter when you're done defining them. Is there some command I can put in the input script that will do this? I couldn't find anything about it in the TUI manual.
Make a journal file. It is just a text file that lists all your TUI commands. Fluent will read the file and then enter the commands exactly as you enter them.
LuckyTran is offline   Reply With Quote

Old   May 11, 2012, 02:18
Default
  #4
Senior Member
 
Join Date: Nov 2010
Location: USA
Posts: 1,232
Rep Power: 24
me3840 is on a distinguished road
When I do that it fills the journal file with text commands which include GUI parameters - will that still work if you run the script on a cluster with no GUI?
me3840 is offline   Reply With Quote

Old   May 11, 2012, 02:21
Default
  #5
Senior Member
 
Lucky
Join Date: Apr 2011
Location: Orlando, FL USA
Posts: 5,649
Rep Power: 65
LuckyTran has a spectacular aura aboutLuckyTran has a spectacular aura aboutLuckyTran has a spectacular aura about
Quote:
Originally Posted by me3840 View Post
When I do that it fills the journal file with text commands which include GUI parameters - will that still work if you run the script on a cluster with no GUI?
without a GUI the GUI commands will not work at all.

you need to make the same journal file using only TUI commands and that will work anywhere.
LuckyTran is offline   Reply With Quote

Old   May 11, 2012, 12:19
Default
  #6
Senior Member
 
Join Date: Nov 2010
Location: USA
Posts: 1,232
Rep Power: 24
me3840 is on a distinguished road
Yes..that's the problem...I don't know what the TUI command is for "enter"
me3840 is offline   Reply With Quote

Old   May 11, 2012, 14:25
Default
  #7
Senior Member
 
Lucky
Join Date: Apr 2011
Location: Orlando, FL USA
Posts: 5,649
Rep Power: 65
LuckyTran has a spectacular aura aboutLuckyTran has a spectacular aura aboutLuckyTran has a spectacular aura about
Quote:
Originally Posted by me3840 View Post
Yes..that's the problem...I don't know what the TUI command is for "enter"
oh sorry.

If you press the enter/return key into the TUI window, a list of all available commands will be printed on the screen. You can use this to learn to navigate your way to get to the right place. Follow all the prompts and enter all the appropriate inputs.

Then write down all your inputs into a separate text file and save it as a journal .jou file. Fluent will read the file exactly as is so anything you put in the journal file will be inputted exactly into the TUI the same way. So an easy to check if your journal is setup properly.

The Fluent manual also contains a list of the TUI commands to get you started but you still need to do it a few times to get all the input strings.
LuckyTran is offline   Reply With Quote

Old   May 11, 2012, 14:39
Default
  #8
Senior Member
 
Join Date: Nov 2010
Location: USA
Posts: 1,232
Rep Power: 24
me3840 is on a distinguished road
Yes, I know this already. But when you choose to do something like projected areas in the TUI, it will eventually ask you for a list of wall zones to project. The only way to get it to stop asking for the list is to hit enter with nothing typed in as a zone. My question is how to "hit enter" while giving no actual name in the script. There has to be some sort of "OK" command.
me3840 is offline   Reply With Quote

Old   May 11, 2012, 14:48
Default
  #9
Senior Member
 
Lucky
Join Date: Apr 2011
Location: Orlando, FL USA
Posts: 5,649
Rep Power: 65
LuckyTran has a spectacular aura aboutLuckyTran has a spectacular aura aboutLuckyTran has a spectacular aura about
Quote:
Originally Posted by me3840 View Post
Yes, I know this already. But when you choose to do something like projected areas in the TUI, it will eventually ask you for a list of wall zones to project. The only way to get it to stop asking for the list is to hit enter with nothing typed in as a zone. My question is how to "hit enter" while giving no actual name in the script. There has to be some sort of "OK" command.
remember that it is a simple text file and will be able to interpret special characters. the enter key is simply a special character. any enters/return characters that are in the script will be interpreted (even if they are at the end of the line).

you therefore need to be careful, because if you accidentally leave a blank line, it will be interpreted as a return command, which may lead to errors afterwards such as when it is in the middle of a list of prompts.
LuckyTran is offline   Reply With Quote

Old   May 11, 2012, 14:50
Default
  #10
Senior Member
 
Join Date: Nov 2010
Location: USA
Posts: 1,232
Rep Power: 24
me3840 is on a distinguished road
I've tried leaving a blank line, but it doesn't do anything. I want it to be interpreted as a return command. Is there some other way to end a list of prompts?
me3840 is offline   Reply With Quote

Old   May 11, 2012, 14:57
Default
  #11
Senior Member
 
Lucky
Join Date: Apr 2011
Location: Orlando, FL USA
Posts: 5,649
Rep Power: 65
LuckyTran has a spectacular aura aboutLuckyTran has a spectacular aura aboutLuckyTran has a spectacular aura about
Quote:
Originally Posted by me3840 View Post
I've tried leaving a blank line, but it doesn't do anything. I want it to be interpreted as a return command. Is there some other way to end a list of prompts?
I think you are looking for () to signify the end of a list

()
Jeeloong, Sabomb, srsel6 and 3 others like this.
LuckyTran is offline   Reply With Quote

Old   May 15, 2012, 23:50
Default
  #12
Senior Member
 
Join Date: Nov 2010
Location: USA
Posts: 1,232
Rep Power: 24
me3840 is on a distinguished road
Yup, that's the one. Thanks.
me3840 is offline   Reply With Quote

Old   August 18, 2017, 14:36
Default
  #13
Member
 
Join Date: Jan 2015
Location: United Kingdom
Posts: 53
Rep Power: 11
Jeeloong is on a distinguished road
Quote:
Originally Posted by luckytran View Post
i think you are looking for () to signify the end of a list

()

very important
Jeeloong is offline   Reply With Quote

Old   September 23, 2019, 14:49
Default
  #14
New Member
 
Join Date: May 2019
Posts: 7
Rep Power: 6
YorkshireTea is on a distinguished road
I believe a comma , also works for 'enter'?
destroy likes this.
YorkshireTea is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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
Question about transiet simulations in Fluent Vitaly FLUENT 5 February 19, 2012 23:06
Question about modeling an elastic wall in Fluent Mosheraa FLUENT 2 June 24, 2011 19:47
Question: BC openFOAM vs. FLUENT oehmu OpenFOAM 2 December 14, 2010 17:14
a question about the liquidus temperature in fluent hunter FLUENT 0 April 13, 2009 22:55
General question regarding Fluent 6.3s mesh motion AndyRoth FLUENT 0 December 8, 2006 13:01


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