A Julia package that simulates coaxial deep borehole heat exchangers in full 3D, single wells or arrays, solving heat advection and diffusion through fluid, pipes, grout and rock on an adaptive grid, on CPU or on NVIDIA and AMD GPUs, with a Stanford geothermal workshop paper behind it.
Trade-offs
- Strang splitting gives each part its own method: ROCK2 for vertical diffusion, implicit ADI for horizontal, semi-Lagrangian for advection.
- A structured Cartesian grid keeps the implicit solves tridiagonal; cells grow from 2.5 mm at the pipes to about 10 m away from them.
- Where advection sits inside the ADI steps was settled empirically: every other placement tested went numerically unstable.
Q&A4
About 150 by 150 by 50, close to a million grid points, for one borehole; time steps of 50 to 150 seconds, orders of magnitude above what a naive explicit scheme allows.
The same KernelAbstractions.jl kernels run on CPU for testing and on NVIDIA or AMD GPUs; switching is a change of backend.
A separate reproducibility repo reproduces results from Li et al. (2021), Hu et al. (2020) and Brown et al. (2023), with convergence studies and well array runs.
Rapid prototyping and well design exploration, from one well to arrays, with GPU speed for long-term simulations.
Links
- Live(opens in a new tab)cwittens.github.io/GeothermalWells.jl
- GitHub(opens in a new tab)github.com/cwittens/GeothermalWells.jl
- Documentation(opens in a new tab)cwittens.github.io/GeothermalWells.jl/stable
- Paper(opens in a new tab)pangea.stanford.edu/ERE/db/GeoConf/papers/SGW/2026/Wittenstein.pdf
- Reproducibility repo(opens in a new tab)github.com/cwittens/2026_DBHEs_Arrays
Built by
Reviews
Loading reviews
More in Julia
Perth.jlJulia project schedules: a CPM engine in the REPL, a live Gantt in the browser
PlutoSlides.jlBeamer-style slideshows from Pluto notebooks, with live code and results
More in GPU
See all 23 →
jobdGPU-aware job broker for a few personal machines, with an MCP server- PXALLM server tuned for Tesla P100, V100 and GTX 10-series GPUs
GlydLossless compression that keeps bf16 weights and KV cache smaller on the GPU- gnss_gpuGPU GNSS positioning for urban canyons with particle filters and ray-traced NLOS
impLLM inference server built only for NVIDIA Blackwell GPUs
AlzeoOne-command installer that turns a DGX Spark or GB10 box into an AI server