MCPで接続 →

計算を入力してください

公式

広告

結果

x = 2
y = 3
z = -1
クラメルの公式による
行列式
det(A) -1
det(Aₓ) -2
det(A_y) -3
det(A_z) 1

この計算機でできること

このツールは、3つの未知数(x, y, z)を含む3元連立一次方程式をクラメルの公式(行列式を用いた解法)で解きます。各方程式の係数を、次の標準形に合わせて入力してください。

\(a_1x + b_1y + c_1z = d_1\)
\(a_2x + b_2y + c_2z = d_2\)
\(a_3x + b_3y + c_3z = d_3\)

計算機は係数行列の行列式と、3つの変形行列式を求め、x・y・zの正確な値を返します。

使い方

各行に4つの数値を入力します。3つの係数(a, b, c)と、右辺の定数(d)です。負の数や小数も使用できます。結果パネルには解だけでなく、\(\det(A)\)、\(\det(A_x)\)、\(\det(A_y)\)、\(\det(A_z)\) も表示されるので、ご自身で計算過程を確認できます。

公式の解説

クラメルの公式によれば、行列式が0でない連立方程式 A·v = d において、各未知数は次のように求められます。係数行列Aの対応する列を定数ベクトルdに置き換えて行列式を計算し、それを \(\det(A)\) で割るのです。つまり \(x = \det(A_x)/\det(A)\) であり、y・z も同様に求めます。\(\det(A) = 0\) の場合は一意の解が存在せず、この公式は適用できません。

$$\begin{gathered} x = \frac{D_x}{D}, \quad y = \frac{D_y}{D}, \quad z = \frac{D_z}{D} \\[1.5em] \text{where}\quad \left\{ \begin{aligned} D &= \begin{vmatrix} a_1 & b_1 & c_1 \\ a_2 & b_2 & c_2 \\ a_3 & b_3 & c_3 \end{vmatrix} \\[0.4em] D_x &= \begin{vmatrix} d_1 & b_1 & c_1 \\ d_2 & b_2 & c_2 \\ d_3 & b_3 & c_3 \end{vmatrix} \\[0.4em] D_y &= \begin{vmatrix} a_1 & d_1 & c_1 \\ a_2 & d_2 & c_2 \\ a_3 & d_3 & c_3 \end{vmatrix} \\[0.4em] D_z &= \begin{vmatrix} a_1 & b_1 & d_1 \\ a_2 & b_2 & d_2 \\ a_3 & b_3 & d_3 \end{vmatrix} \end{aligned} \right. \end{gathered}$$
広告
Diagram showing Cramer's rule with matrix A and three modified matrices A1, A2, A3 where each column is replaced by the constants vector b
Cramer's Rule replaces one column of A with the constants vector b to form A1, A2, and A3.

計算例

次の連立方程式を解きます:\(2x + y - z = 8\)、\(-3x - y + 2z = -11\)、\(-2x + y + 2z = -3\)。

\(\det(A) = -1\)、\(\det(A_x) = -2\)、\(\det(A_y) = 3\)、\(\det(A_z) = -1\) となります。よって \(x = (-2)/(-1) = 2\)、\(y = 3\)、\(z = -1\) です。検算すると、$$2(2) + 3 - (-1) = 4 + 3 + 1 = 8 \checkmark$$ となり、確かに成り立ちます。

Three intersecting planes meeting at a single point in 3D space representing the unique solution of a 3x3 linear system
Each equation is a plane; their single common intersection point is the solution (x, y, z).

よくある質問

\(\det(A)\) が0のときは? その連立方程式は解を持たないか、無数の解を持ちます。クラメルの公式には0でない行列式が必要なため、計算機はこの場合を検知して知らせます。

小数や分数は使えますか? 小数はそのまま入力できます。分数の場合は、まず小数に変換してください(例:\(1/2 = 0.5\))。

クラメルの公式は効率的ですか? 3×3の連立方程式なら高速かつ正確です。ただし、もっと大規模な連立方程式では、一般にガウスの消去法が好まれます。

最終更新: