Bed distance from the low wall
Head of the bed
At the low (sloping) side
At the high side
Low wall height
Ceiling rise per metre
Top of the mattress from floor
Sitting height above mattress
Gap above your head, sitting up
Ceiling above the low end of the bed
A 200 cm long bed, drawn side-on. The ceiling stops rising at 260 cm. The person sits about 20 cm away from the headboard, leaning on pillows. A comfort margin of about 10 cm is my rule of thumb, not a standard.