Commit 379abd90 by Fabian Neumann

### update sheets

parent b9ddcf9e
No preview for this file type
 ... @@ -67,18 +67,29 @@ ... @@ -67,18 +67,29 @@ %===================================================================== %===================================================================== \begin{document} \begin{document} \begin{flushright} \textbf{Energy System Modelling }\\ {\small Karlsruhe Institute of Technology}\\ {\small Institute for Automation and Applied Informatics}\\ {\small Summer Term 2019}\\ \end{flushright} \vspace{-0.5em} \hrulefill \vspace{0.3em} \begin{center} \begin{center} \textbf{\Large Energy System Modelling }\\ {SS 2018, Karlsruhe Institute of Technology}\\ {Institute for Automation and Applied Informatics}\\ [1em] \textbf{\textsc{\Large Tutorial I: Time Series Analysis}}\\ \textbf{\textsc{\Large Tutorial I: Time Series Analysis}}\\ \small Will be worked on in the exercise session on Wednesday, 11 July 2018.\\[1.5em] \small Will be worked on in the exercise session on Thursday, 6 June 2019.\\[1.5em] \end{center} \end{center} \vspace{1em} \vspace{-0.8em} \hrulefill \vspace{0.8em} %=============== ====================================================== %=============== ====================================================== \paragraph{Problem I.1 \normalsize (data analysis).}~\\ \paragraph{Problem I.1 (programming) -- Data Analysis}~\\ %===================================================================== %===================================================================== The following data are made available to you on the course home The following data are made available to you on the course home ... @@ -94,16 +105,17 @@ They describe (quasi-real) time series for wind power generation $$W(t)$$, solar ... @@ -94,16 +105,17 @@ They describe (quasi-real) time series for wind power generation $$W(t)$$, solar \item For all three regions, plot the time series $$W(t)$$, \item For all three regions, plot the time series $$W(t)$$, $$S(t)$$, $$S(t)$$, $$L(t)$$ for a winter month (January) and a summer month (July). $$L(t)$$ for a winter month (January) and a summer month (July). \item Resample the time series to daily, weekly and monthly data points and visualise them in plots. Can you identify some recurring patterns? \item For all three regions, plot the duration curve for $$W(t)$$, $$S(t)$$, $$L(t)$$. \item For all three regions, plot the duration curve for $$W(t)$$, $$S(t)$$, $$L(t)$$. \item For all three regions, plot the probability density function of $$W(t)$$, $$S(t)$$, $$L(t)$$. \item For all three regions, plot the probability density function of $$W(t)$$, $$S(t)$$, $$L(t)$$. \item Apply a (Fast) Fourier Transform to the the three time series $X \in W(t), S(t), L(t)$: \item Recurring patterns of time series can also be visualised more rigorously by applying a Fourier Transform. Apply a (Fast) Fourier Transform to the the three time series $X \in W(t), S(t), L(t)$: \begin{equation*} \begin{equation*} \tilde{X}(\omega) = \int_0^T X(t) e^{\i \omega t} \,\ud t \, . \tilde{X}(\omega) = \int_0^T X(t) e^{\i \omega t} \,\ud t \, . \end{equation*} \end{equation*} For all three regions, plot the energy spectrum For all three regions, plot the energy spectrum $\left| \tilde{X}(\omega) \right|^2$ as a function of $\left| \tilde{X}(\omega) \right|^2$ as a function of $\omega$. Discuss the relationship of these results with the $\omega$. Discuss the relationship of these results with the findings obtained in (b)-(e). findings obtained in (b)-(f). \item Normalize the time series to one, so that $$\expect{W} = \expect{S} = \expect{L} = 1$$. \item Normalize the time series to one, so that $$\expect{W} = \expect{S} = \expect{L} = 1$$. Now, for all three regions, plot the mismatch time series Now, for all three regions, plot the mismatch time series \begin{equation*} \begin{equation*} ... @@ -112,12 +124,15 @@ They describe (quasi-real) time series for wind power generation $$W(t)$$, solar ... @@ -112,12 +124,15 @@ They describe (quasi-real) time series for wind power generation $$W(t)$$, solar for the same winter and summer months as in (c). Choose for the same winter and summer months as in (c). Choose $$\alpha \in \{0.0, 0.5, 0.75, 1.0\}$$ with $$\gamma = 1$$, $$\alpha \in \{0.0, 0.5, 0.75, 1.0\}$$ with $$\gamma = 1$$, and $\gamma \in \{0.5, 0.75, 1.0, 1.25, 1.5\}$ with $\alpha = 0.75$. and $\gamma \in \{0.5, 0.75, 1.0, 1.25, 1.5\}$ with $\alpha = 0.75$. \item For all three regions, repeat (b)-(f) for the mismatch time series. Which configuration entails the lowest mismatch on average and in extremes? \item For all three regions, repeat (b)-(g) for the mismatch time series. \end{enumerate} \end{enumerate} \pagebreak \pagebreak %===================================================================== %===================================================================== \paragraph{Problem I.2 \normalsize (analytical).}~\\ \paragraph{Problem I.2 (analytical) -- Effect of Seasonality}~\\ %===================================================================== %===================================================================== \begin{wrapfigure}[11]{r}{0pt} \begin{wrapfigure}[11]{r}{0pt} ... @@ -181,10 +196,12 @@ The time series are normalized to ... @@ -181,10 +196,12 @@ The time series are normalized to \pagebreak \pagebreak %=============== ====================================================== %=============== ====================================================== \paragraph{Remarks (Python pointers or where to start).}~\\ \paragraph{Remarks -- Introductions to Python}~\\ %===================================================================== %===================================================================== I found the python notebook based notes of Robert Johansson to be a In the tutorials we will repeatedly work with the programming language Python. If you are unfamiliar with the language, you might find the following tutorials useful.\\ The Python notebook based notes of Robert Johansson are a comprehensive kick starter\footnote{\url{http://nbviewer.jupyter.org/github/jrjohansson/scientific-python-lectures/tree/master/}}. comprehensive kick starter\footnote{\url{http://nbviewer.jupyter.org/github/jrjohansson/scientific-python-lectures/tree/master/}}. \begin{itemize} \begin{itemize} \item \item ... @@ -195,14 +212,9 @@ comprehensive kick starter\footnote{\url{http://nbviewer.jupyter.org/github/jrjo ... @@ -195,14 +212,9 @@ comprehensive kick starter\footnote{\url{http://nbviewer.jupyter.org/github/jrjo brush over it and stop reading early, i.e. if you read the word brush over it and stop reading early, i.e. if you read the word \verb+classes+ you already know too much). \verb+classes+ you already know too much). \item \href{http://nbviewer.jupyter.org/github/jrjohansson/scientific-python-lectures/blob/master/Lecture-2-Numpy.ipynb}{Lecture~2} is the most important and closely connected to the exercises. \item \href{http://nbviewer.jupyter.org/github/jrjohansson/scientific-python-lectures/blob/master/Lecture-2-Numpy.ipynb}{Lecture~2} is the most important and closely connected to the exercises. \item You might as well stop now, but if you \emph{are} hooked, I recommend \href{http://nbviewer.jupyter.org/github/jrjohansson/scientific-python-lectures/blob/master/Lecture-3-Scipy.ipynb}{Lecture~3} for more physics and \href{http://nbviewer.jupyter.org/github/jrjohansson/scientific-python-lectures/blob/master/Lecture-4-Matplotlib.ipynb}{Lecture~4} for prettier graphs. \item You might as well stop now, but if you \emph{are} hooked, have a look at \href{http://nbviewer.jupyter.org/github/jrjohansson/scientific-python-lectures/blob/master/Lecture-3-Scipy.ipynb}{Lecture~3} for more physics and \href{http://nbviewer.jupyter.org/github/jrjohansson/scientific-python-lectures/blob/master/Lecture-4-Matplotlib.ipynb}{Lecture~4} for prettier graphs. \end{itemize} Further reference material of help is: \begin{itemize} \item The website-books \url{http://python-course.eu/} (english), \url{http://python-kurs.eu/} (german); especially if you only \emph{very} quickly skim over the \href{https://www.python-course.eu/python3_course.php}{python3 tutorial} and switch over to the \href{http://www.python-course.eu/numerical_programming.php}{numerical python} stuff early; especially of interest might be the \href{http://www.python-course.eu/pandas.php}{pandas} bit in the end, which will make the exercises a breeze at the expense of yet another package to learn. \item the exhaustive (overly so) official python tutorial\footnote{\url{https://docs.python.org/3.6/tutorial/}} available in \href{https://docs.python.org/3.6/tutorial/}{english} and \href{https://py-tutorial-de.readthedocs.org/}{german}; which will NOT introduce you to numpy or scipy. \end{itemize} \end{itemize} Further reference material of help is are the website-books \url{http://python-course.eu/} (english), \url{http://python-kurs.eu/} (german); especially of interest might be the \href{http://www.python-course.eu/pandas.php}{pandas} bit in the end, which will make the exercises a breeze at the expense of yet another package to learn. \end{document} \end{document}
This diff is collapsed.
This source diff could not be displayed because it is too large. You can view the blob instead.
 ... @@ -20,13 +20,14 @@ ... @@ -20,13 +20,14 @@ }, }, { { "cell_type": "code", "cell_type": "code", "execution_count": 10, "execution_count": 1, "metadata": {}, "metadata": {}, "outputs": [], "outputs": [], "source": [ "source": [ "import numpy as np\n", "import numpy as np\n", "import pandas as pd\n", "import pandas as pd\n", "import matplotlib.pyplot as plt\n", "import matplotlib.pyplot as plt\n", "plt.style.use('bmh')\n", "%matplotlib inline" "%matplotlib inline" ] ] }, }, ... @@ -334,7 +335,7 @@ ... @@ -334,7 +335,7 @@ }, }, { { "cell_type": "code", "cell_type": "code", "execution_count": 18, "execution_count": 2, "metadata": {}, "metadata": {}, "outputs": [], "outputs": [], "source": [ "source": [ ... @@ -345,7 +346,7 @@ ... @@ -345,7 +346,7 @@ }, }, { { "cell_type": "code", "cell_type": "code", "execution_count": 54, "execution_count": 3, "metadata": {}, "metadata": {}, "outputs": [], "outputs": [], "source": [ "source": [ ... @@ -363,10 +364,94 @@ ... @@ -363,10 +364,94 @@ }, }, { { "cell_type": "code", "cell_type": "code", "execution_count": null, "execution_count": 4, "metadata": {}, "metadata": {}, "outputs": [], "outputs": [ "source": [] { "data": { "text/html": [ "
\n", "\n", "\n", "