Thanks buddy for your advise, i will give a try.
I can't second guess a doctor, but if you have (painful?) cough when you yawn I say "don't yawn". Yawning is to my mind a voluntary action, that is I know I am going to yawn and usually let or encourage it happening.
Yawning can be a response to a need for more oxygen. Did you doctor(s) measure you blood oxygen saturation level? This is normal test whenever I see a doctor, along with taking my body weight, heart rate, blood pressure, guess that's about it.
I own a personal oxyimeter so I can quickly measure my Oxygen Saturation level and HR - this led me to suspect I might suffer from sleep apnea and I took a at-home test with a doctor prescribed recording Oximeter and it showed I had unacceptable low levels of oxygen during brief periods of the sleep period... an indication of sleep apnea, which was confirmed by additional tests.
I'm not try to say you have sleep apnea, seems you yawn at various time during your awake period, still I think it worth a check to see if you have good oxygen saturation levels, 95% an higher are the guidelines in the USA.