FhSim  3.1.0
Marine systems simulation
Loading...
Searching...
No Matches
marenv::wake::WakeBlendSum Struct Reference

#include <WakeSampleParts.h>

Public Member Functions

void Add (double share, const WakeSample &sample)
 Adds a snapshot's sample with its share of the blend.
 
void Add (double share, const WakeBlendSum &part)
 Adds the sums of a state blended from with its share of the blend.
 
Status ToSample (const double zeroDeficitVelocity[3], WakeSample &out) const
 

Public Attributes

bool inside = false
 True once a snapshot contributed.
 
double deficit = 0.0
 Sum of share d.
 
double weightedVelocity [3] = {0.0, 0.0, 0.0}
 Sum of share d u_s, m/s, NED.
 
double weightedShading = 0.0
 Sum of share d w_e, w_e the effective shading weight of the snapshot's sample (MENV-0097).
 
double weightedRatio = 0.0
 Sum of share d m, m the inflow ratio of the snapshot (MENV-0097).
 

Detailed Description

The sums over the snapshots of a blend that contributed at one point (WakeBlend::Evaluate()).

Member Function Documentation

◆ ToSample()

Status marenv::wake::WakeBlendSum::ToSample ( const double  zeroDeficitVelocity[3],
WakeSample &  out 
) const
inline

The field's sample from the sums: d = sum(share d), u_s = sum(share d u_s) / d.

Parameters
[in]zeroDeficitVelocityThe source velocity the field reports where d = 0, m/s, NED.
[out]outThe sample; d = 0 and u_s = 0 when no snapshot contributed; the shading weight and the inflow ratio are the deficit-weighted means sum(share d w_e) / d and sum(share d m) / d, so d w_e and d m blend in time like d u_s (MENV-0097); 0 and 1 where d = 0.
Returns
Status::OK, or Status::ERROR_NOT_SET when no snapshot contributed.

The documentation for this struct was generated from the following file: