c:\Users\bnjhe\Documents\calorimetry_laboratory\ausarbeitung_laborversuch.ipynb Cell 6 line 2
<a href='vscode-notebook-cell:/c%3A/Users/bnjhe/Documents/calorimetry_laboratory/ausarbeitung_laborversuch.ipynb#W5sZmlsZQ%3D%3D?line=0'>1</a> import numpy as np
----> <a href='vscode-notebook-cell:/c%3A/Users/bnjhe/Documents/calorimetry_laboratory/ausarbeitung_laborversuch.ipynb#W5sZmlsZQ%3D%3D?line=1'>2</a> from matplotlib import pyplot as plt
<a href='vscode-notebook-cell:/c%3A/Users/bnjhe/Documents/calorimetry_laboratory/ausarbeitung_laborversuch.ipynb#W5sZmlsZQ%3D%3D?line=2'>3</a> import h5py as h5
Hinweis: Sie können die Funktion *get_json_entry* nutzen um auf Metadaten zuzugreifen.
Für die Messdatenauswertung steht Ihnen bereits ein Modul utility.py zur Verfügung. Ergänzen sie die Funktionen im Modul zwischen TODO und DONE. Sie finden weitere Hinweise im jeweiligen Bereich TODO->DONE.
%% Cell type:markdown id: tags:
#### (i) Messdaten einlesen
Lesen Sie die Messdaten in ihr Notebook ein.
%% Cell type:code id: tags:
``` python
# TODO: Define the path to hdf5 file, which containing experiment data for constant.
datafile_path_const=None
# DONE #
```
%% Cell type:code id: tags:
``` python
importlib.reload(utility)
# TODO: Read all experimental data and associated metadata from HDF5 files for data processing.
data_dict=utility.get_plot_data_from_dataset()
# DONE #
```
%% Cell type:code id: tags:
``` python
# TODO: In order to be able to process data from sensors with the same position,
# it is first necessary to obtain the index of the sensors with different positions in the list(np.array).
# it is first necessary to obtain the index of the sensors with different positions in the numpy.ndarray.
# List the index of all calorimeter sensors (index_calorimeter) and
# the environment sensor (index_environment).
# You can use this variables to easily get access to the correct measurement data later.
index_calorimeter=[]
index_environment=[]
# DONE #
```
%% Cell type:markdown id: tags:
#### (ii) Mittelwert und Standardabweichung für Plots bestimmen
Die Mittelwerte und Standardabweichungen der Messungen werden in der nächsten Sektion geplottet.
Nachdem die Mittelwerte und Standardabweichungen berechnet wurden, können Daten jeder Wärmequelle jeweils in einem numpy.ndarray gespeichert werden.
%% Cell type:code id: tags:
``` python
importlib.reload(utility)
# TODO: Calculate the average value and standard deviation of the calorimeter sensors and the environment sensor.
Im Kalorimeter befinden sich mehrere Sensoren, deren Mittelwerte sowie Standardabweichungen der Messung an jeden Zeitpunkt bestimmt wurden. Die Messdaten bzw. ihre Mittelwerte sollen in einem Plot eingetragen werden. Die Standardabweichungen der Sensoren sind als Errorbar im Plot zu sehen.
%% Cell type:code id: tags:
``` python
importlib.reload(utility)
# TODO: Use the temperature and time data for plotting
plot_temp_over_time()
utility.plot_temp_over_time()
# DONE #
```
%% Cell type:markdown id: tags:
#### (iv) Metadaten auslesen
Die notwendigen Daten bzw. Metadaten für die Berechnung der Wärmekapazität wird ausgelesen.
%% Cell type:code id: tags:
``` python
# Heat capacity of Water has been given
water_heat_capa=4.18
# TODO: Read mass of the water from the metadata of the experiment.
water_mass=None
# DONE #
```
%% Cell type:code id: tags:
``` python
# TODO: Reading heater related data from hdf5 file, please use the same datafile_path_const variable for the HDF5 path.
# Hint: Note whether the data is stored as an array or a scalar in the hdf5 dataset.
current=None
heat_time=None
voltage=None
# DONE #
```
%% Cell type:markdown id: tags:
#### (v) Anfangs- und Endwert der Temperatur
Die Anfangs- und Endwert der Temperatur im Kloriemeter sind notwendig, um die Wärmekapazität zu bestimmen.
Eine Möglichkeit wäre, durch das Maxium bzw. Minium und einen Schwellenwert ist ein Teil der Daten zu entnehmen.
Daraus sind Mittelwerte zu berechnen. Die entsprechenden Mittelwerte können als Anfangs- und Endtemperatur verwendet werden.
%% Cell type:code id: tags:
``` python
importlib.reload(utility)
# TODO: Calculation of temperature data necessary to determine the specific heat capacity
# TODO: Determine the initial temperature of the sample.
# Since the temperature of the water bath is stable, the initial temperature
# of the sample can be taken as the average of the 10 data after the start of the measurement.
temperature_start_sample=None
# DONE #
```
%% Cell type:markdown id: tags:
#### (vi) spezifische Wärmekapazität bestimmen
%% Cell type:code id: tags:
``` python
# TODO: Calulate specific heat capacity of the sample.
sample_heat_capa=None
# DONE #
```
%% Cell type:markdown id: tags:
#### (Vii) Ergebnis
%% Cell type:code id: tags:
``` python
sample_heat_capa
```
%% Cell type:markdown id: tags:
## Diskussion
Analysieren Sie Ihre Ergebnisse aus wissenschaflticher Sicht. Berücksichtigen Sie dabei Ihre oben genannte Forschungsfrage. Wie wirkt sich die mit der Probe aus dem Heißwasserbad transportierte Wassermenge auf das Ergebnis aus? Welche weiteren Fehlerquellen gibt es?