renamed file for Untertweng
This commit is contained in:
@@ -215,7 +215,6 @@
|
|||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"%matplotlib qt5\n",
|
"%matplotlib qt5\n",
|
||||||
"# Con_T_ime loop\n",
|
|
||||||
"\n",
|
"\n",
|
||||||
"# create a figure and subplots to display the velocity and pressure distribution across the pipeline in each pipeline step\n",
|
"# create a figure and subplots to display the velocity and pressure distribution across the pipeline in each pipeline step\n",
|
||||||
"fig1,axs1 = plt.subplots(2,1)\n",
|
"fig1,axs1 = plt.subplots(2,1)\n",
|
||||||
@@ -247,28 +246,7 @@
|
|||||||
"cell_type": "code",
|
"cell_type": "code",
|
||||||
"execution_count": 6,
|
"execution_count": 6,
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [
|
"outputs": [],
|
||||||
{
|
|
||||||
"ename": "KeyboardInterrupt",
|
|
||||||
"evalue": "",
|
|
||||||
"output_type": "error",
|
|
||||||
"traceback": [
|
|
||||||
"\u001b[1;31m---------------------------------------------------------------------------\u001b[0m",
|
|
||||||
"\u001b[1;31mKeyboardInterrupt\u001b[0m Traceback (most recent call last)",
|
|
||||||
"\u001b[1;32mv:\\georg\\Documents\\Persönliche Dokumente\\Arbeit\\Kelag\\Coding\\Python\\DT_Slot_3\\Kelag_DT_Slot_3\\Untertweng.ipynb Cell 6\u001b[0m in \u001b[0;36m<cell line: 5>\u001b[1;34m()\u001b[0m\n\u001b[0;32m <a href='vscode-notebook-cell:/v%3A/georg/Documents/Pers%C3%B6nliche%20Dokumente/Arbeit/Kelag/Coding/Python/DT_Slot_3/Kelag_DT_Slot_3/Untertweng.ipynb#W5sZmlsZQ%3D%3D?line=63'>64</a>\u001b[0m lo_qmax\u001b[39m.\u001b[39mremove()\n\u001b[0;32m <a href='vscode-notebook-cell:/v%3A/georg/Documents/Pers%C3%B6nliche%20Dokumente/Arbeit/Kelag/Coding/Python/DT_Slot_3/Kelag_DT_Slot_3/Untertweng.ipynb#W5sZmlsZQ%3D%3D?line=64'>65</a>\u001b[0m \u001b[39m# plot new pressure and velocity distribution in the pipeline\u001b[39;00m\n\u001b[1;32m---> <a href='vscode-notebook-cell:/v%3A/georg/Documents/Pers%C3%B6nliche%20Dokumente/Arbeit/Kelag/Coding/Python/DT_Slot_3/Kelag_DT_Slot_3/Untertweng.ipynb#W5sZmlsZQ%3D%3D?line=65'>66</a>\u001b[0m lo_p, \u001b[39m=\u001b[39m axs1[\u001b[39m0\u001b[39;49m]\u001b[39m.\u001b[39;49mplot(Pip_x_vec,pressure_conversion(pipe\u001b[39m.\u001b[39;49mget_current_pressure_distribution()\u001b[39m-\u001b[39;49mp_0,pUnit_calc,pUnit_conv),marker\u001b[39m=\u001b[39;49m\u001b[39m'\u001b[39;49m\u001b[39m.\u001b[39;49m\u001b[39m'\u001b[39;49m,c\u001b[39m=\u001b[39;49m\u001b[39m'\u001b[39;49m\u001b[39mblue\u001b[39;49m\u001b[39m'\u001b[39;49m)\n\u001b[0;32m <a href='vscode-notebook-cell:/v%3A/georg/Documents/Pers%C3%B6nliche%20Dokumente/Arbeit/Kelag/Coding/Python/DT_Slot_3/Kelag_DT_Slot_3/Untertweng.ipynb#W5sZmlsZQ%3D%3D?line=66'>67</a>\u001b[0m lo_pmin, \u001b[39m=\u001b[39m axs1[\u001b[39m0\u001b[39m]\u001b[39m.\u001b[39mplot(Pip_x_vec,pressure_conversion(pipe\u001b[39m.\u001b[39mget_lowest_pressure_per_node()\u001b[39m-\u001b[39mp_0,pUnit_calc,pUnit_conv),c\u001b[39m=\u001b[39m\u001b[39m'\u001b[39m\u001b[39mred\u001b[39m\u001b[39m'\u001b[39m)\n\u001b[0;32m <a href='vscode-notebook-cell:/v%3A/georg/Documents/Pers%C3%B6nliche%20Dokumente/Arbeit/Kelag/Coding/Python/DT_Slot_3/Kelag_DT_Slot_3/Untertweng.ipynb#W5sZmlsZQ%3D%3D?line=67'>68</a>\u001b[0m lo_pmax, \u001b[39m=\u001b[39m axs1[\u001b[39m0\u001b[39m]\u001b[39m.\u001b[39mplot(Pip_x_vec,pressure_conversion(pipe\u001b[39m.\u001b[39mget_highest_pressure_per_node()\u001b[39m-\u001b[39mp_0,pUnit_calc,pUnit_conv),c\u001b[39m=\u001b[39m\u001b[39m'\u001b[39m\u001b[39mred\u001b[39m\u001b[39m'\u001b[39m)\n",
|
|
||||||
"File \u001b[1;32mc:\\Users\\georg\\anaconda3\\envs\\DT_Slot_3\\lib\\site-packages\\matplotlib\\axes\\_axes.py:1634\u001b[0m, in \u001b[0;36mAxes.plot\u001b[1;34m(self, scalex, scaley, data, *args, **kwargs)\u001b[0m\n\u001b[0;32m 1632\u001b[0m lines \u001b[39m=\u001b[39m [\u001b[39m*\u001b[39m\u001b[39mself\u001b[39m\u001b[39m.\u001b[39m_get_lines(\u001b[39m*\u001b[39margs, data\u001b[39m=\u001b[39mdata, \u001b[39m*\u001b[39m\u001b[39m*\u001b[39mkwargs)]\n\u001b[0;32m 1633\u001b[0m \u001b[39mfor\u001b[39;00m line \u001b[39min\u001b[39;00m lines:\n\u001b[1;32m-> 1634\u001b[0m \u001b[39mself\u001b[39;49m\u001b[39m.\u001b[39;49madd_line(line)\n\u001b[0;32m 1635\u001b[0m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39m_request_autoscale_view(scalex\u001b[39m=\u001b[39mscalex, scaley\u001b[39m=\u001b[39mscaley)\n\u001b[0;32m 1636\u001b[0m \u001b[39mreturn\u001b[39;00m lines\n",
|
|
||||||
"File \u001b[1;32mc:\\Users\\georg\\anaconda3\\envs\\DT_Slot_3\\lib\\site-packages\\matplotlib\\axes\\_base.py:2281\u001b[0m, in \u001b[0;36m_AxesBase.add_line\u001b[1;34m(self, line)\u001b[0m\n\u001b[0;32m 2279\u001b[0m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39m_set_artist_props(line)\n\u001b[0;32m 2280\u001b[0m \u001b[39mif\u001b[39;00m line\u001b[39m.\u001b[39mget_clip_path() \u001b[39mis\u001b[39;00m \u001b[39mNone\u001b[39;00m:\n\u001b[1;32m-> 2281\u001b[0m line\u001b[39m.\u001b[39;49mset_clip_path(\u001b[39mself\u001b[39;49m\u001b[39m.\u001b[39;49mpatch)\n\u001b[0;32m 2283\u001b[0m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39m_update_line_limits(line)\n\u001b[0;32m 2284\u001b[0m \u001b[39mif\u001b[39;00m \u001b[39mnot\u001b[39;00m line\u001b[39m.\u001b[39mget_label():\n",
|
|
||||||
"File \u001b[1;32mc:\\Users\\georg\\anaconda3\\envs\\DT_Slot_3\\lib\\site-packages\\matplotlib\\artist.py:790\u001b[0m, in \u001b[0;36mArtist.set_clip_path\u001b[1;34m(self, path, transform)\u001b[0m\n\u001b[0;32m 787\u001b[0m \u001b[39mif\u001b[39;00m transform \u001b[39mis\u001b[39;00m \u001b[39mNone\u001b[39;00m:\n\u001b[0;32m 788\u001b[0m \u001b[39mif\u001b[39;00m \u001b[39misinstance\u001b[39m(path, Rectangle):\n\u001b[0;32m 789\u001b[0m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mclipbox \u001b[39m=\u001b[39m TransformedBbox(Bbox\u001b[39m.\u001b[39munit(),\n\u001b[1;32m--> 790\u001b[0m path\u001b[39m.\u001b[39;49mget_transform())\n\u001b[0;32m 791\u001b[0m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39m_clippath \u001b[39m=\u001b[39m \u001b[39mNone\u001b[39;00m\n\u001b[0;32m 792\u001b[0m success \u001b[39m=\u001b[39m \u001b[39mTrue\u001b[39;00m\n",
|
|
||||||
"File \u001b[1;32mc:\\Users\\georg\\anaconda3\\envs\\DT_Slot_3\\lib\\site-packages\\matplotlib\\patches.py:278\u001b[0m, in \u001b[0;36mPatch.get_transform\u001b[1;34m(self)\u001b[0m\n\u001b[0;32m 276\u001b[0m \u001b[39mdef\u001b[39;00m \u001b[39mget_transform\u001b[39m(\u001b[39mself\u001b[39m):\n\u001b[0;32m 277\u001b[0m \u001b[39m\"\"\"Return the `~.transforms.Transform` applied to the `Patch`.\"\"\"\u001b[39;00m\n\u001b[1;32m--> 278\u001b[0m \u001b[39mreturn\u001b[39;00m \u001b[39mself\u001b[39;49m\u001b[39m.\u001b[39;49mget_patch_transform() \u001b[39m+\u001b[39m artist\u001b[39m.\u001b[39mArtist\u001b[39m.\u001b[39mget_transform(\u001b[39mself\u001b[39m)\n",
|
|
||||||
"File \u001b[1;32mc:\\Users\\georg\\anaconda3\\envs\\DT_Slot_3\\lib\\site-packages\\matplotlib\\patches.py:754\u001b[0m, in \u001b[0;36mRectangle.get_patch_transform\u001b[1;34m(self)\u001b[0m\n\u001b[0;32m 747\u001b[0m \u001b[39mdef\u001b[39;00m \u001b[39mget_patch_transform\u001b[39m(\u001b[39mself\u001b[39m):\n\u001b[0;32m 748\u001b[0m \u001b[39m# Note: This cannot be called until after this has been added to\u001b[39;00m\n\u001b[0;32m 749\u001b[0m \u001b[39m# an Axes, otherwise unit conversion will fail. This makes it very\u001b[39;00m\n\u001b[0;32m 750\u001b[0m \u001b[39m# important to call the accessor method and not directly access the\u001b[39;00m\n\u001b[0;32m 751\u001b[0m \u001b[39m# transformation member variable.\u001b[39;00m\n\u001b[0;32m 752\u001b[0m bbox \u001b[39m=\u001b[39m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mget_bbox()\n\u001b[0;32m 753\u001b[0m \u001b[39mreturn\u001b[39;00m (transforms\u001b[39m.\u001b[39mBboxTransformTo(bbox)\n\u001b[1;32m--> 754\u001b[0m \u001b[39m+\u001b[39m transforms\u001b[39m.\u001b[39;49mAffine2D()\u001b[39m.\u001b[39;49mrotate_deg_around(\n\u001b[0;32m 755\u001b[0m bbox\u001b[39m.\u001b[39;49mx0, bbox\u001b[39m.\u001b[39;49my0, \u001b[39mself\u001b[39;49m\u001b[39m.\u001b[39;49mangle))\n",
|
|
||||||
"File \u001b[1;32mc:\\Users\\georg\\anaconda3\\envs\\DT_Slot_3\\lib\\site-packages\\matplotlib\\transforms.py:2042\u001b[0m, in \u001b[0;36mAffine2D.rotate_deg_around\u001b[1;34m(self, x, y, degrees)\u001b[0m\n\u001b[0;32m 2040\u001b[0m \u001b[39m# Cast to float to avoid wraparound issues with uint8's\u001b[39;00m\n\u001b[0;32m 2041\u001b[0m x, y \u001b[39m=\u001b[39m \u001b[39mfloat\u001b[39m(x), \u001b[39mfloat\u001b[39m(y)\n\u001b[1;32m-> 2042\u001b[0m \u001b[39mreturn\u001b[39;00m \u001b[39mself\u001b[39;49m\u001b[39m.\u001b[39;49mtranslate(\u001b[39m-\u001b[39;49mx, \u001b[39m-\u001b[39;49my)\u001b[39m.\u001b[39;49mrotate_deg(degrees)\u001b[39m.\u001b[39mtranslate(x, y)\n",
|
|
||||||
"File \u001b[1;32mc:\\Users\\georg\\anaconda3\\envs\\DT_Slot_3\\lib\\site-packages\\matplotlib\\transforms.py:2020\u001b[0m, in \u001b[0;36mAffine2D.rotate_deg\u001b[1;34m(self, degrees)\u001b[0m\n\u001b[0;32m 2012\u001b[0m \u001b[39mdef\u001b[39;00m \u001b[39mrotate_deg\u001b[39m(\u001b[39mself\u001b[39m, degrees):\n\u001b[0;32m 2013\u001b[0m \u001b[39m\"\"\"\u001b[39;00m\n\u001b[0;32m 2014\u001b[0m \u001b[39m Add a rotation (in degrees) to this transform in place.\u001b[39;00m\n\u001b[0;32m 2015\u001b[0m \n\u001b[1;32m (...)\u001b[0m\n\u001b[0;32m 2018\u001b[0m \u001b[39m and :meth:`scale`.\u001b[39;00m\n\u001b[0;32m 2019\u001b[0m \u001b[39m \"\"\"\u001b[39;00m\n\u001b[1;32m-> 2020\u001b[0m \u001b[39mreturn\u001b[39;00m \u001b[39mself\u001b[39;49m\u001b[39m.\u001b[39;49mrotate(math\u001b[39m.\u001b[39;49mradians(degrees))\n",
|
|
||||||
"File \u001b[1;32mc:\\Users\\georg\\anaconda3\\envs\\DT_Slot_3\\lib\\site-packages\\matplotlib\\transforms.py:2008\u001b[0m, in \u001b[0;36mAffine2D.rotate\u001b[1;34m(self, theta)\u001b[0m\n\u001b[0;32m 2005\u001b[0m b \u001b[39m=\u001b[39m math\u001b[39m.\u001b[39msin(theta)\n\u001b[0;32m 2006\u001b[0m rotate_mtx \u001b[39m=\u001b[39m np\u001b[39m.\u001b[39marray([[a, \u001b[39m-\u001b[39mb, \u001b[39m0.0\u001b[39m], [b, a, \u001b[39m0.0\u001b[39m], [\u001b[39m0.0\u001b[39m, \u001b[39m0.0\u001b[39m, \u001b[39m1.0\u001b[39m]],\n\u001b[0;32m 2007\u001b[0m \u001b[39mfloat\u001b[39m)\n\u001b[1;32m-> 2008\u001b[0m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39m_mtx \u001b[39m=\u001b[39m np\u001b[39m.\u001b[39;49mdot(rotate_mtx, \u001b[39mself\u001b[39;49m\u001b[39m.\u001b[39;49m_mtx)\n\u001b[0;32m 2009\u001b[0m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39minvalidate()\n\u001b[0;32m 2010\u001b[0m \u001b[39mreturn\u001b[39;00m \u001b[39mself\u001b[39m\n",
|
|
||||||
"File \u001b[1;32m<__array_function__ internals>:180\u001b[0m, in \u001b[0;36mdot\u001b[1;34m(*args, **kwargs)\u001b[0m\n",
|
|
||||||
"\u001b[1;31mKeyboardInterrupt\u001b[0m: "
|
|
||||||
]
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"source": [
|
"source": [
|
||||||
"# needed for turbine convergence\n",
|
"# needed for turbine convergence\n",
|
||||||
"convergence_parameters = [p_old[-2],v_old[-2],Pip_dia,Pip_area,Pip_angle,Pip_f_D,Pip_pw_vel,rho,Pip_dt,p_old[-1]]\n",
|
"convergence_parameters = [p_old[-2],v_old[-2],Pip_dia,Pip_area,Pip_angle,Pip_f_D,Pip_pw_vel,rho,Pip_dt,p_old[-1]]\n",
|
||||||
@@ -350,7 +328,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"cell_type": "code",
|
"cell_type": "code",
|
||||||
"execution_count": null,
|
"execution_count": 7,
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
@@ -416,7 +394,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"cell_type": "code",
|
"cell_type": "code",
|
||||||
"execution_count": null,
|
"execution_count": 8,
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
Reference in New Issue
Block a user