Skip to content

Commit

Permalink
282 Binder not working with Poetry issue (#340)
Browse files Browse the repository at this point in the history
* Update 1_Timoshenko_Beam.ipynb to remove vscode hash
* Update 2_Slithering_Snake.ipynb to remove vscode hash
  • Loading branch information
Ali-7800 authored Mar 9, 2024
1 parent c55677b commit f582749
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 9 deletions.
5 changes: 4 additions & 1 deletion examples/Binder/1_Timoshenko_Beam.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@
}
},
"outputs": [],
"source": []
"source": [
"!pip install \"pyelastica[examples,docs]\""
]
},
{
"cell_type": "code",
Expand Down Expand Up @@ -194,6 +196,7 @@
},
"outputs": [],
"source": [
"\n",
"dl = base_length / n_elem\n",
"dt = 0.01 * dl\n",
"timoshenko_sim.dampen(shearable_rod).using(\n",
Expand Down
19 changes: 11 additions & 8 deletions examples/Binder/2_Slithering_Snake.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,15 @@
"To set up the simulation, the first thing you need to do is import the necessary classes. As with the Timoshenko bean, we need to import modules which allow us to more easily construct different simulation systems. We also need to import a rod class, all the necessary forces to be applied, timestepping functions, and callback classes. "
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"!pip install \"pyelastica[examples,docs]\""
]
},
{
"cell_type": "code",
"execution_count": null,
Expand All @@ -32,13 +41,7 @@
"import numpy as np\n",
"\n",
"# import modules\n",
"from elastica.modules import (\n",
" BaseSystemCollection,\n",
" Constraints,\n",
" Forcing,\n",
" CallBacks,\n",
" Damping,\n",
")\n",
"from elastica.modules import BaseSystemCollection, Constraints, Forcing, CallBacks, Damping\n",
"\n",
"# import rod class, damping and forces to be applied\n",
"from elastica.rod.cosserat_rod import CosseratRod\n",
Expand Down Expand Up @@ -111,7 +114,7 @@
")\n",
"\n",
"# Add rod to the snake system\n",
"snake_sim.append(shearable_rod)"
"snake_sim.append(shearable_rod)\n"
]
},
{
Expand Down

0 comments on commit f582749

Please sign in to comment.