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

Constructing filenames with a parameter for the simulation name

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 1, 2019, 05:28
Default Constructing filenames with a parameter for the simulation name
  #1
New Member
 
Frank Richter
Join Date: Oct 2018
Posts: 13
Rep Power: 8
FrankR is on a distinguished road
Dear Community,

the analysis of my simulation is split into several log files, for ease of inspection. In this configuration I have to replace the name of the simulation in every single log file when analyzing another simulation.

How can I define the name of the simulation only once, construct file names for output within the log files, and retain in FLUENT's mind the name of the simulation for all log files that are called subsequently ?

I think of something like (sn = simulation name)

(define sn "Test-07")
(display sn)
(begin sn)

where sn acts as a parameter.

Now, I want to have the path and filename for a transcript file
"M:/Brandraumbeispiel/Test-07/Test-07-Journal-Output/Test-07-Oeffnen der Case-Datei.txt"
contructed (tf = transcript file):

(define TF (string-append "M:/Brandraumbeispiel/" sn "/" sn "-Journal-Output/" sn "-Oeffnen der Case-Datei.txt"))
(display TF)
(begin tf)

and feed this into the following block:

; Open the case-file and have the output written to a file
(cx-gui-do cx-activate-item "MenuBar*WriteSubMenu*Start Transcript...")
; instead of
; (cx-gui-do cx-set-file-dialog-entries "Select File" '( "M:/Brandraumbeispiel/Test-07/Test-07-Journal-Output/Test-07-Oeffnen der Case-Datei.txt") "Transcript Files (*.trn *.out )")
(cx-gui-do cx-set-file-dialog-entries "Select File" '( tf) "Transcript Files (*.trn *.out )")
(cx-gui-do cx-activate-item "MenuBar*WriteSubMenu*Stop Transcript")

I also experimented with
(cx-gui-do cx-set-file-dialog-entries "Select File" '( begin(tf)) "Transcript Files (*.trn *.out )")

Other log files should automatically know sn.

The above commands are GUI commands. I'd need this also in TUI commands, for example in
/file/read-data "M:/Brandraumbeispiel/Test-07/Test-07-Autosave/Test-07-time_step=-1-00001.dat"

I use the FLUENT "Academic Student Release" 19.2 on a Windows-PC in stand-alone mode (not using Workbench).

Thank you dearly for sharing your expertise and your kind advice,

FrankR
FrankR is offline   Reply With Quote

Reply

Tags
log files, parameter


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
Using output parameter as input parameter within the same simulation jjfm20 FLUENT 11 November 6, 2017 09:53
Surface Source - Fixed Temperature? robtheslob FloEFD, FloWorks & FloTHERM 18 May 12, 2017 03:28
Simulation FPEs - turbulence for transient and steady-state? DaveR OpenFOAM Running, Solving & CFD 5 March 5, 2017 16:06
Expert parameter to stop the fluid flow simulation KK CFX 1 February 25, 2008 17:29
3-D Contaminant Dispersal Simulation Apple L S Chan Main CFD Forum 1 December 23, 1998 11:06


All times are GMT -4. The time now is 17:57.