@dnv-plant/typescriptpws 1.0.97 → 1.0.98-alpha.2397542
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/LICENSE +1 -1
- package/azure-test-job.yml +25 -0
- package/index.ts +18 -13
- package/package.json +2 -1
- package/src/calculations/applicationTools.ts +16 -12
- package/src/calculations/calculationBase.ts +40 -13
- package/src/calculations/discharge.ts +752 -109
- package/src/calculations/dispersion.ts +17 -15
- package/src/calculations/dispersionView.ts +31 -27
- package/src/calculations/fireball.ts +17 -13
- package/src/calculations/flammableWorkflow.ts +291 -0
- package/src/calculations/jetFire.ts +19 -22
- package/src/calculations/lateExplosion.ts +16 -12
- package/src/calculations/linkedRunners.ts +2715 -780
- package/src/calculations/poolFire.ts +16 -12
- package/src/calculations/properties.ts +17 -14
- package/src/calculations/radiation.ts +65 -61
- package/src/calculations/standalones.ts +16 -12
- package/src/calculations/toxics.ts +17 -13
- package/src/calculations/utilities.ts +673 -23
- package/src/constants.ts +25 -15
- package/src/entities.ts +455 -320
- package/src/entity-schemas.ts +284 -148
- package/src/enums.ts +123 -64
- package/src/materials.ts +152 -152
- package/src/utilities.ts +40 -27
|
@@ -1,15 +1,19 @@
|
|
|
1
|
-
|
|
2
|
-
*
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
|
|
1
|
+
// ************************************************************************************
|
|
2
|
+
// *
|
|
3
|
+
// * This file has been auto-generated by a code generation tool.
|
|
4
|
+
// *
|
|
5
|
+
// * DO NOT MODIFY THIS FILE
|
|
6
|
+
// * This file is maintained by DNV.
|
|
7
|
+
// * Editing it may lead to inconsistent results and limit DNV's ability to provide support.
|
|
8
|
+
// * Please contact DNV if you believe changes are required.
|
|
9
|
+
// *
|
|
10
|
+
// * API version: 1.0.
|
|
11
|
+
// * MDE version: 9.3.8211.
|
|
12
|
+
// * Package version: 1.0.98
|
|
13
|
+
// * Date/time: 23 Jun 2026 12:11:11.
|
|
14
|
+
// * Template: TYPE_SCRIPT_PWS/calculations.sbn.
|
|
15
|
+
// *
|
|
16
|
+
// ************************************************************************************
|
|
13
17
|
|
|
14
18
|
import * as Enums from '../enums';
|
|
15
19
|
import * as Entities from '../entities';
|
|
@@ -1,15 +1,19 @@
|
|
|
1
|
-
|
|
2
|
-
*
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
|
|
1
|
+
// ************************************************************************************
|
|
2
|
+
// *
|
|
3
|
+
// * This file has been auto-generated by a code generation tool.
|
|
4
|
+
// *
|
|
5
|
+
// * DO NOT MODIFY THIS FILE
|
|
6
|
+
// * This file is maintained by DNV.
|
|
7
|
+
// * Editing it may lead to inconsistent results and limit DNV's ability to provide support.
|
|
8
|
+
// * Please contact DNV if you believe changes are required.
|
|
9
|
+
// *
|
|
10
|
+
// * API version: 1.0.
|
|
11
|
+
// * MDE version: 9.3.8211.
|
|
12
|
+
// * Package version: 1.0.98
|
|
13
|
+
// * Date/time: 23 Jun 2026 12:11:11.
|
|
14
|
+
// * Template: TYPE_SCRIPT_PWS/calculations.sbn.
|
|
15
|
+
// *
|
|
16
|
+
// ************************************************************************************
|
|
13
17
|
|
|
14
18
|
import * as Enums from '../enums';
|
|
15
19
|
import * as Entities from '../entities';
|
|
@@ -77,8 +81,7 @@ export class FlashCalculation extends CalculationBase {
|
|
|
77
81
|
flashResult?: Entities.FlashResult;
|
|
78
82
|
|
|
79
83
|
/**
|
|
80
|
-
* Calculates fluid properties for a user-defined material where the user has defined the pressure and temperature or pressure and liquid fraction. The model carries out a flash calculation
|
|
81
|
-
to obtain the fluid properties.
|
|
84
|
+
* Calculates fluid properties for a user-defined material where the user has defined the pressure and temperature or pressure and liquid fraction. The model carries out a flash calculation to obtain the fluid properties.
|
|
82
85
|
*
|
|
83
86
|
*/
|
|
84
87
|
constructor(data: { material: Entities.Material; materialState: Entities.State; controller?: AbortController }) {
|
|
@@ -1,15 +1,19 @@
|
|
|
1
|
-
|
|
2
|
-
*
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
|
|
1
|
+
// ************************************************************************************
|
|
2
|
+
// *
|
|
3
|
+
// * This file has been auto-generated by a code generation tool.
|
|
4
|
+
// *
|
|
5
|
+
// * DO NOT MODIFY THIS FILE
|
|
6
|
+
// * This file is maintained by DNV.
|
|
7
|
+
// * Editing it may lead to inconsistent results and limit DNV's ability to provide support.
|
|
8
|
+
// * Please contact DNV if you believe changes are required.
|
|
9
|
+
// *
|
|
10
|
+
// * API version: 1.0.
|
|
11
|
+
// * MDE version: 9.3.8211.
|
|
12
|
+
// * Package version: 1.0.98
|
|
13
|
+
// * Date/time: 23 Jun 2026 12:11:11.
|
|
14
|
+
// * Template: TYPE_SCRIPT_PWS/calculations.sbn.
|
|
15
|
+
// *
|
|
16
|
+
// ************************************************************************************
|
|
13
17
|
|
|
14
18
|
import * as Enums from '../enums';
|
|
15
19
|
import * as Entities from '../entities';
|
|
@@ -113,12 +117,12 @@ export class DistancesAndEllipsesToRadiationLevelsCalculation extends Calculatio
|
|
|
113
117
|
flammableOutputConfigs: Entities.FlammableOutputConfig[];
|
|
114
118
|
flammableOutputConfigCount: number;
|
|
115
119
|
distances?: number[];
|
|
116
|
-
contourPoints?: Entities.LocalPosition[];
|
|
117
120
|
nContourPoints?: number[];
|
|
118
121
|
areas?: number[];
|
|
122
|
+
contourPoints?: Entities.LocalPosition[];
|
|
119
123
|
|
|
120
124
|
/**
|
|
121
|
-
* Calculates the distances and ellipses to specified radiation intensity levels from a flame model. This calculation can be called after fireball and jet fire
|
|
125
|
+
* Calculates the distances and ellipses to specified radiation intensity levels from a flame model. This calculation can be called after fireball and jet fire calculations.
|
|
122
126
|
*
|
|
123
127
|
*/
|
|
124
128
|
constructor(data: {
|
|
@@ -170,9 +174,9 @@ export class DistancesAndEllipsesToRadiationLevelsCalculation extends Calculatio
|
|
|
170
174
|
if (this.resultCode === Enums.ResultCode.SUCCESS) {
|
|
171
175
|
Object.assign(this, {
|
|
172
176
|
distances: validatedResponse.distances,
|
|
173
|
-
contourPoints: validatedResponse.contourPoints,
|
|
174
177
|
nContourPoints: validatedResponse.nContourPoints,
|
|
175
178
|
areas: validatedResponse.areas,
|
|
179
|
+
contourPoints: validatedResponse.contourPoints,
|
|
176
180
|
resultCode: validatedResponse.resultCode,
|
|
177
181
|
messages: validatedResponse.messages ?? [],
|
|
178
182
|
calculationElapsedTime: validatedResponse.calculationElapsedTime,
|
|
@@ -198,14 +202,14 @@ export class DistancesAndEllipsesToRadiationLevelsCalculation extends Calculatio
|
|
|
198
202
|
|
|
199
203
|
parts.push('*** distances:');
|
|
200
204
|
parts.push(this.distances && this.distances.length > 0 ? this.distances.map((point) => `distancesElement: ${point}`).join('\n') : 'distances does not contain any elements');
|
|
201
|
-
parts.push('*** contourPoints:');
|
|
202
|
-
parts.push(this.contourPoints && this.contourPoints.length > 0 ? this.contourPoints.map((point) => `contourPointsElement: ${point}`).join('\n') : 'contourPoints does not contain any elements');
|
|
203
205
|
parts.push('*** nContourPoints:');
|
|
204
206
|
parts.push(
|
|
205
207
|
this.nContourPoints && this.nContourPoints.length > 0 ? this.nContourPoints.map((point) => `nContourPointsElement: ${point}`).join('\n') : 'nContourPoints does not contain any elements',
|
|
206
208
|
);
|
|
207
209
|
parts.push('*** areas:');
|
|
208
210
|
parts.push(this.areas && this.areas.length > 0 ? this.areas.map((point) => `areasElement: ${point}`).join('\n') : 'areas does not contain any elements');
|
|
211
|
+
parts.push('*** contourPoints:');
|
|
212
|
+
parts.push(this.contourPoints && this.contourPoints.length > 0 ? this.contourPoints.map((point) => `contourPointsElement: ${point}`).join('\n') : 'contourPoints does not contain any elements');
|
|
209
213
|
parts.push(`resultCode: ${String(this.resultCode)}`);
|
|
210
214
|
parts.push('*** messages:');
|
|
211
215
|
parts.push(`messages: ${this.messages !== undefined ? this.messages : '(None)'}`);
|
|
@@ -218,9 +222,9 @@ export class DistancesAndEllipsesToRadiationLevelsCalculation extends Calculatio
|
|
|
218
222
|
|
|
219
223
|
export class DistancesAndEllipsesToRadiationLevelsCalculationResponse extends CalculationResponseBase {
|
|
220
224
|
distances: number[];
|
|
221
|
-
contourPoints: Entities.LocalPosition[];
|
|
222
225
|
nContourPoints: number[];
|
|
223
226
|
areas: number[];
|
|
227
|
+
contourPoints: Entities.LocalPosition[];
|
|
224
228
|
|
|
225
229
|
/**
|
|
226
230
|
* DistancesAndEllipsesToRadiationLevels calculation response class.
|
|
@@ -228,9 +232,9 @@ export class DistancesAndEllipsesToRadiationLevelsCalculationResponse extends Ca
|
|
|
228
232
|
*/
|
|
229
233
|
constructor(data: {
|
|
230
234
|
distances: number[];
|
|
231
|
-
contourPoints: Entities.LocalPosition[];
|
|
232
235
|
nContourPoints: number[];
|
|
233
236
|
areas: number[];
|
|
237
|
+
contourPoints: Entities.LocalPosition[];
|
|
234
238
|
resultCode: Enums.ResultCode;
|
|
235
239
|
messages: string[];
|
|
236
240
|
calculationElapsedTime: number;
|
|
@@ -238,9 +242,9 @@ export class DistancesAndEllipsesToRadiationLevelsCalculationResponse extends Ca
|
|
|
238
242
|
}) {
|
|
239
243
|
super();
|
|
240
244
|
this.distances = data.distances;
|
|
241
|
-
this.contourPoints = data.contourPoints;
|
|
242
245
|
this.nContourPoints = data.nContourPoints;
|
|
243
246
|
this.areas = data.areas;
|
|
247
|
+
this.contourPoints = data.contourPoints;
|
|
244
248
|
this.resultCode = data.resultCode;
|
|
245
249
|
this.messages = data.messages;
|
|
246
250
|
this.calculationElapsedTime = data.calculationElapsedTime;
|
|
@@ -248,8 +252,14 @@ export class DistancesAndEllipsesToRadiationLevelsCalculationResponse extends Ca
|
|
|
248
252
|
}
|
|
249
253
|
|
|
250
254
|
initialiseFromDictionary(data: { [key: string]: unknown }) {
|
|
251
|
-
if (data.distances && Array.isArray(data.distances)) {
|
|
252
|
-
this.distances = data.distances
|
|
255
|
+
if (data.distances !== undefined && Array.isArray(data.distances)) {
|
|
256
|
+
this.distances = data.distances as number[];
|
|
257
|
+
}
|
|
258
|
+
if (data.nContourPoints !== undefined && Array.isArray(data.nContourPoints)) {
|
|
259
|
+
this.nContourPoints = data.nContourPoints as number[];
|
|
260
|
+
}
|
|
261
|
+
if (data.areas !== undefined && Array.isArray(data.areas)) {
|
|
262
|
+
this.areas = data.areas as number[];
|
|
253
263
|
}
|
|
254
264
|
if (data.contourPoints && Array.isArray(data.contourPoints)) {
|
|
255
265
|
this.contourPoints = data.contourPoints.map((item) => {
|
|
@@ -258,12 +268,6 @@ export class DistancesAndEllipsesToRadiationLevelsCalculationResponse extends Ca
|
|
|
258
268
|
return record;
|
|
259
269
|
});
|
|
260
270
|
}
|
|
261
|
-
if (data.nContourPoints && Array.isArray(data.nContourPoints)) {
|
|
262
|
-
this.nContourPoints = data.nContourPoints.map((item) => parseInt(item));
|
|
263
|
-
}
|
|
264
|
-
if (data.areas && Array.isArray(data.areas)) {
|
|
265
|
-
this.areas = data.areas.map((item) => parseFloat(item));
|
|
266
|
-
}
|
|
267
271
|
if (data.resultCode !== undefined && (typeof data.resultCode === 'string' || typeof data.resultCode === 'number')) {
|
|
268
272
|
this.resultCode = data.resultCode as Enums.ResultCode;
|
|
269
273
|
}
|
|
@@ -282,9 +286,9 @@ export class DistancesAndEllipsesToRadiationLevelsCalculationResponse extends Ca
|
|
|
282
286
|
|
|
283
287
|
export interface DistancesAndEllipsesToRadiationLevelsCalculationResponseSchemaData {
|
|
284
288
|
distances: number[];
|
|
285
|
-
contourPoints: Entities.LocalPosition[];
|
|
286
289
|
nContourPoints: number[];
|
|
287
290
|
areas: number[];
|
|
291
|
+
contourPoints: Entities.LocalPosition[];
|
|
288
292
|
resultCode: Enums.ResultCode;
|
|
289
293
|
messages: string[];
|
|
290
294
|
calculationElapsedTime: number;
|
|
@@ -301,9 +305,9 @@ export class DistancesAndEllipsesToRadiationLevelsCalculationResponseSchema {
|
|
|
301
305
|
constructor() {
|
|
302
306
|
this.schema = Joi.object({
|
|
303
307
|
distances: Joi.array().items(Joi.number().unsafe()).allow(null),
|
|
304
|
-
contourPoints: Joi.array().items(new EntitySchemas.LocalPositionSchema().schema).allow(null),
|
|
305
308
|
nContourPoints: Joi.array().items(Joi.number().integer()).allow(null),
|
|
306
309
|
areas: Joi.array().items(Joi.number().unsafe()).allow(null),
|
|
310
|
+
contourPoints: Joi.array().items(new EntitySchemas.LocalPositionSchema().schema).allow(null),
|
|
307
311
|
resultCode: Joi.string().valid(...Object.values(Enums.ResultCode)),
|
|
308
312
|
messages: Joi.array().items(Joi.string()),
|
|
309
313
|
calculationElapsedTime: Joi.number().unsafe(),
|
|
@@ -312,9 +316,9 @@ export class DistancesAndEllipsesToRadiationLevelsCalculationResponseSchema {
|
|
|
312
316
|
|
|
313
317
|
this.propertyTypes = {
|
|
314
318
|
distances: 'number[]',
|
|
315
|
-
contourPoints: 'Entities.LocalPosition[]',
|
|
316
319
|
nContourPoints: 'number[]',
|
|
317
320
|
areas: 'number[]',
|
|
321
|
+
contourPoints: 'Entities.LocalPosition[]',
|
|
318
322
|
};
|
|
319
323
|
}
|
|
320
324
|
|
|
@@ -425,12 +429,12 @@ export class DistancesAndEllipsesToRadiationLevelsForPoolFiresCalculation extend
|
|
|
425
429
|
flammableOutputConfigs: Entities.FlammableOutputConfig[];
|
|
426
430
|
flammableOutputConfigCount: number;
|
|
427
431
|
distances?: number[];
|
|
428
|
-
contourPoints?: Entities.LocalPosition[];
|
|
429
432
|
nContourPoints?: number[];
|
|
430
433
|
areas?: number[];
|
|
434
|
+
contourPoints?: Entities.LocalPosition[];
|
|
431
435
|
|
|
432
436
|
/**
|
|
433
|
-
* Calculates the distances and ellipses to specified radiation intensity levels from a flame model.
|
|
437
|
+
* Calculates the distances and ellipses to specified radiation intensity levels from a flame model. This calculation can be called after pool fire calculations.
|
|
434
438
|
*
|
|
435
439
|
*/
|
|
436
440
|
constructor(data: {
|
|
@@ -482,9 +486,9 @@ export class DistancesAndEllipsesToRadiationLevelsForPoolFiresCalculation extend
|
|
|
482
486
|
if (this.resultCode === Enums.ResultCode.SUCCESS) {
|
|
483
487
|
Object.assign(this, {
|
|
484
488
|
distances: validatedResponse.distances,
|
|
485
|
-
contourPoints: validatedResponse.contourPoints,
|
|
486
489
|
nContourPoints: validatedResponse.nContourPoints,
|
|
487
490
|
areas: validatedResponse.areas,
|
|
491
|
+
contourPoints: validatedResponse.contourPoints,
|
|
488
492
|
resultCode: validatedResponse.resultCode,
|
|
489
493
|
messages: validatedResponse.messages ?? [],
|
|
490
494
|
calculationElapsedTime: validatedResponse.calculationElapsedTime,
|
|
@@ -510,14 +514,14 @@ export class DistancesAndEllipsesToRadiationLevelsForPoolFiresCalculation extend
|
|
|
510
514
|
|
|
511
515
|
parts.push('*** distances:');
|
|
512
516
|
parts.push(this.distances && this.distances.length > 0 ? this.distances.map((point) => `distancesElement: ${point}`).join('\n') : 'distances does not contain any elements');
|
|
513
|
-
parts.push('*** contourPoints:');
|
|
514
|
-
parts.push(this.contourPoints && this.contourPoints.length > 0 ? this.contourPoints.map((point) => `contourPointsElement: ${point}`).join('\n') : 'contourPoints does not contain any elements');
|
|
515
517
|
parts.push('*** nContourPoints:');
|
|
516
518
|
parts.push(
|
|
517
519
|
this.nContourPoints && this.nContourPoints.length > 0 ? this.nContourPoints.map((point) => `nContourPointsElement: ${point}`).join('\n') : 'nContourPoints does not contain any elements',
|
|
518
520
|
);
|
|
519
521
|
parts.push('*** areas:');
|
|
520
522
|
parts.push(this.areas && this.areas.length > 0 ? this.areas.map((point) => `areasElement: ${point}`).join('\n') : 'areas does not contain any elements');
|
|
523
|
+
parts.push('*** contourPoints:');
|
|
524
|
+
parts.push(this.contourPoints && this.contourPoints.length > 0 ? this.contourPoints.map((point) => `contourPointsElement: ${point}`).join('\n') : 'contourPoints does not contain any elements');
|
|
521
525
|
parts.push(`resultCode: ${String(this.resultCode)}`);
|
|
522
526
|
parts.push('*** messages:');
|
|
523
527
|
parts.push(`messages: ${this.messages !== undefined ? this.messages : '(None)'}`);
|
|
@@ -530,9 +534,9 @@ export class DistancesAndEllipsesToRadiationLevelsForPoolFiresCalculation extend
|
|
|
530
534
|
|
|
531
535
|
export class DistancesAndEllipsesToRadiationLevelsForPoolFiresCalculationResponse extends CalculationResponseBase {
|
|
532
536
|
distances: number[];
|
|
533
|
-
contourPoints: Entities.LocalPosition[];
|
|
534
537
|
nContourPoints: number[];
|
|
535
538
|
areas: number[];
|
|
539
|
+
contourPoints: Entities.LocalPosition[];
|
|
536
540
|
|
|
537
541
|
/**
|
|
538
542
|
* DistancesAndEllipsesToRadiationLevelsForPoolFires calculation response class.
|
|
@@ -540,9 +544,9 @@ export class DistancesAndEllipsesToRadiationLevelsForPoolFiresCalculationRespons
|
|
|
540
544
|
*/
|
|
541
545
|
constructor(data: {
|
|
542
546
|
distances: number[];
|
|
543
|
-
contourPoints: Entities.LocalPosition[];
|
|
544
547
|
nContourPoints: number[];
|
|
545
548
|
areas: number[];
|
|
549
|
+
contourPoints: Entities.LocalPosition[];
|
|
546
550
|
resultCode: Enums.ResultCode;
|
|
547
551
|
messages: string[];
|
|
548
552
|
calculationElapsedTime: number;
|
|
@@ -550,9 +554,9 @@ export class DistancesAndEllipsesToRadiationLevelsForPoolFiresCalculationRespons
|
|
|
550
554
|
}) {
|
|
551
555
|
super();
|
|
552
556
|
this.distances = data.distances;
|
|
553
|
-
this.contourPoints = data.contourPoints;
|
|
554
557
|
this.nContourPoints = data.nContourPoints;
|
|
555
558
|
this.areas = data.areas;
|
|
559
|
+
this.contourPoints = data.contourPoints;
|
|
556
560
|
this.resultCode = data.resultCode;
|
|
557
561
|
this.messages = data.messages;
|
|
558
562
|
this.calculationElapsedTime = data.calculationElapsedTime;
|
|
@@ -560,8 +564,14 @@ export class DistancesAndEllipsesToRadiationLevelsForPoolFiresCalculationRespons
|
|
|
560
564
|
}
|
|
561
565
|
|
|
562
566
|
initialiseFromDictionary(data: { [key: string]: unknown }) {
|
|
563
|
-
if (data.distances && Array.isArray(data.distances)) {
|
|
564
|
-
this.distances = data.distances
|
|
567
|
+
if (data.distances !== undefined && Array.isArray(data.distances)) {
|
|
568
|
+
this.distances = data.distances as number[];
|
|
569
|
+
}
|
|
570
|
+
if (data.nContourPoints !== undefined && Array.isArray(data.nContourPoints)) {
|
|
571
|
+
this.nContourPoints = data.nContourPoints as number[];
|
|
572
|
+
}
|
|
573
|
+
if (data.areas !== undefined && Array.isArray(data.areas)) {
|
|
574
|
+
this.areas = data.areas as number[];
|
|
565
575
|
}
|
|
566
576
|
if (data.contourPoints && Array.isArray(data.contourPoints)) {
|
|
567
577
|
this.contourPoints = data.contourPoints.map((item) => {
|
|
@@ -570,12 +580,6 @@ export class DistancesAndEllipsesToRadiationLevelsForPoolFiresCalculationRespons
|
|
|
570
580
|
return record;
|
|
571
581
|
});
|
|
572
582
|
}
|
|
573
|
-
if (data.nContourPoints && Array.isArray(data.nContourPoints)) {
|
|
574
|
-
this.nContourPoints = data.nContourPoints.map((item) => parseInt(item));
|
|
575
|
-
}
|
|
576
|
-
if (data.areas && Array.isArray(data.areas)) {
|
|
577
|
-
this.areas = data.areas.map((item) => parseFloat(item));
|
|
578
|
-
}
|
|
579
583
|
if (data.resultCode !== undefined && (typeof data.resultCode === 'string' || typeof data.resultCode === 'number')) {
|
|
580
584
|
this.resultCode = data.resultCode as Enums.ResultCode;
|
|
581
585
|
}
|
|
@@ -594,9 +598,9 @@ export class DistancesAndEllipsesToRadiationLevelsForPoolFiresCalculationRespons
|
|
|
594
598
|
|
|
595
599
|
export interface DistancesAndEllipsesToRadiationLevelsForPoolFiresCalculationResponseSchemaData {
|
|
596
600
|
distances: number[];
|
|
597
|
-
contourPoints: Entities.LocalPosition[];
|
|
598
601
|
nContourPoints: number[];
|
|
599
602
|
areas: number[];
|
|
603
|
+
contourPoints: Entities.LocalPosition[];
|
|
600
604
|
resultCode: Enums.ResultCode;
|
|
601
605
|
messages: string[];
|
|
602
606
|
calculationElapsedTime: number;
|
|
@@ -613,9 +617,9 @@ export class DistancesAndEllipsesToRadiationLevelsForPoolFiresCalculationRespons
|
|
|
613
617
|
constructor() {
|
|
614
618
|
this.schema = Joi.object({
|
|
615
619
|
distances: Joi.array().items(Joi.number().unsafe()).allow(null),
|
|
616
|
-
contourPoints: Joi.array().items(new EntitySchemas.LocalPositionSchema().schema).allow(null),
|
|
617
620
|
nContourPoints: Joi.array().items(Joi.number().integer()).allow(null),
|
|
618
621
|
areas: Joi.array().items(Joi.number().unsafe()).allow(null),
|
|
622
|
+
contourPoints: Joi.array().items(new EntitySchemas.LocalPositionSchema().schema).allow(null),
|
|
619
623
|
resultCode: Joi.string().valid(...Object.values(Enums.ResultCode)),
|
|
620
624
|
messages: Joi.array().items(Joi.string()),
|
|
621
625
|
calculationElapsedTime: Joi.number().unsafe(),
|
|
@@ -624,9 +628,9 @@ export class DistancesAndEllipsesToRadiationLevelsForPoolFiresCalculationRespons
|
|
|
624
628
|
|
|
625
629
|
this.propertyTypes = {
|
|
626
630
|
distances: 'number[]',
|
|
627
|
-
contourPoints: 'Entities.LocalPosition[]',
|
|
628
631
|
nContourPoints: 'number[]',
|
|
629
632
|
areas: 'number[]',
|
|
633
|
+
contourPoints: 'Entities.LocalPosition[]',
|
|
630
634
|
};
|
|
631
635
|
}
|
|
632
636
|
|
|
@@ -739,7 +743,7 @@ export class DistancesToRadiationLevelsCalculation extends CalculationBase {
|
|
|
739
743
|
distances?: number[];
|
|
740
744
|
|
|
741
745
|
/**
|
|
742
|
-
* Calculates the distances to specified radiation intensity levels from a flame model.
|
|
746
|
+
* Calculates the distances to specified radiation intensity levels from a flame model. This calculation can be called after any type of fire calculation (fireball, jet fire, pool fire).
|
|
743
747
|
*
|
|
744
748
|
*/
|
|
745
749
|
constructor(data: {
|
|
@@ -843,8 +847,8 @@ export class DistancesToRadiationLevelsCalculationResponse extends CalculationRe
|
|
|
843
847
|
}
|
|
844
848
|
|
|
845
849
|
initialiseFromDictionary(data: { [key: string]: unknown }) {
|
|
846
|
-
if (data.distances && Array.isArray(data.distances)) {
|
|
847
|
-
this.distances = data.distances
|
|
850
|
+
if (data.distances !== undefined && Array.isArray(data.distances)) {
|
|
851
|
+
this.distances = data.distances as number[];
|
|
848
852
|
}
|
|
849
853
|
if (data.resultCode !== undefined && (typeof data.resultCode === 'string' || typeof data.resultCode === 'number')) {
|
|
850
854
|
this.resultCode = data.resultCode as Enums.ResultCode;
|
|
@@ -993,7 +997,7 @@ export class DistanceToRadiationCalculation extends CalculationBase {
|
|
|
993
997
|
distance?: number;
|
|
994
998
|
|
|
995
999
|
/**
|
|
996
|
-
* Calculates the distance to a specified radiation intensity or lethality level from a flame model.
|
|
1000
|
+
* Calculates the distance to a specified radiation intensity or lethality level from a flame model. This calculation can be called after any type of fire calculation (fireball, jet fire, pool fire).
|
|
997
1001
|
*
|
|
998
1002
|
*/
|
|
999
1003
|
constructor(data: {
|
|
@@ -1854,8 +1858,8 @@ export class RadiationAtPointsCalculationResponse extends CalculationResponseBas
|
|
|
1854
1858
|
}
|
|
1855
1859
|
|
|
1856
1860
|
initialiseFromDictionary(data: { [key: string]: unknown }) {
|
|
1857
|
-
if (data.radiation && Array.isArray(data.radiation)) {
|
|
1858
|
-
this.radiation = data.radiation
|
|
1861
|
+
if (data.radiation !== undefined && Array.isArray(data.radiation)) {
|
|
1862
|
+
this.radiation = data.radiation as number[];
|
|
1859
1863
|
}
|
|
1860
1864
|
if (data.resultCode !== undefined && (typeof data.resultCode === 'string' || typeof data.resultCode === 'number')) {
|
|
1861
1865
|
this.resultCode = data.resultCode as Enums.ResultCode;
|
|
@@ -2115,8 +2119,8 @@ export class RadiationAtPointsForPoolFiresCalculationResponse extends Calculatio
|
|
|
2115
2119
|
}
|
|
2116
2120
|
|
|
2117
2121
|
initialiseFromDictionary(data: { [key: string]: unknown }) {
|
|
2118
|
-
if (data.radiation && Array.isArray(data.radiation)) {
|
|
2119
|
-
this.radiation = data.radiation
|
|
2122
|
+
if (data.radiation !== undefined && Array.isArray(data.radiation)) {
|
|
2123
|
+
this.radiation = data.radiation as number[];
|
|
2120
2124
|
}
|
|
2121
2125
|
if (data.resultCode !== undefined && (typeof data.resultCode === 'string' || typeof data.resultCode === 'number')) {
|
|
2122
2126
|
this.resultCode = data.resultCode as Enums.ResultCode;
|
|
@@ -2265,7 +2269,7 @@ export class RadiationContourCalculation extends CalculationBase {
|
|
|
2265
2269
|
contourPoints?: Entities.LocalPosition[];
|
|
2266
2270
|
|
|
2267
2271
|
/**
|
|
2268
|
-
* Calculates the radiation contours from a flame model out to a specified intensity or lethality level. This calculation
|
|
2272
|
+
* Calculates the radiation contours from a flame model out to a specified intensity or lethality level. This calculation can be called after any type of fire calculation (fireball, jet fire, pool fire). Sideviews and footprints can be requested.
|
|
2269
2273
|
*
|
|
2270
2274
|
*/
|
|
2271
2275
|
constructor(data: {
|
|
@@ -2520,7 +2524,7 @@ export class RadiationTransectCalculation extends CalculationBase {
|
|
|
2520
2524
|
radiationRecords?: Entities.RadiationRecord[];
|
|
2521
2525
|
|
|
2522
2526
|
/**
|
|
2523
|
-
* Calculates the radiation along a specified transect from a flame model down to a specified intensity or lethality level. This calculation
|
|
2527
|
+
* Calculates the radiation along a specified transect from a flame model down to a specified intensity or lethality level. This calculation can be called after any type of fire calculation (fireball, jet fire, pool fire).
|
|
2524
2528
|
*
|
|
2525
2529
|
*/
|
|
2526
2530
|
constructor(data: {
|
|
@@ -2779,7 +2783,7 @@ export class RadiationTransectForPoolFiresCalculation extends CalculationBase {
|
|
|
2779
2783
|
radiationRecords?: Entities.RadiationRecord[];
|
|
2780
2784
|
|
|
2781
2785
|
/**
|
|
2782
|
-
* Calculates the radiation along a specified transect from a flame model down to a specified intensity or lethality level. This calculation can be called after pool fire
|
|
2786
|
+
* Calculates the radiation along a specified transect from a flame model down to a specified intensity or lethality level. This calculation can be called after pool fire calculations.
|
|
2783
2787
|
*
|
|
2784
2788
|
*/
|
|
2785
2789
|
constructor(data: {
|
|
@@ -1,15 +1,19 @@
|
|
|
1
|
-
|
|
2
|
-
*
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
|
|
1
|
+
// ************************************************************************************
|
|
2
|
+
// *
|
|
3
|
+
// * This file has been auto-generated by a code generation tool.
|
|
4
|
+
// *
|
|
5
|
+
// * DO NOT MODIFY THIS FILE
|
|
6
|
+
// * This file is maintained by DNV.
|
|
7
|
+
// * Editing it may lead to inconsistent results and limit DNV's ability to provide support.
|
|
8
|
+
// * Please contact DNV if you believe changes are required.
|
|
9
|
+
// *
|
|
10
|
+
// * API version: 1.0.
|
|
11
|
+
// * MDE version: 9.3.8211.
|
|
12
|
+
// * Package version: 1.0.98
|
|
13
|
+
// * Date/time: 23 Jun 2026 12:11:11.
|
|
14
|
+
// * Template: TYPE_SCRIPT_PWS/calculations.sbn.
|
|
15
|
+
// *
|
|
16
|
+
// ************************************************************************************
|
|
13
17
|
|
|
14
18
|
import * as Enums from '../enums';
|
|
15
19
|
import * as Entities from '../entities';
|
|
@@ -1,15 +1,19 @@
|
|
|
1
|
-
|
|
2
|
-
*
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
|
|
1
|
+
// ************************************************************************************
|
|
2
|
+
// *
|
|
3
|
+
// * This file has been auto-generated by a code generation tool.
|
|
4
|
+
// *
|
|
5
|
+
// * DO NOT MODIFY THIS FILE
|
|
6
|
+
// * This file is maintained by DNV.
|
|
7
|
+
// * Editing it may lead to inconsistent results and limit DNV's ability to provide support.
|
|
8
|
+
// * Please contact DNV if you believe changes are required.
|
|
9
|
+
// *
|
|
10
|
+
// * API version: 1.0.
|
|
11
|
+
// * MDE version: 9.3.8211.
|
|
12
|
+
// * Package version: 1.0.98
|
|
13
|
+
// * Date/time: 23 Jun 2026 12:11:11.
|
|
14
|
+
// * Template: TYPE_SCRIPT_PWS/calculations.sbn.
|
|
15
|
+
// *
|
|
16
|
+
// ************************************************************************************
|
|
13
17
|
|
|
14
18
|
import * as Enums from '../enums';
|
|
15
19
|
import * as Entities from '../entities';
|
|
@@ -122,7 +126,7 @@ export class LethalityDistanceCalculation extends CalculationBase {
|
|
|
122
126
|
toxicRecords?: Entities.ToxicRecord[];
|
|
123
127
|
|
|
124
128
|
/**
|
|
125
|
-
*
|
|
129
|
+
* Calculates the probability of death vs distance from a dispersing toxic cloud, down to the minimum probability of death. Integrates dose over time at each location and uses probit relations to convert to a probability of death. A successful dispersion calculation is required as input.
|
|
126
130
|
*
|
|
127
131
|
*/
|
|
128
132
|
constructor(data: {
|