Note that the denominators are positive, so that the first solution is more adequate. If exemption is taken at x = B, then these two solutions degenerate into M

B and M