See here, I have taken an, this equation of motion I have taken, where the body system is having its axis at centre of gravity, but sometime supposing it is having an axis which is a some other location a o o here, so that the centre of gravity is the coordinates are x G