VSP File Types & VSP Meshing -...

32
Rob McDonald – Cal Poly VSP Workshop August 23, 2012 VSP File Types & VSP Meshing

Transcript of VSP File Types & VSP Meshing -...

Page 1: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

Rob McDonald – Cal Poly

VSP Workshop August 23, 2012

VSP File Types & VSP Meshing

Page 2: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

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

Page 3: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

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

Page 4: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

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

Page 5: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

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

Page 6: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

6

Quadrilateral Wireframe

Unintersected Triangle

Wireframe

Triangle Mesh

Intersected Triangle

Wireframe

Page 7: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

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

Page 8: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

8

Export Unintersected (before) 1

2

3

4 5

Page 9: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

9

Export Unintersected (after)

Page 10: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

10

Execute CompGeom (before) 1

2

3

Page 11: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

11

Execute CompGeom (after)

1

Page 12: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

12

Export CompGeom 1

2

3

4 5

Page 13: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

13

Practice Session •  Unintersected

•  CompGeom –  Save for Cart3D tutorial

•  Resolution Effects (quads to triangles directly) –  Num Pts –  Num XSecs

Page 14: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

14

CFD Mesh Generator

Page 15: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

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

Page 16: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

16

Local Radius of Curvature

Greatest Principal Normal Curvature r = 1k

r

Page 17: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

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

Page 18: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

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.

Page 19: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

19

Source Types Point Line Box

Page 20: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

20

Sourcing

Attached to components (u, w) Size in model units (length) Sphere of influence (radius)

Page 21: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

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

Page 22: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

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

Page 23: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

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

Page 24: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

24

‘Top’ Model

http://hangar.openvsp.org/vspfiles/106

Constant curvature (constant radius)

Increasing curvature (decreasing radius)

Extreme curvature (vanishing radius)

Page 25: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

25

CFD Mesh GUI

Page 26: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

26

Global Global Source Adjustment

Global & Curvature Meshing Criteria

Half Mesh Switch

TetGen Far Field

Mesh Output

‘Go’ Button

Page 27: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

27

Display Source Display Switch

Mesh Display Switch

Mesh Output

‘Go’ Button

Page 28: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

28

Output File Output Switches

Mesh Output

‘Go’ Button

File Paths

File Browser Button

Page 29: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

29

Sources Component Chooser

Add Default Button

Source Type Chooser

Add/Delete Buttons

Mesh Output

‘Go’ Button

Component Source List

Individual Source Editor

Page 30: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

30

Wakes Wake Length

Wake Angle

Component Chooser

Wake Switch

Mesh Output

‘Go’ Button

Page 31: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

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

Page 32: VSP File Types & VSP Meshing - OpenVSPopenvsp.org/wiki/lib/exe/fetch.php?media=vsp_file_types_meshing.pdf · VSP File Types & VSP Meshing. 2 VSP Input Representations • Input –

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’.