Body must be saying that it needs some physical activity or it cannot keep alertness with current level of physical activity. It might also be communicating to others that some physical activity at this point may be good. Others concur by yawning back. Wow! what a subconscious communication.
The action happening at yawning is effectively a deep breath - which is simulating the result of physical activity without actually moving your body.
Only this can explain:
Why we yawn when:
- bored sitting in place for long time
Olympic athletes usually seen yawning before the competition.
We don't yawn at:
- extremely tired after a long run
Also, why is yawning is contagious to others, while hiccups are not.