Methods of diagnosis and treatment of sleep apnea by taking measurements from a subject suffering from sleep apnea are disclosed. The methods include modelling the air flow through the upper airway of a subject suffering from sleep apnea.