\documentclass[paper=A4]{article}
\usepackage[utf8]{inputenc}

\usepackage[a4paper, left=2cm, right=2cm, top=2cm, bottom=2cm]{geometry}

\usepackage{siunitx}
\sisetup{
     group-separator = {.},
     input-decimal-markers={.},
     output-decimal-marker = {.},
     group-minimum-digits=9}
\usepackage{graphicx}
\usepackage{fancyhdr}
\usepackage{lastpage}
\usepackage{subfigure}
\usepackage{float}
\usepackage{wrapfig}
\usepackage{multicol}
\usepackage{amsmath, amssymb}
\usepackage{hyperref}

\hyphenpenalty=10000	%to stop cutting words in a paragraph

\pagestyle{fancy}
\fancyhf{}

\rhead{\includegraphics*[scale=0.013]{./Pictures/FaSTTUBe_Logo_ohneAuto.png}}
\rfoot{Page \thepage \hspace{1pt} of \pageref{LastPage}}
\lhead{Car 313, 06.03, Rev. 1}
\chead{\large Temperature Measurement Error Calculation}

\begin{document}

\begin{wrapfigure}{l}{0.4\textwidth}
	\includegraphics[width=1\linewidth]{./Pictures/NTC-schematic.png}
	\caption{NTC Voltage Divider and Filter}
	\label{fig:NTC-schematic}
\end{wrapfigure}

The following calculation is based on the Look-Up Table (LUT) provided by Vishay\cite{vishay website}, which is used in the AMS software.

Since the characteristic curve of the NTC thermistor is nonlinear, determining the absolute maximum measurement error is not straightforward. 
Therefore, we will calculate the maximum error specifically at \SI{60}{\celsius}.

As seen in Fig.\ref{fig:NTC-schematic} our voltage measurement system consists of an NTC thermistor (NTCLE413E2103F102L) and a \SI{10}{\kilo\ohm} 0.1\% resistor forming a voltage divider. 
The output voltage is then passed through an RC filter before being fed to an ADC.

To estimate the error, we calculate the highest possible measured voltage at \SI{60}{\celsius}. 
According to the design of the voltage divider, the lower the temperature, the higher the output voltage.

As shown in Fig. \ref{fig:vref}, the supply voltage $V_{REF2}$ for the voltage divider can reach a maximum value of \SI{3.006}\volt. 
Additionally, the total measurement error of the GPIO is $\pm\SI{0.0028}{\volt}$ (as shown in Fig. \ref{fig:aux}). 
Lastly, the maximum resistance of the NTC at \SI{60}{\celsius}, according to the LUT (Tab. \ref{tab:lut}), is \SI{3086.8}{\ohm}. 
The maximum possible voltage measurement can then be calculated as such:

\begin{align}
	V_{worstcase} & = V_{REF2} \cdot \frac{R_{NTC}}{R_{NTC}+R_1} + V_{err}                                                   \\
	              & = \SI{3.006}\volt \cdot \frac{\SI{3086.8}{\ohm}}{\SI{3086.8}{\ohm}+\SI{9990}{\ohm}} + \SI{0.0028}{\volt} \\
	              & \approx \SI{0.7124}{\volt}
\end{align}

To find the largest possible error, the lowest possible matching temperature should be calculated, which theoretically can produce the same voltage output. The calculation is as follows:

\begin{align}
	V_{worstcase}      & = V_{REF2} \cdot \frac{R_{NTC}}{R_{NTC}+R_1} + V_{err}                                  \\
	\SI{0.7124}{\volt} & = \SI{2.994}{\volt} \cdot \frac{R_{NTC}}{R_{NTC}+\SI{10010}{\ohm}} - \SI{0.0028}{\volt} \\
	R_{NTC}            & \approx \SI{3141.6}{\ohm}
\end{align}

Since the LUT is used to match the voltage to the temperature, and the nominal resistance from the LUT is used for the calculation, the closest matching temperature is \SI{58.7}{\celsius}.

\begin{figure}[H]
	\centering
	\includegraphics[width=\textwidth]{./Pictures/Table 5. Voltage Reference Specifications.png}
	\caption{Voltage Reference Specifications}
	\label{fig:vref}
\end{figure}

\begin{figure}[H]
	\centering
	\includegraphics[width=\textwidth]{./Pictures/Table 3. Auxiliary (AUX) ADC DC Specifications.png}
	\caption{Auxiliary (AUX) ADC DC Specifications}
	\label{fig:aux}
\end{figure}


\begin{table}[h!]
	\centering
	\caption{NTC Look Up Table}
	\label{tab:lut}
	\begin{tabular}{||c c c c c c||}
		\hline
		Temp. [\SI{}{\celsius}] & $R_{nom} [\Omega]$ & $R_{min} [\Omega]$ & $R_{max} [\Omega]$ & $\Delta R/R [\%]$ & $\Delta T [\SI{}{\celsius}]$ \\
		\hline\hline
		58                      & 3214.99            & 3145.6             & 3284.4             & 2.16              & 0.69                         \\
		58.1                    & 3204.88            & 3135.6             & 3274.2             & 2.16              & 0.69                         \\
		58.2                    & 3194.81            & 3125.6             & 3264.0             & 2.17              & 0.69                         \\
		58.3                    & 3184.78            & 3115.7             & 3253.9             & 2.17              & 0.69                         \\
		58.4                    & 3174.78            & 3105.8             & 3243.7             & 2.17              & 0.69                         \\
		58.5                    & 3164.81            & 3096.0             & 3233.7             & 2.18              & 0.69                         \\
		58.6                    & 3154.89            & 3086.2             & 3223.6             & 2.18              & 0.69                         \\
		58.7                    & 3145.00            & 3076.4             & 3213.6             & 2.18              & 0.69                         \\
		58.8                    & 3135.15            & 3066.7             & 3203.6             & 2.18              & 0.70                         \\
		58.9                    & 3125.33            & 3056.9             & 3193.7             & 2.19              & 0.70                         \\
		59                      & 3115.55            & 3047.3             & 3183.8             & 2.19              & 0.70                         \\
		59.1                    & 3105.80            & 3037.7             & 3173.9             & 2.19              & 0.70                         \\
		59.2                    & 3096.09            & 3028.1             & 3164.1             & 2.20              & 0.70                         \\
		59.3                    & 3086.41            & 3018.5             & 3154.3             & 2.20              & 0.70                         \\
		59.4                    & 3076.77            & 3009.0             & 3144.6             & 2.20              & 0.70                         \\
		59.5                    & 3067.17            & 2999.5             & 3134.9             & 2.21              & 0.71                         \\
		59.6                    & 3057.60            & 2990.0             & 3125.2             & 2.21              & 0.71                         \\
		59.7                    & 3048.06            & 2980.6             & 3115.5             & 2.21              & 0.71                         \\
		59.8                    & 3038.56            & 2971.2             & 3105.9             & 2.22              & 0.71                         \\
		59.9                    & 3029.09            & 2961.9             & 3096.3             & 2.22              & 0.71                         \\
		60                      & 3019.66            & 2952.5             & 3086.8             & 2.22              & 0.71                         \\
		60.1                    & 3010.26            & 2943.3             & 3077.3             & 2.23              & 0.71                         \\
		\hline
	\end{tabular}
\end{table}

\bibliographystyle{plain}
%\nocite{*}

\newpage
\renewcommand\refname{Reference}
\begin{thebibliography}{00}
	
	\bibitem{ADBMS6830B datasheet} \textit{Table 3 Data Sheet ADBMS6830B Rev.0 page 6}. \hyperlink{https://www.analog.com/media/en/technical-documentation/data-sheets/adbms6830b.pdf}{www.analog.com}, 01.2024
	\bibitem{ADBMS6830B datasheet} \textit{Table 5 Data Sheet ADBMS6830B Rev.0 page 7}. \hyperlink{https://www.analog.com/media/en/technical-documentation/data-sheets/adbms6830b.pdf}{www.analog.com}, 01.2024
	\bibitem{vishay website} \textit{NTC RT Calculation Tool}. \hyperlink{https://www.vishay.com/en/thermistors/ntc-rt-calculator/}{www.vishay.com}, 03.2025
	
\end{thebibliography}

\end{document}
