Modulefpreviousupnextcontentsindex[BIG][Normal][small]
Next: 1.5.7 Limitations and bugs Up: The EMC˛ preprocessor Prev: The EDIT_MESH application Index Contents


1.5.6 Example

The unit square with a hole

In this section, we show how to mesh a unit square with a hole. First of all, we run emc2, enter the number of the F3D graphic device and answer the few supplementary questions that are posed by the system (this depends on the particular F3D implementation).

Construction of the unit square with a hole

  1. Click the POINT item of the construction menu
  2. Click the XY POINT item of the selection menu
  3. Enter 0=0=1=0=0=1=1=1=.5=.5= on the keyboard 5 points are displayed in the middle of the screen since the scale is equal to 1
  4. Click the SEE_ALL item to see the five points clearly. The 5th point will be the center of the hole.
  5. Click the SEGMENT item of the construction menu (on top of the screen. The bottom SEGMENT item belongs to the selection menu)
  6. Click the POINT item of the selection menu (bottom)
  7. Click in the graphic window on the extreme points of the 4 segments to be created. After each couple of clicks a segment is created. Therefore we must click 8 times, for example close to the following points in this order (0,0), (1,0), (1,0), (1,1), (1,1), (0,1), (0,1), (0,0)
  8. Click the CIRCLE item of the construction menu (top) then click the CENTER item
  9. Click in the graphic window close to the point (.5,.5) (we are still in point selection mode)
  10. Click the RADIUS item
  11. Enter 1/4= on the keyboard: a circle of center (.5,.5) and radius 1/4 is displayed. Warning: the circle as well as the straight line is only a construction aid. It must be transformed into an arc
  12. Click the ARC item of the menu to construct arcs
  13. Click the IDEM item
  14. Click the CIRCLE item of the selection menu to select the circle
  15. Click in the graphic window. Since there is only one circle, it is selected. The circle being now useless, we destruct it.
  16. Click the DESTRUCT item of the general menu (left)
  17. Click in the graphic window. The circle and the arc disappear since they are superimposed . Warning: we are still in destruction mode.
  18. Click the REFRESH item to display the arc

The construction of the geometry is done (figure 1.33).

We can switch to the PREP_MESH application.

 
Figure 1.33: The geometry of the square domain with a hole 

Definition of the boundary discretization

  1. Click the PREP_MESH item of the general menu
  2. Click the NB_INTERVAL item of the application menu (top)
  3. Enter 4= on the keyboard
  4. ALL of the application menu (top) ???? All the elements are divided into 4 intervals
  5. Enter 12= on the keyboard
  6. Then click in the graphic window close to the arc. It is divided into 12 intervals. There is no need to change selection mode.
  7. Click the SAVE item of the general menu
  8. Enter the file name square_with_hole(CR) . We have created the file square_with_hole.emc2_bd

 
Figure 1.34: Discretization of the lines of the square domain with a hole 

The file square_with_hole.emc2_bd :

'-- TYPE N BD(1) BD(2) BD(3) BD(4) BD(5) NBNODE RATIO NUREFG NUREFD NUREF1G NUREF1D NUREF2G NUREF2D FIS'
'DROITE'        1 -1.000000 0.0000000 1.000000 0.0000000 0.0000000 0.0000000 0 0.0000000 0 0 0 0 0 0 F
'DROITE'        2 -1.000000 1.000000 0.0000000 0.0000000 0.0000000 0.0000000 0 0.0000000 0 0 0 0 0 0 F
'POINT'       3 0.0000000 0.0000000 0.0000000 0.0000000 0.0000000 0.0000000 0 1.000000 0 0 0 0 0 0 F
'POINT'       4 0.0000000 1.000000 0.0000000 0.0000000 0.0000000 0.0000000 0 1.000000 0 0 0 0 0 0 F
'POINT'       5 0.0000000 0.0000000 1.000000 0.0000000 0.0000000 0.0000000 0 1.000000 0 0 0 0 0 0 F
'POINT'       6 0.0000000 1.000000 1.000000 0.0000000 0.0000000 0.0000000 0 1.000000 0 0 0 0 0 0 F
'POINT'       7 0.0000000 0.5000000 0.5000000 0.0000000 0.0000000 0.0000000 0 1.000000 0 0 0 0 0 0 F
'SEGMENT'     8 -3.000000 0.0000000 0.0000000 1.000000 0.0000000 0.0000000 5 1.000000 0 0 0 0 0 0 F
'SEGMENT'     9 -3.000000 1.000000 0.0000000 1.000000 1.000000 0.0000000 5 1.000000 0 0 0 0 0 0 F
'SEGMENT'     10 -3.000000 1.000000 1.000000 0.0000000 1.000000 0.0000000 5 1.000000 0 0 0 0 0 0 F
'SEGMENT'     11 -3.000000 0.0000000 1.000000 0.0000000 0.0000000 0.0000000 5 1.000000 0 0 0 0 0 0 F
'CERCLE'      12 0.2500000 0.5000000 0.5000000 0.0000000 0.0000000 0.0000000 2 1.000000 0 0 0 0 0 0 F
'ARC'         13 -2.000000 0.5000000 0.5000000 0.7500000 0.5000000 6.283185 13 1.000000 0 0 0 0 0 0 F
'MASQUE' 0 -0.4632312 1.465731 -5.0000010E-02 1.052500 0.0000000 0.0000000 0 0. 0 0 0  0 0 0  F
'RADIUS' 0 0.2500000 0. 0. 0. 0. 0. 0 0. 0 0 0  0 0 0  F
'ANGLE' 0 0.0000000 0. 0. 0. 0. 0. 0 0. 0 0 0  0 0 0  F
'DISTANCE' 0 1.000000 0. 0. 0. 0. 0. 0 0. 0 0 0  0 0 0  F
'RAISON' 0 1.000000 0. 0. 0. 0. 0. 0 0. 0 0 0  0 0 0  F
'NOMBRE' 0 0.0000000 0. 0. 0. 0. 0. 0 0. 0 0 0  0 0 0  F
'ECHELLE' 0 14.32432 0. 0. 0. 0. 0. 0 0. 0 0 0  0 0 0  F
'NUREF' 0 0.0000000 0. 0. 0. 0. 0. 0 0. 0 0 0  0 0 0  F
'NB_INTERVALS' 0 12.00000 0. 0. 0. 0. 0. 0 0. 0 0 0  0 0 0  F
'NUDSD' 0 1.000000 0. 0. 0. 0. 0. 0 0. 0 0 0  0 0 0  F

We have completed the preparation of the mesh (figure 1.34)

Generating and saving the mesh

  1. Click the EDIT_MESH item of the general menu to activate the
    [4] EDIT_MESH application. Then type 4 (CR) to select the default options of the mesh generator. The mesh is displayed, it includes the hole. We are going to suppress the mesh in the hole.
  2. Click the S_DOM item of the selection menu.
  3. Click the SUPPRESS item of the edit_mesh menu (top).
  4. Click in the meshed circle. The mesh of the hole disappears.
  5. Click the SAVE item then enter the type of format, for example
    [4] am_fmt(CR) , then the file name square_with_hole(CR) . A file titled square_with_hole.am_fmt is generated.
  6. Click the EXIT item to quit Emc

 
Figure 1.35: The final mesh in the square domain with a hole 

The file square_with_hole.am_fmt:

 44 60  -- nbs,nbt
      1      2     29        25     24     29
     24     31     29         3     43     30
     15     16     31        22     34     23
     26     25     30        23     34     31
     32     27     43        28     27     32
     22     33     34        21     40     38
      4     32     43        34     15     31
     33     14     34        21     33     22
      5      6     39        20     42     40
     28     32     39        41     42     19
      7      8     36        18     36     37
     28     39     35        34     14     15
     12     13     38         6     35     39
     28     35     17        43     27     26
     38     13     14        23     31     24
      7     36     17        31     16     29
     11     12     40         3     30      2
     37      8     44        30     25     29
     41     10     42        30     29      2
     44     10     41        29     16      1
     35      6      7        17     35      7
     36      8     37        17     36     18
     41     37     44        18     37     19
     38     14     33        21     38     33
     39     32      4         5     39      4
     40     12     38        20     40     21
     42     10     11        37     41     19
     42     11     40        19     42     20
     43     26     30         4     43      3
     44      8      9        10     44      9
   0.000000E+00   0.000000E+00      2.500000E-01   0.000000E+00
   5.000000E-01   0.000000E+00      7.500000E-01   0.000000E+00
   1.000000E+00   0.000000E+00      1.000000E+00   2.500000E-01
   1.000000E+00   5.000000E-01      1.000000E+00   7.500000E-01
   1.000000E+00   1.000000E+00      7.500000E-01   1.000000E+00
   5.000000E-01   1.000000E+00      2.500000E-01   1.000000E+00
   0.000000E+00   1.000000E+00      0.000000E+00   7.500000E-01
   0.000000E+00   5.000000E-01      0.000000E+00   2.500000E-01
   7.500000E-01   5.000000E-01      7.165064E-01   6.250000E-01
   6.250000E-01   7.165064E-01      5.000000E-01   7.500000E-01
   3.750000E-01   7.165064E-01      2.834937E-01   6.250000E-01
   2.500000E-01   5.000001E-01      2.834936E-01   3.750001E-01
   3.749999E-01   2.834937E-01      4.999999E-01   2.500000E-01
   6.249999E-01   2.834936E-01      7.165062E-01   3.749999E-01
   2.077567E-01   2.075703E-01      4.017089E-01   1.482612E-01
   1.483122E-01   4.021604E-01      7.024530E-01   2.009149E-01
   2.021900E-01   7.009841E-01      1.471843E-01   5.790281E-01
   8.609530E-01   3.646002E-01      8.519265E-01   6.222693E-01
   7.943417E-01   7.355210E-01      2.050139E-01   8.383228E-01
   8.379703E-01   1.980158E-01      4.015485E-01   8.609668E-01
   7.210978E-01   8.353896E-01      5.831956E-01   8.603261E-01
   5.796704E-01   1.470356E-01      8.526899E-01   8.640727E-01
       0       0       0       0       0       0       0       0       0       0
       0       0       0       0       0       0       0       0       0       0
       0       0       0       0       0       0       0       0       0       0
       0       0       0       0       0       0       0       0       0       0
       0       0       0       0       0       0       0       0       0       0
       0       0       0       0       0       0       0       0       0       0
       0       0       0       0       0       0       0       0       0       0
       0       0       0       0       0       0       0       0       0       0
       0       0       0       0       0       0       0       0       0       0
       0       0       0       0       0       0       0       0       0       0
       0       0       0       0

A NACA0012 wing

Introduction

The parametrization of the naca0012 is

for

To normalize the naca0012, we use the change of variables:

With the following small fortran program:
      PROGRAM NACA12
      DOUBLE PRECISION X,Y,C,XX,YY
      PARAMETER (C=1.008930411365D0)
      INTEGER NB,I
C --------  ENTER THE NUMBER OF INTERVALS -----------
      READ *,NB
      DO I=0,NB
C -----------------------------------------------------
C              4                                       |
C      WE USE X  INSTEAD OF X SO THAT THE PROGRESSION  |
C      OF GENERATED POINTS IS DENSER AROUND O          |
C -----------------------------------------------------
       XX= (DBLE(I)/DBLE(NB))**4
       X = C*XX
       Y = 5*.12*( 0.2969*SQRT(X) -0.126*X
     +            -0.3516*X**2    +0.2843*X**3 -0.1015*X**4)
       YY = Y / C
       PRINT*, XX,YY
      ENDDO
      END
We generate the file "naca12.21pts" by using this program with 20 intervals.

The file "naca12.21pts":

 0.0000000000000000 0.0000000000000000
 6.2500000000000000E-06 4.4290213310617220E-04
 1.0000000000000000E-04 1.7659364374154260E-03
 5.0625000000000000E-04 3.9520447457293480E-03
 1.6000000000000000E-03 6.9724900930098020E-03
 3.9062500000000000E-03 1.0785816129632120E-02
 8.1000000000000000E-03 1.5335254409279880E-02
 1.5006250000000000E-02 2.0543538719326360E-02
 2.5600000000000000E-02 2.6304013971036800E-02
 4.1006250000000000E-02 3.2467169756843240E-02
 6.2500000000000000E-02 3.8822480697810590E-02
 9.1506250000000000E-02 4.5076893778196040E-02
 0.1296000000000000 5.0833559338836810E-02
 0.1785062500000000 5.5577241169031020E-02
 0.2401000000000000 5.8675384962268570E-02
 0.3164062500000000 5.9403968668221290E-02
 0.4096000000000000 5.7000809116986590E-02
 0.5220062500000000 5.0728415111155510E-02
 0.6561000000000000 3.9881091560527040E-02
 0.8145062500000000 2.3576580331835940E-02
 1.000000000000000 2.0060198232592660E-14

Constructing the geometry

  1. Click the SPLINE item of the construction menu
  2. Enter < on the keyboard or click the XY FILE item of the selection menu then enter the name of the file that contains the points of the NACA0012 by typing naca12.21pts(CR) . The spline of the naca appears on the screen.
  3. Click the SEE_ALL item to see the spline clearly.
  4. We want to mesh the exterior of the naca0012. To do this, we must define the boundary at infinity that we will place at -5 upstream, +11 downstream and +8 in the orthogonal direction. We thus construct the 3 points (-5,0), (0,8), (11,0) The 3 points appear. We now construct the arc passing through these 3 points:
  5. To finish the construction of the domain, we must construct the two segments that go from "infinity" to the naca.

     
    Figure 1.36: The complete geometry of the naca0012 and infinity 

     
    Figure 1.37: Zoom around the naca0012 

The construction of the geometrical domain is done. (figures 1.36 and 1.37).

Discretization of the contours

We switch to the PREP_MESH application to define the discretization of the contours.

  1. Click the PREP_MESH item
  2. The discretization of lines is done as follows:
The discretization of lines is done (figures 1.38 and 1.39).

Generating and editing the mesh

We generate the mesh by switching to the EDIT_MESH application.

  1. Click the EDIT_MESH item then type (CR) 4 times to give the default answer to the 4 questions. A mesh appears (figure 1.40).

     
    Figure 1.40: Mesh around the half naca0012 

    We now define references in order to take boundary conditions into account: 1 on infinity , 2 on the NACA, 3 on the trailing edge.

  2. Click the MODIF_REF item of the application menu. Entry of references is done. Now we save the mesh of the half naca.
  3. Click the SAVE item then type mesh(CR) then naca12_5(CR) . The file
    [4] naca12_5.mesh is created.

    To obtain a complete mesh, we make it symmetrical. First we change point of view to see the whole naca.

  4. Click the C_MASK item then type x1/2=0= to center the graphic window on point
  5. Click the SCALE item then type 10= for a scale of 10
  6. Click the SYMMETRY item Now we save the mesh of the naca.
  7. Click the SAVE item then type mesh(CR) then naca12(CR) . The file
    [4] naca12.mesh is created.


Modulefpreviousupnextcontentsindex[BIG][Normal][small]
Next: 1.5.7 Limitations and bugs Up: The EMC˛ preprocessor Prev: The EDIT_MESH application Index Contents