When you are in a chair or on a desk try to keep your leg in figure of 4 position alternatively. Take short breaks in between long duration of sitting. Make a habit to stretch regularly.