|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectiterator.AbstractIterator
util.CommandLineRunner
util.Cart3DRunner
public class Cart3DRunner
Runs CART3D with or without using a job-queueing system.
First, it needs access to a directory in which CART3D-related files are made
and modified. By default, it looks for one called cart3dScratch.
Provide a symlink of this name in $JAMPOTHOME. Next, it needs a
CART3D command that will do the following: 1. Setup and run CART3D using the
geometry described in the PLOT3D files cart3dScratch/model.plot3d and
cart3dScratch/model.plot3d.component.list from start to finish, and
2. Return a job id JOB_ID for this process. By default, tries the
command cart3d. Create a script (bash, or PBS, or what have you) and
make sure a symlink to this exists on the PATH.
Finally, it needs a command to check for completion. By default, tries
qstat $JOB_ID. This command should return a null output when done,
but some non-empty output while still running. Note that this is default
behavior for the PBS command qstat.
| Field Summary |
|---|
| Fields inherited from class util.CommandLineRunner |
|---|
commandLine, DEFAULT_POLL_INTERVAL, DEFAULT_RUN_COMMAND, DEFAULT_SCRATCH_DIR, DEFAULT_STATUS_COMMAND, DEFAULT_TIMEOUT_INTERVAL, statArgument, timeElapsed |
| Fields inherited from class iterator.AbstractIterator |
|---|
diagnosticString, iter |
| Constructor Summary | |
|---|---|
Cart3DRunner()
Default constructor. |
|
Cart3DRunner(boolean inline)
|
|
| Method Summary | |
|---|---|
boolean |
isTerminated()
Returns true after a timeout. |
static void |
main(java.lang.String[] args)
Test run of whatever PASS-style XML file is in the scratch directory. |
double |
readDrag(java.lang.String fileName)
Reads the drag value from the CLiC output file. |
double[] |
readForces(java.lang.String fileName)
Reads lift and drag forces from the CLiC output file. |
void |
setClic(double alfa,
double sref,
double lref)
Modifies the default CLiC input control file clic.cntl. |
void |
setClic(double alfa,
double sref,
double lref,
java.lang.String clicCntl)
Modifies the given clic control file to set angle of attack, reference area and reference length for CliC. |
void |
setInput(double alfa,
double M)
Modifies the default CART3D input control file input.cntl. |
void |
setInput(double alfa,
double M,
java.lang.String inputCntl)
Modifies a given input control file to set angle of attack and Mach number for CART3D. |
void |
singleIteration()
Sleeps for a designated sleep interval. |
| Methods inherited from class util.CommandLineRunner |
|---|
getArgList, getPollInterval, getRunCommand, getScratchDir, getStatusCommand, getTimeoutInterval, init, isInline, iterate, run, run, run, setArgList, setInline, setPollInterval, setRunCommand, setScratchDir, setStatusCommand, setTimeoutInterval, updateDiagnostics |
| Methods inherited from class iterator.AbstractIterator |
|---|
isVerbose, printDiagnostics, setVerbose |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Cart3DRunner()
public Cart3DRunner(boolean inline)
| Method Detail |
|---|
public static void main(java.lang.String[] args)
args - None used.public boolean isTerminated()
CommandLineRunnertrue after a timeout.
isTerminated in interface IterableisTerminated in class CommandLineRunnertrue when done.Iterable.isTerminated()public void singleIteration()
CommandLineRunner
singleIteration in interface IterablesingleIteration in class CommandLineRunnerIterable.singleIteration()public double readDrag(java.lang.String fileName)
fileName - name of the output file.
public double[] readForces(java.lang.String fileName)
fileName - name of the output file.
public void setInput(double alfa,
double M,
java.lang.String inputCntl)
alfa - angle of attack in degrees.M - Mach number.
java.lang.Exception
public void setClic(double alfa,
double sref,
double lref,
java.lang.String clicCntl)
alfa - angle of attack in degrees.sref - reference area in consistent units.lref - reference length in consistent units.clicCntl - name of the clic control file
public void setClic(double alfa,
double sref,
double lref)
clic.cntl.
alfa - angle of attack in degrees.sref - reference area.lref - reference length.
public void setInput(double alfa,
double M)
input.cntl.
alfa - angle of attack in degrees.M - mach number.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||