PDA

Archiv verlassen und diese Seite im Standarddesign anzeigen : Matheproblem mit alignat



nixversteh
11-10-2015, 19:15
Hallo liebe User,

ich stelle mich im Moment etwas dumm an, kann die Fehler (angeblich 100) nicht finden:
! Extra }, or forgotten $.
\math@egroup #1->#1\egroup oder
! Missing } inserted.
<inserted text>
}
l.29 \end{alignat*} und so weiter.


\documentclass[paper=a4,fontsize=10pt]{scrartcl}
\usepackage[utf8]{inputenc}
\usepackage[disallowspaces]{mathtools}
\usepackage{amssymb}[2002/01/22] %% and additional symbols
\usepackage[ngerman]{babel}
\usepackage[detect-all, locale = DE]{siunitx}
\begin{alignat*}{2}
\notag b &= R - \SI{5}{\cm}\\
\notag r &= R - \SI{4}{\cm}\\
\notag r^2 &= a^2 + b^2 \Rightarrow\\
(R - \SI{4.5}{\cm}^2) &= \SI{4.5}^2 + (R - \SI{5}{\cm}^2)
\end{alignat*}
\end{document}

Wer hat keinen benebelten Blick und hilft mir aus der Klemme?

Vielen Dank im voaus

Gruß

Martin

Johannes_B
11-10-2015, 19:25
Zum einen fehlt \begin{document}, zum anderen fehlt in der letzten Zeile eine Einheit, und damit ein Argument für \SI.


\documentclass[paper=a4,fontsize=10pt]{scrartcl}
\usepackage[utf8]{inputenc}
\usepackage[disallowspaces]{mathtools}
\usepackage{amssymb}[2002/01/22] %% and additional symbols
\usepackage[ngerman]{babel}
\usepackage[detect-all, locale = DE]{siunitx}
\begin{document}
\begin{alignat*}{2}
\notag b &= R - \SI{5}{\cm}\\
\notag r &= R - \SI{4}{\cm}\\
\notag r^2 &= a^2 + b^2 \Rightarrow\\
(R - \SI{4.5}{\cm}^2) &= \SI{4.5}{\cm}^2 + (R - \SI{5}{\cm}^2)
\end{alignat*}
\end{document}

nixversteh
11-10-2015, 19:46
Hallo Johannes,

sorry, das erste war ein Kopierfehler ... das zweite ist meine Dummheit gewesen. Danke dir.

Gruß

Martin

PS.: Leider habe ich noch einige Fehler drin, magst noch einmal drüber blicken? Danke

\begin{alignat*}{2}
b &= R - \SI{5}{\cm}\\
r &= R - \SI{4}{\cm}\\
r^2 &= a^2 + b^2 \Rightarrow\\
(R - \SI{4.5}{\cm}^2) &= \SI{4.5}{\cm}^2 + (R - \SI{5}{\cm}^2)\\
{\cancel{R^2} - 2\cdot\SI{4.5}{\cm}~R + \cancel{\SI{20.5}{\cm}^2} &= \cancel{20,25~cm^2} + \cancel{R^2} - 10~R + \SI{25}{\cm}^2}\\
- \SI{9}{\cm}~R &= - \SI{10}{\cm}~R + \SI{25}{\cm}^2 \bigg\vert + \SI{10}{\cm}~R\\
\SI{1}{\cm}~R &= \SI{25}{\cm}^2 \bigg\vert : \SI{1}{\cm}\\
R &= \dfrac{\SI{25}{\cm}^2}{\SI{1}{\cm}}\Rightarrow\\
R &= \SI{25}{\cm}\\
r &= R - \SI{4.5}{\cm}\\
r &= \SI{25}{\cm} - \SI{4.5}{\cm} \Rightarrow\\
r &= \SI{20.5}{\cm}\Rightarrow\\
(R^{2} - r^{2})\cdot \pi &= 643,24~cm^{2}
\end{alignat*}


Lösung:
\cancel{R^2} - 2\cdot\SI{4.5}{\cm}~R + \cancel{\SI{20.5}{\cm}^2} &= \cancel{\SI{20.5}{\cm}^2} + \cancel{R^2} - 10~R + \SI{25}{\cm}^2\\