measur-tools-suite 1.0.11-beta.99 → 1.0.12-beta.111

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/README.md CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  ## Update (08/25/2025)
4
4
 
5
- The MEASUR Tools Suite is currently undergoing a major update to improve usability and maintainability. This includes a refactoring of the codebase to follow consistent practices, better organization, and enhanced documentation around the engineering aspects of the calculations. To follow the progress of this update, please refer to the [Roadmap](ROADMAP.md). As the codebase is refactored, some Emscripten bindings will change. A summary of these changes can be found in the [Emscripten Bindings Changes](EMSCRIPTEN_BINDINGS_CHANGES.md) document.
5
+ The MEASUR Tools Suite is currently undergoing a major update to improve usability and maintainability. This includes a refactoring of the codebase to follow consistent practices, better organization, and enhanced documentation around the engineering aspects of the calculations. To follow the progress of this update, please refer to the [Roadmap](ROADMAP.md).
6
6
 
7
7
  ## About
8
8
 
@@ -65,8 +65,34 @@ The npm packages can be downloaded and install from [registry](https://www.npmjs
65
65
 
66
66
  MEASUR Tools Suite is distributed as a modularized WebAssembly Module. Below is an illustration of the WASM initialization and usage process:
67
67
 
68
- <!-- TODO: Replace with updated code snippet -->
69
- ![WASM Initialization](assets/wasm-initialization.png)
68
+ ```js
69
+ //initialize module
70
+ const moduleFactory = (await import('/path/to/client.js')).default;
71
+ toolsSuiteModule = await moduleFactory({
72
+ locateFile: (filename) => '/path/to/client.wasm'
73
+ });
74
+
75
+ const surfaceArea = 500;
76
+ const ambientTemperature = 80;
77
+ const surfaceTemperature = 225;
78
+ const windSpeed = 10;
79
+ const surfaceEmissivity = 0.9;
80
+ const shapeFactor = 1.394;
81
+ const correctionFactor = 1;
82
+
83
+ // Calculate total heat loss
84
+ const totalHeatLoss = toolsSuiteModule.wallTotalHeatLoss(
85
+ surfaceArea,
86
+ ambientTemperature,
87
+ surfaceTemperature,
88
+ windSpeed,
89
+ surfaceEmissivity,
90
+ shapeFactor,
91
+ correctionFactor);
92
+ ```
93
+
94
+
95
+
70
96
 
71
97
  ### WASM Unit Tests
72
98
 
package/bin/client.wasm CHANGED
Binary file
package/bin/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "measur-tools-suite",
3
- "version": "1.0.11-beta.99",
3
+ "version": "1.0.12-beta.111",
4
4
  "engines": {
5
5
  "node": "20.19.4",
6
6
  "npm": "10.8.2"
@@ -0,0 +1,46 @@
1
+ /**
2
+ * @defgroup atmosphere_heat_loss_calculator Atmosphere Heat Loss Calculator
3
+ * @ingroup heat_loss_calculators
4
+ * @brief Calculates heat losses from escaping atmospheric gases in process heating equipment.
5
+ * @details This calculator is used to estimate heat losses of process heating equipment due to the introduction of
6
+ * atmospheric gases (e.g., nitrogen, hydrogen, etc.). These gases absorb heat from the equipment and carry it away when
7
+ * they exit the system. The calculator computes the total heat loss based on the flow rate, specific heat of the gas,
8
+ * inlet and outlet temperatures, and a correction factor @cite trinks2003industrial. Relevant formulas and values are
9
+ * documented below.
10
+ *
11
+ * @heading{Heat Loss}
12
+ * @copydoc atmosphere_heat_loss_formula
13
+ *
14
+ * @heading{Specific Heat Values}
15
+ * @copydoc atmosphere_specific_heat_values
16
+ */
17
+
18
+ /**
19
+ * @defgroup atmosphere_heat_loss_formula Atmosphere Heat Loss Formula
20
+ * @ingroup atmosphere_heat_loss_calculator
21
+ * @formula{atmosphere-heat-loss; Q = \dot{v} \cdot c_p \cdot (T_\text{out} - T_\text{in}) \cdot
22
+ * f_\text{corr}}
23
+ * @subheading{Symbols}
24
+ * @symtable
25
+ * @symrow{Q; Heat loss; \btu\per\hour}
26
+ * @symrow{\dot{v}; Flow rate of gas; \standardCubicFeet\per\hour}
27
+ * @symrow{c_p; Specific heat of gas; \btu\per\standardCubicFeet\degreeFahrenheit}
28
+ * @symrow{T_\text{out}; Outlet temperature of gas; \degreeFahrenheit}
29
+ * @symrow{T_\text{in}; %Inlet temperature of gas; \degreeFahrenheit}
30
+ * @symrow{f_\text{corr}; Correction factor; \unitless}
31
+ * @endsymtable
32
+ */
33
+
34
+ /**
35
+ * @defgroup atmosphere_specific_heat_values Atmosphere Specific Heat Values
36
+ * @ingroup atmosphere_heat_loss_calculator
37
+ * Reference temperature: @qty{60; \degreeFahrenheit}
38
+ * | Gas Type | Specific Heat @unitb{\btu\per\standardCubicFeet\degreeFahrenheit} |
39
+ * | --------------- | ----------------------------------------------------------------- |
40
+ * | Nitrogen | 0.0185 |
41
+ * | Hydrogen | 0.0182 |
42
+ * | Exothermic Gas | 0.0185 |
43
+ * | Endothermic Gas | 0.0185 |
44
+ * | Air | 0.0184 |
45
+ * | Water Vapor | 0.0212 |
46
+ */
@@ -0,0 +1,4 @@
1
+ /**
2
+ * @defgroup leakage_heat_loss_calculator Leakage Heat Loss Calculator
3
+ * @ingroup heat_loss_calculators
4
+ */
@@ -0,0 +1,4 @@
1
+ /**
2
+ * @defgroup opening_heat_loss_calculator Opening Heat Loss Calculator
3
+ * @ingroup heat_loss_calculators
4
+ */
@@ -1,10 +1,14 @@
1
1
  /**
2
2
  * @defgroup wall_heat_loss_calculator Wall Heat Loss Calculator
3
3
  * @ingroup heat_loss_calculators
4
- * @brief Calculates heat losses from walls in industrial settings.
5
- * @details The Wall Heat Loss Calculator is used to estimate heat losses from walls in industrial settings. The
6
- * calculator computes the total heat loss as the sum of convective and radiative heat losses, adjusted by a correction
7
- * factor. Relevant formulas and factors are documented below.
4
+ * @brief Calculates heat losses from walls of process heating equipment to the ambient.
5
+ * @details This calculator can be used to calculate fuel savings from improving wall insulation or otherwise reduce
6
+ * heat lost through the walls. Wall losses occur as heat is transferred from the outer surface of the walls or casing
7
+ * of process heating equipment to the surrounding environment. This can occur via convection and radiation. Wall losses
8
+ * are high for systems that are poorly insulated or use poorly designed materials or surfaces. The calculator computes
9
+ * the total heat loss as the sum of convective and radiative heat losses, adjusted by a correction factor. Relevant
10
+ * formulas and factors are documented below. Heat losses due to openings in the unit are covered by the
11
+ * @ref opening_heat_loss_calculator, @ref leakage_heat_loss_calculator, or @ref atmosphere_heat_loss_calculator.
8
12
  *
9
13
  * @heading{Total Heat Loss}
10
14
  * @copydoc wall_total_heat_loss_formula
@@ -30,7 +34,9 @@
30
34
  * @symrow{Q_\text{rad}; Radiative heat loss; \btu\per\hour}
31
35
  * @symrow{f_\text{corr}; Correction factor; \unitless}
32
36
  * @endsymtable
33
- *
37
+ */
38
+
39
+ /**
34
40
  * @defgroup wall_convective_heat_loss_formula Wall Convective Heat Loss Formula
35
41
  * @ingroup wall_heat_loss_calculator
36
42
  * @formula{wall-qconv; Q_\text{conv} = h A \Delta T}
@@ -60,7 +66,9 @@
60
66
  * @symrow{T_s; Surface temperature; \degreeFahrenheit}
61
67
  * @symrow{T_a; Ambient temperature; \degreeFahrenheit}
62
68
  * @endsymtable
63
- *
69
+ */
70
+
71
+ /**
64
72
  * @defgroup wall_radiative_heat_loss_formula Wall Radiative Heat Loss Formula
65
73
  * @ingroup wall_heat_loss_calculator
66
74
  * @formula{wall-qrad; Q_\text{rad} = \varepsilon \sigma A (T_s^4 - T_a^4)}
@@ -74,17 +82,19 @@
74
82
  * @symrow{T_s; Surface temperature; \degreeRankine}
75
83
  * @symrow{T_a; Ambient temperature; \degreeRankine}
76
84
  * @endsymtable
77
- *
78
- * @defgroup shape_factors Shape Factors
85
+ */
86
+
87
+ /**
88
+ * @defgroup wall_shape_factors Wall Shape Factors
79
89
  * @ingroup wall_heat_loss_calculator
80
- * | Surface Configuration | Value @unitb{\unitless} |
81
- * |-----------------------------------------------|-------------------------|
82
- * | Horizontal cylinders | 1.016 |
83
- * | Longer vertical cylinders | 1.235 |
84
- * | Vertical plates | 1.394 |
85
- * | Horizontal plate facing up, warmer than air | 1.79 |
86
- * | Horizontal plate facing down, warmer than air | 0.89 |
87
- * | Horizontal plate facing up, cooler than air | 0.89 |
88
- * | Horizontal plate facing down, cooler than air | 1.79 |
90
+ * | Wall Type | Shape Factor @unitb{\unitless} |
91
+ * |-----------------------------------------------|--------------------------------|
92
+ * | Horizontal cylinders | 1.016 |
93
+ * | Longer vertical cylinders | 1.235 |
94
+ * | Vertical plates | 1.394 |
95
+ * | Horizontal plate facing up, warmer than air | 1.79 |
96
+ * | Horizontal plate facing down, warmer than air | 0.89 |
97
+ * | Horizontal plate facing up, cooler than air | 0.89 |
98
+ * | Horizontal plate facing down, cooler than air | 1.79 |
89
99
  * Source: @cite astmC680
90
100
  */
@@ -80,6 +80,9 @@ window.MathJax = {
80
80
 
81
81
  \DeclareSIUnit{\percent}{\%}
82
82
  \DeclareSIUnit{\unitless}{-}
83
+
84
+ \DeclareSIUnit{\standardCubicFeet}{scf}
85
+ \DeclareSIUnit{\scf}{scf}
83
86
  `);
84
87
  }
85
88
  },
@@ -16,4 +16,12 @@
16
16
  url={https://books.google.com/books?id=9-VQPgAACAAJ},
17
17
  year={2007},
18
18
  publisher={Taylor \& Francis}
19
+ }
20
+
21
+ @book{trinks2003industrial,
22
+ title={Industrial furnaces},
23
+ author={Trinks, Willibald and Mawhinney, Matthew Holmes and Shannon, RA and Reed, RJ and Garvey, JR},
24
+ volume={1},
25
+ year={2003},
26
+ publisher={John Wiley \& Sons}
19
27
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "measur-tools-suite",
3
- "version": "1.0.11-beta.99",
3
+ "version": "1.0.12-beta.111",
4
4
  "engines": {
5
5
  "node": "20.19.4",
6
6
  "npm": "10.8.2"
@@ -1,19 +0,0 @@
1
- # Emscripten Bindings Changes
2
-
3
- The following table summarizes the changes made to the Emscripten bindings in the MEASUR Tools Suite. These changes are part of an ongoing effort to improve the usability and maintainability of the codebase.
4
-
5
- ## WallLosses class
6
-
7
- The `WallLosses` class has been refactored into a namespace called `wall_heat_loss` with many methoids being removed or renamed. The following table outlines the updated emscripten bindings:
8
-
9
- | Current Signature | Previous Signature | Notes |
10
- | -------------------------------- | ------------------ | --------------------------------------------------------------------- |
11
- | totalHeatLoss | getHeatLoss | Renamed |
12
- | convectiveHeatLoss | --- | New standalone method to calculate convective heat loss. |
13
- | radiativeHeatLoss | --- | New standalone method to calculate radiative heat loss. |
14
- | ShapeFactor | --- | New Struct that holds shape factor data (description & factor value). |
15
- | ShapeFactor.surfaceConfiguration | surfaceDescription | New field in ShapeFactor struct that holds the description. |
16
- | ShapeFactor.value | shapeFactor | New field in ShapeFactor struct that holds the factor value. |
17
- | shapeFactors | --- | New method that returns a vector of ShapeFactor structs. |
18
-
19
- See `wasm_wall_heat_loss.test.js` for usage examples.
Binary file