measur-tools-suite 1.2.6-rc.4 → 1.2.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/bin/client.wasm CHANGED
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "measur-tools-suite",
3
- "version": "1.2.6-rc.4",
3
+ "version": "1.2.6",
4
4
  "engines": {
5
5
  "node": "20.19.4",
6
6
  "npm": "10.8.2"
@@ -34,6 +34,7 @@ export * from "./ts_def_modules/motorDriven/motor/motor";
34
34
  export * from "./ts_def_modules/motorDriven/motor/motorEnum";
35
35
 
36
36
  export * from "./ts_def_modules/motorDriven/pump/pump";
37
+ export * from "./ts_def_modules/motorDriven/pump/pump_head";
37
38
  export * from "./ts_def_modules/motorDriven/pump/pump_valve_power_loss";
38
39
 
39
40
  export * from "./ts_def_modules/motorDriven/pumpFan/pumpFan";
@@ -145,6 +146,7 @@ export type MeasurToolsSuite =
145
146
  import("./ts_def_modules/motorDriven/motor/motor").MotorModule &
146
147
  // motorDriven/pump
147
148
  import("./ts_def_modules/motorDriven/pump/pump").PumpModule &
149
+ import("./ts_def_modules/motorDriven/pump/pump_head").PumpHeadModule &
148
150
  import("./ts_def_modules/motorDriven/pump/pump_valve_power_loss").PumpValvePowerLossModule &
149
151
  // motorDriven/pumpFan
150
152
  import("./ts_def_modules/motorDriven/pumpFan/pumpFan").PumpFanModule &
@@ -5,130 +5,9 @@ import { PumpStyle, SpecificSpeed } from "../pumpFan/pumpFan";
5
5
  /**
6
6
  * Pump calculations.
7
7
  *
8
- * Provides pump head tools and pump-system result calculators for baseline
9
- * and modified operating conditions.
8
+ * Provides pump-system result calculators for baseline and modified operating conditions.
10
9
  */
11
10
 
12
- /**
13
- * Result object returned by head tool calculations.
14
- */
15
- export declare class HeadToolOutput {
16
- /**
17
- * Constructor for HeadToolOutput
18
- * @param differentialElevationHead Differential elevation head, units ft.
19
- * @param differentialPressureHead Differential pressure head, units ft.
20
- * @param differentialVelocityHead Differential velocity head, units ft.
21
- * @param estimatedSuctionFrictionHead Estimated suction friction head, units ft.
22
- * @param estimatedDischargeFrictionHead Estimated discharge friction head, units ft.
23
- * @param pumpHead Total pump head, units ft.
24
- */
25
- constructor(
26
- differentialElevationHead: number,
27
- differentialPressureHead: number,
28
- differentialVelocityHead: number,
29
- estimatedSuctionFrictionHead: number,
30
- estimatedDischargeFrictionHead: number,
31
- pumpHead: number
32
- );
33
-
34
- /** Differential elevation head, units ft */
35
- differentialElevationHead: number;
36
- /** Differential pressure head, units ft */
37
- differentialPressureHead: number;
38
- /** Differential velocity head, units ft */
39
- differentialVelocityHead: number;
40
- /** Estimated suction friction head, units ft */
41
- estimatedSuctionFrictionHead: number;
42
- /** Estimated discharge friction head, units ft */
43
- estimatedDischargeFrictionHead: number;
44
- /** Total pump head, units ft */
45
- pumpHead: number;
46
-
47
- /** Frees the underlying resource; must be called when finished with the instance */
48
- delete(): void;
49
- }
50
-
51
- /**
52
- * Head tool model for systems with a suction tank.
53
- */
54
- export declare class HeadToolSuctionTank {
55
- /**
56
- * @param specificGravity double, specific gravity, dimensionless (unitless)
57
- * @param flowRate double, flow rate in gpm
58
- * @param suctionPipeDiameter Suction pipe diameter, units ft.
59
- * @param suctionTankGasOverPressure double, suction tank gas over pressure in psig
60
- * @param suctionTankFluidSurfaceElevation double, suction tank fluid surface elevation in ft
61
- * @param suctionLineLossCoefficients double, suction line loss coefficients (unitless)
62
- * @param dischargePipeDiameter Discharge pipe diameter, units ft.
63
- * @param dischargeGaugePressure double, discharge gauge pressure in psig
64
- * @param dischargeGaugeElevation Discharge gauge elevation, units ft.
65
- * @param dischargeLineLossCoefficients double, discharge line loss coefficients (unitless)
66
- */
67
- constructor(
68
- specificGravity: number,
69
- flowRate: number,
70
- suctionPipeDiameter: number,
71
- suctionTankGasOverPressure: number,
72
- suctionTankFluidSurfaceElevation: number,
73
- suctionLineLossCoefficients: number,
74
- dischargePipeDiameter: number,
75
- dischargeGaugePressure: number,
76
- dischargeGaugeElevation: number,
77
- dischargeLineLossCoefficients: number
78
- );
79
-
80
- /**
81
- * Calculates the operating pump head
82
- * @returns HeadToolOutput
83
- */
84
- calculate(): HeadToolOutput;
85
-
86
- /** Frees the underlying resource; must be called when finished with the instance */
87
- delete(): void;
88
- }
89
-
90
- /**
91
- * Head tool model for systems without a suction tank.
92
- */
93
- export declare class HeadTool {
94
- /**
95
- * Constructor for HeadTool with no Suction Tank, all inputs specified
96
- *
97
- * @param specificGravity double, specific gravity, dimensionless - unitless
98
- * @param flowRate double, flow rate in gpm (gallons per minute)
99
- * @param suctionPipeDiameter double, diameter of suction pipe in feet
100
- * @param suctionGaugePressure double, gauge pressure of suction in psig (pounds per square inch guage)
101
- * @param suctionGaugeElevation double, gauge elevation of suction in feet
102
- * @param suctionLineLossCoefficients double, line loss coefficients of suction - unitless
103
- * @param dischargePipeDiameter double, diameter of discharge pipe in feet
104
- * @param dischargeGaugePressure double, gauge pressure of discharge in psig (pounds per square inch guage)
105
- * @param dischargeGaugeElevation double, gauge elevation of discharge in feet
106
- * @param dischargeLineLossCoefficients double, line loss coefficients of discharge - unitless
107
- *
108
- * */
109
- constructor(
110
- specificGravity: number,
111
- flowRate: number,
112
- suctionPipeDiameter: number,
113
- suctionGaugePressure: number,
114
- suctionGaugeElevation: number,
115
- suctionLineLossCoefficients: number,
116
- dischargePipeDiameter: number,
117
- dischargeGaugePressure: number,
118
- dischargeGaugeElevation: number,
119
- dischargeLineLossCoefficients: number
120
- );
121
-
122
- /**
123
- * Calculates the operating pump head
124
- * @returns HeadToolOutput
125
- */
126
- calculate(): HeadToolOutput;
127
-
128
- /** Frees the underlying resource; must be called when finished with the instance */
129
- delete(): void;
130
- }
131
-
132
11
  /**
133
12
  * Input parameters for pump result calculations.
134
13
  */
@@ -226,8 +105,8 @@ export declare class PumpResults {
226
105
  * @param motor_power_factor Motor power factor, dimensionless.
227
106
  * @param motor_current Motor current, units A.
228
107
  * @param motor_power Motor power, units kW.
229
- * @param annual_energy Annual energy, units kWh/year.
230
- * @param annual_cost Annual cost, units $/year.
108
+ * @param annual_energy Annual energy, units MWh/year.
109
+ * @param annual_cost Annual cost, units thousand dollars/year.
231
110
  * @param load_factor Load factor, dimensionless fraction.
232
111
  * @param drive_efficiency Drive efficiency, dimensionless fraction.
233
112
  */
@@ -262,9 +141,9 @@ export declare class PumpResults {
262
141
  motor_current: number;
263
142
  /** Motor power, units kW */
264
143
  motor_power: number;
265
- /** Annual energy, units kWh */
144
+ /** Annual energy, units MWh/year */
266
145
  annual_energy: number;
267
- /** Annual cost, units $ */
146
+ /** Annual cost, units thousand dollars/year */
268
147
  annual_cost: number;
269
148
  /** Load factor, dimensionless fraction. */
270
149
  load_factor: number;
@@ -320,9 +199,6 @@ export declare class PumpResult {
320
199
  }
321
200
 
322
201
  export type PumpModule = {
323
- HeadToolOutput: typeof HeadToolOutput;
324
- HeadToolSuctionTank: typeof HeadToolSuctionTank;
325
- HeadTool: typeof HeadTool;
326
202
  PumpResultInput: typeof PumpResultInput;
327
203
  PumpFieldData: typeof PumpFieldData;
328
204
  PumpResult: typeof PumpResult;
@@ -0,0 +1,97 @@
1
+ /**
2
+ * Inputs for pump-head calculation from suction- and discharge-gauge measurements.
3
+ * Gauge elevations refer to the centers of the gauges from a common datum and must correspond
4
+ * to the supplied pressure readings. For a reading corrected to another reference elevation,
5
+ * use that elevation instead.
6
+ */
7
+ export interface PumpHeadSuctionGaugeInput {
8
+ /** Fluid specific gravity, dimensionless. */
9
+ specificGravity: number;
10
+ /** Volumetric flow rate, units gpm. */
11
+ flowRate: number;
12
+ /** Pipe inside diameter at the suction pressure-measurement location, units in. */
13
+ suctionPipeDiameter: number;
14
+ /** Suction gauge pressure, units psig. */
15
+ suctionGaugePressure: number;
16
+ /** Elevation of the suction gauge center or corrected pressure reference from the common datum, units ft. */
17
+ suctionGaugeElevation: number;
18
+ /** Aggregate suction-line loss coefficient, dimensionless. */
19
+ suctionLineLossCoefficients: number;
20
+ /** Pipe inside diameter at the discharge pressure-measurement location, units in. */
21
+ dischargePipeDiameter: number;
22
+ /** Discharge gauge pressure, units psig. */
23
+ dischargeGaugePressure: number;
24
+ /** Elevation of the discharge gauge center or corrected pressure reference from the common datum, units ft. */
25
+ dischargeGaugeElevation: number;
26
+ /** Aggregate discharge-line loss coefficient, dimensionless. */
27
+ dischargeLineLossCoefficients: number;
28
+ }
29
+
30
+ /**
31
+ * Inputs for pump-head calculation with a pressurized suction tank.
32
+ * The suction elevation refers to the tank fluid surface. Discharge elevation refers to the
33
+ * gauge center, or the reference elevation to which the pressure reading has been corrected,
34
+ * measured from the same datum.
35
+ */
36
+ export interface PumpHeadSuctionTankInput {
37
+ /** Fluid specific gravity, dimensionless. */
38
+ specificGravity: number;
39
+ /** Volumetric flow rate, units gpm. */
40
+ flowRate: number;
41
+ /** Suction-pipe inside diameter used as the reference for suction-line losses, units in. */
42
+ suctionPipeDiameter: number;
43
+ /** Suction-tank gas overpressure, units psig. */
44
+ suctionTankGasOverPressure: number;
45
+ /** Suction-tank fluid-surface elevation from the common datum, units ft. */
46
+ suctionTankFluidSurfaceElevation: number;
47
+ /** Aggregate suction-line loss coefficient, dimensionless. */
48
+ suctionLineLossCoefficients: number;
49
+ /** Pipe inside diameter at the discharge pressure-measurement location, units in. */
50
+ dischargePipeDiameter: number;
51
+ /** Discharge gauge pressure, units psig. */
52
+ dischargeGaugePressure: number;
53
+ /** Elevation of the discharge gauge center or corrected pressure reference from the common datum, units ft. */
54
+ dischargeGaugeElevation: number;
55
+ /** Aggregate discharge-line loss coefficient, dimensionless. */
56
+ dischargeLineLossCoefficients: number;
57
+ }
58
+
59
+ /** Component heads and pump head returned as a plain object. */
60
+ export interface PumpHeadResult {
61
+ /** Discharge-minus-suction elevation head, units ft. */
62
+ differentialElevationHead: number;
63
+ /** Discharge-minus-suction pressure head, units ft. */
64
+ differentialPressureHead: number;
65
+ /** Discharge-minus-suction velocity head, units ft. */
66
+ differentialVelocityHead: number;
67
+ /** Estimated suction-line friction head, units ft. */
68
+ estimatedSuctionFrictionHead: number;
69
+ /** Estimated discharge-line friction head, units ft. */
70
+ estimatedDischargeFrictionHead: number;
71
+ /** Pump head, units ft. */
72
+ pumpHead: number;
73
+ }
74
+
75
+ /**
76
+ * Calculates pump head from suction- and discharge-gauge measurements.
77
+ * @param input Flow, pipe, pressure, elevation, and loss-coefficient inputs in U.S. customary units.
78
+ * @returns Component heads and pump head, units ft.
79
+ */
80
+ export declare function calculatePumpHeadFromSuctionGauge(
81
+ input: PumpHeadSuctionGaugeInput
82
+ ): PumpHeadResult;
83
+
84
+ /**
85
+ * Calculates pump head for a system supplied from a pressurized suction tank.
86
+ * @param input Flow, pipe, tank, discharge, and loss-coefficient inputs in U.S. customary units.
87
+ * @returns Component heads and pump head, units ft.
88
+ */
89
+ export declare function calculatePumpHeadFromSuctionTank(
90
+ input: PumpHeadSuctionTankInput
91
+ ): PumpHeadResult;
92
+
93
+ /** Runtime exports contributed by the pump-head binding. */
94
+ export type PumpHeadModule = {
95
+ calculatePumpHeadFromSuctionGauge: typeof calculatePumpHeadFromSuctionGauge;
96
+ calculatePumpHeadFromSuctionTank: typeof calculatePumpHeadFromSuctionTank;
97
+ };