Difference between speed and velocity:

Image result for speed examples
Speed: The rate at which a moving body describes its path is called as speed or the rate of change of distance with respect to time is termed as speed.

E.g.If the length of the path followed by a moving body between two points ‘P’ and ‘Q’ is 20 km and the time taken to travel this path is 2 hrs, then the speed of the body is 20 km/2 hr = 10 km/hr. The path followed by the body may be curved or a straight line and its shape have no concern with the speed of the body.
Speed is purely a scalar quantity and hence it has magnitude only.

Velocity: The rate of change of displacement with respect to time is called as velocity.

E.g.; If ∆x represents the displacement of the body in time interval ∆t, then the velocity of the body is defined as
                           v = ∆x/∆t
In the limiting case when ∆t →0, v = Lim∆t→0 ∆x/∆t = dx/dt

Velocity is also expressed by both magnitude and direction just like displacement. Hence velocity is a vector quantity.

Relative velocity: How to find relative velocities in different cases:-


Relative velocity: The velocity of a body or with respect to another body is termed as relative velocity.

How to find relative velocities in different cases:

   Case 01. When two bodies are moving along a straight line in the same direction (say body ‘A’ and ‘B’), the magnitude of the relative velocity of body ‘A’ with respect to ‘B’ is just equal to the difference of the magnitudes of their velocities, i.e. magnitude of the velocity of body ‘A’ minus magnitude of velocity of body ‘B’.

                       Therefore,   vAB = vA – vB 

   Case 02. When two bodies are moving along a straight line in the opposite direction (say body ‘A’and ‘B’), the magnitude of the relative velocity of body ‘A’ with respect to ‘B’ is just equal to the sum of the magnitudes of their velocities.

                  Therefore,   vAB = vA + vB

   Case 03. Motion of a body on a body in the same direction: If a train is moving with velocity ‘v1’ and a man is running inside it in the same direction with a velocity ‘v2’, then,

           Relative velocity of man with respect to earth is = v1 + v2
      

    Case 04. Motion of a body on a body in the opposite direction: If a train is moving with velocity ‘v1’ and a man is running inside it in a direction opposite to that of train with a velocity ‘v2’, then,

                Relative velocity of man with respect to earth is = v1 v2