\usechemmodule 来自 chemmacros 未定义

\usechemmodule 来自 chemmacros 未定义

我正在尝试使用热力学模块等来显示焓,但似乎不起作用。

\documentclass[twocolumn]{article}
\usepackage{chemmacros}
\usechemmodule{all}

\begin{document} 
  \enthalpy*(r){1} 
\end{document}

答案1

以下内容适用于 v5.0 之前的版本和当前版本:

\documentclass{article}
\usepackage{chemmacros}

% versions below 5.0 don't have the macro. Let's provide it
% to expand to the “false” branch if it isn't defined:
\providecommand\IfChemCompatibilityTF[4]{#4}

% let's check if the current version of chemmacros (or rather the
% compatibility mode it is used with) is 5.0 or newer:
\IfChemCompatibilityTF{>=}{5.0}{
  % load all the modules we need. “all” is overkill but will do:
  \usechemmodule{all}
}{
  % in the new versions \Enthalpy is called \enthalpy. Let's
  % take care we can use the same command either way:
  \let\enthalpy\Enthalpy
}

\begin{document} 

\enthalpy*(r){1} 

\end{document}

相关内容