{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Horizontal wells" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "A horizontal well is located in a 20 m thick aquifer; the hydraulic conductivity is $k = 10$ m/d and the vertical\n", "anisotropy factor is 0.1. The horizontal well is placed 5 m above the bottom of the\n", "aquifer. The well has a discharge of 1000 m$^3$/d and radius of $r=0.2$ m. The well\n", "is 200 m long and runs from $(x, y) = (−100, 0)$ to $(x, y) = (100, 0)$. \n", "\n", "Three-dimensional flow to the horizontal well is modeled by dividing the aquifer up in\n", "11 layers; the elevations are: `[20, 15, 10, 8, 6, 5.5, 5.2, 4.8, 4.4, 4, 2, 0]`. At\n", "the depth of the well, the layer thickness is equal to the diameter of the well, and it\n", "increases in the layers above and below the well. A transient timflow model is created with the\n", "Model3D command. The horizontal well is located in layer 6 and is modeled with the\n", "`DitchString` element." ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "import matplotlib.pyplot as plt\n", "import numpy as np\n", "\n", "import timflow.transient as tft\n", "\n", "figsize = (6, 6)" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "# parameters\n", "k = 10 # hydraulic conductivity, m/d\n", "Ss = 1e-4 # specific storage, 1/m\n", "anisotropy = 0.1 # kz / kh\n", "z = [20, 15, 10, 8, 6, 5.5, 5.2, 4.8, 4.4, 4, 2, 0] # top and bottoms of layers, m" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "ml = tft.Model3D(kaq=k, z=z, Saq=Ss, kzoverkh=anisotropy, tmin=0.1, tmax=100)\n", "nls = 21\n", "x = np.linspace(-100, 100, nls)\n", "y = np.zeros(nls)\n", "xy = np.vstack((x, y)).T\n", "hw = tft.DitchString(\n", " ml, xy=xy, tsandQ=[(0, 1000)], layers=6\n", ") # horizontal well in layer 6\n", "ml.solve()" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "h = ml.headgrid(\n", " np.linspace(-200, 200, 20),\n", " np.linspace(-100, 100, 20),\n", " t=[10, 20],\n", " layers=range(7),\n", " parallel=True,\n", " show_progress=True,\n", ")" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "ml.plots.contour(win=[-200, 200, -100, 100], ngr=20, t=10, layers=6, parallel=True);" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "hw.headinside(20)[0] # returns heads in each line-sink (but they are all equal)" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "t = np.linspace(1, 100, 100)\n", "hwinside = hw.headinside(t)\n", "plt.plot(t, hwinside[0, 0])\n", "plt.xlabel(\"time (d)\")\n", "plt.ylabel(\"head inside well (m)\")\n", "plt.grid()" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "# contours in vertical cross-section. interpolation between cell centers\n", "ax = ml.plots.vcontour(\n", " win=[-400, 400, 0, 0],\n", " n=100,\n", " t=50,\n", " levels=20,\n", " vinterp=True,\n", " figsize=(16, 4),\n", " horizontal_axis=\"x\",\n", ")" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "# contours in vertical cross-section. no interpolation between cell centers\n", "ax = ml.plots.vcontour(\n", " win=[-400, 400, 0, 0],\n", " n=100,\n", " t=50,\n", " levels=20,\n", " vinterp=False,\n", " figsize=(16, 4),\n", " horizontal_axis=\"x\",\n", ")" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [] } ], "metadata": { "kernelspec": { "display_name": "Python 3 (ipykernel)", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.13.5" } }, "nbformat": 4, "nbformat_minor": 4 }