Skip to content

GDF Manipulating

dpratavieira edited this page Dec 9, 2019 · 6 revisions

GDF class

import gdf_class

A class for manipulating the gdf file.

The main use is to obtain the hydrostatics properties to export a model in new loading conditions.

It is also possible to scale the original mesh to obtain a vessel with new dimensions.

Load a gdf file

ship = gdf_class.GDF('ship.gdf')

The command above loads a gdf file and creates

Evaluate properties for a determined draft

ship.props(T=[], KGn=[])

Optional Inputs:

  • T: new draft, if it is empty or greater than Depth it will be equal to depth.
  • KGn: new KG, if it is empty it will be equal to original KG evaluated from the mesh.

Scale GDF

ship.gdf_scale(Lf, Bf, Df, T=[], KGn=[])

Necessary inputs:

  • Lf: Final length
  • Bf: Final Beam
  • Df: Final Depth

Optional inputs:

  • T: new draft, if it is empty or greater than Depth it will be equal to depth.
  • KGn: new KG, if it is empty it will be equal to original KG evaluated from the mesh.

Clone this wiki locally