A technique for calculating in vivo ligament lengths with application to the human knee joint