Skip to content

Commit

Permalink
Merge pull request #120 from csdms/mdpiper/rearrange-lessons
Browse files Browse the repository at this point in the history
Rearrange Python lessons
  • Loading branch information
mdpiper authored Aug 11, 2023
2 parents ff948f6 + 0513d96 commit 1510a49
Show file tree
Hide file tree
Showing 12 changed files with 19 additions and 18 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,7 @@
"$$\\frac{\\partial C}{\\partial t} = -v \\frac{\\partial C}{\\partial x} + D\\frac{\\delta^2 C}{\\delta x^2} \n",
"\\label{eq:5}\\tag{5}$$\n",
"\n",
"Copy-paste your script from the diffusion notebook. \n",
"Copy-paste your script from the [diffusion](./diffusion.ipynb) notebook. \n",
"Adjust the script by adding advection.\n",
"You can use the code derived in the previous blocks. \n",
"\n",
Expand Down
8 changes: 4 additions & 4 deletions lessons/python/4_arrays.ipynb → lessons/python/arrays.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@
"metadata": {},
"source": [
"NumPy arrays have an attribute\n",
"(this is an object-oriented programming term; more [later](7_oop.ipynb))\n",
"(this is an object-oriented programming term; more [later](oop.ipynb))\n",
"called `shape` that provides the dimensions of an array.\n",
"\n",
"What is the shape of `a`?"
Expand Down Expand Up @@ -251,7 +251,7 @@
"source": [
"## Indexing\n",
"\n",
"NumPy arrays can be indexed in the manner described in the first lesson on [variables](1_fundamentals.ipynb)."
"NumPy arrays can be indexed in the manner described in the first lesson on [variables](fundamentals.ipynb)."
]
},
{
Expand Down Expand Up @@ -866,10 +866,10 @@
"\n",
"The [NumPy documentation](https://numpy.org/doc/stable/index.html) contains just about anything you'll need to know about NumPy.\n",
"\n",
"Last, although we deemphasize visualization here,\n",
"Although we deemphasize visualization in Ivy,\n",
"it almost always really helps to visualize data.\n",
"Data visualization is covered well in many other places,\n",
"but we do have a [notebook](./4a_plots.ipynb) demonstrating how to visualize the DEM data used here."
"but we do have a [notebook](./visualization.ipynb) demonstrating how to visualize the DEM data used here."
]
}
],
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"source": [
"# Functions\n",
"\n",
"In the [diffusion](8_diffusion.ipynb) and [advection](9_advection.ipynb) notebooks,\n",
"In the [diffusion](diffusion.ipynb) and [advection](advection.ipynb) notebooks,\n",
"we wrote code\n",
"to solve the one-dimensional diffusion and advection equations numerically,\n",
"evolve the solutions with time,\n",
Expand Down
File renamed without changes.
24 changes: 12 additions & 12 deletions lessons/python/index.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -85,25 +85,25 @@
"source": [
"## Topics\n",
"\n",
"Before we dive into the solution of the advection-diffusion problem posed by the volcanic eruption, we need to cover a series of Python and general programming topics.\n",
"In addition to the solution of the advection-diffusion problem posed by the volcanic eruption, we will cover a series of Python and general programming topics.\n",
"\n",
"### Python Fundamentals\n",
"\n",
"1. [Variables, indexing, and containers](1_fundamentals.ipynb)\n",
"1. [Libraries](2_libraries.ipynb)\n",
"1. [Loops, conditionals, and errors](3_more_fundamentals.ipynb)\n",
"1. [Arrays](4_arrays.ipynb)\n",
"1. [Variables, indexing, and containers](fundamentals.ipynb)\n",
"2. [Libraries](libraries.ipynb)\n",
"3. [Loops, conditionals, and errors](more_fundamentals.ipynb)\n",
"4. [Arrays](arrays.ipynb)\n",
"\n",
"### Python Programming\n",
"### Scientific Programming: the Advection-Diffusion Equation\n",
"\n",
"5. [Scripts](5_scripts.ipynb)\n",
"6. [Functions](6_functions.ipynb)\n",
"7. [A very basic introduction to object-oriented programming](7_oop.ipynb)\n",
"5. [Diffusion](diffusion.ipynb)\n",
"6. [Advection](advection.ipynb)\n",
"\n",
"### Scientific Programming: the Advection-Diffusion Equation\n",
"### Programming with Python\n",
"\n",
"8. [Diffusion](8_diffusion.ipynb)\n",
"9. [Advection](9_advection.ipynb)"
"5. [Functions](functions.ipynb)\n",
"6. [Modules, scripts, and the basics of packaging](modules.ipynb)\n",
"7. [An introduction to object-oriented programming](oop.ipynb)\n"
]
}
],
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
1 change: 1 addition & 0 deletions lessons/python/7_oop.ipynb → lessons/python/oop.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,7 @@
"metadata": {},
"outputs": [],
"source": [
"# Uncomment the next line to try to create a Shape.\n",
"# x = Shape()"
]
},
Expand Down
File renamed without changes.
File renamed without changes.

0 comments on commit 1510a49

Please sign in to comment.