Skip to content

Commit 6555562

Browse files
committed
Features:
- Margin Amount Estimator Output #1 (1, 2) - Margin Amount Estimator Output #2 (3, 4) - Collateral Position Group Specification Extensions (5) - Position Group Specification - Constructor/Annotation (6, 7) - Fixed Threshold Position Group Specification (8) - Zero Threshold Position Group Specification (9, 10) - Book Group Layout Position Specification (11) - Book Group State Position Specification (12) - XVA Hypothecation Margin Amount Estimator (13, 14) - XVA Dynamics Position Group Trajectory (15, 16) - Position Group Schema Specification Proto (17, 18) Bug Fixes/Clean-up: - Collateral Group Specification CleanUp #1 (19, 20) - Collateral Group Specification CleanUp #2 (23, 24) Samples: - XVA Digest CPGA Collateralized (21, 22) - XVA Topology Book Group Layout (25, 26) - Book Latent State Map (27) - XVA Digest CPGA Collateralized Correlated (28, 29) - XVA Digest CPGA Zero Threshold (30, 31) - XVA Digest CPGA Zero Threshold Correlated (32, 33) - Albanese Andersen Basel Proxy (34, 35) - Gold Plated Basel Proxy (36) - Set Off Basel Proxy (37, 38) - Semi Replication Basel Proxy (39) - Hedge Error Basel Proxy (40, 41) - One Way Basel Proxy (42) - XVA Collateralized Collateral Group (43, 44) - XVA Collateralized Collateral Group Correlated (45, 46) - XVA Portfolio Collateral Estimate (47, 48) - XVA Zero Threshold Collateral Group (49, 50) - XVA Zero Threshold Collateral Group Correlated (51, 52) - XVA Basel Collateralized Collateral Neutral (53, 54) - XVA Basel Collateralized Collateral Neutral Stochastic (55, 56) - XVA Basel Collateralized Collateral Payable (57, 58) - XVA Basel Collateralized Collateral Payable Stochastic (59, 60) - XVA Basel Collateralized Collateral Receivable (61, 62) - XVA Basel Collateralized Collateral Receivable Stochastic (63, 64) - XVA Basel Collateralized Funding Neutral (65, 66) - XVA Basel Collateralized Funding Neutral Stochastic (67, 68) - XVA Basel Collateralized Funding Payable (69, 70) - XVA Basel Collateralized Funding Payable Stochastic (71, 72) - XVA Basel Collateralized Funding Receivable (73, 74) - XVA Basel Collateralized Funding Receivable Stochastic (75, 76) - XVA Basel Collateralized Netting Neutral (77, 78) - XVA Basel Collateralized Netting Neutral Stochastic (79, 80) - XVA Basel Collateralized Netting Payable (81, 82) - XVA Basel Collateralized Netting Payable Stochastic (83, 84) - XVA Basel Collateralized Netting Receivable (85, 86) - XVA Basel Collateralized Netting Receivable Stochastic (87, 88) - XVA Basel Zero Threshold Collateral Neutral (89, 90) - XVA Basel Zero Threshold Collateral Neutral Stochastic (91, 92) - XVA Basel Zero Threshold Collateral Payable (93, 94) - XVA Basel Zero Threshold Collateral Payable Stochastic (95, 96) - XVA Basel Zero Threshold Collateral Receivable (97, 98) - XVA Basel Zero Threshold Collateral Receivable Stochastic (99, 100) - XVA Basel Zero Threshold Funding Neutral (101, 102) - XVA Basel Zero Threshold Funding Neutral Stochastic (103, 104) - XVA Basel Zero Threshold Funding Payable (105, 106) - XVA Basel Zero Threshold Funding Payable Stochastic (107, 108) - XVA Basel Zero Threshold Funding Receivable (109, 110) - XVA Basel Zero Threshold Funding Receivable Stochastic (111, 112) - XVA Basel Zero Threshold Netting Neutral (113, 114) - XVA Basel Zero Threshold Netting Neutral Stochastic (115, 116) - XVA Basel Zero Threshold Netting Payable (117, 118) - XVA Basel Zero Threshold Netting Payable Stochastic (119, 120) - XVA Basel Zero Threshold Netting Receivable (121, 122) - XVA Basel Zero Threshold Netting Receivable Stochastic (123, 124) - Perfect Replication Collateralized Funding (125, 126) - Perfect Replication Collateralized Funding Stochastic (127, 128) - Perfect Replication Zero Threshold Funding (129, 130) - Perfect Replication Zero Threshold Funding Stochastic (131, 132) - Semi Replication Collateralized Funding (133, 134) - Semi Replication Collateralized Funding Stochastic (135, 136) - Semi Replication Zero Threshold Funding (137, 138) - Semi Replication Zero Threshold Funding Stochastic (139, 140) - Set Off Replication Collateralized Funding (141, 142) - Set Off Replication Collateralized Funding Stochastic (143, 144) - Set Off Replication Zero Threshold Funding (145, 146) - Set Off Replication Zero Threshold Funding Stochastic (147, 148)
1 parent ad97e4e commit 6555562

File tree

73 files changed

+878
-942
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

73 files changed

+878
-942
lines changed

ReleaseNotes/03_22_2018.txt

Lines changed: 89 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,89 @@
1+
2+
Features:
3+
4+
- Margin Amount Estimator Output #1 (1, 2)
5+
- Margin Amount Estimator Output #2 (3, 4)
6+
- Collateral Position Group Specification Extensions (5)
7+
- Position Group Specification - Constructor/Annotation (6, 7)
8+
- Fixed Threshold Position Group Specification (8)
9+
- Zero Threshold Position Group Specification (9, 10)
10+
- Book Group Layout Position Specification (11)
11+
- Book Group State Position Specification (12)
12+
- XVA Hypothecation Margin Amount Estimator (13, 14)
13+
- XVA Dynamics Position Group Trajectory (15, 16)
14+
- Position Group Schema Specification Proto (17, 18)
15+
16+
17+
Bug Fixes/Clean-up:
18+
19+
- Collateral Group Specification CleanUp #1 (19, 20)
20+
- Collateral Group Specification CleanUp #2 (23, 24)
21+
22+
23+
Samples:
24+
25+
- XVA Digest CPGA Collateralized (21, 22)
26+
- XVA Topology Book Group Layout (25, 26)
27+
- Book Latent State Map (27)
28+
- XVA Digest CPGA Collateralized Correlated (28, 29)
29+
- XVA Digest CPGA Zero Threshold (30, 31)
30+
- XVA Digest CPGA Zero Threshold Correlated (32, 33)
31+
- Albanese Andersen Basel Proxy (34, 35)
32+
- Gold Plated Basel Proxy (36)
33+
- Set Off Basel Proxy (37, 38)
34+
- Semi Replication Basel Proxy (39)
35+
- Hedge Error Basel Proxy (40, 41)
36+
- One Way Basel Proxy (42)
37+
- XVA Collateralized Collateral Group (43, 44)
38+
- XVA Collateralized Collateral Group Correlated (45, 46)
39+
- XVA Portfolio Collateral Estimate (47, 48)
40+
- XVA Zero Threshold Collateral Group (49, 50)
41+
- XVA Zero Threshold Collateral Group Correlated (51, 52)
42+
- XVA Basel Collateralized Collateral Neutral (53, 54)
43+
- XVA Basel Collateralized Collateral Neutral Stochastic (55, 56)
44+
- XVA Basel Collateralized Collateral Payable (57, 58)
45+
- XVA Basel Collateralized Collateral Payable Stochastic (59, 60)
46+
- XVA Basel Collateralized Collateral Receivable (61, 62)
47+
- XVA Basel Collateralized Collateral Receivable Stochastic (63, 64)
48+
- XVA Basel Collateralized Funding Neutral (65, 66)
49+
- XVA Basel Collateralized Funding Neutral Stochastic (67, 68)
50+
- XVA Basel Collateralized Funding Payable (69, 70)
51+
- XVA Basel Collateralized Funding Payable Stochastic (71, 72)
52+
- XVA Basel Collateralized Funding Receivable (73, 74)
53+
- XVA Basel Collateralized Funding Receivable Stochastic (75, 76)
54+
- XVA Basel Collateralized Netting Neutral (77, 78)
55+
- XVA Basel Collateralized Netting Neutral Stochastic (79, 80)
56+
- XVA Basel Collateralized Netting Payable (81, 82)
57+
- XVA Basel Collateralized Netting Payable Stochastic (83, 84)
58+
- XVA Basel Collateralized Netting Receivable (85, 86)
59+
- XVA Basel Collateralized Netting Receivable Stochastic (87, 88)
60+
- XVA Basel Zero Threshold Collateral Neutral (89, 90)
61+
- XVA Basel Zero Threshold Collateral Neutral Stochastic (91, 92)
62+
- XVA Basel Zero Threshold Collateral Payable (93, 94)
63+
- XVA Basel Zero Threshold Collateral Payable Stochastic (95, 96)
64+
- XVA Basel Zero Threshold Collateral Receivable (97, 98)
65+
- XVA Basel Zero Threshold Collateral Receivable Stochastic (99, 100)
66+
- XVA Basel Zero Threshold Funding Neutral (101, 102)
67+
- XVA Basel Zero Threshold Funding Neutral Stochastic (103, 104)
68+
- XVA Basel Zero Threshold Funding Payable (105, 106)
69+
- XVA Basel Zero Threshold Funding Payable Stochastic (107, 108)
70+
- XVA Basel Zero Threshold Funding Receivable (109, 110)
71+
- XVA Basel Zero Threshold Funding Receivable Stochastic (111, 112)
72+
- XVA Basel Zero Threshold Netting Neutral (113, 114)
73+
- XVA Basel Zero Threshold Netting Neutral Stochastic (115, 116)
74+
- XVA Basel Zero Threshold Netting Payable (117, 118)
75+
- XVA Basel Zero Threshold Netting Payable Stochastic (119, 120)
76+
- XVA Basel Zero Threshold Netting Receivable (121, 122)
77+
- XVA Basel Zero Threshold Netting Receivable Stochastic (123, 124)
78+
- Perfect Replication Collateralized Funding (125, 126)
79+
- Perfect Replication Collateralized Funding Stochastic (127, 128)
80+
- Perfect Replication Zero Threshold Funding (129, 130)
81+
- Perfect Replication Zero Threshold Funding Stochastic (131, 132)
82+
- Semi Replication Collateralized Funding (133, 134)
83+
- Semi Replication Collateralized Funding Stochastic (135, 136)
84+
- Semi Replication Zero Threshold Funding (137, 138)
85+
- Semi Replication Zero Threshold Funding Stochastic (139, 140)
86+
- Set Off Replication Collateralized Funding (141, 142)
87+
- Set Off Replication Collateralized Funding Stochastic (143, 144)
88+
- Set Off Replication Zero Threshold Funding (145, 146)
89+
- Set Off Replication Zero Threshold Funding Stochastic (147, 148)

src/main/java/org/drip/sample/burgard2013/PerfectReplicationCollateralizedFunding.java

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,6 @@
1010
import org.drip.measure.statistics.UnivariateDiscreteThin;
1111
import org.drip.quant.common.FormatUtil;
1212
import org.drip.service.env.EnvManager;
13-
import org.drip.state.identifier.CSALabel;
14-
import org.drip.state.identifier.OvernightLabel;
1513
import org.drip.xva.basel.*;
1614
import org.drip.xva.cpty.*;
1715
import org.drip.xva.definition.*;
@@ -180,7 +178,6 @@ private static final ExposureAdjustmentAggregator[] Mix (
180178
final double dblSwapNotional2)
181179
throws Exception
182180
{
183-
String currency = "USD";
184181
int iNumStep = 10;
185182
int iNumPath = 100000;
186183
int iNumVertex = 10;
@@ -210,10 +207,8 @@ private static final ExposureAdjustmentAggregator[] Mix (
210207
double dblBankSubordinateFundingSpread = dblBankHazardRate / (1. - dblBankSubordinateRecoveryRate);
211208
double dblCounterPartyFundingSpread = dblCounterPartyHazardRate / (1. - dblCounterPartyRecoveryRate);
212209

213-
CollateralGroupSpecification cgs = CollateralGroupSpecification.FixedThreshold (
210+
PositionGroupSpecification positionGroupSpecification = PositionGroupSpecification.FixedThreshold (
214211
"FIXEDTHRESHOLD",
215-
OvernightLabel.Create (currency),
216-
CSALabel.ISDA (currency),
217212
dblCounterPartyThreshold,
218213
dblBankThreshold,
219214
PositionReplicationScheme.BURGARD_KJAER_HEDGE_ERROR_DUAL_BOND_VERTEX,
@@ -301,8 +296,8 @@ private static final ExposureAdjustmentAggregator[] Mix (
301296
double dblValueEnd2 = aadblPortfolio2Value[i][j];
302297

303298
if (0 != j) {
304-
CollateralAmountEstimator hae1 = new CollateralAmountEstimator (
305-
cgs,
299+
MarginAmountEstimator hae1 = new MarginAmountEstimator (
300+
positionGroupSpecification,
306301
new BrokenDateInterpolatorLinearT (
307302
dtStart.julian(),
308303
dtEnd.julian(),
@@ -314,8 +309,8 @@ private static final ExposureAdjustmentAggregator[] Mix (
314309

315310
dblCollateralBalance1 = hae1.postingRequirement (dtEnd);
316311

317-
CollateralAmountEstimator hae2 = new CollateralAmountEstimator (
318-
cgs,
312+
MarginAmountEstimator hae2 = new MarginAmountEstimator (
313+
positionGroupSpecification,
319314
new BrokenDateInterpolatorLinearT (
320315
dtStart.julian(),
321316
dtEnd.julian(),
@@ -722,5 +717,7 @@ public static final void main (
722717
eeaGround,
723718
eeaExtended
724719
);
720+
721+
EnvManager.TerminateEnv();
725722
}
726723
}

src/main/java/org/drip/sample/burgard2013/PerfectReplicationCollateralizedFundingStochastic.java

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,6 @@
1212
import org.drip.quant.common.FormatUtil;
1313
import org.drip.quant.linearalgebra.Matrix;
1414
import org.drip.service.env.EnvManager;
15-
import org.drip.state.identifier.CSALabel;
16-
import org.drip.state.identifier.OvernightLabel;
1715
import org.drip.xva.basel.*;
1816
import org.drip.xva.cpty.*;
1917
import org.drip.xva.definition.*;
@@ -270,7 +268,6 @@ private static final ExposureAdjustmentAggregator[] Mix (
270268
final double dblSwapNotional2)
271269
throws Exception
272270
{
273-
String currency = "USD";
274271
int iNumStep = 10;
275272
int iNumPath = 100000;
276273
int iNumVertex = 10;
@@ -321,10 +318,8 @@ private static final ExposureAdjustmentAggregator[] Mix (
321318
{0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 1.00} // COUNTER PARTY FUNDING SPREAD
322319
};
323320

324-
CollateralGroupSpecification cgs = CollateralGroupSpecification.FixedThreshold (
321+
PositionGroupSpecification positionGroupSpecification = PositionGroupSpecification.FixedThreshold (
325322
"FIXEDTHRESHOLD",
326-
OvernightLabel.Create (currency),
327-
CSALabel.ISDA (currency),
328323
dblCounterPartyThreshold,
329324
dblBankThreshold,
330325
PositionReplicationScheme.BURGARD_KJAER_HEDGE_ERROR_DUAL_BOND_VERTEX,
@@ -592,8 +587,8 @@ private static final ExposureAdjustmentAggregator[] Mix (
592587
);
593588

594589
if (0 != j) {
595-
CollateralAmountEstimator hae1 = new CollateralAmountEstimator (
596-
cgs,
590+
MarginAmountEstimator hae1 = new MarginAmountEstimator (
591+
positionGroupSpecification,
597592
new BrokenDateInterpolatorLinearT (
598593
dtStart.julian(),
599594
dtEnd.julian(),
@@ -605,8 +600,8 @@ private static final ExposureAdjustmentAggregator[] Mix (
605600

606601
dblCollateralBalance1 = hae1.postingRequirement (dtEnd);
607602

608-
CollateralAmountEstimator hae2 = new CollateralAmountEstimator (
609-
cgs,
603+
MarginAmountEstimator hae2 = new MarginAmountEstimator (
604+
positionGroupSpecification,
610605
new BrokenDateInterpolatorLinearT (
611606
dtStart.julian(),
612607
dtEnd.julian(),

src/main/java/org/drip/sample/burgard2013/PerfectReplicationZeroThresholdFunding.java

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,6 @@
1010
import org.drip.measure.statistics.UnivariateDiscreteThin;
1111
import org.drip.quant.common.FormatUtil;
1212
import org.drip.service.env.EnvManager;
13-
import org.drip.state.identifier.CSALabel;
14-
import org.drip.state.identifier.OvernightLabel;
1513
import org.drip.xva.basel.*;
1614
import org.drip.xva.cpty.*;
1715
import org.drip.xva.definition.*;
@@ -180,7 +178,6 @@ private static final ExposureAdjustmentAggregator[] Mix (
180178
final double dblSwapNotional2)
181179
throws Exception
182180
{
183-
String currency = "USD";
184181
int iNumStep = 10;
185182
int iNumPath = 100000;
186183
int iNumVertex = 10;
@@ -210,10 +207,8 @@ private static final ExposureAdjustmentAggregator[] Mix (
210207
double dblBankSubordinateFundingSpread = dblBankHazardRate / (1. - dblBankSubordinateRecoveryRate);
211208
double dblCounterPartyFundingSpread = dblCounterPartyHazardRate / (1. - dblCounterPartyRecoveryRate);
212209

213-
CollateralGroupSpecification cgs = CollateralGroupSpecification.FixedThreshold (
210+
PositionGroupSpecification positionGroupSpecification = PositionGroupSpecification.FixedThreshold (
214211
"FIXEDTHRESHOLD",
215-
OvernightLabel.Create (currency),
216-
CSALabel.ISDA (currency),
217212
dblCounterPartyThreshold,
218213
dblBankThreshold,
219214
PositionReplicationScheme.BURGARD_KJAER_HEDGE_ERROR_DUAL_BOND_VERTEX,
@@ -301,8 +296,8 @@ private static final ExposureAdjustmentAggregator[] Mix (
301296
double dblValueEnd2 = aadblPortfolio2Value[i][j];
302297

303298
if (0 != j) {
304-
CollateralAmountEstimator cae1 = new CollateralAmountEstimator (
305-
cgs,
299+
MarginAmountEstimator cae1 = new MarginAmountEstimator (
300+
positionGroupSpecification,
306301
new BrokenDateInterpolatorLinearT (
307302
dtStart.julian(),
308303
dtEnd.julian(),
@@ -314,8 +309,8 @@ private static final ExposureAdjustmentAggregator[] Mix (
314309

315310
dblCollateralBalance1 = cae1.postingRequirement (dtEnd);
316311

317-
CollateralAmountEstimator cae2 = new CollateralAmountEstimator (
318-
cgs,
312+
MarginAmountEstimator cae2 = new MarginAmountEstimator (
313+
positionGroupSpecification,
319314
new BrokenDateInterpolatorLinearT (
320315
dtStart.julian(),
321316
dtEnd.julian(),
@@ -722,5 +717,7 @@ public static final void main (
722717
cpgaGround,
723718
cpgaExtended
724719
);
720+
721+
EnvManager.TerminateEnv();
725722
}
726723
}

src/main/java/org/drip/sample/burgard2013/PerfectReplicationZeroThresholdFundingStochastic.java

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,6 @@
1212
import org.drip.quant.common.FormatUtil;
1313
import org.drip.quant.linearalgebra.Matrix;
1414
import org.drip.service.env.EnvManager;
15-
import org.drip.state.identifier.CSALabel;
16-
import org.drip.state.identifier.OvernightLabel;
1715
import org.drip.xva.basel.*;
1816
import org.drip.xva.cpty.*;
1917
import org.drip.xva.definition.*;
@@ -270,7 +268,6 @@ private static final ExposureAdjustmentAggregator[] Mix (
270268
final double dblSwapNotional2)
271269
throws Exception
272270
{
273-
String currency = "USD";
274271
int iNumStep = 10;
275272
int iNumPath = 100000;
276273
int iNumVertex = 10;
@@ -321,10 +318,8 @@ private static final ExposureAdjustmentAggregator[] Mix (
321318
{0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 1.00} // COUNTER PARTY FUNDING SPREAD
322319
};
323320

324-
CollateralGroupSpecification cgs = CollateralGroupSpecification.FixedThreshold (
321+
PositionGroupSpecification positionGroupSpecification = PositionGroupSpecification.FixedThreshold (
325322
"FIXEDTHRESHOLD",
326-
OvernightLabel.Create (currency),
327-
CSALabel.ISDA (currency),
328323
dblCounterPartyThreshold,
329324
dblBankThreshold,
330325
PositionReplicationScheme.BURGARD_KJAER_HEDGE_ERROR_DUAL_BOND_VERTEX,
@@ -592,8 +587,8 @@ private static final ExposureAdjustmentAggregator[] Mix (
592587
);
593588

594589
if (0 != j) {
595-
CollateralAmountEstimator cae1 = new CollateralAmountEstimator (
596-
cgs,
590+
MarginAmountEstimator cae1 = new MarginAmountEstimator (
591+
positionGroupSpecification,
597592
new BrokenDateInterpolatorLinearT (
598593
dtStart.julian(),
599594
dtEnd.julian(),
@@ -605,8 +600,8 @@ private static final ExposureAdjustmentAggregator[] Mix (
605600

606601
dblCollateralBalance1 = cae1.postingRequirement (dtEnd);
607602

608-
CollateralAmountEstimator cae2 = new CollateralAmountEstimator (
609-
cgs,
603+
MarginAmountEstimator cae2 = new MarginAmountEstimator (
604+
positionGroupSpecification,
610605
new BrokenDateInterpolatorLinearT (
611606
dtStart.julian(),
612607
dtEnd.julian(),
@@ -1009,5 +1004,7 @@ public static final void main (
10091004
cpgaGround,
10101005
cpgaExtended
10111006
);
1007+
1008+
EnvManager.TerminateEnv();
10121009
}
10131010
}

src/main/java/org/drip/sample/burgard2013/SemiReplicationCollateralizedFunding.java

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,6 @@
1010
import org.drip.measure.statistics.UnivariateDiscreteThin;
1111
import org.drip.quant.common.FormatUtil;
1212
import org.drip.service.env.EnvManager;
13-
import org.drip.state.identifier.CSALabel;
14-
import org.drip.state.identifier.OvernightLabel;
1513
import org.drip.xva.basel.*;
1614
import org.drip.xva.cpty.*;
1715
import org.drip.xva.definition.*;
@@ -180,7 +178,6 @@ private static final ExposureAdjustmentAggregator[] Mix (
180178
final double dblSwapNotional2)
181179
throws Exception
182180
{
183-
String currency = "USD";
184181
int iNumStep = 10;
185182
int iNumPath = 100000;
186183
int iNumVertex = 10;
@@ -210,10 +207,8 @@ private static final ExposureAdjustmentAggregator[] Mix (
210207
double dblBankSubordinateFundingSpread = dblBankHazardRate / (1. - dblBankSubordinateRecoveryRate);
211208
double dblCounterPartyFundingSpread = dblCounterPartyHazardRate / (1. - dblCounterPartyRecoveryRate);
212209

213-
CollateralGroupSpecification cgs = CollateralGroupSpecification.FixedThreshold (
210+
PositionGroupSpecification positionGroupSpecification = PositionGroupSpecification.FixedThreshold (
214211
"FIXEDTHRESHOLD",
215-
OvernightLabel.Create (currency),
216-
CSALabel.ISDA (currency),
217212
dblCounterPartyThreshold,
218213
dblBankThreshold,
219214
PositionReplicationScheme.BURGARD_KJAER_SEMI_REPLICATION_DUAL_BOND_VERTEX,
@@ -301,8 +296,8 @@ private static final ExposureAdjustmentAggregator[] Mix (
301296
double dblValueEnd2 = aadblPortfolio2Value[i][j];
302297

303298
if (0 != j) {
304-
CollateralAmountEstimator hae1 = new CollateralAmountEstimator (
305-
cgs,
299+
MarginAmountEstimator hae1 = new MarginAmountEstimator (
300+
positionGroupSpecification,
306301
new BrokenDateInterpolatorLinearT (
307302
dtStart.julian(),
308303
dtEnd.julian(),
@@ -314,8 +309,8 @@ private static final ExposureAdjustmentAggregator[] Mix (
314309

315310
dblCollateralBalance1 = hae1.postingRequirement (dtEnd);
316311

317-
CollateralAmountEstimator hae2 = new CollateralAmountEstimator (
318-
cgs,
312+
MarginAmountEstimator hae2 = new MarginAmountEstimator (
313+
positionGroupSpecification,
319314
new BrokenDateInterpolatorLinearT (
320315
dtStart.julian(),
321316
dtEnd.julian(),
@@ -720,5 +715,7 @@ public static final void main (
720715
eeaGround,
721716
eeaExtended
722717
);
718+
719+
EnvManager.TerminateEnv();
723720
}
724721
}

0 commit comments

Comments
 (0)