From eb384b1490623e58a0b0432d3175b28f16b4b762 Mon Sep 17 00:00:00 2001 From: vs2788 Date: Fri, 6 Jul 2018 15:22:29 +0200 Subject: [PATCH] adding tutorial 6 --- tutorial-6/Tutorial06-Solution.ipynb | 875 +++++++++++++++++++++++++++ tutorial-6/Tutorial06.ipynb | 419 +++++++++++++ tutorial-6/sheet06.pdf | Bin 0 -> 67113 bytes tutorial-6/sheet06.tex | 172 ++++++ tutorial-6/tutorial.py | 219 +++++++ 5 files changed, 1685 insertions(+) create mode 100644 tutorial-6/Tutorial06-Solution.ipynb create mode 100644 tutorial-6/Tutorial06.ipynb create mode 100644 tutorial-6/sheet06.pdf create mode 100755 tutorial-6/sheet06.tex create mode 100644 tutorial-6/tutorial.py diff --git a/tutorial-6/Tutorial06-Solution.ipynb b/tutorial-6/Tutorial06-Solution.ipynb new file mode 100644 index 0000000..ad32219 --- /dev/null +++ b/tutorial-6/Tutorial06-Solution.ipynb @@ -0,0 +1,875 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Energy System Modelling - Tutorial 06\n", + "\n", + "Clustering the European Grid\n", + "\n", + "\n" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "**Tasks:**\n", + ">-Load a European Power Grid
\n", + ">-Calculate order and size
\n", + ">-Use clustering algorithm
\n", + ">-Study the impact of the number of clusters on minimum installed capacities
\n" + ] + }, + { + "cell_type": "code", + "execution_count": 1, + "metadata": {}, + "outputs": [], + "source": [ + "import yaml\n", + "import pypsa\n", + "import numpy as np\n", + "import xarray as xr\n", + "import pandas as pd\n", + "#\n", + "import matplotlib as mpl\n", + "import matplotlib.pyplot as plt\n", + "import matplotlib.lines as mlines\n", + "from sklearn.cluster import KMeans\n", + "#\n", + "%matplotlib inline\n", + "import time\n", + "\n", + "import tutorial\n" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Introduction – the European grid" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "**Import base.nc,
\n", + "plot it with library.plot_network(network_base,option=\"kV\",basemap=\"no\")