The cape.pycart
moduleΒΆ
The cape.pycart
module contains the top-level interface for
Cart3D setup and execution.
import cape.pycart
For example the following will read in a global settings instance assuming that the present working directory contains the correct files. (If not, various defaults will be used, but it is unlikely that the resulting setup will be what you intended.)
import cape.pycart cntl = cape.pycart.Cntl()
A simpler example is to simply read a .tri
file, rotate it about the
x-axis by 20 degrees, and write it to a new file.
# Import the module. import cape.pycart # Read the .tri file. tri = pyCart.Tri('bJet.i.tri') # Rotate it. tri.Rotate([0.,0.,0.], [1.,0.,0.], 20) # Write it to a new file. tri.Write('bJet_rotated.i.tri')
Most of the pyCart submodules essentially contain a one or more class
definitions, and some of these classes are accessible directly from
cape.pycart
.
The module also contains the cape.pycart.bin
module, which
contains functions that run the main Cart3D binaries: autoInputs
,
cubes
, mgPrep
, and flowCart
.
Modules included within this one are outlined below.
- Cart3D and Cape files
cape.pycart.runmatrix
- Supporting modules
cape.pycart.cntl
: Cart3D control modulecape.pycart.options
: Cart3D and pyCart Settingscape.pycart.case
: Case Control Modulecape.pycart.tri
: Cart3D Triangulation Modulecape.pycart.bin
: Cart3D executable interface modulecape.pycart.cmd
: Create commands for Cart3D executablescape.pycart.inputCntl
: Cart3Dinput.cntl
interfacecape.pycart.aeroCsh
: Cart3Daero.csh
interfacecape.pycart.preSpecCntl
: Cart3D preSpec.c3d.cntl Interfacecape.pycart.dataBook
: pyCart data book modulecape.pycart.lineLoad
: Sectional loads modulecape.pycart.pointSensor
: Cart3D point sensors modulecape.pycart.report
: Automated report interfacecape.pycart.manage
: Manage pyCart case folderscape.pycart.util
: Utilities for pyCart