Rewrite Rulesams/substack-expand

ams/substack-expand

Expand substack directly to the explicit centered subarray environment.

Rewrite patterns#

  1. \substack{#1\\#2}\begin{subarray}{c}#1\\#2\end{subarray}

Examples#

Each example shows this rule applied in isolation. A complete normalization profile may make additional changes.

Three row substack#

Before

\sum_{\substack{1\le i\le n\\ i\text{ odd}\\ i\ne 5}} a_i

After this rule

\sum_{\begin{subarray}{c}1\le i\le n\\ i\text{ odd}\\ i\ne 5\end{subarray}} a_i

Rendering verified with the declared packages.

Same family#

Disable this rule#

TransformEngine(profile="corpus", disable_rules=["ams/substack-expand"])
new TransformEngine({ profile: 'corpus', disableRules: ['ams/substack-expand'] })

Open in Playground