Multiple Input Files
To create multiple input files, the parameters of interest are represented by Templex variables.
By creating a simple iterative loop surrounding the new input deck, Templex writes out the necessary decks while maintaining all format requirements.
{GZ143 = 458.0000}
{dz = 3}
{output_file = "bulkdata"}
{str = { "_1.out", "_2.out", "_3.out"}}
{for(i=0; i<=2; i++)}
{open output_file+str[i]}
BEGIN BULK
GRID 143 848.000 200.000 {GZ143+i*dz,%7.3f}
GRID 145 849.508 225.000 458.000
GRID 165 848.000 200.000 430.750
GRID 169 849.508 225.000 430.750
CQUAD4 125 1 143 165 169 145
{close}
{endloop}
This
template produces three separate files containing Nastran bulk data decks with z-coordinates for Grid# 143 of 458.000, 461.000, and
464.000.