VSP File Types & VSP Meshing -...
Transcript of VSP File Types & VSP Meshing -...
Rob McDonald – Cal Poly
VSP Workshop August 23, 2012
VSP File Types & VSP Meshing
2
VSP Input Representations • Input
– Parametric geometry (vsp) – Background image (jpg) – Surface textures (tga, jpg) – Automation script (txt) – Airfoil definition (af) – Fuselage section definition (fxs) – Cabin definition (cab) – Wireframe as mesh (hrm) – Wireframe as surfaces (hrm) – Triangulated mesh (stl, NASCART) – Vorlax case file (cas)
• Coming soon – Design file (des, xdes, XDDM)
http://www.openvsp.org/wiki/doku.php?id=representations
3
VSP Output Representations • Output
– Parametric geometry (vsp) – Screen capture (jpg) – Automation script (txt) – Wetted area/volume report (txt, csv) – Drag buildup report (tsv) – Area ruling report (txt) – Mass properties report (txt) – Wireframe (hrm) – X3D 3D Web model (x3d) – Felisa (fel) – Untrimmed surfaces (3dm)
• Coming soon – Design file (des, xdes, XDDM)
– Trimmed surfaces (srf) – Unintersected triangulated components
(tri, possibly others) – Intersected triangulated components
(stl, NASCART, tri, msh, pov) – Isotropic triangulated surface mesh
(stl, poly, tri, obj, msh, NASCART) – Structural mesh
(stl, NASTRAN, Calculix) – Vorlax case file (cas) – Vorlax geometry & input (inp)
http://www.openvsp.org/wiki/doku.php?id=representations
4
Paths to Cart3D Quadrilateral
Wireframe
Cart3D intersect
CompGeom
Export… CART3d File (.tri)
Export… CART3d File (.tri)
Unintersected Triangle
Wireframe
Triangle Mesh
Intersected Triangle
Wireframe
CFD Mesh Output .tri
Bicubic Bezier
Surface
5
Paths to Cart3D Quadrilateral
Wireframe
Cart3D intersect
CompGeom
Export… CART3d File (.tri)
Export… CART3d File (.tri)
Unintersected Triangle
Wireframe
Triangle Mesh
Intersected Triangle
Wireframe
CFD Mesh Output .tri
Bicubic Bezier
Surface
6
Quadrilateral Wireframe
Unintersected Triangle
Wireframe
Triangle Mesh
Intersected Triangle
Wireframe
7
Recommended for Today
Pros / Cons of Paths
• Pros – Speed – Robustness – Derivatives with
design framework
• Cons – Robustness
• Coincident faces • Nacelles
– Extra step
Unintersected
• Pros – Speed – Robustness – Special cases
• Cons – Robustness
• Pros – Triangle Quality – Special cases
• Cons – Robustness
CompGeom CFD Mesh
8
Export Unintersected (before) 1
2
3
4 5
9
Export Unintersected (after)
10
Execute CompGeom (before) 1
2
3
11
Execute CompGeom (after)
1
12
Export CompGeom 1
2
3
4 5
13
Practice Session • Unintersected
• CompGeom – Save for Cart3D tutorial
• Resolution Effects (quads to triangles directly) – Num Pts – Num XSecs
14
CFD Mesh Generator
15
CFD Mesh • Surface mesh generator
– Isotropic triangles (no stretching) – Bicubic Bezier surfaces – Bezier intersection curves – Sourcing control – Curvature control – Optional wakes – Optional half-models
• Preferred for most CFD tools – CBAero – TetGen – AFLR3 – VLE
16
Local Radius of Curvature
Greatest Principal Normal Curvature r = 1k
r
17
Curvature Meshing Criteria
l =N > 2; r !2 !sin !
N( )N " 2; r ! 4 N
#
$%
&%
l = r > g; 2 2 ! r ! g" g2
r # g; 2 ! g
$%&
'&
g
l
l
Num CircleSegments = 8
Max Gap Num Circle Segments
18
Growth Ratio Limiter
0 2 4 6 8 10
1
1.2
1.4
1.6
1.8
2
X
Gro
wth
Rat
io
Limits length of next edge to ratio of current edge.
19
Source Types Point Line Box
20
Sourcing
Attached to components (u, w) Size in model units (length) Sphere of influence (radius)
21
Mesh Criteria Precedence
Max Gap Num Circle Segments
Min Edge Len
Max Edge Len
Sources
Growth Ratio
Smallest Edge Across Criteria
Subject to Constraints
Above & Below
22
Turning Mesh Criteria ‘OFF’
Criteria Direction Value Scaled? Max Edge Len large 100.0 (scaled) Growth Ratio large 10.0 Sources none Max Gap large 10.0 (scaled) Num Circle Segments small 0.00001 Min Edge Len small 0.000001 (scaled)
Sometimes it is useful to turn a mesh criteria ‘OFF’.
Max = Min will turn ‘OFF’ Max Gap &
Num Circle Segments Max Gap Num Circle
Segments
Min Edge Len
Max Edge Len
Sources
Growth Ratio
23
Meshing Strategy
1. Set Max based on model dimensions • Set Min = Max (turning off MG and NCS) • No Sources • Adjust Max & Min until satisfied (uniform coarsest)
2. Set Min to smaller value • Say Min = Max/20
3. Choose MG or NCS as preferred curvature parameter (CP) • Set other curvature parameter (OCP) ‘OFF’ • Adjust CP until satisfied • Adjust Min as required (are smallest edges small enough?)
4. Adjust OCP (optional) 5. Add mesh sources as required
• Resolve flow features
24
‘Top’ Model
http://hangar.openvsp.org/vspfiles/106
Constant curvature (constant radius)
Increasing curvature (decreasing radius)
Extreme curvature (vanishing radius)
25
CFD Mesh GUI
26
Global Global Source Adjustment
Global & Curvature Meshing Criteria
Half Mesh Switch
TetGen Far Field
Mesh Output
‘Go’ Button
27
Display Source Display Switch
Mesh Display Switch
Mesh Output
‘Go’ Button
28
Output File Output Switches
Mesh Output
‘Go’ Button
File Paths
File Browser Button
29
Sources Component Chooser
Add Default Button
Source Type Chooser
Add/Delete Buttons
Mesh Output
‘Go’ Button
Component Source List
Individual Source Editor
30
Wakes Wake Length
Wake Angle
Component Chooser
Wake Switch
Mesh Output
‘Go’ Button
31
Practice Session • CFD Mesh
– ‘Top’ model – Experiment with meshing parameters – Turn all criteria off – ‘play’ with one at a time – Follow meshing strategy
• Resolution Effects (quads to bicubic Bezier patches) – Num Pts – Num XSecs – Computational cost (Build Target Map)
• CFD Mesh – ‘Your’ model – Follow meshing strategy
32
Command Line Unintersected:
vsp –batch airplane.vsp –tri CompGeom:
vsp –batch airplane.vsp –compgeom –tri CFD Mesh:
vsp –batch airplane.vsp –cfdmesh 1.0 (1.0 is refinement factor)
Each command will output corresponding ‘airplane.tri’.