diff options
Diffstat (limited to 'Master/texmf-dist')
-rw-r--r-- | Master/texmf-dist/doc/latex/chemmacros/README | 35 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/chemmacros/chemmacros_doc_de.pdf | bin | 0 -> 271993 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/latex/chemmacros/chemmacros_doc_de.tex | 557 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/chemmacros/chemmacros_doc_en.pdf | bin | 0 -> 276867 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/latex/chemmacros/chemmacros_doc_en.tex | 552 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/chemmacros/chemmacros.sty | 412 |
6 files changed, 1556 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/latex/chemmacros/README b/Master/texmf-dist/doc/latex/chemmacros/README new file mode 100644 index 00000000000..99ac626a2df --- /dev/null +++ b/Master/texmf-dist/doc/latex/chemmacros/README @@ -0,0 +1,35 @@ +-------------------------------------------------------------------------- +the chemmarcos package v1.0 +a collection of macros to make typesetting chemistry documents more +convenient +2011/05/15 +-------------------------------------------------------------------------- +Clemens Niederberger +Web: http://www.mychemistry.eu/ +E-Mail: contact@mychemistry.eu +-------------------------------------------------------------------------- +Copyright 2011 Clemens Niederberger + +This work may be distributed and/or modified under the +conditions of the LaTeX Project Public License, either version 1.3 +of this license or (at your option) any later version. +The latest version of this license is in + http://www.latex-project.org/lppl.txt +and version 1.3 or later is part of all distributions of LaTeX +version 2005/12/01 or later. + +This work has the LPPL maintenance status `maintained'. + +The Current Maintainer of this work is Clemens Niederberger. + +This work consists of the files chemmacros.sty, chemmacros_doc_de.tex +and chemmacros_doc_en.tex +-------------------------------------------------------------------------- +chemmacros is a collection of macros and commands which are intended to +make typesetting chemistry documents faster and more convenient. +This includes some nomenclature commands, oxidation numbers, +thermodynamical data, newman projections... +-------------------------------------------------------------------------- +If you have any ideas, questions, suggestions or bugs to report, please +feel free to contact me. +--------------------------------------------------------------------------
\ No newline at end of file diff --git a/Master/texmf-dist/doc/latex/chemmacros/chemmacros_doc_de.pdf b/Master/texmf-dist/doc/latex/chemmacros/chemmacros_doc_de.pdf Binary files differnew file mode 100644 index 00000000000..a589e67b0b2 --- /dev/null +++ b/Master/texmf-dist/doc/latex/chemmacros/chemmacros_doc_de.pdf diff --git a/Master/texmf-dist/doc/latex/chemmacros/chemmacros_doc_de.tex b/Master/texmf-dist/doc/latex/chemmacros/chemmacros_doc_de.tex new file mode 100644 index 00000000000..09c7900a752 --- /dev/null +++ b/Master/texmf-dist/doc/latex/chemmacros/chemmacros_doc_de.tex @@ -0,0 +1,557 @@ +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% ------------------------------------------------------------------------------------- % +% - chemmacros - chemmacros_doc_de.tex ------------------------------------------------ % +% - a collection of macros to make typesetting chemistry documents more convenient ---- % +% ------------------------------------------------------------------------------------- % +% - Clemens Niederberger -------------------------------------------------------------- % +% - 2011/05/15 ------------------------------------------------------------------------ % +% ------------------------------------------------------------------------------------- % +% - http://www.mychemistry.eu/ -------------------------------------------------------- % +% - contact@mychemistry.eu ------------------------------------------------------------ % +% ------------------------------------------------------------------------------------- % +% - If you have any ideas, questions, suggestions or bugs to report, please feel free - % +% - to contact me. -------------------------------------------------------------------- % +% ------------------------------------------------------------------------------------- % +% - Copyright 2011 Clemens Niederberger - % +% - - % +% - This work may be distributed and/or modified under the - % +% - conditions of the LaTeX Project Public License, either version 1.3 - % +% - of this license or (at your option) any later version. - % +% - The latest version of this license is in - % +% - http://www.latex-project.org/lppl.txt - % +% - and version 1.3 or later is part of all distributions of LaTeX - % +% - version 2005/12/01 or later. - % +% - - % +% - This work has the LPPL maintenance status `maintained'. - % +% - - % +% - The Current Maintainer of this work is Clemens Niederberger. - % +% - - % +% - This work consists of the files chemmacros.sty, chemmacros_doc_de.tex, - % +% - chemmacros_doc_de.tex, README - % +% ------------------------------------------------------------------------------------- % +\documentclass[parskip=full]{scrartcl} +\usepackage[ngerman]{babel} +\usepackage[utf8]{inputenx} +\usepackage[dvipsnames]{xcolor} + \colorlet{code}{RawSienna} +\usepackage{listings,url,chemfig,chemstyle,bpchem,siunitx,booktabs} +\usepackage[version=3,arrows=pgf]{mhchem} +\usepackage[xspace=true]{chemmacros} +\usetikzlibrary{calc} +\lstset{literate={ä}{{\"a}}1 {ö}{{\"o}}1 {ü}{{\"u}}1 {Ä}{{\"A}}1 {Ö}{{\"O}}1 {Ü}{{\"U}}1 {ß}{{\ss}}1} +\lstset{ + language=[LaTeX]TeX, + basicstyle={\ttfamily}, % Grundstil + extendedchars=true, + numbers=left, % Zeilennummern + numberstyle=\tiny, % Größe des Zeilennummern + numberblanklines=true, % Leerzeilen nummerieren + gobble=1, % das erste Leerzeichen abschneiden + xleftmargin=20pt, % Einrückung links + breaklines=true, % Zeilenumbruch + moredelim=[is][\color{red!25!purple}]{!!}{!!},% Hervorhebung + commentstyle={\color[named]{Gray}}, + emph={begin,end}, % Umgebungen hervorheben + emphstyle=\color{red}, + keywordstyle=\color{code}, + keywordstyle=[20]\color{blue}, + morekeywords=[20]{reaction,reactions}, + texcsstyle=[30]\color{code}, + moretexcs=[30]{ce,cf,chemabove,chembelow,chemfig,cip,cis,color,delm,delp,Dfi,draw,E,el,ElPot,ensuremath,Enthalpy,Entropy,Gibbs,gram,Helmholtz,HtO,Hpl,Hyd,IUPAC,joule,kelvin,kilo,lewis,Lfi,liter,mch,meta,milli,mole,newman,node,ntr,nu,ortho,ox,OX,para,pch,per,phorb,porb,prt,pxorb,pyorb,pzorb,Rcip,Rconf,redox,renewtagform,setorbheight,Scip,Sconf,scrm,scrp,setatomsep,setnewstate,sisetup,standardstate,State,text,tikz,trans,transitionstatesymbol,usetikzlibrary,xspace,Z}, + } + +\usepackage{hyperref} + \hypersetup{colorlinks=true, + plainpages=false, + bookmarksopen=true, + bookmarksopenlevel=2, + bookmarksnumbered=true, + pdfauthor={Clemens Niederberger}, + pdftitle={chemmacros - Manual}, + pdfsubject={Hilfsmakros für den Chemiker}, + pdfkeywords={chemmacros}, + pdfcreator={LaTeX} + } + +\newcommand\paket[1]{`#1'\footnote{\url{http://www.ctan.org/pkg/#1}}} +\makeatletter +\let\CMname\CM@name% +\makeatother +\begin{document} + +\begin{titlepage} + \centering + \Huge\makeatletter\CM@name\ v\CM@version\makeatother + \vskip.5cm + \large\makeatletter\CM@date\makeatother + \vskip.5cm + \Large Clemens \textsc{Niederberger} + \vskip.25cm + \normalsize\url{http://www.mychemistry.eu/}\\ + \href{mailto:contact@mychemistry.eu}{contact@mychemistry.eu} + \vskip2cm + \begin{abstract} + `\CMname' ist eine Sammlung von Hilfs-Makros für Chemiker. Sie sind dazu gedacht, das Schreiben von chemischen Dokumenten bequemer zu machen. + %This is a collection of helper macros for the chemist which are intended to make writing chemical documents more convenient. + \end{abstract} +\end{titlepage} + +\tableofcontents + +\section{Lizenz, Voraussetzungen} +\makeatletter\CM@name\ v\CM@version\makeatother\ steht unter der \LaTeX\ Project Public License Version 1.3 oder später.\newline(\url{http://www.latex-project.org/lppl.txt}) + +\CMname\ ruft intern die Pakete \paket{xkeyval}, \paket{amsmath} und `tikz' (Ti\textbf{\textit{k}}Z = \paket{pgf}) auf. Sind sie nicht vorhanden, wird eine Fehlermeldung ausgegeben. + +Manche Befehle haben allerdings unterschiedliche Definitionen, je nachdem ob andere Pakete vom Benutzer \emph{vorher} geladen wurden oder nicht. Manche Befehle werden auch nur definiert, wenn ein bestimmtes Paket geladen ist. Das betrifft die Pakete \paket{mhchem}, \paket{siunitx} und \paket{chemstyle} sowie die Befehle aus Abschnitt \ref{sec:teilchen}, \lstinline=\ox= (Abschnitt \ref{ssec:oxidationszahlen}), die Befehle aus Abschnitt \ref{sec:standardstate} und die Umgebungenen aus Abschnitt \ref{sec:mhchem}. + +Für die Paketoption \lstinline=xspace= (Abschnitt \ref{sec:optionen}) wird das Paket \paket{xspace} benötigt. + +Wenn der Benutzer das Paket `mhchem' \emph{vor} \CMname\ lädt, so werden außerdem die Pakete \paket{mathtools} und \paket{environ} benötigt. + +Für den \lstinline=\redox=-Befehl (Abschnitt \ref{sec:redoxreaktionen}) und den \lstinline=\newman=-Befehl (Abschnitt \ref{sec:newman} muss die Tikzlibrary `calc' eingebunden werden. + +Volle Funktionalität steht also mit folgender oder ähnlicher Präambel bereit: +\begin{lstlisting} + \usepackage{siunitx,chemstyle} + \usepackage[version=3,arrows=pgf]{mhchem} + \usepackage[xspace=true]{chemmacros} + \usetikzlibrary{calc} +\end{lstlisting} + +\section{Teilchen, Ionen und ein Symbol}\label{sec:teilchen} +Eine Reihe einfacher Makros, um häufig gebrauchte Teilchen sowie ein Symbol darzustellen: +\begin{itemize} + \item\lstinline=\Hpl= \Hpl (Proton) + \item\lstinline=\Hyd= \Hyd (Hydroxid) + \item\lstinline=\HtO= \HtO (Oxonium) + \item\lstinline=\el= \el (Elektron) + \item\lstinline=\prt= \prt (Proton) + \item\lstinline=\ntr= \ntr (Neutron) + \item\lstinline=\transitionstatesymbol= \transitionstatesymbol\ Über\-gangs\-zu\-stands\-symbol (verwendet Ti\textbf{\textit{k}}Z) +\end{itemize} +Diese Befehle sind sowohl im Text- wie im Mathematikmodus einsetzbar. Je nachdem, ob `mhchem' geladen wurde oder nicht, werden die ersten drei Teilchen mit dem \lstinline=\cf{}=-Befehl von `mhchem' oder mit \lstinline=\ensuremath{\text{}}= geschrieben. + +\section{Stereo-Deskriptoren, Nomenklatur}\label{sec:stereo} +Die folgenden Makros sollen das Schreiben von IUPAC-Namen etwas erleichtern: +\begin{itemize} + \item Cahn-Ingold-Prelog: + \begin{itemize} + \item\lstinline=\Rcip= \Rcip + \item\lstinline=\Scip= \Scip + \item\lstinline=\cip{<conf>}= z.\,B.: \lstinline=\cip{R,S}= \cip{R,S} + \end{itemize} + \item Fischer: + \begin{itemize} + \item\lstinline=\Dfi= \Dfi + \item\lstinline=\Lfi= \Lfi + \end{itemize} + \item cis/trans u. zusammen/entgegen: + \begin{itemize} + \item\lstinline=\Z= \Z + \item\lstinline=\E= \E + \item\lstinline=\cis= \cis + \item\lstinline=\trans= \trans + \end{itemize} + \item ortho/meta/para: + \begin{itemize} + \item\lstinline=\ortho= \ortho + \item\lstinline=\meta= \meta + \item\lstinline=\para= \para + \end{itemize} +\end{itemize} +Anzeigen der absoluten Konfiguration (verwendet Ti\textbf{\textit{k}}Z): +\begin{itemize} + \item\lstinline=\Rconf[<letter>]= \lstinline=\Rconf=: \Rconf \quad\lstinline=\Rconf[]=: \Rconf[] + \item\lstinline=\Sconf[<letter>]= \lstinline=\Sconf=: \Sconf \quad\lstinline=\Sconf[]=: \Sconf[] +\end{itemize} + +\begin{lstlisting} + \Dfi-Weinsäure = \cip{2S,3S}-Weinsäure, \Dfi-($-$)-Threose = \cip{2S,3R}-($-$)-2,3,4-Trihydroxybutanal\\ + \cis-2-Buten = \Z-2-Buten, \cip{2E,4Z}-Hexadien\\ + \meta-Xylol = 1,3-Dimethylbenzol + + % mit `bpchem'-Befehl \IUPAC: + \IUPAC{\Dfi-Wein\|säure} = \IUPAC{\cip{2S,3S}-Wein\|säure}, \IUPAC{\Dfi-($-$)-Threose} = \IUPAC{\cip{2S,3R}-($-$)-2,3,4\-Tri\|hydroxy\|butanal} +\end{lstlisting} +\Dfi-Weinsäure = \cip{2S,3S}-Weinsäure, \Dfi-($-$)-Threose = \cip{2S,3R}-($-$)-2,3,4-Trihydroxybutanal\\ +\cis-2-Buten = \Z-2-Buten, \cip{2E,4Z}-Hexadien\\ +\meta-Xylol = 1,3-Dimethylbenzol + +\IUPAC{\Dfi-Wein\|säure} = \IUPAC{\cip{2S,3S}-Wein\|säure}, \IUPAC{\Dfi-($-$)-Threose} = \IUPAC{\cip{2S,3R}-($-$)-2,3,4\-Tri\|hydroxy\|butanal} + +Im letzten Beispiel wurde der Befehl \lstinline=\IUPAC= des Pakets \paket{bpchem} eingesetzt. + +\section{Oxidationszahlen und (echte) Ladungen}\label{sec:ladungen} +\subsection{Ionenladungen}\label{ssec:ionen} +Einfaches Darstellen von Ladungen: +\begin{itemize} + \item\lstinline=\pch[<number>]= positive Ladung (\textbf{p}lus + \textbf{ch}arge), \lstinline=\pch, Na\pch, Ca\pch[2]= \pch, Na\pch, Ca\pch[2] + \item\lstinline=\mch[<number>]= negative Ladung (\textbf{m}inus + \textbf{ch}arge), \lstinline=\mch, F\mch, S\mch[2]= \mch, F\mch, S\mch[2] +\end{itemize} + +\subsection{Oxidationszahlen}\label{ssec:oxidationszahlen} +Setzen von Oxidationszahlen: +\begin{itemize} + \item\lstinline=\ox{<number>,<atom>}= setzt \lstinline=<number>= über \lstinline=<atom>=; \lstinline=\ox{+1,Na}=, \lstinline=\ox{+I,Na}=, \lstinline=\ox{-2,S}=, \lstinline=\ox{-II,S}= \ox{+1,Na}, \ox{+I,Na}, \ox{-2,S}, \ox{-II,S} +\end{itemize} +Wenn das Paket `mhchem' geladen wurde, wird \lstinline=<atom>= innerhalb des \lstinline=\cf=-Befehls gesetzt: \lstinline=\ox{+II,Ca}\ox{-I,F2}= \ox{+II,Ca}\ox{-I,F2}. Ohne `mhchem' funktioniert das so nicht {\makeatletter\def\oxNoMhchem#1#2{\ensuremath{\overset{\text{\tiny\CM@ox@sign#1}}{\text{#2}}}}\makeatother(\oxNoMhchem{+II}{Ca}\oxNoMhchem{-I}{F2}) und die konventionelle Methode muss verwendet werden: \lstinline=\ox{+II,Ca}\ox{-I,F$_2$}= \oxNoMhchem{+II}{Ca}\oxNoMhchem{-I}{F$_2$}}. + +\subsection{Partialladungen und ähnliches}\label{ssec:partialladungen} +Vielleicht selten gebraucht, nichtsdestoweniger nützlich: +\begin{itemize} + \item\lstinline=\delp= \delp (\textbf{del}ta + \textbf{p}lus) + \item\lstinline=\delm= \delm (\textbf{del}ta + \textbf{m}inus) +\end{itemize} +Diese Makros können zum Beispiel mit dem \lstinline=\ox=-Befehl eingesetzt werden oder zusammen mit dem Paket \paket{chemfig}: +\begin{lstlisting} + \ox{\delp,H}\ox{\delm,Cl}\par + \chemfig{\chemabove[3pt]{\lewis{246,Br}}{\delm}-\chemabove[3pt]{H}{\delp}} +\end{lstlisting} +\ox{\delp,H}\ox{\delm,Cl}\par +\chemfig{\chemabove[3pt]{\lewis{246,Br}}{\delm}-\chemabove[3pt]{H}{\delp}} + +Auch die beiden folgenden Makros sind v.a. beim Einsatz mit `chemfig' nützlich. +\begin{itemize} + \item\lstinline=\scrp= \scrp (\textbf{scr}iptstyle + \textbf{p}lus) + \item\lstinline=\scrm= \scrm (\textbf{scr}iptstyle + \textbf{m}inus) +\end{itemize} +Zum Beispiel: +\begin{lstlisting} + {\setatomsep{1.8em}\chemfig{CH_3-CH_2-\chemabove{\lewis{026,O}}{\hspace{5mm}\scrm}}} +\end{lstlisting} +{\setatomsep{1.8em}\chemfig{CH_3-CH_2-\chemabove{\lewis{026,O}}{\hspace{5mm}\scrm}}} + +\section{Redoxreaktionen}\label{sec:redoxreaktionen} +\CMname\ stellt zwei Befehle zur Verfügung\footnote{Dank an \href{http://www.mathannotated.com/}{Peter Cao}, der das Feature vorschlug.}, mit denen die Elektronenübertragungen bei Redoxreaktionen angezeigt werden können. Beide Befehle verwenden `Ti\textbf{\textit{k}}Z', der zweite benötigt außerdem die Tikzlibrary `calc', \textbf{die daher in der Präambel geladen werden muss}. +\begin{lstlisting} + \OX{<name>,<atom>} + \redox(<name1>,<name2>)[<tikz>][<dim>]{<text>} +\end{lstlisting} +Mit \lstinline=\OX= wird ein \lstinline=<atom>= in eine Node geschrieben, die den Namen \lstinline=<name>= bekommt. Hat man zwei \lstinline=\OX= gesetzt, können Sie mit \lstinline=\redox= mit einen Linie verbunden werden. Dazu werden die Namen der zu verbindenen Nodes in die Runden Klammern geschrieben. Da \lstinline=\redox= ein Tikzpicture mit den Optionen \lstinline=remember picture,overlay= zeichnet, muss das Dokument \emph{mindestens zweimal kompiliert} werden. +\begin{lstlisting} + \OX{a,Na} $\rightarrow$ \OX{b,Na}\pch\redox(a,b){oxidation} +\end{lstlisting} +\OX{a,Na} $\rightarrow$ \OX{b,Na}\pch\redox(a,b){oxidation} + +Die Linie kann via \lstinline=<tikz>= mit Ti\textbf{\textit{k}}Z-Keys angepasst werden: +\begin{lstlisting} + \begin{center} + \OX{a,Na} $\rightarrow$ \OX{b,Na}\pch\redox(a,b)[->,red]{ox}\redox(a,b)[<-,blue][-.6em]{red} + \end{center} +\end{lstlisting} +\begin{center} + \OX{a,Na} $\rightarrow$ \OX{b,Na}\pch\redox(a,b)[->,red]{ox}\redox(a,b)[<-,blue][-.6em]{red} +\end{center} + +Mit \lstinline=<dim>= kann die Länge der vertikalen Linie festgelegt werden. Diese ist per Default \lstinline=.6em= lang. Gibt man hier einen negativen Wert an, wird die Linie \emph{unterhalb} des Textes geschrieben. +\begin{lstlisting} + \OX{a,Na} $\rightarrow$ \OX{b,Na}\pch + \redox(a,b)[->]{ox} + \redox(a,b)[<-][-.6em]{red} +\end{lstlisting} +\OX{a,Na} $\rightarrow$ \OX{b,Na}\pch +\redox(a,b)[->,red]{ox} +\redox(a,b)[<-,blue][-.6em]{red} +\vskip1cm +Die Befehle funktionieren auch mit dem `mhchem'-Befehl \lstinline=\ce= und in Verbindung mit dem \lstinline=\ox=-Befehl (Abschnitt \ref{ssec:oxidationszahlen}). +\begin{lstlisting} + \ce{ 2 \OX{o1,Na} + \OX{r1,Cl2} -> 2 \OX{o2,Na}\pch + 2 \OX{r2,Cl}\mch } + \redox(o1,o2){\small OX: $- 2\el$} + \redox(r1,r2)[][-.6em]{\small RED: $+ 2\el$} + + \vskip2cm + \ce{ 2 \OX{o1,\ox{0,Na}} + \OX{r1,\ox{0,Cl2}} -> 2 \OX{o2,\ox{+I,Na}}\pch + 2 \OX{r2,\ox{-I,Cl}}\mch } + \redox(o1,o2){\small OX: $- 2\el$} + \redox(r1,r2)[][-.6em]{\small RED: $+ 2\el$} + + \vskip3cm + \ce{ 2 \OX{o1,\ox{0,Na}} + \OX{r1,\ox{0,Cl2}} -> 2 \OX{o2,\ox{+I,Na}}\pch + 2 \OX{r2,\ox{-I,Cl}}\mch } + \redox(o1,o2)[draw=red,->][2em]{\small OX: $- 2\el$} + \redox(r1,r2)[draw=blue,->]{\small RED: $+ 2\el$} + + \vskip1cm + \ce{ 2 \OX{o1,\ox{0,Na}} + \OX{r1,\ox{0,Cl2}} -> 2 \OX{o2,\ox{+I,Na}}\pch + 2 \OX{r2,\ox{-I,Cl}}\mch } + \redox(o1,o2)[green,-stealth]{\small OX: $- 2\el$} + \redox(r1,r2)[purple,-stealth][-.6em]{\small RED: $+ 2\el$} +\end{lstlisting} +\ce{ 2 \OX{o1,Na} + \OX{r1,Cl2} -> 2 \OX{o2,Na}\pch + 2 \OX{r2,Cl}\mch } +\redox(o1,o2){\small OX: $- 2\el$} +\redox(r1,r2)[][-.6em]{\small RED: $+ 2\el$} + +\vskip2cm +\ce{ 2 \OX{o1,\ox{0,Na}} + \OX{r1,\ox{0,Cl2}} -> 2 \OX{o2,\ox{+I,Na}}\pch + 2 \OX{r2,\ox{-I,Cl}}\mch } +\redox(o1,o2){\small OX: $- 2\el$} +\redox(r1,r2)[][-.6em]{\small RED: $+ 2\el$} + +\vskip3cm +\ce{ 2 \OX{o1,\ox{0,Na}} + \OX{r1,\ox{0,Cl2}} -> 2 \OX{o2,\ox{+I,Na}}\pch + 2 \OX{r2,\ox{-I,Cl}}\mch } +\redox(o1,o2)[draw=red,->][2em]{\small OX: $- 2\el$} +\redox(r1,r2)[draw=blue,->]{\small RED: $+ 2\el$} + +\vskip1cm +\ce{ 2 \OX{o1,\ox{0,Na}} + \OX{r1,\ox{0,Cl2}} -> 2 \OX{o2,\ox{+I,Na}}\pch + 2 \OX{r2,\ox{-I,Cl}}\mch } +\redox(o1,o2)[green,-stealth]{\small OX: $- 2\el$} +\redox(r1,r2)[purple,-stealth][-.6em]{\small RED: $+ 2\el$} + +\section{(Standard) Zustand, Thermodynamik}\label{sec:standardstate} +\subsection{Mit `siunitx'}\label{ssec:siunitx} +Wenn das Paket `siunitx' geladen ist, stehen die folgenden Befehle zur Verfügung: +\begin{itemize} + \item\lstinline=\Enthalpy[<kind>,<exponent>,<unit>]{<value>}= + \item\lstinline=\Entropy[<kind>,<exponent>,<unit>]{<value>}= + \item\lstinline=\Gibbs[<kind>,<exponent>,<unit>]{<value>}= +\end{itemize} +Ihr Einsatz ist eigentlich selbsterklärend: mit \lstinline=\Enthalpy{123}= wird \Enthalpy{123} gesetzt. Möchte man genauer spezifizieren, wofür die Enthalpie gelten soll, kann man das über das erste optionale Argument machen:\\ +\lstinline=\Enthalpy[r]{123}= \Enthalpy[r]{123}. + +Das Standardzustandssymbol kann durch das zweite optionale Argument ersetzt werden\ldots\\ +\lstinline=\Enthalpy[,0]{123}= \Enthalpy[,0]{123}\\ +\ldots und wird sowieso nur dann als Standardzustand gesetzt, wenn das Paket `chemstyle' geladen wurde, siehe Abschnitt \ref{ssec:state}. + +Mit dem dritten optionalen Argument schließlich kann die Einheit geändert werden:\\ +\lstinline=\Enthalpy[,kcal/mol]{123}= \Enthalpy[,,kcal/mol]{123}\\ +Die Einheit wird jeweils entsprechend der Regeln von `siunitx' gesetzt und hängt von den dort gewählten Otionen ab. +\begin{lstlisting} + \Enthalpy{-1234.56e3}\par + \sisetup{per-mode=symbol,exponent-product=\cdot,output-decimal-marker={,},group-four-digits=true} + \Enthalpy{-1234.56e3} +\end{lstlisting} +{\Enthalpy{-1234.56e3}\par +\sisetup{per-mode=symbol,exponent-product=\cdot,output-decimal-marker={,},group-four-digits=true} +\Enthalpy{-1234.56e3}} + +Ganz entsprechendes gilt für +\begin{lstlisting} + \Entropy{12.3}, \Gibbs{-12.3}. +\end{lstlisting} +\Entropy{12.3}, \Gibbs{-12.3}. + +Mit dem Befehl \lstinline=\setnewstate[<standard exponent>,<Delta symbol>]{<name>}{<symbol>}{<unit>}= können Sie auch neue entsprechende Befehle festlegen: +\begin{lstlisting} + \setnewstate{Helmholtz}{A}{\kilo\joule\per\mole} + \setnewstate{ElPot}{E}{Volt} + \Helmholtz{123.4} \ElPot{-1.1} +\end{lstlisting} +{\setnewstate{Helmholtz}{A}{\kilo\joule\per\mole}\setnewstate{ElPot}{E}{Volt}\Helmholtz{123.4} \ElPot{-1.1}} + +Tatsächlich wurden +\begin{lstlisting} + \Enthalpy, \Entropy, \Gibbs +\end{lstlisting} +über +\begin{lstlisting} + \setnewstate{Enthalpy}{H}{\kilo\joule\per\mole} + \setnewstate[, ]{Entropy}{S}{\joule\per\kelvin\per\mole} + \setnewstate{Gibbs}{G}{\kilo\joule\per\mole} +\end{lstlisting} +definiert. + +Sie können mit \lstinline=\setnewstate= auch die vordefinierten Befehle überschreiben: +\begin{lstlisting} + \setnewstate{Enthalpy}{X}{\joule\per\mole} + \Enthalpy[f]{12.5} +\end{lstlisting} +{\setnewstate{Enthalpy}{X}{\joule\per\mole}\Enthalpy[f]{12.5}} + +\subsection{State}\label{ssec:state} +Die in Abschnitt \ref{ssec:siunitx} vorgestellten Befehle verwenden alle den auch ohne `siunitx' definierten Befehl +\begin{lstlisting} + \State[<exponent>,<Delta symbol>]{<symbol>}{<kind>} +\end{lstlisting} +Mit diesem Befehl können die thermodynamischen Größen auch ohne Zahl und Einheit angegeben werden. +\begin{lstlisting} + \State{G}{f}, \State[ ]{E}{}, \State[\SI{1000}{\celsius}]{H}{f} +\end{lstlisting} +\State{G}{f}, \State[ ]{E}{}, \State[\SI{1000}{\celsius}]{H}{f} + +Das Standardzustandssymbol wird nur angezeigt, wenn das Paket `chemstyle' geladen wurde und mit dem Befehl \lstinline=\standardstate= zur Verfügung steht. \lstinline=\State{A}{b}=: Wenn `chemstyle' geladen wurde \State{A}{b}, sonst \State[ ]{A}{b}. + +\section{Umgebungen für `mhchem'}\label{sec:mhchem} +Falls das Paket `mhchem' geladen wurde, stehen die Umgebungen +\begin{lstlisting} + \begin{reaction} + <mhchem code> + \end{reaction} + \begin{reactions} + <mhchem code> + \end{reactions} +\end{lstlisting} +sowie die Varianten +\begin{lstlisting} + \begin{reaction*} + <mhchem code> + \end{reaction*} + \begin{reactions*} + <mhchem code> + \end{reactions*} +\end{lstlisting} +zur Verfügung. Die Umgebung \lstinline=reaction=/\lstinline=reaction*= verwendet die Mathematik-Um\-ge\-bung \lstinline=equation=/\lstinline=equation*=, die Umgebung \lstinline=reactions=/\lstinline=reactions*= die Mathematik-Umgebung \lstinline=align=/\lstinline=align*=, um die Reaktionen zu setzen. +\begin{lstlisting} + Reaktion mit Zähler: + \begin{reaction} + H2 + 1/2 O2 -> H2O + \end{reaction} + Reaktion ohne Zähler: + \begin{reaction*} + C + O2 -> CO2 + \end{reaction*} + mehrere Reaktionen mit Zähler: + \begin{reactions} + Cl2 &-> 2 Cl. \\ + Cl.{} + CH4 &-> HCl + {}.CH3\\ + {}{}.CH3 + Cl2 &-> CH3Cl + Cl. + \end{reactions} + mehrere Reaktionen ohne Zähler: + \begin{reactions*} + \Hpl + \Hyd &<=>> H2O\\ + SO4 \mch[2] + Ba \pch[2] &-> BaSO4 v + \end{reactions*} +\end{lstlisting} +Reaktion mit Zähler: +\begin{reaction} + H2 + 1/2 O2 -> H2O +\end{reaction} +Reaktion ohne Zähler: +\begin{reaction*} + C + O2 -> CO2 +\end{reaction*} +mehrere Reaktionen mit Zähler: +\begin{reactions} + Cl2 &-> 2 Cl. \\ + Cl.{} + CH4 &-> HCl + {}.CH3\\ + {}{}.CH3 + Cl2 &-> CH3Cl + Cl. +\end{reactions} +mehrere Reaktionen ohne Zähler: +\begin{reactions*} + \Hpl + \Hyd &<=>> H2O\\ + SO4 \mch[2] + Ba \pch[2] &-> BaSO4 v +\end{reactions*} +Wenn Sie das Aussehen des Zählers ändern wollen, so können Sie \lstinline=\renewtagform{<tagname>}[<format>]{<right delim>}{<left delim>}=\footnote{Durch das Paket `mathtools' zur Verfügung gestellt} verwenden. +\begin{lstlisting} + \renewtagform{CMreaction}[R \textbf]{[}{]} + \begin{reaction} + H2O + CO2 <<=> H2CO3 + \end{reaction} +\end{lstlisting} +{\renewtagform{CMreaction}[R \textbf]{[}{]} +\begin{reaction} + H2O + CO2 <<=> H2CO3 +\end{reaction} +} + +\section{Newman-Projektionen}\label{sec:newman} +Mit dem Befehl +\begin{lstlisting} + \newman[<angle>,<scale>,<tikz>]{<1>,<2>,<3>,<4>,<5>,<6>} +\end{lstlisting} +lassen sich Newman-Projektionen erstellen (verwendet Ti\textbf{\textit{k}}Z). \textbf{Dazu müssen sie in der Präambel die Tikzlibrary `calc' einbinden}: +\begin{lstlisting} + \usetikzlibrary{calc} +\end{lstlisting} +Beispiele: +\begin{lstlisting} + \newman{}\par% Standard: gestaffelt + \newman[165]{}\par% gedreht => ekliptisch + \newman{1,2,3,4,5,6} \newman{1,2,3} \newman{,,,4,5,6}\par% mit Atomen + \newman[,.75,draw=blue,fill=blue!20]{}% verkleinert und mit TikZ angepasst +\end{lstlisting} +\newman{}\par +\newman[165]{}\par +\newman{1,2,3,4,5,6} \newman{1,2,3} \newman{,,,4,5,6}\par +\newman[,.75,draw=blue,fill=blue!20]{} + +Mit einer weiteren Option können die Nodes der Atome gestaltet werden: +\begin{lstlisting} + \newman[][<tikz nodes>]{<1>,<2>,<3>,<4>,<5>,<6>} + % Beispiel: + \newman[][draw=red,fill=red!20,inner sep=2pt,rounded corners]{1,2,3,4,5,6} +\end{lstlisting} +\newman[][draw=red,fill=red!20,inner sep=2pt,rounded corners]{1,2,3,4,5,6} + +Wenn Sie die "`vorderen"' und "`hinteren"' Nodes verschieden gestalten wollen, können Sie noch eine dritte Option verwenden: +\begin{lstlisting} + \newman[][<tikz front nodes>][[<tikz back nodes>]]{<1>,<2>,<3>,<4>,<5>,<6>} + % Beispiel: + \newman[][draw=red,fill=red!20,inner sep=2pt,rounded corners][draw=blue,fill=blue!20,inner sep=2pt,rounded corners]{1,2,3,4,5,6} \newman[170][draw=red,fill=red!20,inner sep=2pt,rounded corners][draw=blue,fill=blue!20,inner sep=2pt,rounded corners]{1,2,3,4,5,6} +\end{lstlisting} +\newman[][draw=red,fill=red!20,inner sep=2pt,rounded corners][draw=blue,fill=blue!20,inner sep=2pt,rounded corners]{1,2,3,4,5,6} \newman[170][draw=red,fill=red!20,inner sep=2pt,rounded corners][draw=blue,fill=blue!20,inner sep=2pt,rounded corners]{1,2,3,4,5,6} + +\section{p-Orbitale}\label{sec:orbitale} +\CMname\ stellt auch Befehle zur Verfügung, mit denen p-Orbitale visualisiert werden können. +\begin{lstlisting} + \porb[<size factor>,<color>,<angle>] + \phorb[<size factor>,<color>,<angle>] + \setorbheight{<length>} +\end{lstlisting} +Damit wird ein liegendes oder um \lstinline=<angle>= gedrehtes p-Orbital dargestellt: \lstinline=\porb \qquad \porb[,,30]= \quad\porb \qquad\porb[,,30] + +\lstinline=\phorb= stellt nur ein halbes Orbital dar: \lstinline=\phorb[,red,90]= \phorb[,red,90] + +Mit den folgenden drei Befehlen stehen die in $x$-, $y$- und $z$-Richtung gedrehten Orbitale zusätzlich als Makro zur Verfügung: +\begin{lstlisting} + \pzorb \qquad \pyorb \qquad \pxorb +\end{lstlisting} +\pzorb \qquad \pyorb \qquad \pxorb + +Durch geeignetes Verschieben lassen sie sich alle an einer Stelle darstellen: +\begin{lstlisting} + \hspace{2cm}\pxorb\hspace{-.3em}\pyorb\hspace{-.3em}\pzorb + \tikz[overlay]{ + \draw[->](0,0)--(1,0)node[right]{$y$}; + \draw[dashed](0,0)--(-1,0); + \draw[->](0,0)--(0,1)node[above]{$z$}; + \draw[dashed](0,0)--(0,-1); + \draw[->](0,0)--(-.707,-.707)node[below left]{$x$}; + \draw[dashed](0,0)--(.707,.707); + } +\end{lstlisting} +\hspace{2cm}\pxorb\hspace{-.3em}\pyorb\hspace{-.3em}\pzorb\tikz[overlay]{\draw[->](0,0)--(1,0)node[right]{$y$};\draw[->](0,0)--(0,1)node[above]{$z$};\draw[->](0,0)--(-.707,-.707)node[below left]{$x$};\draw[dashed](0,0)--(-1,0);\draw[dashed](0,0)--(0,-1);\draw[dashed](0,0)--(.707,.707);} +\vspace{2cm} + +Die Orbitale lassen sich z.\,B. auch zusammen mit `chemfig' einsetzen: +\begin{lstlisting} + \setorbheight{2em}\setbondoffset{0pt} + \chemfig{?\pzorb-[,1.3]\pzorb-[:30,1.1]\pzorb-[:150,.9]\pzorb-[4,1.3]\pzorb-[:-150,1.1]\pzorb?}\qquad + \chemfig{?\pzorb-[,1.3]{\porb[,,-90]}-[:30,1.1]\pzorb-[:150,.9]{\porb[,,-90]}-[4,1.3]\pzorb-[:-150,1.1]{\porb[,,-90]}?} +\end{lstlisting} +\vspace{1cm} +{\setorbheight{2em}\setbondoffset{0pt} +\chemfig{?\pzorb-[,1.3]\pzorb-[:30,1.1]\pzorb-[:150,.9]\pzorb-[4,1.3]\pzorb-[:-150,1.1]\pzorb?}\qquad +\chemfig{?\pzorb-[,1.3]{\porb[,,-90]}-[:30,1.1]\pzorb-[:150,.9]{\porb[,,-90]}-[4,1.3]\pzorb-[:-150,1.1]{\porb[,,-90]}?}} + +\section{Paket-Optionen}\label{sec:optionen} +\CMname\ hat zwei Paketoptionen: +\begin{itemize} + \item\lstinline+xspace=<boolean>+ Mit der Option \lstinline+xspace=true+ bekommen folgende Befehle ein \lstinline=\xspace= angehängt:\\ + \lstinline=\Hyd \HtO Text \Hyd, \HtO, Text= \Hyd \HtO Text \Hyd, \HtO, Text\\ + Default: \lstinline+xspace=false+ + \item\lstinline+circled=<boolean>+ Nicht alle mögen Kreise um die Ladungssymbole ($\oplus$ und $\ominus$) sondern bevorzugen sie ohne Kreise ($+$ und $-$). Dieses Verhalten kann mit dieser Option gesteuert werden. Mit \lstinline+circled=false+ verwenden alle Befehle von \CMname\ die Symbole ohne Kreis.\\ + Default: \lstinline+circled=true+ +\end{itemize} + +\section{Liste der Befehle}\label{sec:befehlsreferenz} +\begin{tabular}{>{\raggedright}p{.35\textwidth}|>{\raggedright}p{.55\textwidth}}\toprule + \lstinline=\el=, \lstinline=\prt=, \lstinline=\ntr= & Abschnitt \ref{sec:teilchen}: Teilchen, Ionen und ein Symbol\tabularnewline + \lstinline=\HtO=, \lstinline=\Hpl=, \lstinline=\Hyd= & \tabularnewline + \lstinline=\transitionstatesymbol= & \tabularnewline\midrule + \lstinline=\cip=, \lstinline=\Rcip=, \lstinline=\Scip= & Abschnitt \ref{sec:stereo}: Stereo-Deskriptoren, Nomenklatur\tabularnewline + \lstinline=\Dfi=, \lstinline=\Lfi= & \tabularnewline + \lstinline=\E=, \lstinline=\Z=, \lstinline=\cis=, \lstinline=\trans= & \tabularnewline + \lstinline=\Rconf=, \lstinline=\Sconf= & \tabularnewline + \lstinline=\ortho=, \lstinline=\meta=, \lstinline=\para= & \tabularnewline\midrule + \lstinline=\delm=, \lstinline=\delp= & Abschnitt \ref{sec:ladungen}: Oxidationszahlen und (echte) Ladungen\tabularnewline + \lstinline=\mch=, \lstinline=\pch= & \tabularnewline + \lstinline=\ox= & \tabularnewline + \lstinline=\scrm=, \lstinline=\scrp= & \tabularnewline\midrule + \lstinline=\Enthalpy=, \lstinline=\Entropy=, \lstinline=\Gibbs= & Abschnitt \ref{sec:standardstate}: (Standard) Zustand, Thermodynamik\tabularnewline + \lstinline=\setnewstate= & \tabularnewline + \lstinline=\State= & \tabularnewline\midrule + \lstinline=\newman= & Abschnitt \ref{sec:newman}: Newman-Projektionen \tabularnewline\midrule + \lstinline=\redox=, \lstinline=\OX= & Abschnitt \ref{sec:redoxreaktionen}: Redoxreaktionen \tabularnewline\midrule + \lstinline=\begin{reaction}=, \lstinline=\begin{reaction*}=, \lstinline=\begin{reactions}=, \lstinline=\begin{reactions*}= & Abschnitt \ref{sec:mhchem}: Umgebungen für `mhchem'\tabularnewline\midrule + \lstinline=\phorb=, \lstinline=\porb=, \lstinline=\pxorb=, \lstinline=\pyorb=, \lstinline=\pzorb= & Abschnitt \ref{sec:orbitale}: p-Orbitale\tabularnewline + \lstinline=\setorbheight= & \tabularnewline\bottomrule +\end{tabular} + +\end{document}
\ No newline at end of file diff --git a/Master/texmf-dist/doc/latex/chemmacros/chemmacros_doc_en.pdf b/Master/texmf-dist/doc/latex/chemmacros/chemmacros_doc_en.pdf Binary files differnew file mode 100644 index 00000000000..af7a68822ed --- /dev/null +++ b/Master/texmf-dist/doc/latex/chemmacros/chemmacros_doc_en.pdf diff --git a/Master/texmf-dist/doc/latex/chemmacros/chemmacros_doc_en.tex b/Master/texmf-dist/doc/latex/chemmacros/chemmacros_doc_en.tex new file mode 100644 index 00000000000..c628602e7ca --- /dev/null +++ b/Master/texmf-dist/doc/latex/chemmacros/chemmacros_doc_en.tex @@ -0,0 +1,552 @@ +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% ------------------------------------------------------------------------------------- % +% - chemmacros - chemmacros_doc_en.tex ------------------------------------------------ % +% - a collection of macros to make typesetting chemistry documents more convenient ---- % +% ------------------------------------------------------------------------------------- % +% - Clemens Niederberger -------------------------------------------------------------- % +% - 2011/05/15 ------------------------------------------------------------------------ % +% ------------------------------------------------------------------------------------- % +% - http://www.mychemistry.eu/ -------------------------------------------------------- % +% - contact@mychemistry.eu ------------------------------------------------------------ % +% ------------------------------------------------------------------------------------- % +% - If you have any ideas, questions, suggestions or bugs to report, please feel free - % +% - to contact me. -------------------------------------------------------------------- % +% ------------------------------------------------------------------------------------- % +% - Copyright 2011 Clemens Niederberger - % +% - - % +% - This work may be distributed and/or modified under the - % +% - conditions of the LaTeX Project Public License, either version 1.3 - % +% - of this license or (at your option) any later version. - % +% - The latest version of this license is in - % +% - http://www.latex-project.org/lppl.txt - % +% - and version 1.3 or later is part of all distributions of LaTeX - % +% - version 2005/12/01 or later. - % +% - - % +% - This work has the LPPL maintenance status `maintained'. - % +% - - % +% - The Current Maintainer of this work is Clemens Niederberger. - % +% - - % +% - This work consists of the files chemmacros.sty, chemmacros_doc_de.tex, - % +% - chemmacros_doc_de.tex, README - % +% ------------------------------------------------------------------------------------- % +\documentclass[parskip=full]{scrartcl} +\usepackage[ngerman]{babel} +\usepackage[utf8]{inputenx} +\usepackage[dvipsnames]{xcolor} + \colorlet{code}{RawSienna} +\usepackage{listings,url,chemfig,chemstyle,bpchem,siunitx,booktabs} +\usepackage[version=3,arrows=pgf]{mhchem} +\usepackage[xspace=true]{chemmacros} +\usetikzlibrary{calc} +\lstset{literate={ä}{{\"a}}1 {ö}{{\"o}}1 {ü}{{\"u}}1 {Ä}{{\"A}}1 {Ö}{{\"O}}1 {Ü}{{\"U}}1 {ß}{{\ss}}1} +\lstset{ + language=[LaTeX]TeX, + basicstyle={\ttfamily}, % Grundstil + extendedchars=true, + numbers=left, % Zeilennummern + numberstyle=\tiny, % Größe des Zeilennummern + numberblanklines=true, % Leerzeilen nummerieren + gobble=1, % das erste Leerzeichen abschneiden + xleftmargin=20pt, % Einrückung links + breaklines=true, % Zeilenumbruch + moredelim=[is][\color{red!25!purple}]{!!}{!!},% Hervorhebung + commentstyle={\color[named]{Gray}}, + emph={begin,end}, % Umgebungen hervorheben + emphstyle=\color{red}, + keywordstyle=\color{code}, + keywordstyle=[20]\color{blue}, + morekeywords=[20]{reaction,reactions}, + texcsstyle=[30]\color{code}, + moretexcs=[30]{ce,cf,chemabove,chembelow,chemfig,cip,cis,color,delm,delp,Dfi,draw,E,el,ElPot,ensuremath,Enthalpy,Entropy,Gibbs,gram,Helmholtz,HtO,Hpl,Hyd,IUPAC,joule,kelvin,kilo,lewis,Lfi,liter,mch,meta,milli,mole,newman,node,ntr,nu,ortho,ox,OX,para,pch,per,phorb,porb,prt,pxorb,pyorb,pzorb,Rcip,Rconf,redox,renewtagform,setorbheight,Scip,Sconf,scrm,scrp,setatomsep,setnewstate,sisetup,standardstate,State,text,tikz,trans,transitionstatesymbol,usetikzlibrary,xspace,Z}, + } + +\usepackage{hyperref} + \hypersetup{colorlinks=true, + plainpages=false, + bookmarksopen=true, + bookmarksopenlevel=2, + bookmarksnumbered=true, + pdfauthor={Clemens Niederberger}, + pdftitle={chemmacros - Manual}, + pdfsubject={Hilfsmakros für den Chemiker}, + pdfkeywords={chemmacros}, + pdfcreator={LaTeX} + } + +\newcommand\paket[1]{`#1'\footnote{\url{http://www.ctan.org/pkg/#1}}} +\makeatletter +\let\CMname\CM@name% +\makeatother +\begin{document} + +\begin{titlepage} + \centering + \Huge\makeatletter\CM@name\ v\CM@version\makeatother + \vskip.5cm + \large\makeatletter\CM@date\makeatother + \vskip.5cm + \Large Clemens \textsc{Niederberger} + \vskip.25cm + \normalsize\url{http://www.mychemistry.eu/}\\ + \href{mailto:contact@mychemistry.eu}{contact@mychemistry.eu} + \vskip2cm + \begin{abstract} + `\CMname' is a collection of macros and commands which are intended to make typesetting chemistry documents faster and more convenient. This includes some nomenclature commands, oxidation numbers, thermodynamic data, newman projections... + \end{abstract} +\end{titlepage} + +\tableofcontents + +\section{Licence, Requirements} +\makeatletter\CM@name\ v\CM@version\makeatother\ underlies the The \LaTeX\ project public license\\(\url{http://www.latex-project.org/lppl.txt}). + +\CMname\ internally loads the packages \paket{xkeyval}, \paket{amsmath} and `tikz' (Ti\textbf{\textit{k}}Z = \paket{pgf}). If they're missing it will cause an error. + +The definition of some commands depends on which packages have been loaded \emph{before} \CMname\ was loaded. Some commands are only defined if a certain package has been loaded. This concern the packages \paket{mhchem}, \paket{siunitx} and \paket{chemstyle} and the commands from section \ref{sec:teilchen}, \lstinline=\ox= (section \ref{ssec:oxidationszahlen}), the commands from section \ref{sec:standardstate} and the environments drom section \ref{sec:mhchem}. + +The package option \lstinline=xspace= (section \ref{sec:optionen}) needs the package \paket{xspace} to be available. + +If the user loads `mhchem' \emph{before} \CMname, the packages \paket{mathtools} and \paket{environ} are needed. + +The \lstinline=\redox= command (section \ref{sec:redoxreaktionen}) and the \lstinline=\newman= command (section \ref{sec:newman} need the tikz library `calc' to be loaded. + +The full functionality should be guaranteed with a preamble like this: +\begin{lstlisting} + \usepackage{siunitx,chemstyle} + \usepackage[version=3,arrows=pgf]{mhchem} + \usepackage[xspace=true]{chemmacros} + \usetikzlibrary{calc} +\end{lstlisting} + +\section{Particles, Ions and a Symbol}\label{sec:teilchen} +Some simple macros for displaying often needed particles and a symbol: +\begin{itemize} + \item\lstinline=\Hpl= \Hpl (proton) + \item\lstinline=\Hyd= \Hyd (hydroxide) + \item\lstinline=\HtO= \HtO (oxonium) + \item\lstinline=\el= \el (electron) + \item\lstinline=\prt= \prt (proton) + \item\lstinline=\ntr= \ntr (neutron) + \item\lstinline=\transitionstatesymbol= \transitionstatesymbol\ transition state symbol (uses Ti\textbf{\textit{k}}Z) +\end{itemize} +These commands are working both in text mode and math mode. Depending on wether `mhchem' has been loaded, the first three particles are defined with the \lstinline=\cf{}= command or with \lstinline=\ensuremath{\text{}}=. + +\section{Stereo Descriptors, Nomenclature}\label{sec:stereo} +The following macros are intended to make the writing of IUPAC names more convenient: +\begin{itemize} + \item Cahn-Ingold-Prelog: + \begin{itemize} + \item\lstinline=\Rcip= \Rcip + \item\lstinline=\Scip= \Scip + \item\lstinline=\cip{<conf>}= e.\,g.: \lstinline=\cip{R,S}= \cip{R,S} + \end{itemize} + \item Fischer: + \begin{itemize} + \item\lstinline=\Dfi= \Dfi + \item\lstinline=\Lfi= \Lfi + \end{itemize} + \item cis/trans \&\ zusammen/entgegen: + \begin{itemize} + \item\lstinline=\Z= \Z + \item\lstinline=\E= \E + \item\lstinline=\cis= \cis + \item\lstinline=\trans= \trans + \end{itemize} + \item ortho/meta/para: + \begin{itemize} + \item\lstinline=\ortho= \ortho + \item\lstinline=\meta= \meta + \item\lstinline=\para= \para + \end{itemize} +\end{itemize} +absolute configuration (uses Ti\textbf{\textit{k}}Z): +\begin{itemize} + \item\lstinline=\Rconf[<letter>]= \lstinline=\Rconf=: \Rconf \quad\lstinline=\Rconf[]=: \Rconf[] + \item\lstinline=\Sconf[<letter>]= \lstinline=\Sconf=: \Sconf \quad\lstinline=\Sconf[]=: \Sconf[] +\end{itemize} + +\begin{lstlisting} + \Dfi-Weinsäure = \cip{2S,3S}-Weinsäure, \Dfi-($-$)-Threose = \cip{2S,3R}-($-$)-2,3,4-Trihydroxybutanal\\ + \cis-2-Buten = \Z-2-Butene, \cip{2E,4Z}-Hexadiene\\ + \meta-Xylol = 1,3-Dimethylbenzene + + % with `bpchem' command \IUPAC: + \IUPAC{\Dfi-Wein\|säure} = \IUPAC{\cip{2S,3S}-Wein\|säure}, \IUPAC{\Dfi-($-$)-Threose} = \IUPAC{\cip{2S,3R}-($-$)-2,3,4\-Tri\|hydroxy\|butanal} +\end{lstlisting} +\Dfi-Weinsäure = \cip{2S,3S}-Weinsäure, \Dfi-($-$)-Threose = \cip{2S,3R}-($-$)-2,3,4-Trihydroxybutanal\\ +\cis-2-Buten = \Z-2-Butene, \cip{2E,4Z}-Hexadiene\\ +\meta-Xylol = 1,3-Dimethylbenzene + +\IUPAC{\Dfi-Wein\|säure} = \IUPAC{\cip{2S,3S}-Wein\|säure}, \IUPAC{\Dfi-($-$)-Threose} = \IUPAC{\cip{2S,3R}-($-$)-2,3,4\-Tri\|hydroxy\|butanal} + +The last example uses the \lstinline=\IUPAC= command, which is provided by the \paket{bpchem} package. + +\section{Oxidation Numbers and (real) Charges}\label{sec:ladungen} +\subsection{Ion Charges}\label{ssec:ionen} +Simple displaying of charges: +\begin{itemize} + \item\lstinline=\pch[<number>]= positive charge (\textbf{p}lus + \textbf{ch}arge), \lstinline=\pch, Na\pch, Ca\pch[2]= \pch, Na\pch, Ca\pch[2] + \item\lstinline=\mch[<number>]= negative charge (\textbf{m}inus + \textbf{ch}arge), \lstinline=\mch, F\mch, S\mch[2]= \mch, F\mch, S\mch[2] +\end{itemize} + +\subsection{Oxidation Numbers}\label{ssec:oxidationszahlen} +Typesetting oxidation numbers: +\begin{itemize} + \item\lstinline=\ox{<number>,<atom>}= places \lstinline=<number>= above \lstinline=<atom>=; \lstinline=\ox{+1,Na}=, \lstinline=\ox{+I,Na}=, \lstinline=\ox{-2,S}=, \lstinline=\ox{-II,S}= \ox{+1,Na}, \ox{+I,Na}, \ox{-2,S}, \ox{-II,S} +\end{itemize} +If the package `mhchem' has been loaded \lstinline=<atom>= is set inside the \lstinline=\ce= command: \lstinline=\ox{+II,Ca}\ox{-I,F2}= \ox{+II,Ca}\ox{-I,F2}. Without `mhchem' this isn't working this way {\makeatletter\def\oxNoMhchem#1#2{\ensuremath{\overset{\text{\tiny\CM@ox@sign#1}}{\text{#2}}}}\makeatother(\oxNoMhchem{+II}{Ca}\oxNoMhchem{-I}{F2}) and you need to use the math way: \lstinline=\ox{+II,Ca}\ox{-I,F$_2$}= \oxNoMhchem{+II}{Ca}\oxNoMhchem{-I}{F$_2$}}. + +\subsection{Partial Charges and similar Stuff}\label{ssec:partialladungen} +The next ones probably are seldomly needed but nevertheless useful: +\begin{itemize} + \item\lstinline=\delp= \delp (\textbf{del}ta + \textbf{p}lus) + \item\lstinline=\delm= \delm (\textbf{del}ta + \textbf{m}inus) +\end{itemize} +These macros for example can be used with the \lstinline=\ox= command or with the \paket{chemfig} package: +\begin{lstlisting} + \ox{\delp,H}\ox{\delm,Cl}\par + \chemfig{\chemabove[3pt]{\lewis{246,Br}}{\delm}-\chemabove[3pt]{H}{\delp}} +\end{lstlisting} +\ox{\delp,H}\ox{\delm,Cl}\par +\chemfig{\chemabove[3pt]{\lewis{246,Br}}{\delm}-\chemabove[3pt]{H}{\delp}} + +Also the following macros are useful together with `chemfig'. +\begin{itemize} + \item\lstinline=\scrp= \scrp (\textbf{scr}iptstyle + \textbf{p}lus) + \item\lstinline=\scrm= \scrm (\textbf{scr}iptstyle + \textbf{m}inus) +\end{itemize} +For example: +\begin{lstlisting} + {\setatomsep{1.8em}\chemfig{CH_3-CH_2-\chemabove{\lewis{026,O}}{\hspace{5mm}\scrm}}} +\end{lstlisting} +{\setatomsep{1.8em}\chemfig{CH_3-CH_2-\chemabove{\lewis{026,O}}{\hspace{5mm}\scrm}}} + +\section{Redox Reactions}\label{sec:redoxreaktionen} +\CMname\ provides two commands \footnote{Thanks to \href{http://www.mathannotated.com/}{Peter Cao} who suggested the feature.} to visualize the transfer of electrons in redox reactions. Both commands are using `Ti\textbf{\textit{k}}Z', the second also needs the tikz library `calc', \textbf{which thus must be loaded in the preamble}. +\begin{lstlisting} + \OX{<name>,<atom>} + \redox(<name1>,<name2>)[<tikz>][<dim>]{<text>} +\end{lstlisting} +\lstinline=\OX= places \lstinline=<atom>= into a node, which is named with \lstinline=<name>=. If you have set two\lstinline=\OX=, they can be connected with a line using \lstinline=\redox=. To do so the names of the two nodes that shall be connected are written in the round braces. Since \lstinline=\redox= draw a tikzpicture with options \lstinline=remember picture,overlay=, the document needs to be \emph{compiled at least two times}. +\begin{lstlisting} + \OX{a,Na} $\rightarrow$ \OX{b,Na}\pch\redox(a,b){oxidation} +\end{lstlisting} +\OX{a,Na} $\rightarrow$ \OX{b,Na}\pch\redox(a,b){oxidation} + +This line can be customized using Ti\textbf{\textit{k}}Z keys in \lstinline=<tikz>=: +\begin{lstlisting} + \OX{a,Na} $\rightarrow$ \OX{b,Na}\pch\redox(a,b)[->,red]{ox} +\end{lstlisting} +\OX{a,Na} $\rightarrow$ \OX{b,Na}\pch\redox(a,b)[->,red]{ox} + +\lstinline=<dim>= can be used to adjust the length of the vertical line. The default value is \lstinline=.6em=. If you use a negative value the line is placed \emph{below} the text. +\begin{lstlisting} + \begin{center} + \OX{a,Na} $\rightarrow$ \OX{b,Na}\pch\redox(a,b)[->,red]{ox}\redox(a,b)[<-,blue][-.6em]{red} + \end{center} +\end{lstlisting} +\begin{center} + \OX{a,Na} $\rightarrow$ \OX{b,Na}\pch\redox(a,b)[->,red]{ox}\redox(a,b)[<-,blue][-.6em]{red} +\end{center} + +Both commands also can be used with the `mhchem' command \lstinline=\ce= and with the \lstinline=\ox= command (section \ref{ssec:oxidationszahlen}). +\begin{lstlisting} + \ce{ 2 \OX{o1,Na} + \OX{r1,Cl2} -> 2 \OX{o2,Na}\pch + 2 \OX{r2,Cl}\mch } + \redox(o1,o2){\small OX: $- 2\el$} + \redox(r1,r2)[][-.6em]{\small RED: $+ 2\el$} + + \vskip2cm + \ce{ 2 \OX{o1,\ox{0,Na}} + \OX{r1,\ox{0,Cl2}} -> 2 \OX{o2,\ox{+I,Na}}\pch + 2 \OX{r2,\ox{-I,Cl}}\mch } + \redox(o1,o2){\small OX: $- 2\el$} + \redox(r1,r2)[][-.6em]{\small RED: $+ 2\el$} + + \vskip3cm + \ce{ 2 \OX{o1,\ox{0,Na}} + \OX{r1,\ox{0,Cl2}} -> 2 \OX{o2,\ox{+I,Na}}\pch + 2 \OX{r2,\ox{-I,Cl}}\mch } + \redox(o1,o2)[draw=red,->][2em]{\small OX: $- 2\el$} + \redox(r1,r2)[draw=blue,->]{\small RED: $+ 2\el$} + + \vskip1cm + \ce{ 2 \OX{o1,\ox{0,Na}} + \OX{r1,\ox{0,Cl2}} -> 2 \OX{o2,\ox{+I,Na}}\pch + 2 \OX{r2,\ox{-I,Cl}}\mch } + \redox(o1,o2)[green,-stealth]{\small OX: $- 2\el$} + \redox(r1,r2)[purple,-stealth][-.6em]{\small RED: $+ 2\el$} +\end{lstlisting} +\ce{ 2 \OX{o1,Na} + \OX{r1,Cl2} -> 2 \OX{o2,Na}\pch + 2 \OX{r2,Cl}\mch } +\redox(o1,o2){\small OX: $- 2\el$} +\redox(r1,r2)[][-.6em]{\small RED: $+ 2\el$} + +\vskip2cm +\ce{ 2 \OX{o1,\ox{0,Na}} + \OX{r1,\ox{0,Cl2}} -> 2 \OX{o2,\ox{+I,Na}}\pch + 2 \OX{r2,\ox{-I,Cl}}\mch } +\redox(o1,o2){\small OX: $- 2\el$} +\redox(r1,r2)[][-.6em]{\small RED: $+ 2\el$} + +\vskip3cm +\ce{ 2 \OX{o1,\ox{0,Na}} + \OX{r1,\ox{0,Cl2}} -> 2 \OX{o2,\ox{+I,Na}}\pch + 2 \OX{r2,\ox{-I,Cl}}\mch } +\redox(o1,o2)[draw=red,->][2em]{\small OX: $- 2\el$} +\redox(r1,r2)[draw=blue,->]{\small RED: $+ 2\el$} + +\vskip1cm +\ce{ 2 \OX{o1,\ox{0,Na}} + \OX{r1,\ox{0,Cl2}} -> 2 \OX{o2,\ox{+I,Na}}\pch + 2 \OX{r2,\ox{-I,Cl}}\mch } +\redox(o1,o2)[green,-stealth]{\small OX: $- 2\el$} +\redox(r1,r2)[purple,-stealth][-.6em]{\small RED: $+ 2\el$} + +\section{(Standard) State, Thermodynamics}\label{sec:standardstate} +\subsection{With `siunitx'}\label{ssec:siunitx} +If the package `siunitx' has been loaded, the following commands are available: +\begin{itemize} + \item\lstinline=\Enthalpy[<kind>,<exponent>,<unit>]{<value>}= + \item\lstinline=\Entropy[<kind>,<exponent>,<unit>]{<value>}= + \item\lstinline=\Gibbs[<kind>,<exponent>,<unit>]{<value>}= +\end{itemize} +Their usage is pretty much self-explaining: \lstinline=\Enthalpy{-123.4}= gives \Enthalpy{-123.4}. If you want to specify what kind of enthalpy (reaction, formation,\ldots) is meant Möchte you can use the first optional argument:\\ +\lstinline=\Enthalpy[r]{-123.4}= \Enthalpy[r]{-123.4}. + +The standard state symbol can be replaced by the second optional argument\ldots\\ +\lstinline=\Enthalpy[,o]{-123.4}= \Enthalpy[,o]{-123.4}\\ +\ldots and is anyway only set as standard state if the package `chemstyle' has been loaded, see section \ref{ssec:state}. + +The third optional argument can be used to change the unit:\\ +\lstinline=\Enthalpy[,kcal/mol]{-123.4}= \Enthalpy[,,kcal/mol]{-123.4}\\ +The unit is set corresponding to the rules of `siunitx' and depends on its settings: +\begin{lstlisting} + \Enthalpy{-1234.56e3}\par + \sisetup{per-mode=symbol,exponent-product=\cdot,output-decimal-marker={,},group-four-digits=true} + \Enthalpy{-1234.56e3} +\end{lstlisting} +{\Enthalpy{-1234.56e3}\par +\sisetup{per-mode=symbol,exponent-product=\cdot,output-decimal-marker={,},group-four-digits=true} +\Enthalpy{-1234.56e3}} + +The other two commands work exactly the same way. +\begin{lstlisting} + \Entropy{12.3}, \Gibbs{-12.3}. +\end{lstlisting} +\Entropy{12.3}, \Gibbs{-12.3}. + +You can use the command \lstinline=\setnewstate[<standard exponent>,<Delta symbol>]{<name>}{<symbol>}{<unit>}= to create new corresponding commands: +\begin{lstlisting} + \setnewstate{Helmholtz}{A}{\kilo\joule\per\mole} + \setnewstate{ElPot}{E}{Volt} + \Helmholtz{123.4} \ElPot{-1.1} +\end{lstlisting} +{\setnewstate{Helmholtz}{A}{\kilo\joule\per\mole}\setnewstate{ElPot}{E}{Volt}\Helmholtz{123.4} \ElPot{-1.1}} + +Indeed, the commands +\begin{lstlisting} + \Enthalpy, \Entropy, \Gibbs +\end{lstlisting} +are defined as follows: +\begin{lstlisting} + \setnewstate{Enthalpy}{H}{\kilo\joule\per\mole} + \setnewstate[, ]{Entropy}{S}{\joule\per\kelvin\per\mole} + \setnewstate{Gibbs}{G}{\kilo\joule\per\mole} +\end{lstlisting} + +With \lstinline=\setnewstate= you also can redefine the existing commands: +\begin{lstlisting} + \setnewstate{Enthalpy}{X}{\joule\per\mole} + \Enthalpy[f]{12.5} +\end{lstlisting} +{\setnewstate{Enthalpy}{X}{\joule\per\mole}\Enthalpy[f]{12.5}} + +\subsection{State}\label{ssec:state} +The commands presented in section \ref{ssec:siunitx} internally all use the command +\begin{lstlisting} + \State[<exponent>,<Delta symbol>]{<symbol>}{<kind>} +\end{lstlisting} +which also is available without `siunitx'. It can be used to write the thermodynamic variables without value and unit. +\begin{lstlisting} + \State{G}{f}, \State[ ]{E}{}, \State[\SI{1000}{\celsius}]{H}{f}, \State[ ,\delta]{+}{} +\end{lstlisting} +\State{G}{f}, \State[ ]{E}{}, \State[\SI{1000}{\celsius}]{H}{f}, \State[ ,\delta]{+}{} + +The standard state symbol \standardstate\ is only used, if the `chemstyle' package has been loaded, which provides it through the command \lstinline=\standardstate=. With `chemstyle': \lstinline=\State{A}{b}= \State{A}{b}, without: \State[ ]{A}{b}. + +\section{Environments for `mhchem'}\label{sec:mhchem} +If the package `mhchem' has been loaded the environments +\begin{lstlisting} + \begin{reaction} + <mhchem code> + \end{reaction} + \begin{reactions} + <mhchem code> + \end{reactions} +\end{lstlisting} +and the starred versions +\begin{lstlisting} + \begin{reaction*} + <mhchem code> + \end{reaction*} + \begin{reactions*} + <mhchem code> + \end{reactions*} +\end{lstlisting} +are defined. \lstinline=reaction=/\lstinline=reaction*= uses the math environment \lstinline=equation=/\lstinline=equation*= and \lstinline=reactions=/\lstinline=reactions*= uses the math environment \lstinline=align=/\lstinline=align*= to display the reactions. +\begin{lstlisting} + reaction with counter: + \begin{reaction} + H2 + 1/2 O2 -> H2O + \end{reaction} + reaction without counter: + \begin{reaction*} + C + O2 -> CO2 + \end{reaction*} + several aligned reactions with counter: + \begin{reactions} + Cl2 &-> 2 Cl. \\ + Cl.{} + CH4 &-> HCl + {}.CH3\\ + {}{}.CH3 + Cl2 &-> CH3Cl + Cl. + \end{reactions} + several aligned reactions without counter: + \begin{reactions*} + \Hpl + \Hyd &<=>> H2O\\ + SO4 \mch[2] + Ba \pch[2] &-> BaSO4 v + \end{reactions*} +\end{lstlisting} +reaction with counter: +\begin{reaction} + H2 + 1/2 O2 -> H2O +\end{reaction} +reaction without counter: +\begin{reaction*} + C + O2 -> CO2 +\end{reaction*} +several aligned reactions with counter: +\begin{reactions} + Cl2 &-> 2 Cl. \\ + Cl.{} + CH4 &-> HCl + {}.CH3\\ + {}{}.CH3 + Cl2 &-> CH3Cl + Cl. +\end{reactions} +several aligned reactions without counter: +\begin{reactions*} + \Hpl + \Hyd &<=>> H2O\\ + SO4 \mch[2] + Ba \pch[2] &-> BaSO4 v +\end{reactions*} +If you want to change the layout of the counter tags, you can use \lstinline=\renewtagform{<tagname>}[<format>]{<right delim>}{<left delim>}=\footnote{provided by the package `mathtools'}. +\begin{lstlisting} + \renewtagform{CMreaction}[R \textbf]{[}{]} + \begin{reaction} + H2O + CO2 <<=> H2CO3 + \end{reaction} +\end{lstlisting} +{\renewtagform{CMreaction}[R \textbf]{[}{]} +\begin{reaction} + H2O + CO2 <<=> H2CO3 +\end{reaction} +} + +\section{Newman Projections}\label{sec:newman} +The command +\begin{lstlisting} + \newman[<angle>,<scale>,<tikz>]{<1>,<2>,<3>,<4>,<5>,<6>} +\end{lstlisting} +allows you to create newman projections (uses Ti\textbf{\textit{k}}Z). \textbf{You need to load the tikz library `calc' for that}: +\begin{lstlisting} + \usetikzlibrary{calc} +\end{lstlisting} +Examples: +\begin{lstlisting} + \newman{}\par% default: staggered + \newman[165]{}\par% rotated by 165 degrees => eclipsed + \newman{1,2,3,4,5,6} \newman{1,2,3} \newman{,,,4,5,6}\par% with atoms + \newman[,.75,draw=blue,fill=blue!20]{}% scaled and customized with TikZ +\end{lstlisting} +\newman{}\par +\newman[165]{}\par +\newman{1,2,3,4,5,6} \newman{1,2,3} \newman{,,,4,5,6}\par +\newman[,.75,draw=blue,fill=blue!20]{} + +Another option allows you to customize the nodes within which the atoms are placed: +\begin{lstlisting} + \newman[][<tikz nodes>]{<1>,<2>,<3>,<4>,<5>,<6>} + % example: + \newman[][draw=red,fill=red!20,inner sep=2pt,rounded corners]{1,2,3,4,5,6} +\end{lstlisting} +\newman[][draw=red,fill=red!20,inner sep=2pt,rounded corners]{1,2,3,4,5,6} + +If you want to display the "front" atoms differently from the "back" atoms, you can use a third option: +\begin{lstlisting} + \newman[][<tikz front nodes>][[<tikz back nodes>]]{<1>,<2>,<3>,<4>,<5>,<6>} + % example: + \newman[][draw=red,fill=red!20,inner sep=2pt,rounded corners][draw=blue,fill=blue!20,inner sep=2pt,rounded corners]{1,2,3,4,5,6} \newman[170][draw=red,fill=red!20,inner sep=2pt,rounded corners][draw=blue,fill=blue!20,inner sep=2pt,rounded corners]{1,2,3,4,5,6} +\end{lstlisting} +\newman[][draw=red,fill=red!20,inner sep=2pt,rounded corners][draw=blue,fill=blue!20,inner sep=2pt,rounded corners]{1,2,3,4,5,6} \newman[170][draw=red,fill=red!20,inner sep=2pt,rounded corners][draw=blue,fill=blue!20,inner sep=2pt,rounded corners]{1,2,3,4,5,6} + +\section{p-Orbitals}\label{sec:orbitale} +\CMname\ provides commands to visualize p-orbitals. +\begin{lstlisting} + \porb[<size factor>,<color>,<angle>] + \phorb[<size factor>,<color>,<angle>] + \setorbheight{<length>} +\end{lstlisting} +This displays a horizontal orbital or one rotated by \lstinline=<angle>=: \lstinline=\porb \qquad \porb[,,30]= \quad\porb \qquad\porb[,,30] + +\lstinline=\phorb= only displays one half orbital: \lstinline=\phorb[,red,90]= \phorb[,red,90] + +There are shortcuts for the $x$-, $y$- and $z$-orbitals: +\begin{lstlisting} + \pzorb \qquad \pyorb \qquad \pxorb +\end{lstlisting} +\pzorb \qquad \pyorb \qquad \pxorb + +With suitable shifting you can display them all on one spot: +\begin{lstlisting} + \hspace{2cm}\pxorb\hspace{-.3em}\pyorb\hspace{-.3em}\pzorb + \tikz[overlay]{ + \draw[->](0,0)--(1,0)node[right]{$y$}; + \draw[dashed](0,0)--(-1,0); + \draw[->](0,0)--(0,1)node[above]{$z$}; + \draw[dashed](0,0)--(0,-1); + \draw[->](0,0)--(-.707,-.707)node[below left]{$x$}; + \draw[dashed](0,0)--(.707,.707); + } +\end{lstlisting} +\hspace{2cm}\pxorb\hspace{-.3em}\pyorb\hspace{-.3em}\pzorb\tikz[overlay]{\draw[->](0,0)--(1,0)node[right]{$y$};\draw[->](0,0)--(0,1)node[above]{$z$};\draw[->](0,0)--(-.707,-.707)node[below left]{$x$};\draw[dashed](0,0)--(-1,0);\draw[dashed](0,0)--(0,-1);\draw[dashed](0,0)--(.707,.707);} +\vspace{2cm} + +The orbitals also can be used together with `chemfig': +\begin{lstlisting} + \setorbheight{2em}\setbondoffset{0pt} + \chemfig{?\pzorb-[,1.3]\pzorb-[:30,1.1]\pzorb-[:150,.9]\pzorb-[4,1.3]\pzorb-[:-150,1.1]\pzorb?}\qquad + \chemfig{?\pzorb-[,1.3]{\porb[,,-90]}-[:30,1.1]\pzorb-[:150,.9]{\porb[,,-90]}-[4,1.3]\pzorb-[:-150,1.1]{\porb[,,-90]}?} +\end{lstlisting} +\vspace{1cm} +{\setorbheight{2em}\setbondoffset{0pt} +\chemfig{?\pzorb-[,1.3]\pzorb-[:30,1.1]\pzorb-[:150,.9]\pzorb-[4,1.3]\pzorb-[:-150,1.1]\pzorb?}\qquad +\chemfig{?\pzorb-[,1.3]{\porb[,,-90]}-[:30,1.1]\pzorb-[:150,.9]{\porb[,,-90]}-[4,1.3]\pzorb-[:-150,1.1]{\porb[,,-90]}?}} + +\section{Pachage Options}\label{sec:optionen} +\CMname\ has two package options: +\begin{itemize} + \item\lstinline+xspace=<boolean>+ With the option \lstinline+xspace=true+ the commands\\ + \lstinline=\Hyd \HtO Text \Hyd, \HtO, Text= \Hyd \HtO Text \Hyd, \HtO, Text\\ + get a \lstinline=\xspace=.\\ + Default: \lstinline+xspace=false+ + \item\lstinline+circled=<boolean>+ not everybody likes circled charge symbols ($\oplus$ and $\ominus$). Some prefer them without circles ($+$ and $-$). This can be chosen this option. With \lstinline+circled=false+ all \CMname\ commands are set without circles.\\ + Default: \lstinline+circled=true+ +\end{itemize} + +\section{List of Commands}\label{sec:befehlsreferenz} +\begin{tabular}{>{\raggedright}p{.35\textwidth}|>{\raggedright}p{.55\textwidth}}\toprule + \lstinline=\el=, \lstinline=\prt=, \lstinline=\ntr= & section \ref{sec:teilchen}: Particles, Ions and a Symbol\tabularnewline + \lstinline=\HtO=, \lstinline=\Hpl=, \lstinline=\Hyd= & \tabularnewline + \lstinline=\transitionstatesymbol= & \tabularnewline\midrule + \lstinline=\cip=, \lstinline=\Rcip=, \lstinline=\Scip= & section \ref{sec:stereo}: Stereo Descriptors, Nomenclature\tabularnewline + \lstinline=\Dfi=, \lstinline=\Lfi= & \tabularnewline + \lstinline=\E=, \lstinline=\Z=, \lstinline=\cis=, \lstinline=\trans= & \tabularnewline + \lstinline=\Rconf=, \lstinline=\Sconf= & \tabularnewline + \lstinline=\ortho=, \lstinline=\meta=, \lstinline=\para= & \tabularnewline\midrule + \lstinline=\delm=, \lstinline=\delp= & section \ref{sec:ladungen}: Oxidation Numbers and (real) Charges\tabularnewline + \lstinline=\mch=, \lstinline=\pch= & \tabularnewline + \lstinline=\ox= & \tabularnewline + \lstinline=\scrm=, \lstinline=\scrp= & \tabularnewline\midrule + \lstinline=\Enthalpy=, \lstinline=\Entropy=, \lstinline=\Gibbs= & section \ref{sec:standardstate}: (Standard) State, Thermodynamics\tabularnewline + \lstinline=\setnewstate= & \tabularnewline + \lstinline=\State= & \tabularnewline\midrule + \lstinline=\newman= & section \ref{sec:newman}: Newman Projections \tabularnewline\midrule + \lstinline=\redox=, \lstinline=\OX= & section \ref{sec:redoxreaktionen}: Redox Reactions \tabularnewline\midrule + \lstinline=\begin{reaction}=, \lstinline=\begin{reaction*}=, \lstinline=\begin{reactions}=, \lstinline=\begin{reactions*}= & section \ref{sec:mhchem}: Environments for `mhchem'\tabularnewline\midrule + \lstinline=\phorb=, \lstinline=\porb=, \lstinline=\pxorb=, \lstinline=\pyorb=, \lstinline=\pzorb= & section \ref{sec:orbitale}: p-Orbitals\tabularnewline + \lstinline=\setorbheight= & \tabularnewline\bottomrule +\end{tabular} + +\end{document}
\ No newline at end of file diff --git a/Master/texmf-dist/tex/latex/chemmacros/chemmacros.sty b/Master/texmf-dist/tex/latex/chemmacros/chemmacros.sty new file mode 100644 index 00000000000..d789aef77ce --- /dev/null +++ b/Master/texmf-dist/tex/latex/chemmacros/chemmacros.sty @@ -0,0 +1,412 @@ +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% ------------------------------------------------------------------------------------- % +% - chemmacros - chemmacros.sty ------------------------------------------------------- % +% - a collection of macros to make typesetting chemistry documents more convenient ---- % +% ------------------------------------------------------------------------------------- % +% - Clemens Niederberger -------------------------------------------------------------- % +% - 2011/05/15 ------------------------------------------------------------------------ % +% ------------------------------------------------------------------------------------- % +% - http://www.mychemistry.eu/ -------------------------------------------------------- % +% - contact@mychemistry.eu ------------------------------------------------------------ % +% ------------------------------------------------------------------------------------- % +% - If you have any ideas, questions, suggestions or bugs to report, please feel free - % +% - to contact me. -------------------------------------------------------------------- % +% ------------------------------------------------------------------------------------- % +% - Copyright 2011 Clemens Niederberger - % +% - - % +% - This work may be distributed and/or modified under the - % +% - conditions of the LaTeX Project Public License, either version 1.3 - % +% - of this license or (at your option) any later version. - % +% - The latest version of this license is in - % +% - http://www.latex-project.org/lppl.txt - % +% - and version 1.3 or later is part of all distributions of LaTeX - % +% - version 2005/12/01 or later. - % +% - - % +% - This work has the LPPL maintenance status `maintained'. - % +% - - % +% - The Current Maintainer of this work is Clemens Niederberger. - % +% - - % +% - This work consists of the files chemmacros.sty, chemmacros_doc_de.tex, - % +% - chemmacros_doc_de.tex, README - % +% ------------------------------------------------------------------------------------- % +% - Version history: ------------------------------------------------------------------ % +% 2011/05/15 version 1.0 CTAN release % +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\def\CM@version{1.0} +\def\CM@date{2011/05/15} +\def\CM@name{chemmacros} +\ProvidesPackage{chemmacros}[\CM@date] +\typeout{\CM@name\space v\CM@version, \CM@date\space Clemens Niederberger} +\RequirePackage{xkeyval,amsmath,tikz} +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% - package options ------------------------------------------------------------------- % +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\newif\if@circled\@circledtrue +\newif\if@mhchemloaded\@mhchemloadedfalse +\newif\if@xspaceloaded\@xspaceloadedfalse +\newif\if@siunitxloaded\@siunitxloadedfalse +\newif\if@chemstyleloaded\@chemstyleloadedfalse + +\define@boolkey+[CM]{chemmacros.sty}[CM@]{circled}{ + \ifCM@circled + \@circledtrue + \else + \@circledfalse + \fi +}{ + \PackageWarning{chemmacros}{option `circled' is not boolean} +} + +\define@key[CM]{chemmacros.sty}{xspace}{ + \def\CM@xspace@value{#1}% +} + +\ProcessOptionsX[CM] + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% - tools ----------------------------------------------------------------------------- % +\def\CM@false{false}% +\def\CM@true{true}% +\def\CM@off{off}% +\def\CM@on{on}% +\def\CM@right{right}% +% Optional Argument Analysis ---------------------------------------------------------- % +% Prüfen ob #2 in #1 enthalten ist +% (das Makro ist eine Kopie von \CF@if@instr in chemfig.tex von Christian Tellechea) +\def\CM@if@instr#1#2{% + \def\CM@if@instr@i##1#2##2\@nil{\ifx\@empty##2\@empty\expandafter\@secondoftwo\else\expandafter\@firstoftwo\fi}% + \CM@if@instr@i#1\@@nil#2\@nil% +} +% Am ersten , splitten, #1 in #3 speichern, #2 in \CM@remainargs +% (das Makro ist eine Kopie von \CF@analyze@movearg in chemfig.tex von Christian Tellechea) +\def\CM@splitfirst#1,#2\@nil#3{% + \def#3{#1}\def\CM@remainargs{#2}% +} +% ein durch , in 3 Teile getrenntes Argument splitten +% (das Makro ist eine Abwandlung von \CF@analyze@movearg in chemfig.tex von Christian Tellechea) +\def\CM@splitarg#1{% + \CM@if@instr{#1}{,}{\expandafter\CM@splitfirst#1\@nil\CM@firstarg}{\def\CM@firstarg{#1}}% + \expandafter\CM@if@instr\expandafter{\CM@remainargs}{,}{\expandafter\CM@splitfirst\CM@remainargs\@nil\CM@secondarg}{\expandafter\def\expandafter\CM@secondarg\expandafter{\CM@remainargs}}% + \ifx\CM@remainargs\CM@secondarg\let\CM@thirdarg\@empty\else\expandafter\def\expandafter\CM@thirdarg\expandafter{\CM@remainargs}\fi% +} + +\let\CM@xspace\empty% +\ifx\CM@xspace@value\CM@false\def\CM@xspace{}\fi% +\ifx\CM@xspace@value\CM@true% + \@ifpackageloaded{xspace}{}{\RequirePackage{xspace}} + \def\CM@xspace{\xspace}% +\fi +\ifx\CM@xspace@value\CM@off\def\CM@xspace{}\fi% +\ifx\CM@xspace@value\CM@on% + \@ifpackageloaded{xspace}{}{\RequirePackage{xspace}}% + \def\CM@xspace{\xspace}% +\fi + +\@ifpackageloaded{mhchem}{\@mhchemloadedtrue}{\@mhchemloadedfalse} +\@ifpackageloaded{siunitx}{\@siunitxloadedtrue}{\@siunitxloadedfalse} +\@ifpackageloaded{chemstyle}{\@chemstyleloadedtrue}{\@chemstyleloadedfalse} + +\if@mhchemloaded% + \def\CM@atom#1{\cf{#1}}% +\else% + \def\CM@atom#1{\ensuremath{\text{#1}}}% +\fi + +\if@circled% + \def\CM@plus{\oplus}% + \def\CM@minus{\ominus}% +\else% + \def\CM@plus{+}% + \def\CM@minus{-}% +\fi +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% - particles, charges, other helpers ------------------------------------------------- % +% electron +\def\el{\ensuremath{e^\CM@minus}\CM@xspace}% +% proton +\def\prt{\ensuremath{p^\CM@plus}\CM@xspace}% +% charges +\def\mch{\@ifnextchar[{\mch@ii}{\mch@i}}% + \def\mch@i{\ensuremath{{}^{\CM@minus}}}% + \def\mch@ii[#1]{\ensuremath{{}^{#1\CM@minus}}}% +\def\pch{\@ifnextchar[{\pch@ii}{\pch@i}}% + \def\pch@i{\ensuremath{{}^{\CM@plus}}}% + \def\pch@ii[#1]{\ensuremath{{}^{#1\CM@plus}}}% +\def\delm{\ensuremath{\text{\tiny$\delta\CM@minus$}}\CM@xspace}% +\def\delp{\ensuremath{\text{\tiny$\delta\CM@plus$}}\CM@xspace}% +\def\scrm{\ensuremath{\scriptstyle\CM@minus}}% +\def\scrp{\ensuremath{\scriptstyle\CM@plus}}% +% neutron +\def\ntr{\ensuremath{n^0}\CM@xspace}% + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% - stereo descriptors ---------------------------------------------------------------- % +% Cahn-Ingold-Prelog +\def\Rcip{\textit{(R)}}% +\def\Scip{\textit{(S)}}% +\def\cip#1{\textit{(#1)}}% +\def\Sconf{\@ifnextchar[{\sconf@ii}{\sconf@i}}% S-Konfiguration + \def\sconf@ii[#1]{\tikz[baseline=(a.base),text height=1.5ex,text depth=.25ex]{\draw node(a) at (0,0) {#1};\draw[->,thick,rotate=90] (20:.3cm) arc (20:340:.3cm);}}% + \def\sconf@i{\tikz[baseline=(a.base),text height=1.5ex,text depth=.25ex]{\draw node(a) at (0,0) {S};\draw[->,thick,rotate=90] (20:.3cm) arc (20:340:.3cm);}}% +\def\Rconf{\@ifnextchar[{\rconf@ii}{\rconf@i}}% R-Konfiguration + \def\rconf@ii[#1]{\tikz[baseline=(a.base),text height=1.5ex,text depth=.25ex]{\draw node(a) at (0,0) {#1};\draw[<-,thick,rotate=90] (20:.3cm) arc (20:340:.3cm);}}% + \def\rconf@i{\tikz[baseline=(a.base),text height=1.5ex,text depth=.25ex]{\draw node(a) at (0,0) {R};\draw[<-,thick,rotate=90] (20:.3cm) arc (20:340:.3cm);}}% +% E/Z +\def\E{\textit{(E)}}% +\def\Z{\textit{(Z)}}% +\def\cis{\textit{cis}}% +\def\trans{\textit{trans}}% +% Fischer +\def\Dfi{\textsc{d}}% +\def\Lfi{\textsc{l}}% +% ortho/meta/para +\def\ortho{\textsl{o}}% +\def\meta{\textsl{m}}% +\def\para{\textsl{p}}% + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% - ions ------------------------------------------------------------------------------ % +% Proton, Hydroxid, Hydronium +\def\Hpl{\CM@atom{H$^\CM@plus$}\CM@xspace}% +\def\Hyd{\CM@atom{OH$^\CM@minus$}\CM@xspace}% +\def\HtO{\CM@atom{H$_3$O$^\CM@plus$}\CM@xspace}% + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% - oxidation numbers ----------------------------------------------------------------- % +% \ox{<number>,<atom>} +\def\CM@ox@sign#1{% + \ifx -#1{$-$}% + \else \ifx +#1{$+$}% + \else #1% + \fi\fi% +} +\def\ox#1{% + \let\CM@remainargs\@empty\CM@splitarg{#1}% + \ifx\CM@firstarg\@empty\PackageError{chemmacros}{\string\ox: oxidation number missing}\fi% + \ifx\CM@secondarg\@empty\PackageError{chemmacros}{\string\ox: atom missing}\fi% + \let\CM@thirdarg\@empty% + \ensuremath{\overset{\text{\tiny\expandafter\CM@ox@sign\CM@firstarg}}{\expandafter\CM@atom\expandafter{\CM@secondarg}}}% +}% + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% - oxidation arrows ------------------------------------------------------------------ % +% \OX{<name>,<atom>} +% \redox(<name1>,<name2>)[<tikz>][<dim>]{<text>} +% node setzen und benennen: +\def\OX#1{% + \let\CM@remainargs\@empty\CM@splitarg{#1}% + \ifx\CM@firstarg\@empty\PackageError{chemmacros}{\string\OX: node name missing}\fi% + \ifx\CM@secondarg\@empty\PackageError{chemmacros}{\string\OX: atom missing}\fi% + \let\CM@thirdarg\@empty% + \tikz[baseline=(\CM@firstarg.base),remember picture]{\node[inner sep=0](\CM@firstarg){\expandafter\CM@atom\expandafter{\CM@secondarg}};}% +} + +% nodes mit Linie verbinden: +\def\redox(#1){% + \let\CM@redox@tikz\@empty% + \let\CM@remainargs\@empty\CM@splitarg{#1}% + \ifx\CM@firstarg\@empty\PackageError{chemmacros}{\string\redox: you must specify coordinates}\fi% + \ifx\CM@secondarg\@empty\PackageError{chemmacros}{\string\redox: you must specify coordinates}\fi% + \let\CM@thirdarg\@empty% + \let\CM@redox@begin\CM@firstarg% + \let\CM@redox@end\CM@secondarg% + \redox@i% +} +\def\redox@i{\@ifnextchar[{\redox@ii}{\def\CM@redox@shift{.6em}\def\CM@redox@anchor{above}\def\CM@redox@side{north}\def\CM@redox@dist{.2em}\redox@v}} +\def\redox@ii[#1]{% + \ifx\@empty#1\@empty + \let\CM@redox@tikz\@empty% + \else% + \def\CM@redox@tikz{#1}% + \fi + \redox@iii% +} +\def\redox@iii{\@ifnextchar[{\redox@iv}{\def\CM@redox@shift{.6em}\def\CM@redox@anchor{above}\def\CM@redox@side{north}\def\CM@redox@dist{.2em}\redox@v}} +\def\redox@iv[#1]{% + \ifx\@empty#1\@empty% + \let\CM@redox@shift\@empty% + \else% + \pgfmathparse{#1<0} + \ifnum\pgfmathresult=1% + \def\CM@redox@anchor{below}\def\CM@redox@side{south}\def\CM@redox@dist{-.2em}% + \else% + \def\CM@redox@anchor{above}\def\CM@redox@side{north}\def\CM@redox@dist{.2em}% + \fi% + \def\CM@redox@shift{#1}% + \fi% + \redox@v% +} +\def\redox@v#1{% + \ifx\CM@redox@tikz\@empty\def\CM@redox@tikz{}\fi% + \ifx\CM@redox@shift\@empty\def\CM@redox@shift{.6em}\def\CM@redox@anchor{above}\fi% + \tikz[remember picture,overlay]{\expandafter\draw\expandafter[\CM@redox@tikz] ($(\CM@redox@begin.\CM@redox@side)+(0,\CM@redox@dist)$) -- ++(0,\CM@redox@shift) -| node[pos=.25,\CM@redox@anchor]{#1} ($(\CM@redox@end.\CM@redox@side)+(0,\CM@redox@dist)$);}% +} + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% - reaction environments for mhchem -------------------------------------------------- % +\if@mhchemloaded + \RequirePackage{mathtools,environ} + \newtagform{CMreaction}{\{}{\}} + \newcounter{save@reaction}% + \newcounter{reaction}% + \def\CM@AtBeginReaction{\setcounter{save@reaction}{\value{equation}}\setcounter{equation}{\value{reaction}}\usetagform{CMreaction}}% + \def\CM@AtEndReaction{\setcounter{reaction}{\value{equation}}\setcounter{equation}{\value{save@reaction}}\usetagform{default}}% + % + \NewEnviron{reaction}{\CM@AtBeginReaction\begin{equation}\expandafter\ce\expandafter{\BODY}\end{equation}\CM@AtEndReaction} + \NewEnviron{reaction*}{\begin{equation*}\expandafter\ce\expandafter{\BODY}\end{equation*}} + % + \NewEnviron{reactions}{\CM@AtBeginReaction\begin{align}\expandafter\cee\expandafter{\BODY}\end{align}\CM@AtEndReaction} + \NewEnviron{reactions*}{\begin{align*}\expandafter\cee\expandafter{\BODY}\end{align*}} +\fi + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% - transition state symbol ----------------------------------------------------------- % +\def\transitionstatesymbol{\tikz[inner sep=0,outer sep=0,minimum size=0]{% + \coordinate (@TSa) at (0,0);% + \coordinate (@TSb) at (0,.6em);% + \draw(@TSa)--node[pos=.3333](@TSx){}node[pos=.6667](@TSy){}(@TSb);% + \draw(@TSx)++(-.3em,0)--++(.6em,0);% + \draw(@TSy)++(-.3em,0)--++(.6em,0);}% +} + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% - enthalpy, entropy ----------------------------------------------------------------- % +% \State[<exp>,<Delta>,right]{<Symbol>}{<Index>} +\def\State{\@ifnextchar[{\CM@state@ii}{\CM@state@i}}% + \def\CM@state@i#1#2{\ensuremath{\Delta_\mathrm{#2}#1\if@chemstyleloaded^\standardstate\fi}}% + \def\CM@state@ii[#1]#2#3{% + \let\CM@remainargs\@empty\CM@splitarg{#1}% + \ensuremath{\ifx\CM@secondarg\@empty\Delta\else\CM@secondarg\fi\ifx\CM@thirdarg\CM@right\else_\mathrm{#3}\fi#2\ifx\CM@thirdarg\CM@right_\mathrm{#3}\fi\ifx\CM@firstarg\@empty\if@chemstyleloaded^{\standardstate}\fi\else^{\CM@firstarg}\fi}% + }% + +\if@siunitxloaded + \if@chemstyleloaded\else\def\standardstate{}\fi + \let\CM@standard@state@symbol\standardstate% + \def\setnewstate{\@ifnextchar[{\CM@setnewstate@ii}{\let\CM@current@standard@state@symbol\@empty\def\CM@state@delta{\Delta}\def\CM@state@kind@right{}\CM@setnewstate@i}}% + \def\CM@setnewstate@ii[#1]{% + \let\CM@remainargs\@empty\CM@splitarg{#1}% exp,Delta,right + \ifx\CM@firstarg\@empty\let\CM@current@standard@state@symbol\@empty\else\let\CM@current@standard@state@symbol\CM@firstarg\fi% + \ifx\CM@secondarg\@empty\def\CM@state@delta{\Delta}\else\let\CM@state@delta\CM@secondarg\fi% + \ifx\CM@thirdarg\CM@right\let\CM@state@kind@right\CM@right\else\def\CM@state@kind@right{}\fi% + \CM@setnewstate@i% + } + \def\CM@setnewstate@i#1#2#3{% + \ifx\CM@current@standard@state@symbol\@empty\let\CM@current@standard@state@symbol\standardstate\fi% + \expandafter\let\csname CM@#1@symbol\endcsname\CM@current@standard@state@symbol% + \expandafter\let\csname CM@#1@delta\endcsname\CM@state@delta% + \expandafter\def\csname#1\endcsname{\@ifnextchar[{\csname CM@#1@ii\endcsname}{\csname CM@#1@i\endcsname}}% + \expandafter\def\csname CM@#1@i\endcsname##1{\ensuremath{\State[\csname CM@#1@symbol\endcsname,\csname CM@#1@delta\endcsname]{#2}{}=\SI{##1}{#3}}}% + \expandafter\def\csname CM@#1@ii\endcsname[##1]##2{% + \let\CM@remainargs\@empty\CM@splitarg{##1}% index,exp,einheit + \let\CM@state@index\CM@firstarg% + \let\CM@state@symbol\CM@secondarg% + \let\CM@state@unit\CM@thirdarg% + \ensuremath{\State[\CM@state@symbol,\csname CM@#1@delta\endcsname]{#2}{\CM@state@index} = \SI{##2}{\ifx\CM@state@unit\@empty#3\else\CM@state@unit\fi}}% + }% + }% + \setnewstate{Enthalpy}{H}{\kilo\joule\per\mole}% + \setnewstate[, ]{Entropy}{S}{\joule\per\kelvin\per\mole}% + \setnewstate{Gibbs}{G}{\kilo\joule\per\mole}% +\fi% + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% - p-orbitals ------------------------------------------------------------------------ % +% \phorb[<size factor>,<color>,<angle>] +\def\CM@phorb{\@ifnextchar[{\CM@phorb@ii}{\let\CM@firstarg\@empty\let\CM@secondarg\@empty\let\CM@thirdarg\@empty\CM@phorb@i}} +\def\CM@phorb@ii[#1]{\let\CM@remainargs\@empty\CM@splitarg{#1}\CM@phorb@i} +\def\CM@phorb@i{ + \ifx\CM@firstarg\@empty\def\CM@orb@flip{1.5*\CM@orb@height}\else\def\CM@orb@flip{\CM@firstarg*1.5*\CM@orb@height}\fi + \ifx\CM@secondarg\@empty\def\CM@orb@color{black}\else\def\CM@orb@color{\CM@secondarg}\fi + \ifx\CM@thirdarg\@empty\def\CM@orb@ang{0}\else\def\CM@orb@ang{\CM@thirdarg}\fi + \tikzpicture[overlay,rotate={\CM@orb@ang-90},opacity=.5,inner sep=0pt,outer sep=0pt,text height=0pt,text depth=0pt] + \pgfsetfillopacity{.5} + \node(\CM@orb@node){}; + \draw[draw=\CM@orb@color,fill=\CM@orb@color] (\CM@orb@node) .. controls ++(-.9*\CM@orb@height,\CM@orb@flip) and ++(.9*\CM@orb@height,\CM@orb@flip) .. (\CM@orb@node); + \endtikzpicture +} +\def\phorb{\CM@phorb} + +% \porb[<size factor>,<color>,<angle>] +\def\CM@porb{\@ifnextchar[{\CM@porb@ii}{\let\CM@firstarg\@empty\let\CM@secondarg\@empty\let\CM@thirdarg\@empty\CM@porb@i}} +\def\CM@porb@ii[#1]{\let\CM@remainargs\@empty\CM@splitarg{#1}\CM@porb@i} +\def\CM@porb@i{ + \ifx\CM@firstarg\@empty\def\CM@orb@flip{1.5*\CM@orb@height}\else\def\CM@orb@flip{\CM@firstarg*1.5*\CM@orb@height}\fi + \ifx\CM@secondarg\@empty\def\CM@orb@color{black}\else\def\CM@orb@color{\CM@secondarg}\fi + \ifx\CM@thirdarg\@empty\def\CM@orb@ang{0}\else\def\CM@orb@ang{\CM@thirdarg}\fi + \tikzpicture[overlay,rotate={\CM@orb@ang-90},opacity=.5,inner sep=0pt,outer sep=0pt,text height=0pt,text depth=0pt] + \pgfsetfillopacity{.5} + \node(\CM@orb@node){}; + \draw[draw=black] (\CM@orb@node) .. controls ++(-.9*\CM@orb@height,\CM@orb@flip) and ++(.9*\CM@orb@height,\CM@orb@flip) .. (\CM@orb@node); + \draw[draw=\CM@orb@color,fill=\CM@orb@color] (\CM@orb@node) .. controls ++(-.9*\CM@orb@height,-\CM@orb@flip) and ++(.9*\CM@orb@height,-\CM@orb@flip) .. (\CM@orb@node); + \endtikzpicture +} +\def\porb{\CM@porb} + +\def\CM@orb@node{x} +\def\CM@orb@height{1em} +\def\setorbheight#1{ + \ifx\@empty#1\@empty + \def\CM@orb@height{1em} + \else + \def\CM@orb@height{#1} + \fi +} + +\def\pzorb{\porb[,,90]} +\def\pyorb{\porb[,,0]} +\def\pxorb{\porb[,,-135]} +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% - Newman projections ---------------------------------------------------------------- % +\let\CM@newman@tikz@ring\@empty% +\let\CM@newman@tikz@one\@empty% +\let\CM@newman@tikz@two\@empty% +\def\newman{\@ifnextchar[{\CM@newman@ii}{\def\CM@newman@angle{0}\def\CM@newman@scale{1}\let\CM@newman@tikz@ring\@empty\let\CM@newman@tikz@one\@empty\let\CM@newman@tikz@two\@empty\CM@newman@i}}% +\def\CM@newman@ii[#1]{% + \let\CM@remainargs\@empty\CM@splitarg{#1}% + \ifx\CM@firstarg\@empty\def\CM@newman@angle{0}\else\let\CM@newman@angle\CM@firstarg\fi% + \ifx\CM@secondarg\@empty\def\CM@newman@scale{1}\else\let\CM@newman@scale\CM@secondarg\fi% + \ifx\CM@thirdarg\@empty\let\CM@newman@tikz@ring\else\let\CM@newman@tikz@ring\CM@thirdarg\fi% + \CM@newman@iii% +} +\def\CM@newman@iii{\@ifnextchar[{\CM@newman@iv}{\CM@newman@i}} +\def\CM@newman@iv[#1]{% + \ifx\@empty#1\@empty\let\CM@newman@tikz@one\@empty\else\edef\CM@newman@tikz@one{#1}\fi% + \let\CM@newman@tikz@two\CM@newman@tikz@one% + \CM@newman@v% +} +\def\CM@newman@v{\@ifnextchar[{\CM@newman@vi}{\CM@newman@i}} +\def\CM@newman@vi[#1]{% + \ifx\@empty#1\@empty\else\edef\CM@newman@tikz@two{#1}\fi% + \CM@newman@i% +} +\def\CM@newman@i#1{% + \let\CM@remainargs\@empty\CM@splitarg{#1}% + \ifx\CM@firstarg\@empty\let\CM@newman@node@one\@empty\else\let\CM@newman@node@one\CM@firstarg\fi% + \ifx\CM@secondarg\@empty\let\CM@newman@node@two\CM@newman@tikz@one\else\let\CM@newman@node@two\CM@secondarg\fi% + \let\CM@remainargs\@empty% + \expandafter\CM@splitarg\expandafter{\CM@thirdarg}% + \ifx\CM@firstarg\@empty\let\CM@newman@node@three\@empty\else\let\CM@newman@node@three\CM@firstarg\fi% + \ifx\CM@secondarg\@empty\let\CM@newman@node@four\@empty\else\let\CM@newman@node@four\CM@secondarg\fi% + \let\CM@remainargs\@empty% + \expandafter\CM@splitarg\expandafter{\CM@thirdarg}% + \ifx\CM@firstarg\@empty\let\CM@newman@node@five\@empty\else\let\CM@newman@node@five\CM@firstarg\fi% + \ifx\CM@secondarg\@empty\let\CM@newman@node@six\@empty\else\let\CM@newman@node@six\CM@secondarg\fi% + \let\CM@thirdarg\@empty% + \edef\CM@newman@tikz{scale=\CM@newman@scale,atomF/.style={inner sep=0,outer sep=0,\CM@newman@tikz@one},atomB/.style={inner sep=0,outer sep=0,\CM@newman@tikz@two}} + \expandafter\tikz\expandafter[\CM@newman@tikz]{% + \coordinate (a) at (0,0); + \expandafter\draw\expandafter[\CM@newman@tikz@ring] (a) circle (.5); + \foreach\i in{30+\CM@newman@angle,150+\CM@newman@angle,270+\CM@newman@angle} + {\expandafter\draw\expandafter[\CM@newman@tikz@ring] ($(a)+(\i:0.5)$) --++(\i:.5);} + \node[atomB,anchor=-150+\CM@newman@angle] at ($(a)+(30+\CM@newman@angle:1.05)$) {\CM@newman@node@five}; + \node[atomB,anchor=-30+\CM@newman@angle] at ($(a)+(150+\CM@newman@angle:1.05)$){\CM@newman@node@six}; + \node[atomB,anchor=90+\CM@newman@angle] at ($(a)+(270+\CM@newman@angle:1.05)$){\CM@newman@node@four}; + \foreach\i in{90,210,330} + {\expandafter\draw\expandafter[\CM@newman@tikz@ring] (a) --++(\i:1);} + \node[atomF,anchor=-90] at ($(a)+(90:1.05)$) {\CM@newman@node@one}; + \node[atomF,anchor=30] at ($(a)+(210:1.05)$){\CM@newman@node@two}; + \node[atomF,anchor=150] at ($(a)+(330:1.05)$){\CM@newman@node@three}; + } +} + +\endinput
\ No newline at end of file |