plus( X_TERM, A+Y, B+Z, C ) = plus( D+Y, E+Z, F )
Solve for X.
ANSWER( D-A, E-B, F-C, G )
ANSWER( D+A, E-B, F-C, G )ANSWER( D-A, E+B, F-C, G )ANSWER( D-A, E-B, F+C, G )ANSWER( D+A, E+B, F-C, G )ANSWER( D+A, E-B, F+C, G )ANSWER( D-A, E+B, F+C, G )ANSWER( D+A, E+B, F+C, G )Combine constant terms on the right.
plus( X_TERM, A+Y, B+Z, color_( C, true ) ) = plus( D+Y, E+Z, color_( F, true ) )
plus( X_TERM, A+Y, B+Z ) = plus( D+Y, E+Z, color_( F-C, true ) )
Combine Z terms on the right.
plus( X_TERM, A+Y, color_( B+Z, false ) ) = plus( D+Y, color_( E+Z, false ), F-C )
plus( X_TERM, A+Y ) = plus( D+Y, color_( (E-B)+Z, false ), F-C )
Combine Y terms on the right.
plus( X_TERM, color_( A+Y, true ) ) = plus( color_( D+Y, true ), (E-B)+Z, F-C )
plus( X_TERM ) = plus( color_( (D-A)+Y, true ), (E-B)+Z, F-C )
Isolate X.
plus( color_( G, false ) + X + color_( X_EXTRAS, false ) ) = plus( (D-A)+Y, (E-B)+Z, F-C )
X = \dfrac{ plus( (D-A)+Y, (E-B)+Z, F-C ) }{ plus( color_( G + X_EXTRAS, false ) ) }
All of these terms are divisible by GCD.
Divide by the common factor and swap signs so the denominator isn't negative.
Divide by the common factor.
Swap the signs so the denominator isn't negative.
X = \dfrac{ plus( color_( round( DIVISOR*(D-A) ), true )+Y, color_( round( DIVISOR*(E-B) ), true )+Z, color_( round( DIVISOR*(F-C) ), true ) ) }{ plus( color_( round( DIVISOR*G )+X_EXTRAS, true ) ) }
plus( A+X+Y, B+X+Z, C+X, D ) = plus( E+Y, F )
Solve for X.
ANSWER( E, F-D, A, B, C )
ANSWER( E, F+D, A, B, C )ANSWER( 0, F-D, A, B, C )ANSWER( E, 0, A, B, C )ANSWER( E, F-D, 0, B, C )ANSWER( E, F-D, A, 0, C )ANSWER( E, F-D, A, B, 0 )ANSWER( E+A, F-D, A, B, C )ANSWER( E-A, F-D, A, B, C )ANSWER( E, F-D, A+B, B, C )ANSWER( E, F-D, A-B, B, C )ANSWER( E, F-D, A, A+B, C )ANSWER( E, F-D, A, A-B, C )ANSWER( E, F-D, A, B, A+C )ANSWER( E, F-D, A, B, A-C )Combine constant terms on the right.
plus( A+X+Y, B+X+Z, C+X, color_( D, true ) ) = plus( E+Y, color_( F, true ) )
plus( A+X+Y, B+X+Z, C+X ) = plus( E+Y, color_( F-D, true ) )
Notice that all the terms on the left-hand side of the equation have X in them.
plus( A+color_( X, false )+Y, B+color_( X, false )+Z, C+color_( X, false ) ) = plus( E+Y, F-D )
Factor out the X.
color_( X, false ) \cdot \left( plus( A+Y, B+Z, C ) \right) = plus( E+Y, F-D )
Isolate the X.
X \cdot \left( color_( plus( A+Y, B+Z, C ), true ) \right) = plus( E+Y, F-D )
X = \dfrac{ plus( E+Y, F-D ) }{ color_( plus( A+Y, B+Z, C ), true ) }
We can simplify this by multiplying the top and bottom by -1.
ANSWER( E, F-D, A, B, C )
\dfrac{ plus( A+X, B+Y ) }{ C } = \dfrac{ plus( D+X, E+Z ) }{ F }
Solve for X.
ANSWER( E_TERM, -B_TERM, A_TERM-D_TERM )
ANSWER( E_TERM, B_TERM, A_TERM-D_TERM )ANSWER( -E_TERM, -B_TERM, A_TERM-D_TERM )ANSWER( -E_TERM, B_TERM, A_TERM-D_TERM )ANSWER( E_TERM, -B_TERM, A_TERM+D_TERM )ANSWER( E_TERM, B_TERM, A_TERM+D_TERM )ANSWER( -E_TERM, -B_TERM, A_TERM+D_TERM )ANSWER( -E_TERM, B_TERM, A_TERM+D_TERM )ANSWER( E_TERM, -B_TERM, -A_TERM-D_TERM )ANSWER( E_TERM, B_TERM, -A_TERM-D_TERM )ANSWER( -E_TERM, B_TERM, -A_TERM-D_TERM )ANSWER( -E_TERM, -B_TERM, -A_TERM-D_TERM )Notice that the left- and right- denominators are the sameopposite.
\dfrac{ plus( A+X, B+Y ) }{ color_( C, true ) } = \dfrac{ plus( D+X, E+Z ) }{ color_( F, true ) }
So we can multiply both sides by C.
color_( C, true ) \cdot \dfrac{ plus( A+X, B+Y ) }{ color_( C, true ) } = color_( C, true ) \cdot \dfrac{ plus( D+X, E+Z ) }{ color_( F, true ) }
plus( A+X, B+Y ) =
plus( D+X, E+Z )
color_( "-", true ) \cdot \left( plus( D+X, E+Z ) \right)
Distribute the negative sign on the right side.
plus( A+X, B+Y ) = plus( D_TERM+X, E_TERM+Z )
plus( color_( A_TERM, true )+X, color_( B_TERM, true )+Y ) = plus( color_( D_TERM, true )+X, color_( E_TERM, true )+Z )
Multiply both sides by the left denominator.
\dfrac{ plus( A+X, B+Y ) }{ color_( C, true ) } = \dfrac{ plus( D+X, E+Z ) }{ F }
color_( C, true ) \cdot \dfrac{ plus( A+X, B+Y ) }{ color_( C, true ) } = color_( C, true ) \cdot \dfrac{ plus( D+X, E+Z ) }{ F }
plus( A+X, B+Y ) = color_( C, true ) \cdot \dfrac { plus( D+X, E+Z ) }{ F }
Reduce the right side.
plus( A+X, B+Y ) = color_( C, false ) \cdot \dfrac{ plus( D+X, E+Z ) }{ color_( F, false ) }
plus( A+X, B+Y ) = color_( C / F, false ) \cdot \left( plus( D+X, E+Z ) \right)
Multiply both sides by the right denominator.
plus( A+X, B+Y ) = C \cdot \dfrac{ plus( D+X, E+Z ) }{ color_( F, false ) }
color_( F, false ) \cdot \left( plus( A+X, B+Y ) \right) = color_( F, false ) \cdot C \cdot \dfrac{ plus( D+X, E+Z ) }{ color_( F, false ) }
color_( F, false ) \cdot \left( plus( A+X, B+Y ) \right) = C \cdot \left( plus( D+X, E+Z ) \right)
Distribute the right sideboth sides.
plus( A+X, B+Y ) = color_( C / F, true ) \cdot \left( plus( color_( D+X, true ), color_( E+Z, true ) ) \right)
color_( F, true ) \cdot \left( plus( A+X, B+Y ) \right) = color_( C, true ) \cdot \left( plus( D+X, E+Z ) \right)
plus( A_TERM+X, B_TERM+Y ) = plus( color_( D_TERM, true )+X, color_( E_TERM, true )+Z )
plus( color_( A_TERM, true )+X, color_( B_TERM, true )+Y ) = plus( color_( D_TERM, true )+X, color_( E_TERM, true )+Z )
Combine X terms on the left.
plus( color_( A_TERM+X, false ), B_TERM+Y ) = plus( color_( D_TERM+X, false ), E_TERM+Z )
plus( color_( (A_TERM-D_TERM)+X, false ), (B_TERM)+Y ) = (E_TERM)+Z
Move the Y term to the right.
plus( (A_TERM-D_TERM)+X, color_( B_TERM+Y, true ) ) = E_TERM+Z
(A_TERM-D_TERM)+X = plus( E_TERM+Z, color_( (-B_TERM)+Y, true ) )
Isolate X by dividing both sides by its coefficient.
color_( A_TERM-D_TERM, false )+X = plus( E_TERM+Z, (-B_TERM)+Y )
X = \dfrac{ plus( E_TERM+Z, (-B_TERM)+Y ) }{ color_( A_TERM-D_TERM, false ) }
All of these terms are divisible by GCD.
Divide by the common factor and swap signs so the denominator isn't negative.
Divide by the common factor.
Swap signs so the denominator isn't negative.
X = \dfrac{ plus( color_( round( E_TERM*DIVISOR ), true )+Z, color_( round( -B_TERM*DIVISOR ), true )+Y ) }{ color_( round( (A_TERM-D_TERM)*DIVISOR ), true ) }