Ejemplo n.º 1
0
 /// <summary>
 /// Calcula a lei dos cossenos em todos os planos
 /// </summary>
 /// <param name="subPose">SubPose que contém a posição dos joints</param>
 /// <returns>Retorna um objeto que contém o resultado do angulo em cada um dos planos 2D utilizando a lei dos cossenos</returns>
 internal static LawOfCosinesResult LawOfCosinesCalculation( SubPose subPose )
 {
     LawOfCosinesResult lawOfCosinesResult = new LawOfCosinesResult();
     lawOfCosinesResult.PlanXY = LawOfCosinesPlanCalculation( subPose.AuxiliaryJoint1.Position, subPose.CenterJoint.Position, subPose.AuxiliaryJoint2.Position, Axis.X, Axis.Y );
     lawOfCosinesResult.PlanXZ = LawOfCosinesPlanCalculation( subPose.AuxiliaryJoint1.Position, subPose.CenterJoint.Position, subPose.AuxiliaryJoint2.Position, Axis.X, Axis.Z );
     lawOfCosinesResult.PlanYZ = LawOfCosinesPlanCalculation( subPose.AuxiliaryJoint1.Position, subPose.CenterJoint.Position, subPose.AuxiliaryJoint2.Position, Axis.Y, Axis.Z );
     return lawOfCosinesResult;
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Constructor that initializes the result properties
 /// </summary>
 /// <param name="scalarProductResult">The result of Scalar Product calculation</param>
 /// <param name="lawOfCosinesResult">The result of Law of Cosines calculation in all plans</param>
 internal AngleCalculation( double scalarProductResult, LawOfCosinesResult lawOfCosinesResult )
 {
     this.LawOfCosinesResult = lawOfCosinesResult;
     this.ScalarProductResult = scalarProductResult;
 }