General
For a shape optimization with Tosca Structure
in combination with fe-safe, you must be able to run your job as a batch
job. This is done by setting up an fe-safe analysis interactively and
then exporting the necessary files or copying the files from the fesafe
project directory. For in-depth information, please see the fe-safe documentation
(fe-safe User Guide) about “Saving analysis configuration settings”
and “Running fe-safe from the command line”.
The following assumes that the user understands the different files and command-line arguments
for fe-safe.
Exporting Setup Files from the fe-safe GUI
In a typical setup, you need to export a project archive .7z
file (fe-safe USER GUIDE, chapter 5.12)
as well as a .macro
file
(fe-safe USER GUIDE, chapter 23)
which executes this project and writes the damage values to a _600.onf
file.
Example of a minimal .macro file
# Change to a new project in this macro directory
SwitchToProject <%macro_dir>/work.fesafe
# Import the fatigue scenario that the user-defined through the fe-safe GUI
# This archive file does NOT contain an ODB file
Import <%macro_dir>/holeplate_fesafe.project.7z
# Run FEA Fatigue Analysis
fe-safe b=run
# Export the fatigue results in an ONF-output file for Tosca
fe-safe o=<%macro_dir>/holeplate_fesafe_600.onf
Example of a .macro file with pre-scan
# Change to a new project in this macro directory
SwitchToProject <%macro_dir>/holeplate_fesafe
# Import the fatigue scenario that the user-defined through the fe-safe GUI
# This archive file does NOT contain an ODB file
Import <%macro_dir>/holeplate_fesafe.project.7z
## Additional commands, for example, for pre-scan, group manipulation, etc.
# PRE-SCAN PRE-SCAN COMMANDS
pre-scan files "<%macro_dir>/holeplate_dam.odb"
# PRE-SCAN POSITION COMMAND
pre-scan position nodal
pre-scan deselect all
# PRE-SCAN OPTIONS
pre-scan select groups
pre-scan select detect-surface
# PRE-SCAN SELECT COMMANDS
pre-scan select source "<%macro_dir>/holeplate_dam.odb" step 1 inc 1 stress
pre-scan select source "<%macro_dir>/holeplate_dam.odb" step 2 inc 1 stress
# PRE-SCAN OPEN COMMAND
pre-scan open selected
groups list deselect all
# Run FEA Fatigue Analysis
fe-safe b=run
# Export the fatigue results in an ONF-output file for Tosca
fe-safe o=<%macro_dir>/holeplate_fesafe_600.onf
# Export the fatigue results in an fer file
fe-safe o=<%macro_dir>/holeplate_fesafe.fer
Generating Results
fe-safe
writes life results per default. The user specifies the fe-safe
output format in combination with Tosca Structure.
Actually, the output format is set to .csv
format, which is converted automatically
to _600.onf
format by Tosca Structure.
As Tosca Structure
expects a "damage like" format, the life results n are automatically
inverted by life2vtm
to 1/n by the added argument -r
, for example,
driver.LifeSolver.Inverse = 1
.
Note:
the naming convention for the _600.onf
file name must
be followed for the Tosca Structure - fe-safe interface to work. If the fe-safe macro file is called
<some_base_name>.macro
, the .onf
-file
produced by the durability run must be named
<some_base_name>_600.onf
.
Running fe-safe on Command Line
Test that fe-safe runs correctly on the command line by executing
the fe-safe job. Change to the directory where your project and macro files (.7z
and .macro
) are saved to execute fe-safe_cl.
Example:
fe-safe_cl.exe macro=holeplate_fesafe.macro
Check that the _600.onf
file is generated and has correct values (life values).
Alternative Configurations of fe-safe
For backward compatibility, Tosca Structure
still support fe-safeconfigurations using .stlx
files.
Tosca Structure
runs in the working directory, therefore are all absolute paths in the
.stlx
file substituted with a relative path to ensure that the current
FE-input file and results are used in the durability analysis. For example, the
following files are assumed to be in the current directory:
- source file(s) (
odb
or fil
)
ldf
file and files referenced
kt
file
msc
file
Legacy .kwd files might also be used, but in that case the user is responsible
for copying the right files into the working directory and that command
line is correct. The copying of files can be done using COPY_FILE
in the FEM_INPUT
command.