答案1
\documentclass{article}
\usepackage{chemfig}
\begin{document}
\chemname[5ex]{\chemfig{
[:30]*6((<HO)-(<:OH)-(<:O>:*6(-(<HO)-(<:OH)-(<:O-[@{cl,0.5},1.2])-O-(<-[:60]OH)--))-O-(<-[:60]OH)-(-[@{op,0.5},1.2])-)
}}{
\huge Cellulose \vspace{1ex} \\
\huge $(\chemfig{C_6H_{10}O_5})_n$
}
\polymerdelim[delimiters ={[]}, height = 19ex, depth = 14ex, indice=\!\mbox{$n$}]{op}{cl}
\end{document}
答案2
我不是化学专业的,只是尝试了一下。我喜欢在 TikZ 中嵌入化学图形和公式node
(高度自定义)。
\documentclass{article}
\usepackage{chemfig} % for chemistry figures and formulae
\usepackage{amsmath,tikz}
\begin{document}
Here is an example.
\[\frac{f(x+\delta x)-f(x)}{\delta x}
\underset{\delta x\to 0}{\longrightarrow}
f'(x)\]
And this is another \verb|chemfig| example.
\def\mych{\chemfig{
[:30]*6((<HO)-(<:OH)-(<:O>:*6(-(<HO)-(<:OH)-(<:O-[@{cl,0.5},1.2])-O-(<-[:60]OH)--))-O-(<-[:60]OH)-(-[@{op,0.5},1.2])-)
}}
\[\underset{\text{Cellulose}}{\mych}\]
I propose a TikZ way:
\newsavebox{\boxCh}
\savebox{\boxCh}{$\mych$}
\begin{center}
\begin{tikzpicture}
\node (C) {\usebox{\boxCh}};
\path (C.south) node[below=5mm,scale=1.5,align=center,red]{Cellulose\\
$(\chemfig{C_6H_{10}O_5})_n$
};
\end{tikzpicture}
\end{center}
\end{document}