| ... | ... | @@ -46,10 +46,12 @@ The grid associated to the volume (fluid), and the fixed, moving and internal bo |
|
|
|
morpher.setField('fld') # volume grid
|
|
|
|
for fxd in ['fxd_0', 'fxd_1', ...]:
|
|
|
|
morpher.addFixed(fxd) # fixed boundary
|
|
|
|
morpher.addMoving('mov') # moving boundary
|
|
|
|
morpher.addInternal('wk', 'wk_') # pair of internal boundaries
|
|
|
|
for mov in ['mov_0', 'mov_1', ...]:
|
|
|
|
morpher.addMoving(mov) # moving boundary
|
|
|
|
for intl in ['intl_0', 'intl_1', ...]:
|
|
|
|
morpher.addInternal(intl, intl+'_') # pair of internal boundaries
|
|
|
|
```
|
|
|
|
where `'fld'` is the name of the physical group of the mesh contaning the volume grid (fluid), `'fxd_i'` is the name of the ith physical group of the mesh contaning a fixed boundary, `'mov'` is the name of the physical group of the mesh contaning the moving boundary (typically, a body), and `'wk','wk_'` is the pair of names of the physical groups of the mesh contaning the internal boundaries (typically, a wake). Note that several pair of internal boundaries can be added by repeating the last instruction.
|
|
|
|
where `'fld'` is the name of the physical group of the mesh contaning the volume grid (fluid), `'fxd_i'` is the name of the ith physical group of the mesh contaning a fixed boundary, `'fxd_i'` is the name of the ith physical group of the mesh contaning a moving boundary (typically, a body), and `'intl_i','intl_i_'` is the pair of names of the ith physical group of the mesh containing the internal boundaries (typically, a wake).
|
|
|
|
For 3D computations, if the problem contains a symmetry plane, it can be added as,
|
|
|
|
```python
|
|
|
|
morpher.setSymmetry('sym', 1)
|
| ... | ... | @@ -61,7 +63,10 @@ morpher.initialize() |
|
|
|
```
|
|
|
|
and can be latter executed using,
|
|
|
|
```python
|
|
|
|
morpher.savePos() # save the initial position of the nodes of the moving boudnary
|
|
|
|
# set the new positions of the nodes of the moving boundary, and then call
|
|
|
|
morpher.deform() # perform the volume deformation
|
|
|
|
# set the new positions of the nodes of the moving boundary, typically
|
|
|
|
for n in mov.nodes:
|
|
|
|
for idim in range(3):
|
|
|
|
n.pos += dx
|
|
|
|
# then call
|
|
|
|
morpher.run() # perform the volume deformation
|
|
|
|
``` |