A .NET library for actuarial reserving, built with a focus on clarity, composability, and domain correctness.
ActuarialForge provides a structured and extensible framework for actuarial reserving methods, including:
- Chain Ladder
- Additive Method
- Bornhuetter-Ferguson
- Residual analysis
- Validation utilities
The library is designed around explicit domain modeling and strong typing, ensuring that actuarial logic remains transparent, reproducible, and robust.
- Domain-driven: Clear separation between model, methods, workflow, and validation
- Composable: Methods can be reused and combined
- Safe by design: Guards against invalid actuarial states (e.g. currency mismatches, zero denominators)
- Extensible: Easy to add new reserving methods or validation approaches
var triangle = new TriangleWorkflowBuilder()
.FromClaimHistories(claims)
.WithTimeGranularity(ReservingTimeGranularity.Yearly)
.UsingClaimDateBasis(ClaimDateBasis.AccidentDate)
.Build();var chainLadder = new ChainLadder(triangle);
var projection = chainLadder.ComputeProjection();
var ultimates = chainLadder.ComputeUltimates();var lossRatios = chainLadder.ComputeUltimateLossRatios(premiums);var bf = new BornhuetterFerguson(
triangle,
chainLadder,
premiums
);
var bfUltimates = bf.ComputeUltimates();The library is structured into clearly separated modules:
Core domain objects:
- Triangle representations
- Money & currency handling
- Period abstractions
Implementation of reserving methods:
- ChainLadder
- AdditiveMethod
- BornhuetterFerguson
Includes:
- Development patterns (multiplicative / additive)
- Run-off factors
- Variance estimation
Transformation layer from raw data to triangles:
- ClaimHistory
- ClaimHistoryEvent
- TriangleWorkflowBuilder
Validation and diagnostics:
- Residual analysis
- Correlation structures
- Method comparison
Mathematical utilities:
- Linear regression
- Decimal-based numerical helpers
var triangle = new TriangleWorkflowBuilder()
.FromClaimHistories(claims)
.WithTimeGranularity(ReservingTimeGranularity.Yearly)
.UsingClaimDateBasis(ClaimDateBasis.AccidentDate)
.Build();
var method = new ChainLadder(triangle);
var projection = method.ComputeProjection();
var ultimates = method.ComputeUltimates();
var residuals = new Residuals(method);
var correlation = AccidentPeriodCorrelationCalculator.Compute(residuals);- Multiplicative (Chain Ladder)
- Incremental / additive
Encapsulated via IRunOffFactors, allowing:
- unified access
- method-specific interpretation
- AccidentPeriod
- DevelopmentPeriod
- Money
- Currency
The library enforces correctness early:
- Currency mismatches throw immediately
- Invalid triangles are rejected
- Division-by-zero situations are guarded explicitly
You can easily add:
- New reserving methods via IPatternBasedReservingMethod
- Custom validation logic via IReservingMethodSelector
- Alternative workflows or data sources
Contributions are welcome.
Please ensure:
- Domain consistency is preserved
- XML documentation is included
- Edge cases are handled explicitly
This project is licensed under the MIT License - see the LICENSE file for details.
Jan Braunschmidt