Run the model to get the table of failure times.
Run the model to see the counts against time.
Run the model to see the distributions over the deposition holes.
Run the model to see every deposition hole: the workbook’s sheet “Calc”.
Buffer erosion and canister corrosion, hole by hole
For a KBS-3 repository the question is: in how many deposition holes does flowing, dilute groundwater erode the bentonite buffer far enough that sulphide in the water reaches the copper canister by advection, and how many canisters does that sulphide corrode through within the assessment time? SKB answered it in SR-Site and again in the PSAR with an Excel workbook, ErosionCorrosionModel_2_0 (SKBdoc 1895159, documented in SKBdoc 1895157), later ported to Python. This page is that calculation, restructured: the arithmetic in one module, the file readers in another, and every parameter carrying the name it has in the workbook and in the Python port. Nothing is uploaded; the files you open stay in the browser.
The answer takes three inputs: a table of every deposition hole from the hydrogeological modelling (flow, aperture, travel time, transport resistance, and which holes are cut by large fractures), a distribution of sulphide concentrations, and the parameter set on the left. What comes back is the table of failure times that feeds the radionuclide transport calculations, the key outputs of the workbook’s Info sheet, and the distribution plots of its five plot sheets.
What happens to each hole
1. Rejection
Holes that would not be used are rejected by criteria on what could be observed during construction. A hole is rejected if any selected criterion holds: FPC ≠ 0 (a fracture that intersects the full tunnel perimeter also cuts the hole); EFPC ≥ the number of consecutive holes (a fracture cuts this and four more neighbouring holes); FLEN above the fracture-length limit; transmissivity above 10−6 m²/s and FLEN above 443 m (the T/L criterion); optionally a Darcy flux above a limit, or membership of an inflow-rejection list. Rejected holes take no part in what follows but stay in the total: the corrected outputs are scaled by Ncanisters / (Ntot − Nrejected), 6000 canisters by default.
Transmissivity is not in the hydro file; it is back-calculated from the transport aperture δ with Doe’s relation T = (δ/0.5)² (TR-09-20, equation 3-2), or with the cubic law T = (δ/a)³ if you choose it.
2. Flow at the hole
The hydro model gives the Darcy flux U0 in the fracture crossing the hole. The water velocity in that fracture is
v = U0·w/δ
with w = 5 m, the height Serco used to turn a fracture flow into a Darcy flux, so that using it again recovers the flow (R-09-20, equation 3-8 and D-7). A DarcyTools table carries the velocity itself and is used as it is. The flow through the hole once the buffer has gone is
qeb = fconc·U0·w·2rh
and the equivalent flow rate that carries sulphide to the copper (TR-06-33, chapter 6; TR-10-42, appendix) is the smaller of qeb and 1.13·√(qeb·Dw·Vzone)/dbuffer, where Vzone = dbuffer·π(rh² − rcan²)/2 is the volume of the eroded half of the buffer. The two cross at qlim, 0.0885 m³/yr with the default geometry.
3. Time to advective conditions
The buffer is advective once mbuffadv = 1200 kg has been lost. The loss rate depends on the model chosen:
OldKTH | SR-Site: R = Aero·δ·v0.41, Aero = 27.2 kg/(m·yr) with v in m/yr (TR-10-66, 4.3.1; TR-09-35). |
NewKTH | PSAR: N = 4ρsδφR·√(DR·rRSS·v) (TR-16-11, chapter 4). DR(cion) is a cubic fit in log c; with “effective DR” it is (ftemp√DR(ctemp) + fglac√DR(cglac))². rRSS, where the smectite is lost to the water, is rh·(G/2 / W(G/2))² with G/2 = ½·Diπ(φi − φR) / (2φR√(DRrhv)) and W the Lambert function — or simply rh + 5 cm when forced (TR-21-03), which is the PSAR setting. |
Sediment | TR-16-11: the smaller of the loss rate at the rim, Jexp·δ·2πrRSS,sed·sin α, and the rate at which the lost material can settle in the fracture, δ³/(12μ)·(ρagg − ρw)g·φRρs·2rRSS,sed. |
Ero+Sed | The two TR-16-11 rates added. |
Amphos2023, Amphos2025 | Power-law fits from Amphos21 (P-23-03 equation 5-1; P-25-05 equation 7, weighted over temperate and glacial cation concentrations), as carried in the Python ports. |
tadv = mbuffadv / (rate · ftdilute)
where ftdilute is the fraction of the time the water is dilute enough to erode: 0.25 in SR-Site, 0.5 in the PSAR. A hole with no flowing fracture, or a rejected one, never becomes advective (1E+99 in the tables). “Initial advection” sets tadv = 0 everywhere, the case of no buffer from the start.
4. Corrosion and the failure table
With the buffer advective, sulphide at concentration [HS⁻] corrodes the copper at the rate Qeq·[HS⁻]·MCu/(fHS·ρCu·Acorr) over the area Acorr = πrcan·hcorr (TR-10-66, 4.3.2–4.3.3), so the time to corrode through dcan = 47 mm is
tcorr = CorrHoleFact / (Qeq·[HS⁻]), CorrHoleFact = dcan·Acorr·ρCu / (fHS·MCu)
the copper in the corroded height, in kmol of sulphide. The sulphide distribution is a table of values; for each accepted hole the model finds the smallest value that fails the canister before the assessment time (HSmin), counts how many table values exceed it, and writes one row per such value: tfail = tadv + tcorr, with the hole’s F, tw and q beside it. Holes whose particle did not reach the surface (OKFLAG ≠ 0) are left out of the table but not rejected. The mean number of failed canisters is the number of rows divided by the number of sulphide values, and the corrected figure scales that to the normalising number of canisters over the accepted holes.
5. The distribution plots
Cumulative distributions over the ensemble of holes of: the hydro model’s own Qeq, with and without the addition for a thermally spalled zone (TR-10-66, equations 4-9 to 4-12); the corrosion rate through an intact buffer at a fixed sulphide concentration, with and without spalling (TR-10-66, equation 4-19a); the buffer loss rate of the chosen model; the corrosion rate through an eroded buffer at the fixed concentration; the hydraulic gradient; the aperture; the velocity; and the time to advection. Each is drawn for all holes and again after rejection, with the reference lines the workbook draws (5 cm of copper in 106 and 105 years; 1200 kg in the assessment time and in the dilute fraction of it).
Hydro files
Four shapes are read, detected from the content rather than the extension:
| ConnectFlow CSV | A header row and one row per hole, as the SR-Site and PSAR deliveries (*_pline_merged.csv and the like) and as Excel writes the workbook’s hydro sheets. Needed: POINT or NPOINT, OKFLAG, U0, QEQ, TW, F, TRAPP, FPC, EFPC, FLEN; the other columns are ignored. Comma, semicolon or tab separated; a decimal comma is understood when the file has no decimal points. |
|---|---|
| ConnectFlow PTB | The parameter-table file the CSVs were made from: # comment lines, a # POINT XS YS … header and space-separated rows. |
| Excel | An .xlsx whose first fitting sheet is such a table — TestCaseHydro_2_0.xlsx, or the Corr/Uncorr workbooks. |
| DarcyTools | The performance-measure tables of the Hydro-SÄK work: a Name column with several particle rows per hole (the first is taken), U [m/year], Qeq (ECPM) [m3/year], tw [year], F [year/m], and either Aperture [m], Utot [m/year] and T/F flags Collected, ZFMC, FPC, EFPC-5 (the .dtpm form, with a Total DHs: line above the header) or iFPC, iEFPC, Porosity (ECPM) and Number of fractures in contact, from which the aperture is 8·porosity/fractures and U0 is scaled by 8/w — exactly as the 2.0 and 2.4 Python ports read them. These tables have no fracture length, so the length and T/L criteria reject nothing, and they list only the holes with particles: give the layout size so the normalisation counts the rest. |
Every file becomes one realisation. Load ten and you have the ten-realisation semi-correlated case of the PSAR: the summary shows min, mean and max over realisations, the failure table carries the realisation number, and the distributions can be pooled. The page never keeps your files beyond the visit; settings are kept in the browser.
Sulphide
HSForsmark and HSLaxemar are the workbook’s tables to the digit; HSTest is the ten-value table of
the code test. The generated distribution replaces the workbook’s one-point HSGeneric: a shifted
lognormal by mean, standard deviation and shift (the 2.4 port’s _gen_hs_generic), or
a log10-normal by μ and σ (the @Risk workbook’s 10^RiskNormal(−5.79757, 0.63849)),
drawn as midpoint quantiles so that the same parameters always give the same table. A custom list
is any text with numbers in it.
Checking it
The code documentation ships a hydro test file built to be checked by hand. Choose the built-in
Code test case: with the SR-Site settings it applies (OldKTH, 25 % dilute, HSTest), the
failure table must hold 35 rows — ten for hole 1 at 850,000 to 940,000 years, ten for hole 2 at
85,000 to 94,000, ten for hole 3 at 900,000 to 990,000 and five for hole 4 at 950,000 to 990,000 —
with 17 holes rejected (11 by FPC, 12–16 and 25–33 by EFPC, 17 by fracture length, 18 by T/L), a
corrected mean of 3.5, one failure by 100,000 years and four advective positions. The
PSAR base case with the PSAR defaults must give 612 rejected holes, 41 advective positions
at one million years, three at 100,000, four failure times, a corrected mean of 0.0827632 and an
earliest failure at 189,441.71 years — the numbers cached in the workbook itself. All of that, the
TR-16-11 rates read off that report’s figures 4-5 and 4-7, the Python port’s failure tables in six
configurations, and the readers for every file format are exercised by
resources/tests/erosion_corrosion/test-model.js.
Two places where the sources differ from each other, and what this page does: the workbook’s VBA Lambert W stops at a residual of 10−3 while the Python port uses SciPy’s — this page solves to machine precision, which matters only with “force rRSS” off; and the Python port’s HSForsmark table is rounded to six digits, so its failure times sit about 10−6 from the workbook’s — this page carries the workbook’s digits. The count “failed canisters at the highest sulphide concentration” follows the workbook (holes with at least one failing value), which the Python port matches with the default filters on.
Parameters
Every setting and parameter, with its default (the PSAR workbook’s), its name in the workbook and its attribute in the Python port. A changed value is marked in the panel and listed on the Summary tab; Save case writes them all to a JSON file that Open case… reads back, and the Excel export puts them on its first sheet.
References
| SKBdoc 1895157 | Hedin A, 2020. Documentation of the code for erosion, sedimentation and corrosion calculations in the PSAR. The model, the workbook’s structure and the test case. |
| SKBdoc 1895159, 1895160 | ErosionCorrosionModel_2_0.xlsm and TestCaseHydro_2_0.xlsx. |
| SKBdoc 1927770, 1939004 | Models, input data and results for the analytical erosion, sedimentation and corrosion calculations of the PSAR; the case files. |
| TR-21-01 | Post-closure safety for the final repository for spent nuclear fuel at Forsmark — PSAR version. Sections 10.3.11, 10.4.9, 12.2.2, 12.6.2 and 14.3.2 use these results. |
| TR-10-66 | Corrosion calculations report for the safety assessment SR-Site. The corrosion models and the SR-Site erosion model. |
| TR-16-11 | Neretnieks I, Moreno L, Liu L, 2017. Clay erosion — impact of flocculation and gravitation. The PSAR erosion and sedimentation models. |
| TR-09-35, TR-10-64 | The buffer erosion rate expression of SR-Site and its fit. |
| TR-06-33, TR-10-42 | Qeq for an eroded buffer, and which expression to use where. |
| TR-11-01 | Long-term safety for the final repository at Forsmark (SR-Site). Rejection criteria (5.2.3), buffer loss for advection (10.3.9), dilute time (10.3.11), pessimistic aperture (12.2.2). |
| R-09-20, R-09-19 | Groundwater flow modelling of periods with temperate climate conditions — Forsmark; the hydro data columns (appendix B) and the inflow criteria. |
| P-23-03, P-25-05 | Amphos21 buffer erosion expressions carried by the Python ports. |