@open3cl/engine 1.0.6 → 1.0.7
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/11_nadeq.spec.js +3 -2
- package/16.2_production_enr.spec.js +1 -0
- package/3.2.1_mur.spec.js +1 -0
- package/3.2.2_plancher_bas.spec.js +1 -0
- package/3.3_baie_vitree.spec.js +1 -0
- package/6.1_apport_gratuit.spec.js +1 -0
- package/7_inertie.spec.js +4 -3
- package/9_chauffage.spec.js +1 -0
- package/9_conso_ch.spec.js +1 -0
- package/9_generateur_ch.spec.js +1 -0
- package/conso.spec.js +1 -0
- package/core/assets/domain/synchronize-assets.spec.js +9 -9
- package/core/assets/domain/synchronize-c1-tables.spec.js +4 -4
- package/core/assets/domain/synchronize-dpe-ges-limit-values-tables.spec.js +6 -6
- package/core/assets/domain/synchronize-enum-tables.spec.js +10 -10
- package/core/assets/domain/synchronize-solicitations-tables.spec.js +6 -6
- package/core/assets/domain/synchronize-valeur-tables.spec.js +14 -14
- package/core/file/infrastructure/adapter/file.store.spec.js +5 -4
- package/core/tv/infrastructure/tvs.store.spec.js +3 -2
- package/core/util/infrastructure/object-util.spec.js +2 -1
- package/core/util/logger/log-service.js +47 -0
- package/features/dpe/domain/models/baie-ets.model.ts +12 -0
- package/features/dpe/domain/models/baie-vitree.model.ts +95 -0
- package/features/dpe/domain/models/climatisation.model.ts +25 -0
- package/features/dpe/domain/models/dpe.model.ts +194 -0
- package/features/dpe/domain/models/ets.model.ts +19 -0
- package/features/dpe/domain/models/installation-chauffage.model.ts +101 -0
- package/features/dpe/domain/models/installation-ecs.model.ts +76 -0
- package/features/dpe/domain/models/mur.model.ts +37 -0
- package/features/dpe/domain/models/plancher-bas.model.ts +38 -0
- package/features/dpe/domain/models/plancher-haut.model.ts +33 -0
- package/features/dpe/domain/models/pont-thermique.model.ts +21 -0
- package/features/dpe/domain/models/porte.model.ts +31 -0
- package/features/dpe/domain/models/production-elec-enr.model.ts +27 -0
- package/features/dpe/domain/models/sortie.model.ts +178 -0
- package/features/dpe/domain/models/type-habitation.model.js +8 -0
- package/features/dpe/domain/models/type-ventilation.model.js +8 -0
- package/features/dpe/domain/models/ventilation.model.ts +33 -0
- package/features/dpe/infrastructure/tv.store.js +389 -0
- package/features/dpe/infrastructure/tv.store.spec.js +690 -0
- package/features/engine/domain/constants.js +1 -0
- package/features/engine/domain/contexte.builder.js +140 -0
- package/features/engine/domain/contexte.builder.spec.js +152 -0
- package/features/engine/domain/engine.service.js +139 -0
- package/features/engine/domain/engine.service.spec.js +7 -0
- package/features/engine/domain/enveloppe/deperdition-enveloppe.service.js +262 -0
- package/features/engine/domain/enveloppe/deperdition-enveloppe.service.spec.js +282 -0
- package/features/engine/domain/enveloppe/deperdition.service.js +101 -0
- package/features/engine/domain/enveloppe/mur/deperdition-mur.service.js +168 -0
- package/features/engine/domain/enveloppe/mur/deperdition-mur.service.spec.js +345 -0
- package/features/engine/domain/enveloppe/plancher_bas/deperdition-plancher-bas.service.js +169 -0
- package/features/engine/domain/enveloppe/plancher_bas/deperdition-plancher-bas.service.spec.js +200 -0
- package/features/engine/domain/enveloppe/plancher_haut/deperdition-plancher-haut.service.js +136 -0
- package/features/engine/domain/enveloppe/plancher_haut/deperdition-plancher-haut.service.spec.js +211 -0
- package/features/engine/domain/enveloppe/porte/deperdition-porte.service.js +56 -0
- package/features/engine/domain/enveloppe/porte/deperdition-porte.service.spec.js +116 -0
- package/features/engine/domain/enveloppe/ventilation/deperdition-ventilation.service.js +338 -0
- package/features/engine/domain/enveloppe/ventilation/deperdition-ventilation.service.spec.js +393 -0
- package/features/engine/domain/models/contexte.model.ts +10 -0
- package/features/engine/domain/models/deperdition.model.ts +8 -0
- package/features/normalizer/domain/dpe-normalizer.service.js +24 -0
- package/features/normalizer/domain/dpe-normalizer.service.spec.js +3 -0
- package/ficheTechnique.spec.js +4 -3
- package/output.js +1 -0
- package/package.json +9 -8
- package/tv-v2.js +79121 -0
- package/utils.js +2 -2
- package/utils.spec.js +4 -3
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
import { DeperditionPorteService } from './deperdition-porte.service.js';
|
|
2
|
+
import corpus from '../../../../../../test/corpus-sano.json';
|
|
3
|
+
import { getAdemeFileJson } from '../../../../../../test/test-helpers.js';
|
|
4
|
+
import { beforeEach, describe, expect, test } from 'vitest';
|
|
5
|
+
import { TvStore } from '../../../../dpe/infrastructure/tv.store.js';
|
|
6
|
+
|
|
7
|
+
/** @type {DeperditionPorteService} **/
|
|
8
|
+
let service;
|
|
9
|
+
|
|
10
|
+
describe('Calcul de déperdition des portes', () => {
|
|
11
|
+
beforeEach(() => {
|
|
12
|
+
service = new DeperditionPorteService(new TvStore());
|
|
13
|
+
});
|
|
14
|
+
|
|
15
|
+
describe('Determination de uPorte', () => {
|
|
16
|
+
/** @type {Contexte} */
|
|
17
|
+
const ctx = { zoneClimatiqueId: '1' };
|
|
18
|
+
|
|
19
|
+
test.each([
|
|
20
|
+
{ type: '1', label: 'porte simple en bois porte opaque pleine', uPorteExpected: 3.5 },
|
|
21
|
+
{
|
|
22
|
+
type: '2',
|
|
23
|
+
label: 'porte simple en bois porte avec moins de 30% de vitrage simple',
|
|
24
|
+
uPorteExpected: 4
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
type: '3',
|
|
28
|
+
label: 'porte simple en bois porte avec 30-60% de vitrage simple',
|
|
29
|
+
uPorteExpected: 4.5
|
|
30
|
+
},
|
|
31
|
+
{ type: '4', label: 'porte simple en bois porte avec double vitrage', uPorteExpected: 3.3 },
|
|
32
|
+
{ type: '5', label: 'porte simple en pvc porte opaque pleine', uPorteExpected: 3.5 },
|
|
33
|
+
{
|
|
34
|
+
type: '6',
|
|
35
|
+
label: 'porte simple en pvc porte avec moins de 30% de vitrage simple',
|
|
36
|
+
uPorteExpected: 4
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
type: '7',
|
|
40
|
+
label: 'porte simple en pvc porte avec 30-60% de vitrage simple',
|
|
41
|
+
uPorteExpected: 4.5
|
|
42
|
+
},
|
|
43
|
+
{ type: '8', label: 'porte simple en pvc porte avec double vitrage', uPorteExpected: 3.3 },
|
|
44
|
+
|
|
45
|
+
{ type: '9', label: 'porte simple en métal porte opaque pleine', uPorteExpected: 5.8 },
|
|
46
|
+
{ type: '10', label: 'porte simple en métal porte avec vitrage simple', uPorteExpected: 5.8 },
|
|
47
|
+
{
|
|
48
|
+
type: '11',
|
|
49
|
+
label: 'porte simple en métal porte avec moins de 30% de double vitrage',
|
|
50
|
+
uPorteExpected: 5.5
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
type: '12',
|
|
54
|
+
label: 'porte simple en métal porte avec 30-60% de double vitrage',
|
|
55
|
+
uPorteExpected: 4.8
|
|
56
|
+
},
|
|
57
|
+
|
|
58
|
+
{ type: '13', label: 'toute menuiserie porte opaque pleine isolée', uPorteExpected: 1.5 },
|
|
59
|
+
{ type: '14', label: 'toute menuiserie porte précédée d’un sas', uPorteExpected: 1.5 },
|
|
60
|
+
{
|
|
61
|
+
type: '15',
|
|
62
|
+
label: 'toute menuiserie porte isolée avec double vitrage',
|
|
63
|
+
uPorteExpected: 1.5
|
|
64
|
+
},
|
|
65
|
+
|
|
66
|
+
{ type: '16', label: 'autre type de porte', uPorteExpected: undefined }
|
|
67
|
+
])('$label (id:$type)', ({ type, uPorteExpected }) => {
|
|
68
|
+
/** @type {PorteDE} */
|
|
69
|
+
const de = {
|
|
70
|
+
enum_type_porte_id: type
|
|
71
|
+
};
|
|
72
|
+
|
|
73
|
+
const di = service.execute(ctx, de);
|
|
74
|
+
expect(di.uporte).toBe(uPorteExpected);
|
|
75
|
+
});
|
|
76
|
+
|
|
77
|
+
test('autre porte Uporte saisie manuellement ', () => {
|
|
78
|
+
/** @type {PorteDE} */
|
|
79
|
+
const de = {
|
|
80
|
+
enum_type_porte_id: '16',
|
|
81
|
+
enum_methode_saisie_uporte_id: '2',
|
|
82
|
+
uporte_saisi: 1.6
|
|
83
|
+
};
|
|
84
|
+
|
|
85
|
+
const di = service.execute(ctx, de);
|
|
86
|
+
expect(di.uporte).toBe(de.uporte_saisi);
|
|
87
|
+
});
|
|
88
|
+
|
|
89
|
+
test('autre porte Uporte saisie manuellement et justifié', () => {
|
|
90
|
+
/** @type {PorteDE} */
|
|
91
|
+
const de = {
|
|
92
|
+
enum_type_porte_id: '16',
|
|
93
|
+
enum_methode_saisie_uporte_id: '3',
|
|
94
|
+
uporte_saisi: 1.88
|
|
95
|
+
};
|
|
96
|
+
|
|
97
|
+
const di = service.execute(ctx, de);
|
|
98
|
+
expect(di.uporte).toBe(de.uporte_saisi);
|
|
99
|
+
});
|
|
100
|
+
});
|
|
101
|
+
|
|
102
|
+
describe("Test d'intégration de porte", () => {
|
|
103
|
+
test.each(corpus)('vérification des DI des portes pour dpe %s', (ademeId) => {
|
|
104
|
+
const dpeRequest = getAdemeFileJson(ademeId);
|
|
105
|
+
/** @type {Contexte} */
|
|
106
|
+
const ctx = { zoneClimatiqueId: dpeRequest.logement.meteo.enum_zone_climatique_id };
|
|
107
|
+
const portes = dpeRequest.logement.enveloppe.porte_collection?.porte || [];
|
|
108
|
+
|
|
109
|
+
portes.forEach((p) => {
|
|
110
|
+
const di = service.execute(ctx, p.donnee_entree);
|
|
111
|
+
expect(di.uporte).toBeCloseTo(p.donnee_intermediaire.uporte, 2);
|
|
112
|
+
expect(di.b).toBeCloseTo(p.donnee_intermediaire.b, 2);
|
|
113
|
+
});
|
|
114
|
+
});
|
|
115
|
+
});
|
|
116
|
+
});
|
|
@@ -0,0 +1,338 @@
|
|
|
1
|
+
import { DeperditionService } from '../deperdition.service.js';
|
|
2
|
+
|
|
3
|
+
import { logger } from '../../../../../core/util/logger/log-service.js';
|
|
4
|
+
import { TypeHabitation } from '../../../../dpe/domain/models/type-habitation.model.js';
|
|
5
|
+
import { TypeVentilation } from '../../../../dpe/domain/models/type-ventilation.model.js';
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* Calcul des déperditions par ventilation
|
|
9
|
+
* Chapitre 4 Calcul des déperditions par renouvellement d’air
|
|
10
|
+
*
|
|
11
|
+
* Méthode de calcul 3CL-DPE 2021
|
|
12
|
+
* Octobre 2021
|
|
13
|
+
* @see consolide_anne…arrete_du_31_03_2021_relatif_aux_methodes_et_procedures_applicables.pdf
|
|
14
|
+
*/
|
|
15
|
+
export class DeperditionVentilationService extends DeperditionService {
|
|
16
|
+
/**
|
|
17
|
+
* Calcul des déperditions par ventilation
|
|
18
|
+
* @param ctx {Contexte}
|
|
19
|
+
* @param ventilationDE {VentilationDE}
|
|
20
|
+
* @param surfaceDeperditive {number}
|
|
21
|
+
* @param surfaceIsolee {number}
|
|
22
|
+
* @param surfaceNonIsolee {number}
|
|
23
|
+
* @param surfaceMenuiserieAvecJoint {number}
|
|
24
|
+
* @param surfaceMenuiserieSansJoint {number}
|
|
25
|
+
* @return {VentilationDI}
|
|
26
|
+
*/
|
|
27
|
+
execute(
|
|
28
|
+
ctx,
|
|
29
|
+
ventilationDE,
|
|
30
|
+
surfaceDeperditive,
|
|
31
|
+
surfaceIsolee,
|
|
32
|
+
surfaceNonIsolee,
|
|
33
|
+
surfaceMenuiserieAvecJoint,
|
|
34
|
+
surfaceMenuiserieSansJoint
|
|
35
|
+
) {
|
|
36
|
+
const q4paConv = this.q4paConv(
|
|
37
|
+
ventilationDE,
|
|
38
|
+
ctx,
|
|
39
|
+
surfaceIsolee,
|
|
40
|
+
surfaceNonIsolee,
|
|
41
|
+
surfaceMenuiserieAvecJoint,
|
|
42
|
+
surfaceMenuiserieSansJoint
|
|
43
|
+
);
|
|
44
|
+
const debitsVentilation = this.#debitsVentilation(ventilationDE.enum_type_ventilation_id);
|
|
45
|
+
|
|
46
|
+
/** @type {VentilationDI} */
|
|
47
|
+
return {
|
|
48
|
+
...{
|
|
49
|
+
hvent: this.hvent(ctx.surfaceHabitable, debitsVentilation),
|
|
50
|
+
hperm: this.hperm(ventilationDE, debitsVentilation, ctx, surfaceDeperditive, q4paConv)
|
|
51
|
+
},
|
|
52
|
+
...this.#consoAuxiliaireVentilation(ventilationDE, ctx, debitsVentilation)
|
|
53
|
+
};
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
/**
|
|
57
|
+
* Valeur conventionnelle de la perméabilité sous 4Pa
|
|
58
|
+
*
|
|
59
|
+
* @param ventilationDE {VentilationDE}
|
|
60
|
+
* @param ctx {Contexte}
|
|
61
|
+
* @param surfaceIsolee {number}
|
|
62
|
+
* @param surfaceNonIsolee {number}
|
|
63
|
+
* @param surfaceMenuiserieAvecJoint {number}
|
|
64
|
+
* @param surfaceMenuiserieSansJoint {number}
|
|
65
|
+
* @return {number}
|
|
66
|
+
*/
|
|
67
|
+
q4paConv(
|
|
68
|
+
ventilationDE,
|
|
69
|
+
ctx,
|
|
70
|
+
surfaceIsolee,
|
|
71
|
+
surfaceNonIsolee,
|
|
72
|
+
surfaceMenuiserieAvecJoint,
|
|
73
|
+
surfaceMenuiserieSansJoint
|
|
74
|
+
) {
|
|
75
|
+
// Pour les bâtiments qui ont fait l’objet d’une mesure d’étanchéité à l’air moins de deux ans avant le diagnostic, la valeur
|
|
76
|
+
// mesurée de Q4Paconv/m² peut être saisie.
|
|
77
|
+
if (ventilationDE.q4pa_conv_saisi) {
|
|
78
|
+
return ventilationDE.q4pa_conv_saisi;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
const enumPeriodeConstructionId = ctx.enumPeriodeConstructionId;
|
|
82
|
+
let isolationSurface;
|
|
83
|
+
let presenceJointsMenuiserie;
|
|
84
|
+
|
|
85
|
+
if (enumPeriodeConstructionId === '1') {
|
|
86
|
+
// Pour les bâtiments ou logements construits avant 1948, avec une isolation des murs et/ou du plafond (isolation
|
|
87
|
+
// de plus de 50% des surfaces) => valeur forfaitaire.
|
|
88
|
+
isolationSurface = surfaceIsolee > surfaceNonIsolee ? '1' : '0';
|
|
89
|
+
|
|
90
|
+
if (isolationSurface === '0') {
|
|
91
|
+
// Pour les bâtiments ou logements construits avant 1948, si les menuiseries possèdent des joints
|
|
92
|
+
// (si les menuiseries représentant plus de 50% de la surface totale possèdent des joints) => valeur forfaitaire.
|
|
93
|
+
if (surfaceMenuiserieAvecJoint > surfaceMenuiserieSansJoint) {
|
|
94
|
+
presenceJointsMenuiserie = '1';
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
} else if (enumPeriodeConstructionId === '2') {
|
|
98
|
+
// Pour les bâtiments ou logements construits entre 1948 et 1974, avec une isolation des murs et/ou du plafond (isolation
|
|
99
|
+
// de plus de 50% des surfaces) => valeur forfaitaire.
|
|
100
|
+
isolationSurface = surfaceIsolee > surfaceNonIsolee ? '1' : '0';
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
return this.tvStore.getQ4paConv(
|
|
104
|
+
ctx.enumPeriodeConstructionId,
|
|
105
|
+
ctx.typeHabitation,
|
|
106
|
+
isolationSurface,
|
|
107
|
+
presenceJointsMenuiserie
|
|
108
|
+
)?.q4pa_conv;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
/**
|
|
112
|
+
* Déperdition thermique par renouvellement d’air due au système de ventilation
|
|
113
|
+
* @param surfaceHabitable {string}
|
|
114
|
+
* @param debitsVentilation {{qvarep_conv?: number, qvasouf_conv?: number, smea_conv?: number}}
|
|
115
|
+
* @return number
|
|
116
|
+
*/
|
|
117
|
+
hvent(surfaceHabitable, debitsVentilation) {
|
|
118
|
+
return 0.34 * Number(debitsVentilation?.qvarep_conv) * surfaceHabitable;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
/**
|
|
122
|
+
* Déperdition thermique par renouvellement d’air due au système de ventilation
|
|
123
|
+
* @param ventilationDE {VentilationDE}
|
|
124
|
+
* @param debitsVentilation {{qvarep_conv?: number, qvasouf_conv?: number, smea_conv?: number}}
|
|
125
|
+
* @param ctx {Contexte}
|
|
126
|
+
* @param surfaceDeperditive {number}
|
|
127
|
+
* @param q4paConv {number}
|
|
128
|
+
* @return number
|
|
129
|
+
*/
|
|
130
|
+
hperm(ventilationDE, debitsVentilation, ctx, surfaceDeperditive, q4paConv) {
|
|
131
|
+
const pfe = ventilationDE.plusieurs_facade_exposee;
|
|
132
|
+
const surfaceHabitable = ctx.surfaceHabitable;
|
|
133
|
+
|
|
134
|
+
// Coefficients de protection
|
|
135
|
+
const e = pfe ? 0.07 : 0.02;
|
|
136
|
+
const f = pfe ? 15 : 20;
|
|
137
|
+
|
|
138
|
+
const q4pa_env = q4paConv * surfaceDeperditive;
|
|
139
|
+
|
|
140
|
+
// Perméabilité sous 4 Pa de la zone
|
|
141
|
+
const q4pa = q4pa_env + 0.45 * debitsVentilation?.smea_conv * surfaceHabitable;
|
|
142
|
+
|
|
143
|
+
const n50 = q4pa / ((4 / 50) ** (2 / 3) * ctx.hauteurSousPlafond * surfaceHabitable);
|
|
144
|
+
|
|
145
|
+
// Débit d’air dû aux infiltrations liées au vent (m3/h)
|
|
146
|
+
const qvinf =
|
|
147
|
+
(ctx.hauteurSousPlafond * surfaceHabitable * n50 * e) /
|
|
148
|
+
(1 +
|
|
149
|
+
(f / e) *
|
|
150
|
+
((debitsVentilation?.qvasouf_conv - debitsVentilation?.qvarep_conv) /
|
|
151
|
+
(ctx.hauteurSousPlafond * n50)) **
|
|
152
|
+
2);
|
|
153
|
+
|
|
154
|
+
return 0.34 * qvinf;
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
/**
|
|
158
|
+
* Puissance moyenne des auxiliaires (W)
|
|
159
|
+
* @param typeVentilation {string}
|
|
160
|
+
* @param ctx {Contexte}
|
|
161
|
+
* @param ventilationPost2012 {boolean}
|
|
162
|
+
* @param debitsVentilation {{qvarep_conv?: number, qvasouf_conv?: number, smea_conv?: number}}
|
|
163
|
+
* @returns {*|number}
|
|
164
|
+
*/
|
|
165
|
+
pventMoy(typeVentilation, ctx, ventilationPost2012, debitsVentilation) {
|
|
166
|
+
let hybride = false;
|
|
167
|
+
|
|
168
|
+
/** @type {TypeVentilation} **/
|
|
169
|
+
let type;
|
|
170
|
+
|
|
171
|
+
/**
|
|
172
|
+
* 1 - ventilation par ouverture des fenêtres
|
|
173
|
+
* 2 - ventilation par entrées d'air hautes et basses
|
|
174
|
+
* 25 - ventilation naturelle par conduit
|
|
175
|
+
* 34 - ventilation naturelle par conduit avec entrées d'air hygro
|
|
176
|
+
* 35 - puits climatique sans échangeur avant 2013
|
|
177
|
+
* 36 - puits climatique sans échangeur à partir de 2013
|
|
178
|
+
* 37 - puits climatique avec échangeur avant 2013
|
|
179
|
+
* 38 - puits climatique avec échangeur à partir de 2013
|
|
180
|
+
*/
|
|
181
|
+
if (['1', '2', '25', '34', '35', '36', '37', '38'].includes(typeVentilation)) {
|
|
182
|
+
return 0;
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
/**
|
|
186
|
+
* 26 - ventilation hybride avant 2001
|
|
187
|
+
* 27 - ventilation hybride de 2001 à 2012
|
|
188
|
+
* 28 - ventilation hybride après 2012
|
|
189
|
+
* 29 - ventilation hybride avec entrées d'air hygro avant 2001
|
|
190
|
+
* 30 - ventilation hybride avec entrées d'air hygro de 2001 à 2012
|
|
191
|
+
* 31 - ventilation hybride avec entrées d'air hygro après 2012
|
|
192
|
+
*/
|
|
193
|
+
if (['26', '27', '28', '29', '30', '31'].includes(typeVentilation)) {
|
|
194
|
+
hybride = true;
|
|
195
|
+
type = TypeVentilation.SIMPLE_FLUX_AUTO;
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
/**
|
|
199
|
+
* 3 - vmc sf auto réglable avant 1982
|
|
200
|
+
* 4 - vmc sf auto réglable de 1982 à 2000
|
|
201
|
+
* 5 - vmc sf auto réglable de 2001 à 2012
|
|
202
|
+
* 6 - vmc sf auto réglable après 2012
|
|
203
|
+
* 32 - ventilation mécanique sur conduit existant avant 2013
|
|
204
|
+
* 33 - ventilation mécanique sur conduit existant à partir de 2013
|
|
205
|
+
*/
|
|
206
|
+
if (['3', '4', '5', '6', '32', '33'].includes(typeVentilation)) {
|
|
207
|
+
type = TypeVentilation.SIMPLE_FLUX_AUTO;
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
/**
|
|
211
|
+
* 10 - vmc sf gaz avant 2001
|
|
212
|
+
* 11 - vmc sf gaz de 2001 à 2012
|
|
213
|
+
* 12 - vmc sf gaz après 2012
|
|
214
|
+
*/
|
|
215
|
+
if (['10', '11', '12'].includes(typeVentilation)) {
|
|
216
|
+
type = TypeVentilation.SIMPLE_FLUX_AUTO;
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
/**
|
|
220
|
+
* 7 - vmc sf hygro a avant 2001
|
|
221
|
+
* 8 - vmc sf hygro a de 2001 à 2012
|
|
222
|
+
* 9 - vmc sf hygro a après 2012
|
|
223
|
+
* 13 - vmc sf hygro b avant 2001
|
|
224
|
+
* 14 - vmc sf hygro b de 2001 à 2012
|
|
225
|
+
* 15 - vmc sf hygro b après 2012
|
|
226
|
+
* 16 - vmc basse pression auto-réglable
|
|
227
|
+
* 17 - vmc basse pression hygro a
|
|
228
|
+
* 18 - vmc basse pression hygro b
|
|
229
|
+
*/
|
|
230
|
+
if (['7', '8', '9', '13', '14', '15', '16', '17', '18'].includes(typeVentilation)) {
|
|
231
|
+
type = TypeVentilation.SIMPLE_FLUX_HYGRO;
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
/**
|
|
235
|
+
* 19 - vmc df individuelle avec échangeur avant 2013
|
|
236
|
+
* 20 - vmc df individuelle avec échangeur à partir de 2013
|
|
237
|
+
* 21 - vmc df collective avec échangeur avant 2013
|
|
238
|
+
* 22 - vmc df collective avec échangeur à partir de 2013
|
|
239
|
+
* 23 - vmc df sans échangeur avant 2013
|
|
240
|
+
* 24 - vmc df sans échangeur après 2012
|
|
241
|
+
*/
|
|
242
|
+
if (['19', '20', '21', '22', '23', '24'].includes(typeVentilation)) {
|
|
243
|
+
type = TypeVentilation.DOUBLE_FLUX;
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
// Puissance des auxiliaires (W/(m³/h))
|
|
247
|
+
let pvent;
|
|
248
|
+
|
|
249
|
+
switch (type) {
|
|
250
|
+
case TypeVentilation.SIMPLE_FLUX_AUTO: {
|
|
251
|
+
if (ctx.typeHabitation === TypeHabitation.MAISON) {
|
|
252
|
+
pvent = ventilationPost2012 ? 35 : 65;
|
|
253
|
+
} else {
|
|
254
|
+
pvent = ventilationPost2012 ? 0.25 : 0.46;
|
|
255
|
+
}
|
|
256
|
+
break;
|
|
257
|
+
}
|
|
258
|
+
case TypeVentilation.SIMPLE_FLUX_HYGRO: {
|
|
259
|
+
if (ctx.typeHabitation === TypeHabitation.MAISON) {
|
|
260
|
+
pvent = ventilationPost2012 ? 15 : 50;
|
|
261
|
+
} else {
|
|
262
|
+
pvent = ventilationPost2012 ? 0.25 : 0.46;
|
|
263
|
+
}
|
|
264
|
+
break;
|
|
265
|
+
}
|
|
266
|
+
case TypeVentilation.DOUBLE_FLUX: {
|
|
267
|
+
if (ctx.typeHabitation === TypeHabitation.MAISON) {
|
|
268
|
+
pvent = ventilationPost2012 ? 35 : 80;
|
|
269
|
+
} else {
|
|
270
|
+
pvent = ventilationPost2012 ? 0.6 : 1.1;
|
|
271
|
+
}
|
|
272
|
+
break;
|
|
273
|
+
}
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
let pventMoy;
|
|
277
|
+
|
|
278
|
+
/**
|
|
279
|
+
* @see Methode_de_calcul_3CL_DPE_2021-338.pdf, pages 41-42
|
|
280
|
+
* Les consommations d’auxiliaires pour une VMC hybride correspondent aux consommations d’une VMC
|
|
281
|
+
* classique autoréglable de 2001 à 2012 multipliées par le ratio du temps d’utilisation
|
|
282
|
+
*/
|
|
283
|
+
const ratioUtilisation = hybride
|
|
284
|
+
? (ctx.typeHabitation === TypeHabitation.MAISON ? 14 : 28) / (24 * 7)
|
|
285
|
+
: 1;
|
|
286
|
+
|
|
287
|
+
if (ctx.typeHabitation === TypeHabitation.MAISON) {
|
|
288
|
+
pventMoy = pvent * ratioUtilisation;
|
|
289
|
+
} else {
|
|
290
|
+
pventMoy = pvent * debitsVentilation?.qvarep_conv * ctx.surfaceHabitable * ratioUtilisation;
|
|
291
|
+
}
|
|
292
|
+
|
|
293
|
+
return pventMoy;
|
|
294
|
+
}
|
|
295
|
+
|
|
296
|
+
/**
|
|
297
|
+
* Débits de ventilation
|
|
298
|
+
* @param typeVentilation {number}
|
|
299
|
+
* @return {{qvarep_conv?: number, qvasouf_conv?: number, smea_conv?: number}}
|
|
300
|
+
*/
|
|
301
|
+
#debitsVentilation(typeVentilation) {
|
|
302
|
+
const debitsVentilation = this.tvStore.getDebitsVentilation(typeVentilation);
|
|
303
|
+
|
|
304
|
+
return {
|
|
305
|
+
qvarep_conv: Number(debitsVentilation?.qvarep_conv),
|
|
306
|
+
qvasouf_conv: Number(debitsVentilation?.qvasouf_conv),
|
|
307
|
+
smea_conv: Number(debitsVentilation?.smea_conv)
|
|
308
|
+
};
|
|
309
|
+
}
|
|
310
|
+
|
|
311
|
+
/**
|
|
312
|
+
* Consommation des auxiliaires de ventilation
|
|
313
|
+
* @param ventilationDE {VentilationDE}
|
|
314
|
+
* @param ctx {Contexte}
|
|
315
|
+
* @param debitsVentilation {{qvarep_conv?: number, qvasouf_conv?: number, smea_conv?: number}}
|
|
316
|
+
* @returns {{conso_auxiliaire_ventilation: number, pvent_moy}|number}
|
|
317
|
+
*/
|
|
318
|
+
#consoAuxiliaireVentilation(ventilationDE, ctx, debitsVentilation) {
|
|
319
|
+
const typeVentilation = ventilationDE.enum_type_ventilation_id;
|
|
320
|
+
let ventilationPost2012 = ventilationDE.ventilation_post_2012;
|
|
321
|
+
|
|
322
|
+
if (typeVentilation === undefined && ventilationPost2012 === undefined) {
|
|
323
|
+
logger.error(`
|
|
324
|
+
Impossible de calculer la consommation des auxiliaires de ventilation sans les variables enum_type_ventilation_id et ventilation_post_2012
|
|
325
|
+
`);
|
|
326
|
+
|
|
327
|
+
return 0;
|
|
328
|
+
}
|
|
329
|
+
|
|
330
|
+
// Puissance moyenne des auxiliaires (W)
|
|
331
|
+
const pventMoy = this.pventMoy(typeVentilation, ctx, ventilationPost2012, debitsVentilation);
|
|
332
|
+
|
|
333
|
+
return {
|
|
334
|
+
conso_auxiliaire_ventilation: 8.76 * pventMoy,
|
|
335
|
+
pvent_moy: pventMoy
|
|
336
|
+
};
|
|
337
|
+
}
|
|
338
|
+
}
|