Coder Social home page Coder Social logo

gmsh-airfoil-2d's Introduction

Pytest PyPi version License Black code style

GMSH-Airfoil-2D

Python tool to genreate 2D unstructured mesh around an airfoil with GMSH in one command line.

Installation

You can install this package from PyPi:

pip install gmshairfoil2d

Or you can clone and install this repository with the following commands:

git clone https://github.com/cfsengineering/GMSH-Airfoil-2D.git
cd GMSH-Airfoil-2D
pip install -e .

Usage

gmshairfoil2d -h                                    

optional arguments:
  -h, --help                  show this help message and exit
  --list                      Display all airfoil available in the database :
                              https://m-selig.ae.illinois.edu/ads/coord_database.html
  --naca [4DIGITS]            NACA airfoil 4 digit (default 0012)
  --airfoil [NAME]            Name of an airfoil profile in the database (database available with
                              the --list argument)
  --aoa [AOA]                 Angle of attack [deg] (default: 0 [deg])
  --farfield [RADIUS]         Create a circular farfield mesh of given radius [m] (default 10m)
  --box [LENGTHxWIDTH]        Create a box mesh of dimensions [length]x[height] [m]
  --airfoil_mesh_size [SIZE]  Mesh size of the airfoil countour [m] (default 0.01m)
  --ext_mesh_size [SIZE]      Mesh size of the external domain [m] (default 0.2m)
  --format [FORMAT]           format of the mesh file, e.g: msh, vtk, wrl, stl, mesh, cgns, su2,
                              dat (default su2)
  --output [PATH]             output path for the mesh file (default : current dir)
  --ui                        Open GMSH user interface to see the mesh

Examples of use

To check all airfoil available in the database:

gmshairfoil2d --list

For all the following examples, the defauld chord lenght is 1 meter.

To create a circular farfield mesh around a NACA0012 of 10m of radius and see the result with GMSH user interface:

gmshairfoil2d --naca 0012 --farfield 10 --ui

GMSH user interface with the 2D mesh

To create a circular farfield mesh around a Drela DAE11 airfoil (the name in the database is "dae11") of 20m or radius with a mesh size of 0.005m on the airfoil:

gmshairfoil2d --airfoil dae11 --farfield 20 --airfoil_mesh_size 0.005

To create mesh around a Eppler E220 airfoil (the name in the database is "e211") with an angle of attack of 8 degree in a box of 12x4m (lenght x hight) and save it as a vtk mesh and see the result with GMSH user interface:

gmshairfoil2d --airfoil e211 --aoa 8 --box 12x4 --format vtk --ui

GMSH user interface with the 2D mesh, rectangular box

gmsh-airfoil-2d's People

Contributors

aidanjungo avatar govonit avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

gmsh-airfoil-2d's Issues

Strange generated mesh

Hello,

I tried to use GMSH-Airfoil-2D with the following command (the airfoil is symmetric) :

gmshairfoil2d --airfoil n64015a --format mesh

Here is what observe near the trailing-edge:

image

I do not find this result satisfactory. How can it be improved?

Best,

Lucas

a question about creating a surface in Gmesh

Hello everyone,

I am trying to create a 2D mesh in Gmesh. The geometry has 2 different plans (x,y, and x,z) at the same mesh. I draw it via AutoCAD and imported it in Gmesh using it as a step file.
Now, I am trying to define a surface but in vain, it selects the boundaries but does not keep it as a surface (there is no e option, only q) .
Would anyone know how to do this?
surface issue

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.