필터 지우기
필터 지우기

Finding the twist angle of a Vector around axis Z

조회 수: 6 (최근 30일)
farzad
farzad 2018년 7월 30일
댓글: Jan 2018년 7월 30일
Hi all
I have the positions of a vector F as a function of time, and I need to find the twist around axis Z, so I need to project it on XY plane and then find the angle with one of X or Y axis.
I know how to do the 2nd part , but I have problem with the first part. I am not sure the quiver() will give me the right result.
Also, as an Idea, could I use the gradients of the vector F along X and Y and divide them on eachother to find the angle with X or Y ?
  댓글 수: 5
farzad
farzad 2018년 7월 30일
Dear Jan
Sorry , My concern was about a problem that the question is not viewed in question feed.
I can't provide the inputs now , but I used this line, looping over the rows of the vector matrix :
Tors(n,1) = atan2(norm(cross(u2d(n,:),X2D)), dot(u2d(n,:),X2D))*180/pi;
I got
??? Error using ==> cross at 37
A and B must have at least one dimension of length 3.
Jan
Jan 2018년 7월 30일
The message is clear. Check the dimensions of the inputs of the cross command. Again:
Please provide what you have as inputs.
Posting the complete code is a good idea also.

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

Help CenterFile Exchange에서 2-D and 3-D Plots에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by