{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Wells in different systems" ] }, { "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", "plt.rcParams[\"font.size\"] = 8.0\n", "plt.rcParams[\"figure.figsize\"] = (8, 3)" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "T = 500 # transmissivity\n", "S = 1e-4\n", "t = np.logspace(-2, 2, 101)\n", "r = 20\n", "Q = 1000" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Regular Theis well" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "ml = tft.ModelMaq(kaq=25, z=[20, 0], Saq=S / 20, tmin=0.01, tmax=100)\n", "w = tft.DischargeWell(ml, tsandQ=[(0, Q)], rw=1e-5)\n", "ml.solve()\n", "h1 = ml.head(r, 0, t)" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Hantush for several different $c$ values" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "clist = [1e2, 1e3, 1e4]\n", "hhantush = np.zeros((len(clist), len(t)))\n", "for i, c in enumerate(clist):\n", " ml = tft.ModelMaq(\n", " kaq=25, z=[21, 20, 0], c=c, Saq=S / 20, topboundary=\"semi\", tmin=0.01, tmax=100\n", " )\n", " w = tft.DischargeWell(ml, tsandQ=[(0, Q)], rw=1e-5)\n", " ml.solve()\n", " hhantush[i] = ml.head(r, 0, t)[0]" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "plt.semilogx(t, h1[0], label=\"Theis\")\n", "for i in range(3):\n", " plt.semilogx(t, hhantush[i], label=\"c=\" + str(int(clist[i])))\n", "plt.legend(loc=\"best\")\n", "plt.title(\"head at r=20\")\n", "plt.grid()" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Two-aquifer system \n", "\n", "With same $T$ in both layers and several different $c$ values" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "clist = [1e2, 1e3, 1e4]\n", "htwolayer = np.zeros((len(clist), len(t)))\n", "for i, c in enumerate(clist):\n", " ml = tft.ModelMaq(\n", " kaq=[25, 25],\n", " z=[20, 0, -5, -25],\n", " c=c,\n", " Saq=S / 20,\n", " topboundary=\"conf\",\n", " tmin=0.01,\n", " tmax=100,\n", " )\n", " w = tft.DischargeWell(ml, tsandQ=[(0, Q)], rw=1e-5)\n", " ml.solve()\n", " htwolayer[i] = ml.head(r, 0, t)[0]" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "plt.semilogx(t, h1[0], label=\"Theis\")\n", "for i in range(3):\n", " plt.semilogx(t, htwolayer[i], label=\"c=\" + str(int(clist[i])))\n", "plt.legend(loc=\"best\")\n", "plt.title(\"head at r=20\")\n", "plt.grid()" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Model that starts at $t=10$ days" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "ml = tft.ModelMaq(kaq=25, z=[20, 0], Saq=S / 20, tmin=0.01, tmax=100, tstart=10)\n", "w = tft.DischargeWell(ml, tsandQ=[(10, Q)], rw=1e-5)\n", "ml.solve()\n", "ht10 = ml.head(r, 0, t)" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "plt.semilogx(t, ht10[0], label=\"time shifted in model\")\n", "plt.semilogx(t + 10, h1[0], \"r--\", label=\"time shifted by hand\")\n", "plt.legend(loc=\"best\")\n", "plt.title(\"note that heads are not computed at the same times\")\n", "plt.grid()" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Well with entry resistance" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "k = 25 # m/d\n", "H = 20 # m\n", "Ss = 1e-4 / H # m^(-1)\n", "rw = 0.3 # m\n", "res = 0.1 # d\n", "Q = 500 # m^3/d\n", "ml = tft.Model3D(kaq=k, z=np.linspace(H, 0, 6), Saq=Ss, tmin=0.001, tmax=10)\n", "w = tft.Well(ml, tsandQ=[(0, Q)], rw=rw, res=res, layers=[0, 1, 2])\n", "ml.solve()" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "hin = w.headinside(t=2)[:, 0]\n", "hout = ml.head(rw, 0, t=2, layers=[0, 1, 2])[:, 0]\n", "print(\"head inside well at t=2: \", hin)\n", "print(\"head just outside well at t=2\", hout)" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "print(\"discharge of screens at t=2\", w.discharge(2)[:, 0])\n", "Qcheck = 2 * np.pi * rw * ml.aq.Haq[:3] * (hout - hin) / res\n", "print(\"discharge from bc at t=2: \", Qcheck)" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Well with different entry resistance per layer" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "k = 25 # m/d\n", "H = 20 # m\n", "Ss = 1e-4 / H # m^(-1)\n", "rw = 0.3 # m\n", "res = [0.05, 0.1, 0.15] # d\n", "Q = 500 # m^3/d\n", "ml = tft.Model3D(kaq=k, z=np.linspace(H, 0, 6), Saq=Ss, tmin=0.001, tmax=10)\n", "w = tft.Well(ml, tsandQ=[(0, Q)], rw=rw, res=res, layers=[0, 1, 2])\n", "ml.solve()" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "hin = w.headinside(t=2)[:, 0]\n", "hout = ml.head(rw, 0, t=2, layers=[0, 1, 2])[:, 0]\n", "print(\"head inside well at t=2: \", hin)\n", "print(\"head just outside well at t=2\", hout)" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "print(\"discharge of screens at t=2\", w.discharge(2)[:, 0])\n", "Qcheck = 2 * np.pi * rw * ml.aq.Haq[:3] * (hout - hin) / res\n", "print(\"discharge from bc at t=2: \", Qcheck)" ] } ], "metadata": { "language_info": { "name": "python" } }, "nbformat": 4, "nbformat_minor": 4 }