home news images pubs c3dTeam
whatIsCart3D?
surfaceModeling
meshGen?
flowSolvers?
postprocess?
mailList?
betaTest?
licensing?

   Mesh Generation

  What is "cubes"?
  What is new in cubes for v1.3?
  What input files does cubes require?
  What is "autoInputs"?
  Usage - cubes
  Tell me more about prespecified adaptation regions.
  File Format of Meshes produced by Cubes
  Further Documentation
What is "cubes"?
 
Cubes  is a mesh generation program which produces topologically unstructured, adaptively refined, Cartesian  meshes around any geometry or configuration that may be described by a collection of simplicial polyhedra (closed surface triangulations - the output of intersect works fine) The source is written in Ansi C and makes extensive use of bitwise operators to minimize memory requirements and maximize speed. 

Features:

  • Gross memory usage is typically 13-15 words/cell 
  • Speed is about 1,000,000 cells/min (MIPS R10000, 195Mhz) 
  • Geometry based adaptive cell division (directional or isotropic). 
  • An aspect ratio limit may be placed on directionally divided cells. 
  • Option for users to limit total # cells & max allowable memory 
  • Multiple region (split-cells) handled automatically 
  • The ability to prespecify mesh adaptation in certain regions 
HSCT configuration 5M cells
5M cell mesh around a HSCT configuration
HSCT configuration 5M cells
side view - zoom box on nacelle region
HSCT configuration 5M cells
closeup near nacelle.
(top)
What is new in cubes for v1.3?
Experienced users of cubes will find a a couple of handy new features included with version 1.3. All new command line options are highighed in the usage statment below.
    Automatic reordering:  "% cubes -reorder" will reorder the mesh before it ever hits your disk. This is completely equivelent to running the standalone reorder program, but you skip ever writing the unreordered mesh, and go straight to Mesh.R.c3d. Since CPU speeds are imrpoving faster than disk speed, writing the mesh has been taking an increasing amount (relative) time in the past few years, Writing out  the mesh at the end of cubes just to read it back in in the first step of reorder seemed like a complete waste of time,  so now you can do it direct. Doing the reorder on-the-fly within cubes does mean that the whole mesh needs to reside in memory at the same time as all the other data structures that cubes needs, so this option does increase the memory requirements of cubes by a bit, but this consumption is not severe, and nobody's complained yet, since cubes has a very tiny memory footprint to start with.
    Sharp Feature Refinement: You can additional refinement sweeps that just target sharp features in your geometry (sharp edges, ridges, etc). This argument takes an integer which says how many additional refinement sweeps to do. Invoke it with "%cubes -sf %d" where %d is an integer.
(top)

What input files does cubes require?
    Cubes requires 2 files to get going:
    1. An input file controlling the mesh you want to make (only 7 entries! ). By default this file is called "input.c3d" it is fully described on the example input/outpuf file page
    2. Input surface triangulations are read in as a Cart3D "wetted surface triangulation" which may contain any number of components.  Entry #1 in the cubes input file takes the name of the triangulation you're gonna mesh. 


    Optionally, you can include a "prespecified adaptation region" file, usually called preSpec.c3d.cntl. Entries in this file can be used to direct cubes to refine more in certain regions of the domain click here to learn more about prespecified adaptation regions, or here to see a sample.
    (top)

  What is "autoInputs"?

"autoInputs" is a new utility (consider it beta test :-) that automatically generates the input.c3d and preSpec
files
that cubes needs to have in order to get going. Its intended to help novice users produce good meshes right out-of-the-box. The utility is new in v1.3, and will continually be improved. Basically you hand autoInputs your geometry and a rough idea of how big you want the mesh to be and it will produce an input.c3d and preSpec.c3d.cntl file that you can use to mesh. More advanced users will probably go in and tweak the input.c3d file that autoInputs produces (the Cartesian bounding box can be a bit ratty), but even the developers find it very handy for getting going in short order. The preSpec.c3d.cntl files that autoInputs produces are quite detailed, and include one preSpec box for the entire configuration, as well as smaller boxes for each component in the configuration. Like the rest of the utility programs in Cart3D, the executable for autoInputs is located in $CART3D/bin/$CART3D_ARCH/. To get a usage statement, type "% autoInputs -" (the trailing "-" will get you the usage statment, as with all executables in the package).

(top)

Usage - Cubes
 
% cubes -
   Usage: cubes [ argument list ]
 Options:
      -i %s      Input  file name, default:<input.c3d>
      -o %s      Output file name, default:< mesh.c3d>
      -v         Verbose mode ON
      -
quiet     Don't make excessive noise
      -mem       Report memory usage (auto on with -v)
      -T         Create tecplot file 'c3d-mesh.plt'-(NOT YET)
      -I         Restrict cells to isotropic division only
      -ascii     Surface geometry file is ascii formatted
      -P         Retain parent cell information
      -no_file   Suppress output file
      -Dunset    dump tecplot format file <unset.dat>
      -Dcut      dump tecplot format file <cutcells.dat>
      -Dflow     dump tecplot format file <flowcells.dat>
      -Dsolid    dump tecplot format file <solidcells.dat>
      -Dsplit    dump tecplot format file <splitcells.dat>
      -Daniso    dump tecplot format file <anisocells.dat>
      -Xcut %d   Num of X=const cut planes <cutPlanes.dat>
      -Ycut %d   Num of Y=const cut planes <cutPlanes.dat>
      -Zcut %d   Num of Z=const cut planes <cutPlanes.dat>
      -maxR %d   Max Num of refinements (override)
      -b %d      Number of layers of buffer cells
      -h         Output history of #Cells with refinement
      -memLim %f Specify Absolute Memory Limit (in Mbytes)
      -verify    Verify cut cells close (auto on in DEBOG)
      -N %d      Maximum number of Cartesian cells
      -try_exact Use Newton solve on REAL cell # fn
      -a %f      Angle threshold for geom refinement (def=20°) 
      -d %f      angle (degrees) for directional refinement
      -weight    Area weight triangles in divide criteria
      -TPC %d    adapt based on # of triangles-per-cutCell
      -sf %d     Number of additional levels at sharp edges
      -Internal  Mesh the *interior* of the geometry
      -reorder   Reorder output mesh with peano Hilbert SFC
      -pre %s    Prespecified adapt region filename (default NONE)
      -no_est    Dont estimate mem. requirements (slower)
      -STARS     Record intermediate refinemnt history in STARS format
(top)
File Format of Meshes produced by Cubes
The file format used by Cart3D to store meshes relies heavilly upon the fact that the meshes are Cartesian to store meshes in a highly compressed format. This produces quite small mesh files, but the format takes a little explaination. For users who wish to use Cart3D meshes in other applications, or wish to write their own visualization software for these meshes, this format is described in the *pdf document fileformat.pdf (50kb)
(top)
Further Documentation
Many of the agorithms in cubes are described in:
AIAA Paper 97-0196: Robust and Efficient Cartesian Mesh Generation for Component-Based Geometry  35th AIAA Aerospace Sciences Meeting, Reno NV Jan, 1997.  (1.7Mb, acrobat format)
(top)

last update June 2004, M. Aftosmis