Commit 58ae2024 authored by Dorchies David's avatar Dorchies David
Browse files

fix(MacroRugo): Adjustments on Vmax, f_h* and Cd

- f_h* = 1 + 0.8 / h*^1.5
- Vmax = max(Vg, Vmax)
- Cd = min(6, Cd)

Refs #295
parent e6a36a93
......@@ -117,7 +117,10 @@ export class MacroRugo extends FishPass {
}
r.resultElement.values.Fr = resFr;
// Vitesse maximale
r.resultElement.values.Vmax = this.r * r.resultElement.values.Vg * Math.sqrt(this.CalcfFr(resVdeb));
r.resultElement.values.Vmax = Math.max(
this.r * r.resultElement.values.Vg * Math.sqrt(this.CalcfFr(resVdeb)),
r.resultElement.values.Vg
);
}
// Puissance dissipée
r.resultElement.values.PV = 1000 * MacroRugo.g * r.resultElement.values.Vdeb * this.prms.If.v;
......@@ -315,7 +318,7 @@ export class MacroRugo extends FishPass {
*/
private get Cd(): number {
if (this._cache.Cd === undefined) {
this._cache.Cd = this.Cx * Math.min(3, (1 + 1 / Math.pow(this.prms.Y.v / this.prms.PBD.v, 2)));
this._cache.Cd = Math.min(6, this.Cx * (1 + 0.8 / Math.pow(this.prms.Y.v / this.prms.PBD.v, 1.5)));
}
return this._cache.Cd;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment