Example program demonstrating how to apply a progressive twist and linear taper to a hexahedral NURBS volume along its axial (z) direction.
The program:
Creates a straight hexahedral block (control points nc = [7,7,9] over a box of size L),
Copies it to shape,
Applies a z-dependent twist up to
twist_deg and a linear taper to factor taper,
Exports the resulting NURBS volume to VTK,
Displays the geometry.
| Type | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|
| real(kind=rk), | parameter | :: | L(3) | = | [1.0_rk, 1.0_rk, 3.0_rk] |
Domain extents in . |
| type(nurbs_volume) | :: | hexa | ||||
| integer, | parameter | :: | nc(3) | = | [7, 7, 9] |
Control point counts per direction. |
| type(nurbs_volume) | :: | sh | ||||
| real(kind=rk), | parameter | :: | taper | = | 0.1_rk |
Target in-plane scale at the top face (0< |
| real(kind=rk), | parameter | :: | twist_deg | = | 360.0_rk |
Total twist angle (degrees) at the top face. |
Apply a z-progressive twist and linear taper to a NURBS hexahedron.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(nurbs_volume), | intent(inout) | :: | this |
Volume to be transformed. |
||
| real(kind=rk), | intent(in) | :: | L(3) |
Box lengths . |
||
| integer, | intent(in) | :: | nc(3) |
Control points sizes. |
||
| real(kind=rk), | intent(in) | :: | twist_deg |
Total twist at top face (degrees). |
||
| real(kind=rk), | intent(in) | :: | taper |
In-plane scale at top face (0< |