calc_rot {AvInertia}R Documentation

A 3x3 rotation matrix constructed by projecting the new axes onto the original system. Likely results in rotation about all axes.

Description

A 3x3 rotation matrix constructed by projecting the new axes onto the original system. Likely results in rotation about all axes.

Usage

calc_rot(z_vector, x_vector)

Arguments

z_vector

a 1x3 vector representing the direction for the desired z axis of the new frame of reference. Frame of reference: VRP

x_vector

a 1x3 vector representing the direction for the desired x axis of the new frame of reference. Frame of reference: VRP

Value

a 3x3 matrix representing the rotation matrix that transforms between VRP frame and object frame

Author(s)

Christina Harvey

Examples

library(AvInertia)
z_vector = c(0,0,1)
x_vector = c(-1,0,0)

# should return matrix [[-1,0,0];[0,-1,0];[0,0,1]]
calc_rot(z_vector, x_vector)


[Package AvInertia version 0.0.1 Index]