矩阵与多行公式测试


矩阵与多行公式渲染测试

矩阵测试

基本矩阵 (使用 bmatrix)

A=[a11a12a13a21a22a23a31a32a33]A = \begin{bmatrix} a_{11} & a_{12} & a_{13} \\ a_{21} & a_{22} & a_{23} \\ a_{31} & a_{32} & a_{33} \end{bmatrix}

带括号的矩阵 (使用 pmatrix)

B=(xyzuvw)B = \begin{pmatrix} x & y & z \\ u & v & w \end{pmatrix}

带方括号的矩阵 (使用 vmatrix)

det(C)=abcd=adbc\det(C) = \begin{vmatrix} a & b \\ c & d \end{vmatrix} = ad - bc

带花括号的矩阵 (使用 Bmatrix)

D={123456789}D = \begin{Bmatrix} 1 & 2 & 3 \\ 4 & 5 & 6 \\ 7 & 8 & 9 \end{Bmatrix}

宽矩阵 (测试换行)

W=[w11w12w13w14w15w16w17w18w21w22w23w24w25w26w27w28]W = \begin{bmatrix} w_{11} & w_{12} & w_{13} & w_{14} & w_{15} & w_{16} & w_{17} & w_{18} \\ w_{21} & w_{22} & w_{23} & w_{24} & w_{25} & w_{26} & w_{27} & w_{28} \\ \end{bmatrix}

多行公式测试

对齐的多行等式 (使用 align)

\begin{align} f(x) &= (a+b)^2 \\ &= a^2 + 2ab + b^2 \\ &= \sum_{i=0}^{n} \binom{n}{i} a^{n-i} b^i \end{align}

多行但不进行编号 (使用 align*)

\begin{align*} \frac{\partial f}{\partial x} &= 2x + y \\ \frac{\partial f}{\partial y} &= x + 2y + z \\ \frac{\partial f}{\partial z} &= y + 2z \end{align*}

使用 cases 环境的分段函数

f(x)={x2,if x0x2,if x<0x3+2x25x+3x+1,otherwisef(x) = \begin{cases} x^2, & \text{if } x \geq 0 \\ -x^2, & \text{if } x < 0 \\ \frac{x^3 + 2x^2 - 5x + 3}{x+1}, & \text{otherwise} \end{cases}

复杂表达式 (换行测试)

S=i=1nj=1nk=1nl=1nm=1nai,j,k,l,mxiyjzkwlvm=000f(x,y,z)dxdydz\begin{aligned} S &= \sum_{i=1}^{n} \sum_{j=1}^{n} \sum_{k=1}^{n} \sum_{l=1}^{n} \sum_{m=1}^{n} a_{i,j,k,l,m} \cdot x_i \cdot y_j \cdot z_k \cdot w_l \cdot v_m \\ &= \int_{0}^{\infty} \int_{0}^{\infty} \int_{0}^{\infty} f(x,y,z) \, dx \, dy \, dz \end{aligned}

系统方程组

{3x+5y+z=07x2y+4z=06x+3y+2z=0\begin{cases} 3x + 5y + z = 0 \\ 7x - 2y + 4z = 0 \\ -6x + 3y + 2z = 0 \end{cases}

带标号的公式

\begin{aligned} E &= mc^2 \tag{1} \\ F &= ma \tag{2} \\ PV &= nRT \tag{3} \end{aligned}

如果公式仍然存在渲染问题,建议检查渲染后页面的HTML结构,确认MathJax是否完全加载。


文章作者: MIKA
版权声明: 本博客所有文章除特別声明外,均采用 CC BY 4.0 许可协议。转载请注明来源 MIKA !
  目录