<jupyter_start><jupyter_text>IntroductionThis first exercise is based on the python crashcourse offered by the department "Nachrichtentechnik" and "Elektrische Messtechnik".[Python Crash-Course](https://fgnt.github.io/python_crashkurs//)  MATLAB vs. Python|                             MATLAB                             |                                       Python                                       ||:--------------------------------------------------------------:|:----------------------------------------------------------------------------------:||                           Commercial                           |                                    Open Source                                     ||     New functions via MATLAB Toolkits(no package manager)     |        Installation of new modules withpackage manager (conda or pip)         || Mainly procedual programming(Objects exists but are a hassle) |                                  Object oriented                                   ||               Mathematical Programming Language                |             General Purpose Language withmany mathematical modules              ||                No Namespaces for Core-Functions                |               Proper Namespaces (e.g. `plt.plot` instead of `plot`)                ||                          GUI included                          | Various GUIs available.We recommend [Pycharm](https://www.jetbrains.com/pycharm/) ||   Download: [Mathworks](https://de.mathworks.com/downloads/)   |              Download: [Anaconda](https://www.anaconda.com/download/)              | Numpy for MATLAB users[https://docs.scipy.org/doc/numpy-1.15.0/user/numpy-for-matlab-users.html](https://docs.scipy.org/doc/numpy-1.15.0/user/numpy-for-matlab-users.html) Common Libraries* Numpy (Vector and Matrix operations, Numeric computing)* Matplotlib (Plotting)* Pandas (Table operations)* Scikit-Learn (Machine Learning)* Tensorflow / PyTorch (Neural Networks)* SymPy (Symbolic computations)* Seaborn (Advanced Plotting)* ... Quickstart<jupyter_code>import numpy as np
import matplotlib.pyplot as plt
#plt.style.use('dark_background')

U_0 = 3     # V
u_peak = 2  # V
f_0 = 50    # 1/s

# Timevector in s (Sequence of numbers)
t = np.arange(start=0, stop=0.04, step=0.001)
u = U_0 + u_peak * np.sin(2 * np.pi * f_0 * t)
plt.plot(t, u, 'o--')
plt.xlabel('Time $t$ / s')
plt.ylabel('Voltage $u(t)$ / V')
plt.grid(True)<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.15825874694873882, 'fraction_numerical': 0.010577705451586655, 'mean_word_length': 1.5324407826982491, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 6, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 17, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '240087', 'license': 'MIT', 'n_tokens_mistral': 673, 'n_tokens_neox': 628, 'n_words': 159, 'path': 'exercises/solutions/ex01/01_introduction.ipynb', 'repo_name': 'adilsheraz/reinforcement_learning_course_materials', 'size': '2458'}