TG Investments
and Research
TGIR QuantLib Tools Interest-rate derivatives, model diagnostics and pricing tools.
Three-factor hybrid · Bermudan LSM

Callable cross-currency quant lab.

A transparent research view of the 10Y NC2 EUR €STR versus USD fixed swap: economics, calibrated Hull–White rate factors, lognormal EURUSD diffusion, domestic-measure quanto drift, Monte Carlo valuation, least-squares stopping policy, exercise profile, and numerical controls.

01 / Valuation snapshot

Value decomposition and Monte Carlo uncertainty.

Values are read from result.json. Opening this page does not recalibrate or simulate; rerun the standalone pricer to refresh the snapshot.

Callable NPV $8,338,546.29 SE $129,232.26 · 95% CI $8,085,255.72 to $8,591,836.86
Non-callable NPV $688,796.97 SE $172,270.45 · 95% CI $351,153.09 to $1,026,440.84
Embedded option $7,649,749.33 SE $80,128.84 · 95% CI $7,492,699.68 to $7,806,798.97
USD fixed leg -$1,055,188.92 SE $67,313.80 · 95% CI -$1,187,121.55 to -$923,256.30
EUR €STR leg $1,743,985.89 SE $167,943.90 · 95% CI $1,414,821.90 to $2,073,149.87

Relative value map

Absolute bar length is scaled to the largest displayed PV; color preserves economic sign.

Callable NPVHolder value after optimal cancellation
$8,338,546.29
Non-callable NPVIdentical cash-flow stream without exercise
$688,796.97
Embedded optionCallable minus non-callable value
$7,649,749.33
USD fixed legPathwise PV of the 4% fixed-pay leg
-$1,055,188.92
EUR €STR legEUR receive leg converted to USD
$1,743,985.89

Numerical configuration

Independent samples fit and value the stopping policy, avoiding same-sample look-ahead bias.

Training paths
10,000
Pricing paths
30,000
Time-grid nodes
169
Maximum step
0.08333 years
Random generator
NUMPY_PCG64_ANTITHETIC
Seed
1729
Runtime
0.979 seconds
02 / Contract economics

Cash flows, exchanges, and cancellation rights.

Positive values and receipts are stated from the exercise holder’s perspective. Reporting and collateral currency are both USD.

Two-leg structure

The sample notionals are aligned at the initial EURUSD spot of 1.1000 USD per EUR.

RECEIVE
EUR 90,909,090.91 · ESTR + 0.0 bp3M payments · ACT/360 · 2 business-day lag
PAY
USD 100,000,000.00 · 4.0000% fixed6M payments · 30/360 · 2 business-day lag

Lifecycle

Contractual event ordering is explicit: due cash flows are paid before cancellation terminates only the remaining tail.

Effective
2026-08-18
Maturity
2036-08-18
Non-call
2Y
Call frequency
1Y
Style
CANCEL_REMAINING_SWAP
Event order
PAY_DUE_THEN_CANCEL
Initial / final exchange
YES / YES
Full generated schedule · 20 USD coupons · 40 EUR coupons · 8 call dates
USD fixed payment dates

2027-02-18 · 2027-08-18 · 2028-02-18 · 2028-08-18 · 2029-02-20 · 2029-08-20 · 2030-02-19 · 2030-08-19 · 2031-02-18 · 2031-08-18 · 2032-02-18 · 2032-08-18 · 2033-02-18 · 2033-08-18 · 2034-02-21 · 2034-08-18 · 2035-02-20 · 2035-08-20 · 2036-02-19 · 2036-08-18

EUR €STR payment dates

2026-11-18 · 2027-02-18 · 2027-05-18 · 2027-08-18 · 2027-11-18 · 2028-02-18 · 2028-05-18 · 2028-08-18 · 2028-11-20 · 2029-02-20 · 2029-05-18 · 2029-08-20 · 2029-11-19 · 2030-02-19 · 2030-05-20 · 2030-08-19 · 2030-11-18 · 2031-02-18 · 2031-05-19 · 2031-08-18 · 2031-11-18 · 2032-02-18 · 2032-05-18 · 2032-08-18 · 2032-11-18 · 2033-02-18 · 2033-05-18 · 2033-08-18 · 2033-11-18 · 2034-02-21 · 2034-05-18 · 2034-08-18 · 2034-11-20 · 2035-02-20 · 2035-05-18 · 2035-08-20 · 2035-11-19 · 2036-02-19 · 2036-05-19 · 2036-08-18

03 / Joint model

Two Hull–White factors and lognormal FX.

All dynamics are simulated jointly under the USD money-market measure with EURUSD quoted as USD per EUR.

Domestic-measure dynamics

The negative EUR quanto term is required by the measure and FX quotation. The log-FX update includes the Itô correction.

USD Hull–White dru=[θu(t)−auru]dt+σudWu
EUR Hull–White under the USD measure dre=[θe(t)−aere−ρeSσeσS(t)]dt+σedWe
EURUSD level process dSS=(ru−re)dt+σS(t)dWS
Log-EURUSD process dlogS=[ru−re−12σS2(t)]dt+σS(t)dWS

Instantaneous correlation

Edit the three independent entries. The symmetric 3×3 matrix is checked in the browser and validated again server-side before any calibration or simulation starts.

USD HWEUR HWEURUSD
USD HW1.0000.300-0.150
EUR HW0.3001.000-0.300
EURUSD-0.150-0.3001.000
det(R) = 0.824500
Full recalibration + Monte Carlo repricingReads data/xccy_market_eurusd.json and data/xccy_deal_10y_nc2.json afresh, applies only the three correlation values above, then atomically replaces result.json. The market JSON itself is not modified.
USD mean reversion0.0300One-factor Hull–White aUSD
USD rate sigma0.8853%Constant σUSD
EUR mean reversion0.0400One-factor Hull–White aEUR
EUR rate sigma0.7724%Constant σEUR
Basis treatmentDeterministicDETERMINISTIC_FORECAST_DISCOUNT
01Bootstrap curvesUSD SOFR, EUR €STR forecast, and USD-collateralized EUR effective curve.
02Calibrate factorsRate sigmas to diagonal normal swaptions; FX buckets to ATM Black options.
03Simulate jointlyExact OU rate kernels, integrated covariance, log FX, antithetics.
04Fit LSM policyBackward continuation regressions on an independent training sample.
05Price frozen policyForward stopping on new paths with confidence intervals and diagnostics.
04 / Calibration

Curve fit, rate smiles, and FX term structure.

Rate calibration uses normal-vol diagonal swaptions. FX diffusion buckets are solved in the full stochastic-rate hybrid to reproduce selected ATM Black targets.

RMSrel=1N∑i=1N(VimodelVimarket−1)2

Exact implementation definition. Each diagonal swaption helper has equal weight, so “weighted RMS” in the versioned JSON means weights wi = 1. It measures typical relative pricing error, penalizes larger misses quadratically, and is dimensionless. The page reports it as a percentage; for example 0.02319 is 2.319%.

Maximum OIS repricing errorpass
5.08864e-10 bp Acceptance limit ≤ 0.01 bp
USD swaption equal-weight RMS errorpass
2.31923 % Acceptance limit ≤ 5 %
EUR swaption equal-weight RMS errorpass
2.88556 % Acceptance limit ≤ 5 %
FX maximum absolute vol errorpass
1.38778e-15 % Acceptance limit ≤ 0.25 %

Hull–White diagonal fits

Market and model values are normalized helper prices; errors are relative price errors.

CCYExpiry × tenorMarketModelRel. error
USD2Yx8Y0.028091490.02823800+0.522%
USD3Yx7Y0.029883250.02965293-0.771%
USD4Yx6Y0.029351830.02877446-1.967%
USD5Yx5Y0.026964290.02628480-2.520%
USD6Yx4Y0.023031080.02260830-1.836%
USD7Yx3Y0.018023570.01793323-0.501%
USD8Yx2Y0.012345180.01253616+1.547%
USD9Yx1Y0.006212400.00652875+5.092%
EUR2Yx8Y0.025014060.02516354+0.598%
EUR3Yx7Y0.026866330.02660112-0.987%
EUR4Yx6Y0.026641390.02598706-2.456%
EUR5Yx5Y0.024675290.02390188-3.134%
EUR6Yx4Y0.021194750.02070884-2.293%
EUR7Yx3Y0.016652740.01654662-0.637%
EUR8Yx2Y0.011434560.01165248+1.906%
EUR9Yx1Y0.005749930.00611418+6.335%

EURUSD ATM Black calibration

Market implied vol differs from the hybrid diffusion coefficient because both interest rates are stochastic.

InstrumentMarket volModel volHybrid σ
EURUSD-ATM-1Y12.500%12.500%12.438%
EURUSD-ATM-2Y12.200%12.200%11.651%
EURUSD-ATM-3Y12.000%12.000%11.099%
EURUSD-ATM-5Y11.700%11.700%10.217%
EURUSD-ATM-7Y11.500%11.500%9.003%
EURUSD-ATM-10Y11.200%11.200%6.584%
Full curve and FX-forward repricing ledger · 46 instruments

USD-OIS

TenorMarket rate / forwardModel rate / forwardError
1W 4.100000%4.100000%-5.468e-11 bp
1M 4.080000%4.080000%+1.693e-11 bp
3M 4.040000%4.040000%+5.343e-12 bp
6M 3.980000%3.980000%+5.294e-11 bp
1Y 3.900000%3.900000%-7.633e-13 bp
2Y 3.780000%3.780000%+6.939e-14 bp
3Y 3.720000%3.720000%+4.292e-10 bp
4Y 3.700000%3.700000%+2.429e-12 bp
5Y 3.710000%3.710000%-1.672e-11 bp
6Y 3.730000%3.730000%-6.578e-11 bp
7Y 3.760000%3.760000%-1.232e-10 bp
8Y 3.790000%3.790000%-7.452e-11 bp
9Y 3.820000%3.820000%-4.864e-11 bp
10Y 3.850000%3.850000%-3.067e-11 bp
12Y 3.900000%3.900000%-9.916e-11 bp
15Y 3.950000%3.950000%-6.939e-14 bp

EUR-OIS

TenorMarket rate / forwardModel rate / forwardError
1W 2.550000%2.550000%+1.478e-11 bp
1M 2.540000%2.540000%+1.370e-11 bp
3M 2.520000%2.520000%+6.939e-14 bp
6M 2.490000%2.490000%+6.523e-12 bp
1Y 2.450000%2.450000%+4.279e-10 bp
2Y 2.400000%2.400000%+5.089e-10 bp
3Y 2.380000%2.380000%+5.794e-12 bp
4Y 2.380000%2.380000%+1.183e-10 bp
5Y 2.400000%2.400000%-1.290e-10 bp
6Y 2.420000%2.420000%-7.244e-11 bp
7Y 2.450000%2.450000%-1.437e-10 bp
8Y 2.480000%2.480000%-8.996e-11 bp
9Y 2.510000%2.510000%-6.120e-11 bp
10Y 2.540000%2.540000%-3.979e-11 bp
12Y 2.600000%2.600000%-1.036e-10 bp
15Y 2.670000%2.670000%+6.939e-14 bp

EUR-EFFECTIVE-USD-COLLATERAL

TenorMarket rate / forwardModel rate / forwardError
1M 1.1014001.101400+0.000e+00
3M 1.1041001.104100+0.000e+00
6M 1.1082001.108200+0.000e+00
1Y 1.1165001.116500+0.000e+00
2Y 1.1332001.133200+0.000e+00
3Y 1.1502001.150200-2.220e-16
4Y 1.1674001.167400+0.000e+00
5Y 1.1849001.184900+0.000e+00
6Y 1.2027001.202700+0.000e+00
7Y 1.2207001.220700+0.000e+00
8Y 1.2390001.239000+0.000e+00
9Y 1.2576001.257600+0.000e+00
10Y 1.2765001.276500+0.000e+00
12Y 1.3152001.315200+0.000e+00
05 / Bermudan exercise

Backward regression, forward stopping.

The holder cancels the remaining swap only when its estimated cancellable continuation value is negative beyond the configured tolerance.

Decision rule

Common cash flows due at the event date are excluded from the comparison, paid, and then retained regardless of the decision.

Conditional continuationCi(Xi)=EUSD[future cancellable cash flows+Vi+1|Xi]
Zero-fee cancellationCancel if0>C^i(Xi)+εexercise
Deterministic tie ruleContinue if|C^i(Xi)|≤εexercise

Regression state includes standardized USD/EUR rate factors, log FX, conditional PV features, squares, and cross terms. The frozen policy is applied to an independent pricing sample.

Forward exercise distribution

Unconditional probability by first stopping date. “No exercise” means the deal survives to maturity.

2028-08-184,228 of 30,000 paths
14.09%
2029-08-202,931 of 30,000 paths
9.77%
2030-08-191,693 of 30,000 paths
5.64%
2031-08-181,399 of 30,000 paths
4.66%
2032-08-181,046 of 30,000 paths
3.49%
2033-08-18875 of 30,000 paths
2.92%
2034-08-18482 of 30,000 paths
1.61%
2035-08-202,008 of 30,000 paths
6.69%
NO_EXERCISESurvives all call dates
51.13%
LSM regression diagnostics · 8 exercise regressions
CallDatePathsRank / basisCondition no.Residual RMSBackward ex.
12028-08-1810,00010 / 104.730$20,658,669.3714.12%
22029-08-2010,00010 / 104.866$19,321,627.7219.68%
32030-08-1910,00010 / 104.826$18,019,286.3422.19%
42031-08-1810,00010 / 105.027$16,235,162.0124.78%
52032-08-1810,00010 / 105.352$14,331,088.7125.89%
62033-08-1810,00010 / 105.419$12,068,384.6227.06%
72034-08-1810,00010 / 105.782$10,267,111.5627.35%
82035-08-2010,00010 / 105.946$8,111,077.6740.71%
06 / Numerical validation

Martingales, reproducibility, and known limits.

These diagnostics are evidence for a research implementation, not a substitute for independent model validation or production approval.

Domestic-numeraire martingales

Sample expectations are compared with analytic targets; the indicator shown uses a three-standard-error diagnostic band.

AssetSampleTargetz-scoreStatus
USD discount bond0.680132280.68023411-0.179pass
FX-converted EUR zero coupon0.868186480.86845707-0.146pass
FX-converted EUR bank account1.100168221.10000000+0.085pass

Model limitations

Explicit boundaries prevent the reference result from being mistaken for a fully governed trading model.

  • Reference implementation; independent model validation is required before production use.
  • Rate volatility is one-piece constant per currency in model version 1.
  • Forecast/discount and cross-currency basis are deterministic.
  • FX uses ATM lognormal volatility and does not fit a strike smile.
  • EUR overnight compounding uses the continuous-time bank-account equivalent with zero lookback and lockout.
  • The LSM estimate is a lower bound and must be convergence-tested against a dual or nested-MC benchmark.
Required next-level validation includes bucketed curve and basis risk, FX vega/smile risk, correlation stresses, multi-seed policy dispersion, time-grid and regression-basis convergence, a trusted nested-MC comparison, and a dual upper bound for the Bermudan exercise value.
07 / Implementation & local use

QuantLib where native; explicit hybrid logic where required.

The Flask page is observational. The standalone engine remains the source of pricing results.

QuantLib responsibilities

  • Calendars, schedules, day counts, OIS helpers, yield curves, and discount factors.
  • ql.HullWhite, ql.SwaptionHelper, and ql.JamshidianSwaptionEngine for rate calibration.
  • Black-vol quote conventions and analytic building blocks used by calibration.
  • Reproducible curve and helper repricing diagnostics.

Explicit Python responsibilities

  • Joint USD-measure transition with the EUR quanto drift and stochastic-rate FX drift.
  • Exact OU kernels, interval covariance integration, and correlated antithetic paths.
  • Pathwise cross-currency cash flows, notional exchanges, discounting, and FX conversion.
  • Two-sample LSM cancellation policy, exercise accounting, confidence intervals, and martingale tests.

Refresh the reference valuation

Run from the repository root. Reload this page after the command completes.

./.venv/bin/python standalone_xccy_pricer.py \ --market data/xccy_market_eurusd.json \ --deal data/xccy_deal_10y_nc2.json \ --output result.json
Data lineage and reproducibility metadata
Market source
ILLUSTRATIVE_REPLACE_WITH_APPROVED_MARKET_SNAPSHOT
Market input
data/xccy_market_eurusd.json
Deal input
data/xccy_deal_10y_nc2.json
Result snapshot
result.json
Normalized input SHA-256
c391d15407e6875f30957faa2fc76c91f5d5d4c00ea35b602a5cad3f1fed3d84
Run ID
4373720a-0bab-4f4d-be53-d6d815847e95
QuantLib / NumPy / Python
1.43 / 2.5.2 / 3.13.5