Skip to content

Advanced Tutorial 4: Complex Appendage Modelling

Overview

This tutorial models a hypothetical energy saving device (ESD) — a duct held by two support struts — with CAESES coupled to SHIPFLOW. You generate a component grid around an imported IGES duct surface, embed it in the hull grid with the overlapping grid approach, and then run a self-propulsion ensemble investigation to see how the angle of attack of the struts affects the delivered power.

The tutorial is split into two parts:

  1. Geometry set-up — import the duct, generate a surface mesh and a volume grid, add rudder-type support struts, and check the overlapping grids
  2. Optimisation — parametrise the strut angles and run an ensemble investigation over three angles per strut

Time required: 1.5–2 hours
Difficulty: Advanced
Prerequisites: Advanced Tutorials 1 and 3; familiarity with the XCHAP self-propulsion set-up and the append command
SHIPFLOW modules used: XPAN, XBOUND, XGRID, XCHAP

CAESES required

This tutorial needs the full CAESES environment from Friendship Systems together with SHIPFLOW. SHIPFLOW Design5 has an Optimize workspace, but the tutorial uses options and tools that only the full CAESES provides, so it cannot be done in SHIPFLOW Design4 or Design5.

Grid resolution

The examples in this tutorial use coarse grids to keep computation times short. Production cases must be run with a much finer grid resolution.


Learning Objectives

By completing this tutorial, you will be able to:

  • Import an IGES surface and generate a surface mesh with the CAESES Mesh Engine
  • Control the surface mesh density with the U- and V-direction settings
  • Generate a volume grid from the surface mesh with the volu command
  • Estimate a first step size that gives y+ of about 1
  • Use rudder-type appendages with cant angles as duct support struts
  • Adapt the strut grids to the hull and the duct with append commands
  • Check the overlapping grids before running the flow solver
  • Activate self-propulsion with a propeller open water file
  • Parametrise appendage angles as CAESES design variables
  • Run an ensemble investigation of the strut angles against the delivered power

Background: Energy Saving Devices

Energy saving devices are appendages fitted near the propeller to improve the propulsive efficiency. The ESD in this tutorial is a hypothetical duct held by two struts.

The duct is modelled as an extra component grid embedded in the hull grid, with the overlapping grid approach introduced in Advanced Tutorial 3. Its surface is meshed in CAESES, and XCHAP generates a volume grid from this surface mesh with the volu command. The two struts are rudder commands turned horizontal with cant angles of 90° and −90°. In Part 2, an ensemble investigation varies the angle of attack of each strut over three values and compares the delivered power in self-propulsion.


The volu Command

The volu command (VOLUME in the XCHAP section of the user manual) creates a volume grid from a surface grid with a hyperbolic grid generator. The surface grid is read from a Plot3D file (.p3d). Use it when a component grid is needed around a surface that you have meshed yourself, such as the imported duct, rather than one of the parametric appendages (rudder, bracket …). Its parameters are explained in step 1.6.


Tutorial Files

The configuration and geometry files for this tutorial are located in your SHIPFLOW installation:

C:\FLOWTECH\SHIPFLOW<version>-x86_64\tutorials\tutorial-files\AdvancedTraining\Tutorials-v5\Tutorial_4\source\
File Description
config_t4-1 SHIPFLOW configuration file
off_t4-1 Offset file (hull geometry)
duct.igs IGES surface geometry of the duct
prop-pow.txt Propeller open water data (used in Part 2)

Part 1: Geometry Set-Up


1.1 Set Up the Project

  1. Start a new project.
  2. Go to Import → Configuration (SHIPFLOW).
  3. Navigate to the source folder and select config_t4-1.
  4. When the file selection dialog appears again, select the offset file off_t4-1.
  5. Save the project as tutorial_ESD.

The imported configuration appears in the Object Tree as config_t4-1. (Some screenshots show the name config_t51 from an earlier numbering of the tutorials.)


1.2 Switch XGRID to the Zonal Approach

  1. Select Object Tree → Configurations → config_t4-1 → xgrid → size.
  2. Add the parameter domain and set it to zonal.

    xgrid → size with domain set to zonal

In the zonal approach, XCHAP computes only the aft part of the hull and takes the inflow at its inlet from the XPAN and XBOUND results. The global and zonal approaches are compared in Basic Tutorial 5.


1.3 Import the Duct Geometry

  1. Go to File → Import → IGES.
  2. Navigate to the source folder and select duct.igs.
  3. Check that both the offset sections and the imported duct surface are visible in the 3DView.

    The imported duct surface (scope duct in the Object Tree) next to the offset sections of the hull


1.4 Create the Duct Surface Mesh

XCHAP needs a surface mesh of the duct to generate the volume grid. Create it with the CAESES Mesh Engine:

  1. In the Object Tree, select the duct surface (duct → TrimSrf_).
  2. Go to Model → Maritime → Panel Mesh → Mesh Engine.

    Mesh Engine in the Panel Mesh menu of the Maritime tab, with the duct surface TrimSrf_ selected

  3. Rename the new mesh engine from meshEngine1 to duct_mesh.

    With the default settings (10 panels in each direction) the mesh is far too coarse to represent the duct:

    Default Mesh Engine settings and the resulting coarse duct mesh, with the offset sections and the duct surface still visible

  4. Hide the offset sections and the imported duct surface to see the mesh on its own.

    The coarse default duct mesh on its own


1.5 Refine the Surface Mesh

In the Object Editor of duct_mesh:

  1. Set the U-Direction parameters (along the duct section):

    Parameter Value
    Number 50
    Factor 0.93

    U-Direction set to Number 50 and Factor 0.93

  2. Set the V-Direction parameters (around the circumference):

    Parameter Value
    Number 31
    Factor 1
  3. In the General section, tick Reversed.

    Mesh Engine with Reversed ticked and the V-Direction set to Number 31 and Factor 1

Number and Factor

Number is the number of panels in the U or V direction of the surface parameter space. Factor is a mapping factor around 1 — positive or negative, for example 0.8, 1.2, −0.8 or −1.2 — that changes the panel density towards the ends of the parameter range (see FMeshEngine in the CAESES help). Suitable values depend on the imported geometry: check the mesh in the 3DView and refine it until it represents the shape of the object.


1.6 Generate the Duct Volume Grid

  1. Select Object Tree → Configurations → config_t4-1 → xchap.
  2. Add the command xchap → volu.
  3. Set its parameters:

    Parameter Value Description
    id duct Name of the component grid; the struts are adapted to it in step 1.8
    file |duct_mesh.exportPlot3D("ductmesh.p3d") Exports the surface mesh to the Plot3D file ductmesh.p3d and passes the file name to XCHAP
    kmax 35 Number of grid planes in the wall-normal direction
    step 0.005 First step size from the wall, in the computational coordinate system (hull length = 1)
    fac 1.1 Expansion factor between successive planes
    bc31 NOSLIP Boundary condition on side n = 1 of the grid, the duct surface

    volu command (volume) in xchap with the file expression that exports the duct mesh to ductmesh.p3d

    The expression refers to the mesh engine by its name. If you kept the default name, use |meshEngine1.exportPlot3D("ductmesh.p3d"), as in the screenshot.

Choosing step for y+ ≈ 1

The surface mesh from CAESES has no cells in the wall-normal direction; XCHAP creates them from kmax, step and fac. For a wall-resolved grid, the first grid point off the wall should be at a y+ of about 1. Because step has to be chosen before the first run, estimate it from the flat-plate skin friction:

  1. Reynolds number, with the ship speed \(U\), the ship length \(L_{pp}\) and the kinematic viscosity \(\nu\):

    \[ Re = \frac{U L_{pp}}{\nu} \]
  2. Skin friction coefficient from the ITTC-1957 correlation line:

    \[ C_f = \frac{0.075}{(\log_{10} Re - 2)^2} \]
  3. Friction velocity:

    \[ u_\tau = U \sqrt{C_f / 2} \]
  4. Wall distance of the first grid point for the target \(y^+\):

    \[ \Delta y = \frac{y^+ \, \nu}{u_\tau} \]
  5. step is given in the computational coordinate system, where the hull length is 1:

    \[ \mathrm{step} = \frac{\Delta y}{L_{pp}} = \frac{y^+}{Re \sqrt{C_f / 2}} \]

In this tutorial \(Re = 1.0 \times 10^6\) (_Rn in the XCHAP results table, see step 2.3). This gives \(C_f = 0.0047\) and, for \(y^+ = 1\), \(\mathrm{step} \approx 2.1 \times 10^{-5}\). The tutorial uses the larger step = 0.005: XCHAP adjusts the near-wall spacing of the grid when necessary (see below), so the estimate is a guide for your own cases rather than a value you must enter.

The estimate assumes flat-plate flow at the ship speed, while the local flow at the duct is different, so treat the result as a starting value. Note also that by default XCHAP stretches imported and parametric grids towards no-slip walls to reach its y+ target (STRETCH and YTARGET in XCHAP CONTROL).


1.7 Add the Duct Support Struts

The duct is held by two horizontal struts, each modelled with a rudder command (RUDDER).

  1. Select Object Tree → Configurations → config_t4-1 → xflow.
  2. Add two xflow → rudder commands.
  3. Set their parameters:

    Parameter Port strut Starboard strut
    id rpc rsc
    span 3.2 3.2
    angle 20 20
    cant 90 -90
    origin [7.6, 0, 5.8] [7.6, 0, 5.8]
    s [0, 1] [0, 1]
    c [2.5, 2] [2.5, 2]
    xle [0.75, 0.5] [0.75, 0.5]
    dime [30, 20, 20] [30, 20, 20]

    rudder command for the port strut: id rpc, span 3.2, angle 20, cant 90, origin [7.6, 0, 5.8]

    rudder command for the starboard strut: id rsc, span 3.2, angle 20, cant -90, origin [7.6, 0, 5.8]

Cant angle

A rudder is positioned by its origin and two rotations: angle about the rudder's own z-axis, then cant about the x-axis. With cant = 90 and cant = -90 the two rudders become horizontal struts that point to opposite sides from the common origin. angle is then the angle of attack of each strut — the parameter that Part 2 varies.


1.8 Append the Struts to the Hull and the Duct

Each strut runs from the hull (its root, at origin) to the duct (its tip). Its grid is therefore adapted at both ends in the spanwise direction (adir = 3): the root (aside = 1) to the hull grid Xgrid and the tip (aside = 2) to the duct grid duct. Add four xflow → append commands:

id adapt adir aside
rpc ["Xgrid"] 3 1
rpc ["duct"] 3 2
rsc ["Xgrid"] 3 1
rsc ["duct"] 3 2

The two append commands for the port strut rpc: to Xgrid with aside 1 and to duct with aside 2

The two append commands for the starboard strut rsc: to Xgrid with aside 1 and to duct with aside 2

How adir and aside are found from grid slices is shown in Choose the append parameters in Advanced Tutorial 3.


1.9 Run the Grid Generation and Check the Overlap

  1. Check that xgrid → size → xgdens is set to coarse.

    xgrid → size with xgdens set to coarse

  2. In xchap → control, set maxit to 0.

    xchap → control with maxit set to 0

  3. Select Computations → shfComputation1. If the Application field is empty (marked with a red asterisk), click the + button next to it to create localApplication1, and set its Executable to shipflow.bat in the C:\FLOWTECH\SHIPFLOW<version>-x86_64\bin directory.

    shfComputation1 with an empty Application field

    localApplication1 created with the + button, with the Executable set to shipflow.bat in the SHIPFLOW bin directory

  4. Run the computation.

    Warnings on coarse grids

    The TaskMonitor may show warnings during this run. They appear only because this tutorial uses very coarse grids and can be ignored here.

  5. When the computation has finished, the component grids duct_1, rpc_1 and rsc_1 are listed under Connect → Post-Processing → Results → shfComputation1 → XCHAP → Component Grids.

    Component Grids after the first run (duct_1, prop_grid_1, rpc_1, rsc_1, Xgrid_1, Xgrid_2) and the duct with the two struts seen from behind

  6. Display the surface meshes of the duct, the struts and the hull refinement zone. The correct set-up should look like this:

    Duct, struts and hull refinement zone seen from behind: the duct grid is embedded in the hull grid and the struts connect the hull to the duct


Part 2: Duct Support Angle Optimisation

Part 2 parametrises the angle of attack of the struts and runs an ensemble investigation to find the combination with the lowest delivered power.


2.1 Activate Self-Propulsion

  1. Continue from Part 1, or open the finished project:

    C:\FLOWTECH\SHIPFLOW<version>-x86_64\tutorials\tutorial-files\AdvancedTraining\Tutorials-v5\Tutorial_4\T_4_2\T_4_2.cdb
    
  2. Activate the lifting line propeller model: in xchap → lline, set diskon to on (see LLINE).

    xchap → lline with diskon set to on

  3. Add the command xflow → selfpr (see SELFPROPULSION) and set:

    Parameter Value Description
    onoff on Activates self-propulsion
    ctow 0.001 Towing force coefficient
    pow prop-pow.txt File with the propeller open water data

    selfpr command with onoff on, ctow 0.001 and pow set to the full path of prop-pow.txt

    Location of the open water file

    prop-pow.txt is stored next to the offset file and the other files imported for this tutorial. If SHIPFLOW is not run from that directory, set pow to the full path of the file, as in the screenshot. On Windows, you can copy the path from the file's right-click menu in File Explorer and paste it into pow; remove the double quotes.


2.2 Run a Baseline Self-Propulsion Simulation

  1. In xchap → control, set maxit to 10.

    xchap → control with maxit set to 10

  2. Run the computation. It takes a few minutes.


2.3 Create the Evaluation Parameter

CAESES needs an evaluation parameter to read the delivered power after each computation.

  1. Open the TableViewer.
  2. In the table with the XCHAP results, find the row _PD (delivered power).
  3. Double-click its value. This creates the evaluation parameter eval__PD (with two underscores).

    TableViewer with the XCHAP results: double-clicking the _PD value creates eval__PD in the Object Tree


2.4 Create the Design Variables

  1. Go to Model → CAD → Design Variable and create two design variables, AOA_port and AOA_stb.

    Design Variable button in the CAD tab of the Model workspace

  2. Set both values to 20.

    The design variables AOA_port and AOA_stb, both with the value 20


  1. In the Object Editor of the rudder with id = rpc (Object Tree → Configurations → config_t4-1 → xflow → rudder), replace the value of angle with the design variable AOA_port.
  2. In the rudder with id = rsc, replace the value of angle with AOA_stb.

    angle of the starboard strut rsc linked to the design variable AOA_stb, which evaluates to 20

The strut angles now follow the design variables in every variant of the ensemble investigation.


2.6 Configure and Run the Ensemble Investigation

  1. Go to Optimize → Optimization → Ensemble Investigation.

    Ensemble Investigation in the Design Space Exploration group of the Optimization tab

  2. In the Object Editor of ensembleInvestigation1, set:

    Design Variables:

    Design Variable Series
    AOA_port 15,20,25
    AOA_stb 15,20,25

    Evaluations:

    Evaluation Objective
    eval__PD observer

    ensembleInvestigation1 with the design variables AOA_port and AOA_stb (series 15,20,25) and the evaluation eval__PD as observer

  3. In Object Tree → Configurations → config_t4-1 → xflow → program, make sure that only xchap is selected. The strut angles change only the XCHAP grids, so XPAN, XBOUND and XGRID do not have to run again for every variant.

  4. Save the project (Ctrl+S) and click the green Run button of ensembleInvestigation1.

The ensemble investigation computes 9 variants (3 × 3 combinations of the two angles). This takes a few minutes.


2.7 Review the Results

When all variants have finished, the results table lists AOA_port, AOA_stb and eval__PD for each design. Compare the eval__PD values to find the combination of strut angles with the lowest delivered power.

Results of the ensemble investigation: nine designs with their AOA_port, AOA_stb and eval__PD values

Demonstration results only

With 10 iterations the solutions are not converged, and the grids are far too coarse for design work. Do not draw design conclusions from these numbers; see Tutorial settings are too coarse for engineering work for production settings.


Troubleshooting

General troubleshooting

Problems that can occur in any SHIPFLOW case are collected on one page: Troubleshooting.

Directly relevant to this tutorial:


Summary

  • A component grid around an imported surface is built in two steps: a surface mesh from the CAESES Mesh Engine, and a volume grid from volu, whose step can be estimated from the flat-plate skin friction for y+ ≈ 1.
  • rudder commands with cant = 90 and cant = -90 act as horizontal struts; append commands fit their grids to the hull at the root and to the duct at the tip.
  • Self-propulsion needs the lifting line model (lline | diskon = on) and the selfpr command with a propeller open water file.
  • An ensemble investigation with the design variables AOA_port and AOA_stb and the evaluation parameter eval__PD compares the delivered power for 3 × 3 strut angle combinations.

Next Steps

Getting help: send questions about this tutorial to [email protected]. Product information: shipflow.se.


Tutorial updated: June 2026
SHIPFLOW version: 8.0.37
Document version: 1.0