Coupled solver: implicit P->T with upwind advection + wells
Ubuntu+1: Claude Opus 4.6
464a35c
wells.py: WellSpec + apply_wells builds per-cell volumetric, injection-heat,
and production-mass arrays for a list of point wells.
coupled.py: sequential implicit step — Darcy pressure, then energy with
conduction + upwind advection + well sources. Returns pressure, temperature,
and face mass fluxes. run_coupled_transient wraps n_steps.
Smoke tests (3 passing):
* zero-wells coupled run matches pure-conduction energy solver to 1e-6
* injector/producer pair elevates P at injector, depresses at producer,
cools the injector cell, and breaks radial symmetry in the +x direction
* single-step sanity check: shapes and finiteness with wells
Full suite: 13/13 green.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Energy solver passes 1D conduction benchmark (0.18% err)
Ubuntu+1: Claude Opus 4.6
259ebe4
Implicit backward-Euler conduction with Dirichlet BCs via identity-row.
mean_rel_err=0.18%, max_rel_err=0.37% vs erfc semi-infinite slab.
Second of two Day-1 GO/NO-GO gates — solver track is GO.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Adds solver/{grid,properties,darcy}.py and solver/benchmarks/theis.py.
Single-phase linearized Boussinesq pressure equation, fully-implicit
backward-Euler, 5-point FV stencil on a structured 2D grid. IAPWS-IF97
reference-state water properties via the iapws PyPI package.
Theis benchmark (tests/test_solver_theis.py):
- 64x64 grid, 1 km square (15.625 m cells)
- k=1e-13, phi=0.15, c_t=1.5e-9, mass_rate=0.01 kg/s injection
- 200 steps of dt=25 s, sampled r in {3,5,7}*dx at 3 times
- mean relative error: 0.38% (threshold 5%)
- max relative error: 0.90% (threshold 10%)
- monotonic pressure rise at the well cell: PASS
Day 1 Afternoon, pressure-solver milestone: GREEN.
Next: energy solver + 1D conduction benchmark.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>