Question: Using matlab Problem 9 Write a Matlab function [n, epsilon] - R2quat(R) that converts a rotation matrix to a quaternion. The input should be a
Problem 9 Write a Matlab function [n, epsilon] - R2quat(R) that converts a rotation matrix to a quaternion. The input should be a 3x3 rotation matrix R. Outputs should be a scalar n and a vector epsilon. To check: verify that llln2 1 and rotation matrix R0.65 0.625 -0.433 results in 0.177 and n 0.884 0.75-0.433 0.5 0.306 0.125 0.65 0.75 0.306 Problem 10 Write a Matlab function H # rigidBodyTransform(Rd) that builds a homogeneous transformation matrix from a rotation and translation. Inputs should be a 3x3 rotation matrix R and 3x1 translation vector d. Output should be a 4x4 homogeneous transformation matrix. 0.75 -0.433 0.5 To check: verify that rotation matrix R 0.65 0.625-0.433and translation vector d 2 0.125 0.65 0.75 0.75-0.433 0.5 0.65 0.625 -0.433 2 esults in H0.125 0.65 0.75 3
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
