![如何在多行中编写一个长方程式并将其缩放到文本宽度?](https://linux22.com/image/259612/%E5%A6%82%E4%BD%95%E5%9C%A8%E5%A4%9A%E8%A1%8C%E4%B8%AD%E7%BC%96%E5%86%99%E4%B8%80%E4%B8%AA%E9%95%BF%E6%96%B9%E7%A8%8B%E5%BC%8F%E5%B9%B6%E5%B0%86%E5%85%B6%E7%BC%A9%E6%94%BE%E5%88%B0%E6%96%87%E6%9C%AC%E5%AE%BD%E5%BA%A6%EF%BC%9F.png)
我想写一个分多行的长方程式,但结果看起来非常不规则。
这个方程怎么写才更好,最好所有方程都占据相同的宽度?
\documentclass[12pt]{book}
\usepackage[]{breqn}
\usepackage{lipsum}
\begin{document}
How can I write equation beatifull. I want all equation the same of text width
\lipsum[1]
\begin{equation*}
\begin{split}
&+\left[ {{T}_{44}}\left( 1,2 \right) \right.+2{{T}_{44}}\left( 5,2 \right)+\left. {{T}_{44}}\left( 2,2 \right) \right]\frac{{{\partial }^{4}}{{w}^{b}}}{\partial {{\eta }^{4}}}+\left[ {{T}_{44}}\left( 1,3 \right) \right.+2{{T}_{44}}\left( 5,3 \right)\\
&+\left. {{T}_{44}}\left( 2,3 \right) \right]\frac{{{\partial }^{4}}{{w}^{b}}}{\partial {{\xi }^{3}}\partial \eta }+\left[ {{T}_{44}}\left( 1,4 \right)+2{{T}_{44}}\left( 5,4 \right)+{{T}_{44}}\left( 2,4 \right) \right]\frac{{{\partial }^{4}}{{w}^{b}}}{\partial \xi \partial {{\eta }^{3}}}\\
&+\left[ {{T}_{44}}\left( 1,5 \right)+2{{T}_{44}}\left( 5,5 \right)+{{T}_{44}}\left( 2,5 \right) \right]\frac{{{\partial }^{4}}{{w}^{b}}}{\partial {{\xi }^{2}}\partial {{\eta }^{2}}}+\left[ {{T}_{43}}\left( 1,1 \right) \right.+2{{T}_{43}}\left( 5,1 \right)\\
&+\left. {{T}_{43}}\left( 2,1 \right) \right]\frac{{{\partial }^{3}}{{w}^{b}}}{\partial {{\xi }^{3}}}+\left[ {{T}_{43}}\left( 1,2 \right)+2{{T}_{43}}\left( 5,2 \right)+{{T}_{43}}\left( 2,2 \right) \right]\frac{{{\partial }^{3}}{{w}^{b}}}{\partial {{\eta }^{3}}}\\
&+\left[ {{T}_{43}}\left( 1,3 \right)+2{{T}_{43}}\left( 5,3 \right)+{{T}_{43}}\left( 2,3 \right) \right]\frac{{{\partial }^{3}}{{w}^{b}}}{\partial {{\xi }^{2}}\partial \eta }++\left[ {{T}_{43}}\left( 1,4 \right) \right.+2{{T}_{43}}\left( 5,4 \right)\\
&+\left. {{T}_{43}}\left( 2,4 \right) \right]\frac{{{\partial }^{3}}{{w}^{b}}}{\partial \xi \partial {{\eta }^{2}}}+\left( {{T}_{42}}\left( 1,1 \right)+2{{T}_{42}}\left( 5,1 \right)+{{T}_{42}}\left( 2,1 \right) \right)\frac{{{\partial }^{2}}{{w}^{b}}}{\partial {{\xi }^{2}}}\\
&+\left[ {{T}_{42}}\left( 1,2 \right)+2{{T}_{42}}\left( 5,2 \right)+{{T}_{42}}\left( 2,2 \right) \right]\frac{{{\partial }^{2}}{{w}^{b}}}{\partial {{\eta }^{2}}}+\left[ {{T}_{42}}\left( 1,3 \right)+ \right.2{{T}_{42}}\left( 5,3 \right)\\
&\left. +{{T}_{42}}\left( 2,3 \right) \right]\frac{{{\partial }^{2}}{{w}^{b}}}{\partial \xi \partial \eta }+\left[ {{T}_{41}}\left( 1,1 \right)+2{{T}_{41}}\left( 5,1 \right)+{{T}_{41}}\left( 2,1 \right) \right]\frac{\partial {{w}^{b}}}{\partial \xi }\\
&\left. +\left[ {{T}_{41}}\left( 1,1 \right)+2{{T}_{41}}\left( 5,1 \right)+{{T}_{41}}\left( 2,1 \right) \right]\frac{\partial {{w}^{b}}}{\partial \eta } \right\}-2\mu {{\tau }^{s}}\left\{ \left[ {{T}_{44}}\left( 1,1 \right)+ \right.2{{T}_{44}}\left( 5,1 \right) \right.\\
&+\left. {{T}_{44}}\left( 2,1 \right) \right]\frac{{{\partial }^{4}}{{w}^{b}}}{\partial {{\xi }^{4}}}+\left[ {{T}_{44}}\left( 1,2 \right) \right.+2{{T}_{44}}\left( 5,2 \right)+\left. {{T}_{44}}\left( 2,2 \right) \right]\frac{{{\partial }^{4}}{{w}^{s}}}{\partial {{\eta }^{4}}}+\left[ {{T}_{44}}\left( 1,3 \right) \right.
\end{split}
\end{equation*}
\end{document}
以下是上述代码的示例输出:
答案1
您有很多不匹配的括号(
和[
,{
这使得源和输出难以理解。我假设它们是要匹配的,并让 Tex 自己找到换行符:
\documentclass[12pt]{book}
\usepackage{lipsum}
\begin{document}
How can I write equation beatifull. I want all equation the same of text width
\lipsum[1]
\begin{center}
$\displaystyle
{[ {{T}_{44}}( 1,2 ) +2{{T}_{44}}( 5,2 )+{{T}_{44}}( 2,2 ) ]\frac{{{\partial }^{4}}{{w}^{b}}}{\partial {{\eta }^{4}}}}+
{[ {{T}_{44}}( 1,3 ) +2{{T}_{44}}( 5,3 )+{{T}_{44}}( 2,3 ) ]\frac{{{\partial }^{4}}{{w}^{b}}}{\partial {{\xi }^{3}}\partial \eta }}+
{[ {{T}_{44}}( 1,4 )+2{{T}_{44}}( 5,4 )+{{T}_{44}}( 2,4 ) ]\frac{{{\partial }^{4}}{{w}^{b}}}{\partial \xi \partial {{\eta }^{3}}}}+
{[ {{T}_{44}}( 1,5 )+2{{T}_{44}}( 5,5 )+{{T}_{44}}( 2,5 ) ]\frac{{{\partial }^{4}}{{w}^{b}}}{\partial {{\xi }^{2}}\partial {{\eta }^{2}}}}+
{[ {{T}_{43}}( 1,1 ) +2{{T}_{43}}( 5,1 )+{{T}_{43}}( 2,1 ) ]\frac{{{\partial }^{3}}{{w}^{b}}}{\partial {{\xi }^{3}}}}+
{[ {{T}_{43}}( 1,2 )+2{{T}_{43}}( 5,2 )+{{T}_{43}}( 2,2 ) ]\frac{{{\partial }^{3}}{{w}^{b}}}{\partial {{\eta }^{3}}}}+
{[ {{T}_{43}}( 1,3 )+2{{T}_{43}}( 5,3 )+{{T}_{43}}( 2,3 ) ]\frac{{{\partial }^{3}}{{w}^{b}}}{\partial {{\xi }^{2}}\partial \eta }}+
{[ {{T}_{43}}( 1,4 ) +2{{T}_{43}}( 5,4 )+ {{T}_{43}}( 2,4 ) ]\frac{{{\partial }^{3}}{{w}^{b}}}{\partial \xi \partial {{\eta }^{2}}}}+
{[ {{T}_{42}}( 1,1 )+2{{T}_{42}}( 5,1 )+{{T}_{42}}( 2,1 ) )\frac{{{\partial }^{2}}{{w}^{b}}}{\partial {{\xi }^{2}}}}+
{[ {{T}_{42}}( 1,2 )+2{{T}_{42}}( 5,2 )+{{T}_{42}}( 2,2 ) ]\frac{{{\partial }^{2}}{{w}^{b}}}{\partial {{\eta }^{2}}}}+
{[ {{T}_{42}}( 1,3 )+ 2{{T}_{42}}( 5,3 ) +{{T}_{42}}( 2,3 ) ]\frac{{{\partial }^{2}}{{w}^{b}}}{\partial \xi \partial \eta }}+
{[ {{T}_{41}}( 1,1 )+2{{T}_{41}}( 5,1 )+{{T}_{41}}( 2,1 ) ]\frac{\partial {{w}^{b}}}{\partial \xi }} +
{[ {{T}_{41}}( 1,1 )+2{{T}_{41}}( 5,1 )+{{T}_{41}}( 2,1 ) ]\frac{\partial {{w}^{b}}}{\partial \eta } -2\mu {{\tau }^{s}}}+
{[ {{T}_{44}}( 1,1 )+ 2{{T}_{44}}( 5,1 ) + {{T}_{44}}( 2,1 ) ]\frac{{{\partial }^{4}}{{w}^{b}}}{\partial {{\xi }^{4}}}}+
{[ {{T}_{44}}( 1,2 ) +2{{T}_{44}}( 5,2 ) +{{T}_{44}}( 2,2 ) ]\frac{{{\partial }^{4}}{{w}^{s}}}{\partial {{\eta }^{4}}}}+
{{T}_{44}}( 1,3 )
$\end{center}
\end{document}
或者使用breqn
基本相同的输入产生
\documentclass[12pt]{book}
\usepackage{breqn}
\usepackage{lipsum}
\begin{document}
How can I write equation beatifull. I want all equation the same of text width
\lipsum[1]
\begin{dmath*}
{[ {{T}_{44}}( 1,2 ) +2{{T}_{44}}( 5,2 )+{{T}_{44}}( 2,2 ) ]\frac{{{\partial }^{4}}{{w}^{b}}}{\partial {{\eta }^{4}}}}+
{[ {{T}_{44}}( 1,3 ) +2{{T}_{44}}( 5,3 )+{{T}_{44}}( 2,3 ) ]\frac{{{\partial }^{4}}{{w}^{b}}}{\partial {{\xi }^{3}}\partial \eta }}+
{[ {{T}_{44}}( 1,4 )+2{{T}_{44}}( 5,4 )+{{T}_{44}}( 2,4 ) ]\frac{{{\partial }^{4}}{{w}^{b}}}{\partial \xi \partial {{\eta }^{3}}}}+
{[ {{T}_{44}}( 1,5 )+2{{T}_{44}}( 5,5 )+{{T}_{44}}( 2,5 ) ]\frac{{{\partial }^{4}}{{w}^{b}}}{\partial {{\xi }^{2}}\partial {{\eta }^{2}}}}+
{[ {{T}_{43}}( 1,1 ) +2{{T}_{43}}( 5,1 )+{{T}_{43}}( 2,1 ) ]\frac{{{\partial }^{3}}{{w}^{b}}}{\partial {{\xi }^{3}}}}+
{[ {{T}_{43}}( 1,2 )+2{{T}_{43}}( 5,2 )+{{T}_{43}}( 2,2 ) ]\frac{{{\partial }^{3}}{{w}^{b}}}{\partial {{\eta }^{3}}}}+
{[ {{T}_{43}}( 1,3 )+2{{T}_{43}}( 5,3 )+{{T}_{43}}( 2,3 ) ]\frac{{{\partial }^{3}}{{w}^{b}}}{\partial {{\xi }^{2}}\partial \eta }}+
{[ {{T}_{43}}( 1,4 ) +2{{T}_{43}}( 5,4 )+ {{T}_{43}}( 2,4 ) ]\frac{{{\partial }^{3}}{{w}^{b}}}{\partial \xi \partial {{\eta }^{2}}}}+
{[ {{T}_{42}}( 1,1 )+2{{T}_{42}}( 5,1 )+{{T}_{42}}( 2,1 ) )\frac{{{\partial }^{2}}{{w}^{b}}}{\partial {{\xi }^{2}}}}+
{[ {{T}_{42}}( 1,2 )+2{{T}_{42}}( 5,2 )+{{T}_{42}}( 2,2 ) ]\frac{{{\partial }^{2}}{{w}^{b}}}{\partial {{\eta }^{2}}}}+
{[ {{T}_{42}}( 1,3 )+ 2{{T}_{42}}( 5,3 ) +{{T}_{42}}( 2,3 ) ]\frac{{{\partial }^{2}}{{w}^{b}}}{\partial \xi \partial \eta }}+
{[ {{T}_{41}}( 1,1 )+2{{T}_{41}}( 5,1 )+{{T}_{41}}( 2,1 ) ]\frac{\partial {{w}^{b}}}{\partial \xi }} +
{[ {{T}_{41}}( 1,1 )+2{{T}_{41}}( 5,1 )+{{T}_{41}}( 2,1 ) ]\frac{\partial {{w}^{b}}}{\partial \eta } -2\mu {{\tau }^{s}}}+
{[ {{T}_{44}}( 1,1 )+ 2{{T}_{44}}( 5,1 ) + {{T}_{44}}( 2,1 ) ]\frac{{{\partial }^{4}}{{w}^{b}}}{\partial {{\xi }^{4}}}}+
{[ {{T}_{44}}( 1,2 ) +2{{T}_{44}}( 5,2 ) +{{T}_{44}}( 2,2 ) ]\frac{{{\partial }^{4}}{{w}^{s}}}{\partial {{\eta }^{4}}}}+
{{T}_{44}}( 1,3 )
\end{dmath*}
\end{document}