Solution: A and B are opposites, then
a+b=0,.....................( 1)
The AB distance is 6, then
b-a=6......................(2)
Solve (1)(2) simultaneously.
a=-3,b=3
2. It is known that the distance between the point M representing the number A and the point representing the number-1 on the number axis is 3, and the distance between the point N representing the number B and the point representing the number 2 is 4. Find the distance between m and n.
Solution: If the distance between the point M representing the number A and the point representing the number-1 on the number axis is 3, then
A=2 or -4
The distance between the point n representing the number B and the point representing the number 2 is 4, so
B=6 or -2
So the distance between m and n is 2 or 4 or 10.
(The last three values are because when a=2, the distance is 4; When a=-4, the distance is 10 or 2. )