<?xml version='1.0' encoding='utf-8' ?>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
		<link type="text/css" rel="stylesheet" href="doxygen.css"/>
		<link type="text/css" rel="stylesheet" href="tabs.css"/>
	</head>
	<body>
	<div>
<!-- Generated by Doxygen 1.8.5 -->
</div><!-- top -->
<div class="header">
  <div class="headertitle">
<div class="title">Use of STAMOD </div>  </div>
</div><!--header-->
<div class="contents">
<div class="toc"><h3>Table of Contents</h3>
<ul><li class="level1"><a href="#ug_stamod_read_system">Read system description file</a></li>
<li class="level1"><a href="#ug_stamod_read_initial">Read initial condition file</a></li>
<li class="level1"><a href="#ug_stamod_modify">Modify / Present system</a><ul><li class="level2"><a href="#ug_stamod_modify_select">Select environment</a></li>
<li class="level2"><a href="#ug_stamod_modify_initial">Initial positions</a></li>
<li class="level2"><a href="#ug_stamod_modify_eliminate">Eliminate degrees of freedom</a></li>
<li class="level2"><a href="#ug_stamod_modify_positioning">Positioning system</a></li>
<li class="level2"><a href="#ug_stamod_modify_restoring">Restoring forces</a></li>
<li class="level2"><a href="#ug_stamod_modify_dynamic">Dynamic positioning</a></li>
</ul>
</li>
<li class="level1"><a href="#ug_stamod_print">Print static condition</a></li>
<li class="level1"><a href="#ug_stamod_equilibrium">Equilibrium calculation</a></li>
<li class="level1"><a href="#ug_stamod_eigenvalue">Eigenvalue calculation</a></li>
<li class="level1"><a href="#ug_stamod_mooring">Mooring system pretension optimization</a></li>
<li class="level1"><a href="#ug_stamod_write_initial">Write initial condition file</a></li>
<li class="level1"><a href="#ug_stamod_write_file">Write file for visualization</a></li>
</ul>
</div>
<div class="textblock"><p>The main purpose of <code>STAMOD</code> is to read and check the system description from <code>SYSFIL</code> and to write those data to a direct access file, <code>INIFIL</code>, which will be used in <code>DYNMOD</code> and <code>OUTMOD</code>. This file contains a complete system description, definition of the environment to be applied and the initial positions for dynamic simulation.</p>
<div class="fragment"><div class="line">I-&gt;  STAMOD main menu</div>
<div class="line">I</div>
<div class="line">I      1 : Read system description file</div>
<div class="line">I      2 : Read initial condition file</div>
<div class="line">I      3 : Modify/present system</div>
<div class="line">I      4 : Print <span class="keyword">static</span> condition</div>
<div class="line">I      5 : Equilibrium calculation</div>
<div class="line">I      6 : Eigen value calculation</div>
<div class="line">I      7 : Mooring system optimization</div>
<div class="line">I      8 : Write initial condition file</div>
<div class="line">I      9 : Write file <span class="keywordflow">for</span> visualisation</div>
<div class="line">I     99 : Terminate</div>
<div class="line">I</div>
<div class="line">I-&gt;  Select option &gt;</div>
</div><!-- fragment --><h1><a class="anchor" id="ug_stamod_read_system"></a>
Read system description file</h1>
<p>The <code>SYSFIL</code> is an <code>ASCII</code> file containing a complete description of the system to be analysed. For a brief description of the sys-file layout and file syntax, see <a class="el" href="a00018.html#ug_system_system_description">System Description File</a>. A detailed description of the file contents is given in Appendix A.</p>
<p>The <code>SYSFIL</code> is read twice, the first time only to find dimensioning parameters for the work array, the second time to put all data into the work array.</p>
<p>If an error occurs, messages will be written both on the print file and in some cases also on the terminal. Error messages on the print file are found by searching for the string '<code>*** ERROR</code>' from the beginning of the file. If a non-fatal error is encountered, reading of <code>SYSFIL</code> will continue until the maximum number of errors are found.</p>
<p>If errors are found during the first scan of <code>SYSFIL</code> and the print file does not give any meaningful indications on the problem, the amount of output to the printfile can be increased by the <code>MAIS</code>-command '<code>@ FILE 5</code>'.</p>
<h3>Symmetry codes</h3>
<p>Wind force coefficients, current force coefficients, wave drift force coefficients and transfer functions are given as functions of directions relative to the body.</p>
<p>In the calculations, extrapolation on directions are not allowed. In order to avoid problems with program termination due to attempted extrapolation, it is advised that both <code>0</code> degrees and <code>360</code> degrees should be represented in the range of directions on the input file.</p>
<p>If symmetry codes are used, this will automatically be taken care of. For example, if symmetry code is <code>2</code> and the directions <code>20</code> degrees and <code>70</code> degrees are specified, they will be mirrored to <code>-20</code>, <code>20</code>, <code>70</code>, <code>110</code>, <code>160</code>, <code>200</code>, <code>250</code>, <code>290</code>, <code>340</code> and <code>380</code> degrees.</p>
<p>NB: It is strongly advised that values are specified for the symmetry lines. For the example above, <code>0</code> deg and <code>90</code> deg should also be included as input.</p>
<h1><a class="anchor" id="ug_stamod_read_initial"></a>
Read initial condition file</h1>
<p>An <code>INIFIL</code> that has been written by <code>STAMOD</code> during the present or a previous run may be read. If no changes have been made to the system as defined on <code>SYSFIL</code>, this is an alternative which is much faster than reading <code>SYSFIL</code>.</p>
<h1><a class="anchor" id="ug_stamod_modify"></a>
Modify / Present system</h1>
<p>The menu for system modification is:</p>
<div class="fragment"><div class="line">I-&gt;  STAMOD modify/present system</div>
<div class="line">I</div>
<div class="line">I      0 : Return</div>
<div class="line">I      1 : Select environment</div>
<div class="line">I      2 : Initial positions</div>
<div class="line">I      3 : Eliminate degrees of freedom</div>
<div class="line">I      4 : Positioning system</div>
<div class="line">I      5 : Restoring force (incl. environmental forces)</div>
<div class="line">I      6 : Dynamic positioning</div>
<div class="line">I</div>
<div class="line">I-&gt;  Select option &gt;</div>
</div><!-- fragment --><h2><a class="anchor" id="ug_stamod_modify_select"></a>
Select environment</h2>
<p>Several regular and irregular wave conditions, current conditions and wind conditions may be defined on <code>SYSFIL</code> (or <code>INIFIL</code>). The default wave condition will be the present condition. If no condition has been selected, the first one defined on <code>SYSFIL</code> will be the default. Waves, current and wind can be removed individually.</p>
<h2><a class="anchor" id="ug_stamod_modify_initial"></a>
Initial positions</h2>
<p>New initial positions for all bodies may be specified. Present positions will be default.</p>
<h2><a class="anchor" id="ug_stamod_modify_eliminate"></a>
Eliminate degrees of freedom</h2>
<p>Elimination of degrees of freedom is implemented by setting the corresponding local acceleration components to zero during time domain simulation (<code>DYNMOD</code>) and equilibrium iteration (<code>STAMOD</code>).</p>
<h2><a class="anchor" id="ug_stamod_modify_positioning"></a>
Positioning system</h2>
<p>The initial tension may be changed. This is done by moving the anchor position. Print of positioning element locations and plot/print of line characteristics are available. It is also possible to get the line profile printed at the <code>prs-xxx.lis</code> file. To obtain this, the parameter <code>ICPRO</code> in data group <code>CATENARY SYSTEM DATA</code> has to be set to <code>1</code>. In addition, the user has to give the macro file command '<code>@RESU 5</code>' before command '<code>9 : Write file for visualization</code>' is given.</p>
<h2><a class="anchor" id="ug_stamod_modify_restoring"></a>
Restoring forces</h2>
<p>The horizontal restoring force for translation in any direction or rotation may be specified. Output is presented on plots and tables.</p>
<h2><a class="anchor" id="ug_stamod_modify_dynamic"></a>
Dynamic positioning</h2>
<p>The following data may be modified:</p>
<ul>
<li>Reference position and heading, including the point on the body to be positioned</li>
<li>Start value on bias forces that are not measured. If static forces have been calculated, the default values will be updated.</li>
<li>Kalman filter data or <code>PID</code> controller data</li>
</ul>
<h1><a class="anchor" id="ug_stamod_print"></a>
Print static condition</h1>
<p>Initial positions for all bodies will be written to the terminal (standard output) and, if selected also to the print file.</p>
<p>Static forces acting on bodies are written to the terminal and optionally to the print file. The following forces are presented:</p>
<ul>
<li>Average wave drift force calculated for the present heading, including wave-current interaction if specified</li>
<li>Wind force (linear interpolation between directions)</li>
<li>Current drag force based on linear and quadratic current coefficients (linear interpolation between directions)</li>
<li>Munk moment caused by current velocity and different magnitude of added mass specified in individual degree of freedom</li>
<li>Positioning element forces</li>
<li>Thruster forces</li>
<li>Coupling element forces</li>
<li>Forces from general line systems</li>
<li>Hydrostatic stiffness force</li>
<li>Gravity and buoyancy forces, also including small volume hydrodynamic force with wave particle velocities and accelerations set to zero. The forces contain contributions from current, gravity force and any static soil reaction forces.</li>
<li>Gravity forces due to time dependent added mass at time zero</li>
<li>Gravity and buoyancy force on slender elements and fixed body elements</li>
<li>Current drag forces acting on slender elements and fixed body elements</li>
<li>Specified forces at time equal to zero</li>
<li>External forces, i.e. forces from any special force subroutines linked into the program</li>
</ul>
<p>If a dynamic positioning system is defined, thrust demand will be calculated according to <a class="el" href="a00010.html#thrust_demand_equation">the thrust demand equation</a>.</p>
<h1><a class="anchor" id="ug_stamod_equilibrium"></a>
Equilibrium calculation</h1>
<p>The following parameters are specified interactively:</p>
<ul>
<li><img class="formulaInl" alt="$ T $" src="form_2.png"/>: Typical (maximum) natural period</li>
<li><img class="formulaInl" alt="$ \delta x$" src="form_17.png"/>: Position tolerance</li>
<li><img class="formulaInl" alt="$ \delta \alpha$" src="form_18.png"/>: Direction tolerance</li>
<li><img class="formulaInl" alt="$ \delta t$" src="form_19.png"/>: Time step</li>
</ul>
<p>From position and direction tolerances, the following tolerances for velocities and acceleration are calculated:</p>
<ul>
<li><img class="formulaInl" alt="$ \omega = 2\pi/T $" src="form_20.png"/></li>
<li><img class="formulaInl" alt="$ \delta \dot{x} = \omega \delta x$" src="form_21.png"/></li>
<li><img class="formulaInl" alt="$ \delta \dot{\alpha} = \omega \delta \alpha$" src="form_22.png"/></li>
<li><img class="formulaInl" alt="$ \delta \ddot{x} = \omega^2 \delta x$" src="form_23.png"/></li>
<li><img class="formulaInl" alt="$ \delta \ddot{\alpha} = \omega^2 \delta \alpha$" src="form_24.png"/></li>
</ul>
<p>By default, critical damping for each degree of freedom can be calculated:</p>
<p><img class="formulaInl" alt="$ c_i = 2M_i \omega, \quad i=1,6 $" src="form_25.png"/></p>
<p>where <img class="formulaInl" alt="$ M_i $" src="form_26.png"/> are the diagonal elements of the total mass matrix.</p>
<p>The equilibrium condition is found by stepping the equations of motion. The following force models will be included (if they are defined):</p>
<ul>
<li>"Critical damping" force</li>
<li>Modified retardation function force, <img class="formulaInl" alt="$ F_{ij} = 4 \Delta t \: h_{ij} (0) \dot{x}_j $" src="form_27.png"/></li>
<li>Hydrostatic stiffness force</li>
<li>Linear damping force</li>
<li>Quadratic damping force</li>
<li>Wind force (linear interpolation between directions)</li>
<li>Linear and quadratic current drag force (linear interpolation between directions)</li>
<li>Average wave drift force. The force will be calculated for the instantaneous heading the first and last time step. For other steps, corrections for instantaneous heading are done using first derivatives.</li>
<li>Small volume hydrodynamic force, wave particle velocities are set to zero.</li>
<li>Coupling element forces</li>
<li>Specified forces for <code>t = 0</code>.</li>
<li>Positioning element forces</li>
<li>Thruster forces.</li>
</ul>
<p><a class="anchor" id="thrust_demand_equation"></a> If a dynamic positioning system is defined, the thruster forces are calculated from the thruster allocation algorithm described in the Theory Manual. The thrust demand is</p>
<p><img class="formulaInl" alt="$ F_{d,i} = \delta x_i G_{il} F_{wi,i} F_{wa,i} F_{cu,i} F_{li,i} F_{co,i}\:, \quad i=1,2,6$" src="form_28.png"/></p>
<p>where</p>
<ul>
<li><img class="formulaInl" alt="$ \delta x_i$" src="form_29.png"/>: Positioning error in local coordinate system</li>
<li><img class="formulaInl" alt="$ G_{il} $" src="form_30.png"/>: Position and heading gains in linear controller matrix</li>
<li><img class="formulaInl" alt="$ F_{wi} $" src="form_31.png"/>: Static wind force</li>
<li><img class="formulaInl" alt="$ F_{wa} $" src="form_32.png"/>: Static wave drift force</li>
<li><img class="formulaInl" alt="$ F_{cu} $" src="form_33.png"/>: Current force</li>
<li><img class="formulaInl" alt="$ F_{li} $" src="form_34.png"/>: Positioning element force</li>
<li><img class="formulaInl" alt="$ F_{co} $" src="form_35.png"/>: Coupling force</li>
</ul>
<p>The equations of motion are stepped the specified number of steps with the modified Euler algorithm. At the last step, relative position and direction "errors" are calculated as:</p>
<p><img class="formulaInl" alt="$ \displaystyle \varepsilon_1 = \mathrm{max} \left[ \left| \frac{\dot{x_i}}{\delta \dot{x}} \right|, \left| \frac{\ddot{x_i}}{\delta \ddot{x}} \right| \right], \quad i = 1,2,3 $" src="form_36.png"/></p>
<p><img class="formulaInl" alt="$ \displaystyle \varepsilon_2 = \mathrm{max} \left[ \left| \frac{\dot{x_i}}{\delta \dot{\alpha}} \right|, \left| \frac{\ddot{x_i}}{\delta \ddot{\alpha}} \right| \right], \quad i = 4,5,6 $" src="form_37.png"/></p>
<p>"Equilibrium position" is found when both <img class="formulaInl" alt="$ \varepsilon_1$" src="form_38.png"/> and <img class="formulaInl" alt="$ \varepsilon_2$" src="form_39.png"/> are less than 1.</p>
<p>Note that initial positions are updated when calculation of equilibrium is selected, even if equilibrium position is not found.</p>
<p>It is advised to check the equilibrium position by calculating static forces and printing new initial positions.</p>
<h1><a class="anchor" id="ug_stamod_eigenvalue"></a>
Eigenvalue calculation</h1>
<p>Natural periods and eigen vectors are calculated for selected modes. The calculation is based on a linearized model of the system. Mass and stiffness matrices are calculated, and the system solved by a standard Jacobian solver. The effect of damping is not included in the analysis.</p>
<p>The mass matrix is built from the virtual mass matrix, including both structural and hydrodynamic mass. The frequency dependency of the latter is <b>not</b> accounted for in the analysis as asymptotic values are used. For bodies of type 1 (see the chapter <a class="el" href="a00024.html#body_data_specification">Body Data Specifications</a>) this means added mass at infinite frequency, while the added mass at zero frequency is used for bodies of type 2.</p>
<p>The secant stiffness for the user selected modes is calculated at the initial position. The user may choose to specify the secant excursion used in the calculation for each mode. The stiffness matrix is made symmetric.</p>
<p>For each natural period, the eigen vectors expresses the relative contribution from each mode. Translations are given in the length unit <img class="formulaInl" alt="$\mathrm{[L]}$" src="form_40.png"/> and rotations in degrees <img class="formulaInl" alt="$\mathrm{[deg]}$" src="form_14.png"/>.</p>
<p>In the interpretation of the results, it should be kept in mind that damping is not included in the analysis. Modes that are heavily damped may thereby not be recognized in time domain simulation results.</p>
<p>Observe also that environmental forces are not included. Thus, the yaw motion of a turret moored or a single point moored vessel can not be checked by an eigenvalue analysis.</p>
<h1><a class="anchor" id="ug_stamod_mooring"></a>
Mooring system pretension optimization</h1>
<p>By this option it is possible to adjust line lengths (or move anchor position) in an optimal way in order to counteract average environmental forces. The sum of squared differences between pretension and actual tension in each line is minimized.</p>
<h1><a class="anchor" id="ug_stamod_write_initial"></a>
Write initial condition file</h1>
<p>After all modifications have been made with the system, the initial condition must be saved. The initial condition file will be read by <code>DYNMOD</code>. It can also be read by <code>STAMOD</code> if more modifications are required.</p>
<h1><a class="anchor" id="ug_stamod_write_file"></a>
Write file for visualization</h1>
<p>A file for 3D visualisation by the stand-alone program <code>SimVis</code> can be written whenever the system description file has been read successfully. This means that the system can be visualized before or after equilibrium condition calculation has been made. Visualisation directly after reading the system description file can be advantageous as a preliminary control of the system geometry. </p>
</div></div><!-- contents -->
	</body>
</html>