FhSim  3.1.0
Marine systems simulation
Loading...
Searching...
No Matches
0124 — Panel laws and cylinder laws use two different water viscosities
ID 0124
Class BUG
Severity 2
Status blocked

Models: — (annotated on the fhsim_environment library group)

Found: 2026-10-20, hydrodynamics overview section 7 (doc/hydrodynamics-overview.md in fhsim_workspace), feature m2-hydro-doc-gaps

Decision needed: Owner: which kinematic viscosity is the default for the cable and cylinder laws (1.005e-6 fresh water at 20 °C, or 1.19e-6 sea water at 15 °C as the panel laws use)? Should it be settable from XML (per object, or from the environment)? Either choice moves the cable drag results (Re changes about 16 %, so Cd and Ct change).

Evidence

  • Panel laws read Nu, default 1.19e-6 m²/s (include/fhsim_environment/hydrodynamics/PanelLoadLaw.h:243).
  • Cylinder laws use a fixed constant, include/fhsim_environment/hydrodynamics/CylinderHydro.h:178-180:

    inline constexpr double kWaterKinematicViscosity = 1.005e-6;

    WetCylinderLaw.h:51 defaults its viscosity member to it.

  • fhsim_base src/cable/Cable.cpp:470 calls cylinder_hydro::DragForce(..., cylinder_hydro::kWaterKinematicViscosity, ...). The value cannot be set from XML there (BASE-0085 lists the other own-hydro code in that repo).

Effect

A net with cables uses two viscosities in one run: panels at 1.19e-6, cables at 1.005e-6. Sea water is the normal case, so the cable Reynolds number is about 16 % low.

Possible fix

Options: (a) one constant for both, 1.19e-6 (sea water), cable results move; (b) keep 1.005e-6 for cylinders and document it (no change, two values stay); (c) make Nu an XML parameter of the cable models and default it from the environment. Option (c) is the most work and needs a parameter name shared with the panel laws.

Test that would prove it

A net-with-cable case that reads Nu once and checks both the panel and the cable Reynolds number use it.

Risk

Moves every cable baseline that runs through cylinder_hydro::DragForce unless option (b) is chosen.