Computer-aided analysis of rigid and flexible multibody systems