Corresponding measures have the same ratio.
.. (x -1)/4 = (2x +1)/10
.. 5(x -1) = 2(2x +1) . . . . . . multiply by 20
.. 5x -5 = 4x +2 . . . . . . . . eliminate parentheses
.. x = 7 . . . . . . . . . . . . . . . add 5 -4x
x = 7

as you notice above, is the first-row components from A, multiplying all the columns subsequently on B, and you add the products of that row, that gives you one component on the AB matrix
in the one above, we end up with a 2x3 AB matrix
substitution and elimination means that you need to use one equation and substitute it in place of some variable in the other equation.
Consider the above two equations.
Take equation 1, which is 4x-2y=22 => x=(22+2y)/4
substitute the x value gained above in equation 2.
so, 2((22+2y)/4)+4y=6
22+2y+8y=12 => 10y = -10 => y= -1.
Substitute y= -1 in x value obtained in the beginning.
So, x= (22 - 2)/4 => 5.
There fore, x= 5 and y= -1
Hope it helps.
To solve for the midpoint of the segment we use the equation that is given as:
(x1 + x2 / 2) , (y1 + y2 / 2)
For the points given,
(x1 + x2 / 2) , (y1 + y2 / 2)
(3+ 2 / 2) , (-5 + 9 / 2)
(5/2 , 2) or (2.5 , 2)
Hope this answers the question. Have a nice day. Feel free to ask more questions.