Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 26 additions & 12 deletions notebooks/part1_flopy/09-gwt-voronoi-demo.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
"\n",
"MODFLOW 6 includes a Groundwater Transport (GWT) Model for simulation of solute transport through the subsurface. The GWT Model can be used with structured or unstructured model grids. The purpose of this example is to demonstrate the construction, running, and post-processing of a simple solute transport model.\n",
"\n",
"The solute transport model is based on an existing flow model of the Freyberg example. The flow model usesd a voronoi model grid to simulate steady-state conditions. In this notebook, we create a transient solute transport model using the same voronoi grid that was used for flow.\n",
"The solute transport model is based on an existing flow model of the Freyberg example. The flow model uses a voronoi model grid to simulate steady-state conditions. In this notebook, we create a transient solute transport model using the same voronoi grid.\n",
"\n",
"The following steps are used in this notebook.\n",
"The following steps are taken in this notebook:\n",
"* Load the existing flow model into FloPy\n",
"* Plot the model grid\n",
"* Create the solute transport model\n",
Expand Down Expand Up @@ -127,7 +127,17 @@
"id": "24a69ac7-9fd0-4dbb-940e-138f7a7493e5",
"metadata": {},
"source": [
"Assign a constant concentration condition to the x, y location of 550, 7900. Use the `modelgrid.intersect` method to determine the cell number for the constant concentration condition."
"We will assign a constant concentration condition to the x, y location of 550, 7900. Use the `modelgrid.intersect` method to determine the cell number for the constant concentration condition."
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "a23b4416",
"metadata": {},
"outputs": [],
"source": [
"x, y = 550, 7900"
]
},
{
Expand All @@ -137,7 +147,8 @@
"metadata": {},
"outputs": [],
"source": [
"gwf.modelgrid.intersect(550, 7900)"
"cc_cell = gwf.modelgrid.intersect(x, y)\n",
"cc_cell"
]
},
{
Expand All @@ -157,7 +168,7 @@
"source": [
"gwf.modelgrid.plot()\n",
"ax = plt.gca()\n",
"ax.plot(550, 7900, marker=\"o\", lw=0, color=\"red\", )"
"ax.plot(x, y, marker=\"o\", lw=0, color=\"red\", )"
]
},
{
Expand Down Expand Up @@ -285,19 +296,22 @@
" cell2d=cell2d,\n",
")\n",
"ic = flopy.mf6.ModflowGwtic(gwt, strt=0.0)\n",
"adv = flopy.mf6.ModflowGwtadv(\n",
" gwt, \n",
" scheme=\"tvd\",\n",
")\n",
"# use the TVD advection solver scheme, upstream is default\n",
"adv = flopy.mf6.ModflowGwtadv(gwt, scheme=\"tvd\")\n",
"# define logitudinal and transverse dispersivity\n",
"dsp = flopy.mf6.ModflowGwtdsp(gwt, alh=50.0, ath1=5)\n",
"# define a uniform porosity in the \"mobile\" portion of the aquifer\n",
"mst = flopy.mf6.ModflowGwtmst(gwt, porosity=0.2)\n",
"# point the transport model to the flow model head and budget outputs\n",
"# these must include outputs from ALL time steps\n",
"pd = [\n",
" (\"GWFHEAD\", f\"../../{model_ws_load}{name_load}.hds\", None),\n",
" (\"GWFBUDGET\", f\"../../{model_ws_load}{name_load}.cbc\", None),\n",
"]\n",
"fmi = flopy.mf6.ModflowGwtfmi(gwt, packagedata=pd)\n",
"ssm = flopy.mf6.ModflowGwtssm(gwt)\n",
"cnc = flopy.mf6.ModflowGwtcnc(gwt, stress_period_data=[(0, 2027, 100.)])\n",
"# this is where we define the constanc concentration\n",
"cnc = flopy.mf6.ModflowGwtcnc(gwt, stress_period_data=[(0, cc_cell, 100.)])\n",
"\n",
"oc = flopy.mf6.ModflowGwtoc(\n",
" gwt,\n",
Expand Down Expand Up @@ -457,7 +471,7 @@
],
"metadata": {
"kernelspec": {
"display_name": "Python 3 (ipykernel)",
"display_name": "pyclass",
"language": "python",
"name": "python3"
},
Expand All @@ -471,7 +485,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.12.1"
"version": "3.12.11"
}
},
"nbformat": 4,
Expand Down
Loading