Bones are made of calcium, the pads in the joints are made of vitamin C, and magnesium strengthens the muscles and relaxes the nerves. Deficiencies of those are rather common among Americans. For instance, a deficiency of magnesium causes bed wetting, and that is so common among young people that some people think it's just part of growing up. Study some books about nutrition so you know these things.
Doctors won't tell you because they have no such training. Some doctors object to that statement. They claim to be registered dietitians. They don't even know the difference. (A dietitian studies what you should swallow. A nutritionist studies what happens after you swallow it.)
1. Bones are NOT made of just calcium. The inorganic composition of bone (bone mineral) is primarily formed from salts of calcium and phosphate, the major salt being hydroxyapatite (Ca10(PO4)6(OH)2).[18] The exact composition of the matrix may change over time and with nutrition, with the ratio of calcium to phosphate varying between 1.3 and 2.0 (per weight), and trace minerals such as magnesium, sodium, potassium and carbonate also being found. 2. The intervertebral discs are NOT made of vitamin C. 3. noun: dietitian; plural noun: dietitians; noun: dietician; plural noun: dieticians an expert on diet AND nutrition.
The answer to your question is complicated, and I do not pretend to be an expert. I imagine it varies between individuals and any malfunctions your back may already have. I'm sure the type of mattress you use also has an effect. Consulting an orthopedist is your best bet. Don't listen to the guys on the mattress ads.
Actually sleeping on my back was the only way I COULD sleep when I suffered from sciatica, I strategically positioned pillows to help prevent rolling over in my sleep - any lateral curvature and I woke up in agony.
We don't end up with aches and pains because we don't normally sleep in one position for long. Unknown to us, the body moves about, rolls onto one side or the other, stretches limbs in different directions, every now and again when we are asleep, to relieve the stress on each area. A time-lapse video of someone fast asleep can be quite startling!