A MATLAB® reference application for reliability engineering workflows — life distribution fitting, accelerated life testing (ALT), field risk assessment, and reliability statistics.
- Clone this repository
- Open MATLAB® and navigate to the repository root
- Add the repository folders to your MATLAB® path:
Or add all subfolders at once:
addpath('/path/to/Reliability-MATLAB'); addpath('/path/to/Reliability-MATLAB/app');
addpath(genpath('/path/to/Reliability-MATLAB')); - Run the main app:
ReliabilityMAT
MathWorks Products (https://www.mathworks.com)
Requires MATLAB® release R2020b or newer (R2025b recommended)
None.
Launch the app from the MATLAB® command window:
ReliabilityMATThe main launcher provides access to four modules:
- Reliability Statistics — Sample size determination, zero-failure testing, confidence intervals
- Life Distribution Fitting — Fit Weibull, Lognormal, or Exponential distributions to time-to-failure data with censoring support
- Accelerated Life Testing — Import ALT data, fit an Arrhenius model, calculate acceleration factors, and project reliability at use conditions
- Field Risk Assessment — Estimate field failure probability and PPM using Monte Carlo simulation
Each module accepts CSV or Excel data files. Sample datasets are included in the data/ folder to get started.
Two simulated datasets are included in data/ that serve as example inputs for the Life Distribution Fitting and Accelerated Life Testing modules:
ev_battery_Life_distribution.csv— EV battery time-to-failure dataev_inverter_ALT.csv— EV inverter accelerated life test data at multiple temperatures
A worked example for each module — Problem, Workflow, Result. These are starting points for your own analyses, not the only way to use the apps.
Problem. Demonstrate 99% reliability at 90% confidence with zero failures permitted during the test.
Workflow (Classical). Open the Statistics module, go to the Sample Size tab. In the Classical section enter Reliability = 0.99, Confidence = 0.90, Allowable Failures = 0 and click Calculate Sample Size.
Result. n = 230 units must complete the test with no failures to demonstrate the target. Allowing failures or extending the test duration relative to design life reduces n.
Bayesian variant — reduce sample size with credible priors. When you have defensible prior data — heritage units from a related program, component-level reliability from a Module 2 fit, or accelerated-test evidence from Module 3 — use the Bayesian section and supply a Beta(α, β) prior. A non-informative prior (α = β = 1, prior mean = 50%) reproduces the Classical result. An informative prior whose mean exceeds the target reduces n: e.g. α = 150, β = 1 (prior mean ≈ 99.3%, equivalent to ~150 prior successful units) drops the requirement to about 80 units, a ~65% reduction. Two cautions worth surfacing: priors centered at or below the target increase the required sample size, and the prior must be defensible to auditors — Module 2 / Module 3 outputs are workflow guidance for assembling that prior, not values that flow automatically.
2. Life Distribution Fitting — Forecast EV battery 8-year warranty exposure from 3 years of field returns
Problem. An EV manufacturer offers an 8-year battery warranty and wants to size the warranty reserve after only 3 years of field data. The dataset (data/ev_battery_Life_distribution.csv) contains 100 battery packs: roughly 30% have failed (capacity dropped below 80%) and 70% are right-censored — still operating in the field. The reliability question is which life distribution describes the degradation, and what failure rate to expect at the 8-year warranty boundary.
Workflow. Open Life Distribution Fitting, click Import and choose the CSV (columns Time_hours, Censor with 0 = failure, 1 = censored), then click Fit Distributions. Once the fit completes, click Generate Probability Plot for visual validation, and use the Reliability Calculator to evaluate R(t) at warranty boundary times (e.g. 3,200 operating hours ≈ 8 years at ~400 op-hr/yr typical EV usage).
Result. Weibull, Lognormal, and Exponential are all fit by maximum likelihood (which handles the 70% censoring correctly via Kaplan–Meier) and the AIC-best is selected — Lognormal wins for this dataset (AIC ≈ 590 vs ≈ 593 for Weibull and ≈ 599 for Exponential), consistent with gradual chemical degradation. The fitted parameters are roughly μ ≈ 9.1, σ ≈ 1.0, giving a median life of ≈ 8,900 operating hours. Goodness of fit is reported via the Kolmogorov–Smirnov test (the Anderson–Darling test is not valid for heavily censored data and is omitted). At the 8-year boundary the predicted failure rate is ≈ 14.5%, which sizes the warranty reserve. The B-life table and probability plot populate alongside in the same click.
Problem. A new EV inverter design must be qualified for ~15 years of field life, but the product launch is 18 months away. An accelerated life test ran 90 units at 85, 105, and 125 °C (data/ev_inverter_ALT.csv); the dominant failure mode is IGBT wire-bond fatigue, which follows Arrhenius kinetics. Project life at a 65 °C worst-case use temperature and check that the B10 life exceeds the 10-year qualification gate.
Workflow. In Acceleration Modeling, set Temperature Unit = Celsius, Import the CSV (columns Time_hours, Censor, Temperature_C), and click Fit Arrhenius Model. On the Predictions tab, enter Use Temperature = 65 °C, Stress Temperature = 125 °C, click Calculate Acceleration Factor, then set Shape at use = Common for the use-condition projection. For a deployment scenario, enter Field Deployment Time = 170,000 hours, Duty Cycle = 10% and click Calculate Reliability.
Result. The fit returns the activation energy Ea with R² ≈ 0.99 — a linear Arrhenius plot consistent with a single failure mechanism. The acceleration factor AF(125 → 65 °C) ≈ 27.7× (90% CI ≈ [2.2, 351.2] — very wide because Ea is poorly constrained by only three stress levels). At the use condition the projection gives β ≈ 2.78 (common-shape method) and η ≈ 42,952 operating hours (≈ 4.9 years continuous); B10 at use is ≈ 19,098 operating hours, or ≈ 19.1 calendar years at 1000 op-hr/yr — comfortably above the 10-year gate. Reliability at 170,000 calendar hours / 10% duty cycle ≈ 92.7%. The activation energy and Weibull shape from this fit are the inputs to Module 4 (re-entered manually — no automatic carryover).
Problem. A safety-critical brake-by-wire actuator is deployed across a 200,000-vehicle fleet operating from Alaska to Arizona. Operating temperature varies roughly 65–105 °C depending on climate, driving style, and brake load. At a $3,500 replacement cost per unit, the warranty reserve depends on how thermal variability propagates into 10-year failure rates — and on which input drives most of the uncertainty.
Workflow. Open Field Risk Assessment. On the Input tab:
- Field Stress Distribution —
Distribution = Normal,Mean = 358 K(85 °C),Std Dev = 10 K. - Life Model —
Distribution = Weibull,Shape β = 2.5,Scale η = 250,000 hours. - Acceleration Model —
Model Type = Arrhenius,Ea = 0.5 eV,Reference Temp = 358 K. - Computation Method —
Monte Carlo. Time Points —8760, 43800, 87600(1, 5, and 10 years).
Click Calculate Field Risk. The Module 2 / Module 3 references are workflow guidance; values are not carried over automatically between modules — this is a proof-of-concept reference app, so you re-enter the parameters here.
Result. The Results tab returns Field CDF, Reliability, and Hazard Rate at each time point with bootstrap 90% CIs from the Monte Carlo runs. For the inputs above the 10-year Field CDF lands at ≈ 0.11 — about 22,000 expected failures in the 200k fleet, a ≈ $77M warranty exposure at $3,500 per replacement. The Sensitivity tab tornado shows mean field temperature dominates the uncertainty; β, σ, and Ea are secondary. The actionable read: instrument a pilot fleet to validate field temperatures before refining the other inputs.
Reliability-MATLAB/
+-- +reliability/ % Function packages (all business logic)
| +-- +stats/ % Sample size, confidence intervals, Fisher's exact test
| +-- +lifedist/ % Weibull, Lognormal, Exponential fitting; Kaplan-Meier; GOF
| +-- +acceleration/ % Arrhenius acceleration modeling
| +-- +fieldrisk/ % Monte Carlo simulation, sensitivity analysis
| +-- +io/ % Data import/export (CSV, Excel)
| +-- +utils/ % ReliabilityData class, distribution helpers
+-- app/ % App Designer interactive UIs
| +-- ReliabilityMAT.mlapp % Main launcher
| +-- Life_Distribution_Fitting.mlapp
| +-- Acceleration_Modeling.mlapp
| +-- Field_risk_assess.mlapp
| +-- Statistics.mlapp
+-- data/ % Sample datasets
+-- README.md
Contribution guidance is available in CONTRIBUTING.md. External contributions may or may not be accepted; please open an issue before proposing a pull request.
The license is available in the LICENSE.txt file in this repository.
Copyright 2026 The MathWorks, Inc.




