Added DEPRECATED marking to the old forcing function.

I do not want to remove it yet. Not until something like that exists in the DSL code.
This commit is contained in:
Miikka Vaisala
2019-06-19 13:46:03 +08:00
parent b5753f0bec
commit 40b4a61a4c
3 changed files with 37 additions and 7 deletions

View File

@@ -7,7 +7,8 @@
"outputs": [],
"source": [
"import astar.data as ad\n",
"import astar.visual as vis"
"import astar.visual as vis\n",
"import numpy as np"
]
},
{
@@ -23,7 +24,7 @@
"metadata": {},
"outputs": [],
"source": [
"meshdir = \"/scratch/data/mvaisala/iotest/\""
"meshdir = \"/scratch/data/mvaisala/forcingtest/\""
]
},
{
@@ -32,10 +33,26 @@
"metadata": {},
"outputs": [],
"source": [
"imesh = 0\n",
"imesh = 10000\n",
"mesh = ad.read.Mesh(imesh, fdir=meshdir)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Auxuliary variables"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"uu_tot = np.sqrt(mesh.uu[0]**2.0 + mesh.uu[1]**2.0 + mesh.uu[2]**2.0)"
]
},
{
"cell_type": "markdown",
"metadata": {},
@@ -51,7 +68,11 @@
},
"outputs": [],
"source": [
"vis.slices.plot_3(mesh, mesh.uu[0], title = r'$u_x$', bitmap = False, fname = 'uux')"
"vis.slices.plot_3(mesh, uu_tot, title = r'$\\|u\\|$')\n",
"vis.slices.plot_3(mesh, mesh.uu[0], title = r'$u_x$')\n",
"vis.slices.plot_3(mesh, mesh.uu[1], title = r'$u_y$')\n",
"vis.slices.plot_3(mesh, mesh.uu[2], title = r'$u_z$')\n",
"vis.slices.plot_3(mesh, mesh.lnrho, title = r'$\\ln_\\rho$')"
]
},
{
@@ -86,6 +107,13 @@
"outputs": [],
"source": []
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
},
{
"cell_type": "code",
"execution_count": null,