Both are components of skeletal tissue and magnesium is necessary for calciums absorption into the bones.