CFturbo can be executed in Batch mode to change designs without any screen display and user interaction. This is essential for using CFturbo with optimization software.
Syntax:
cfturbo.exe -batch <batch file> [-verbose] [-export <interface name>]
Options:
batch <batch file> |
Run CFturbo in batch mode. <batch file> can be either a CFturbo file or a batch command file. |
verbose |
Display log output on the commandline. |
export <interface name> |
If CFturbo is started with a CFturbo file in batch mode, export interface can be selected like in the batch file. |
All other batch commands have to be defined in a file (<batch file>).
Batch file
The batch-mode of CFturbo is controlled by a file in XML file format. A template for a specific CFturbo project can be created by Export component | Basic | Batch mode template. It contains all changeable values with a short description and sample actions.
File structure:
<?xml version="1.0" standalone="yes"?> <CFturboFile Version="9"> <CFturboBatchProject InputFile="<InputFileName>" /> <Updates> [...] </Updates> <BatchAction .../> </CFturboBatchProject> </CFturboFile> |
A batch-file can contain multiple elements of the CFturboBatchProject-type, each one handling a specific CFturbo-project. All subelements are optional and can occur multiple times except the Updates-block.
The InputFile-attribute of the CFturboBatchProject-element specifies the absolute path of the CFturbo-projectfile.
The Updates-block is created by exporting a template for the project. All changeable values are included and can be modified or deleted if not used.
2 action are available for further processing of the project data:
| • | <BatchAction Name="Export" ExportFormat="General" Path="c:\testing\examples\impeller\myexports"/> |
Used to export the active component (point based exports) or all geometry elements visible in the 3d-view visible when running CFturbo not in batch mode. The export interface is selected by ExportFormat. The following values are valid:
AutoCAD
AxCent
BladeGenRtzt
Catia
DXF
Fluent
General
GridGen
IcemTin
IGES
Inventor
NumecaAG
NumecaIGG
ProE
PumpLinx
SolidWorks
StarCCM
STEP
STL
TurboDesign
TurboGrid
Unigraphics
By using the Path-attribute a folder for the exported files can be specified.
| • | <BatchAction Name="Save" OutputFile="C:\Testing\Examples\Impeller\Pump1_new.cft"/> |
Used for saving the CFturbo-project after applying the updates. By using this action, also a automatic conversion the the actual CFturbo file format could be realized. OutputFile specifies the absolute path to the file to save.
Example:
<?xml version="1.0" standalone="yes"?> <CFturboFile Version="9"> <CFturboBatchProject InputFile="C:\Testing\Examples\Impeller\Pump1.cft"> <Updates> <CFturboProject Type="Object" SelIndex="0"> <CFturboDesign_RadialImpeller Type="Object" SelIndex="0" Desc="CFturbo component"> <MainDimensions Type="Object" SelIndex="0" Desc="Main dimensions"> <MainDimensionsElement Type="Object" Name="Version 1." Desc="Main dimensions list element"> <nBl Type="Integer" Desc="Number of blades">7</nBl> </MainDimensionsElement> </MainDimensions> </CFturboDesign_RadialImpeller> </CFturboProject> </Updates> <BatchAction Name="Export" ExportFormat="General" Path="C:\Testing\Examples\Impeller\MyExport"/> <BatchAction Name="Save" OutputFile="C:\Testing\Examples\Impeller\Pump1_new.cft"/> </CFturboBatchProject> </CFturboFile> |
A log-file <batch file>.log is created in the directory of <batch file>:
19.04.2011 14:17:52 [INFO] CFturbo 9.0 - 18.04.2011 19.04.2011 14:17:52 [INFO] Batch mode started 19.04.2011 14:17:52 [INFO] Time: 19.04.2011 14:17:52 19.04.2011 14:17:52 [INFO] File: c:\Testing\Batch\Pump1.cft-batch 19.04.2011 14:17:52 [INFO] *** 19.04.2011 14:17:52 [INFO] Reading batch file: c:\Testing\Batch\Pump1.cft-batch 19.04.2011 14:17:52 [INFO] Open input file: C:\Testing\Examples\Impeller\Pump1.cft 19.04.2011 14:17:54 [INFO] Update design parameters 19.04.2011 14:17:54 [INFO] Running geometry update with data: 19.04.2011 14:17:54 [INFO] <CFturboProject Type="Object" SelIndex="0"> <CFturboDesign_RadialImpeller Type="Object" SelIndex="0" Desc="CFturbo component"> <MainDimensions Type="Object" SelIndex="0" Desc="Main dimensions"> <MainDimensionsElement Type="Object" Name="Version 1." Desc="Main dimensions list element"> <nBl Type="Integer" Desc="Number of blades">7</nBl> </MainDimensionsElement> </MainDimensions> </CFturboDesign_RadialImpeller> </CFturboProject> 19.04.2011 14:17:54 [INFO] Run design steps 19.04.2011 14:17:57 [INFO] Run trimming 19.04.2011 14:18:01 [INFO] Run fillet creation 19.04.2011 14:19:09 [INFO] No hints. 19.04.2011 14:19:09 [INFO] Save export file: C:\Testing\Examples\Impeller\Pump1.cft-geo 19.04.2011 14:19:10 [INFO] Save output file: C:\Testing\Examples\Impeller\Pump1_new.cft 19.04.2011 14:19:10 [INFO] *** 19.04.2011 14:19:10 [INFO] Batch mode terminated. (01:17:662 sec) |
Page url: http://www.cfturbo.com/fileadmin/content/manual/en/index.html?batch_mode.html