3d geometry, matlab coding, I have to find relative angles of cation pi interactions, I have a biology background and am struggling with the arithmetic and mild coding for my project.
if have 2 points in a 3d space, T(xt,yt,zt) and L(xl,yl,zl), T also happens to be the centroid of a plane, i have 3 non collinear points vec1(x1y1z1), vec2(x2y2z2)and vec3(x2y3andz3) and i need to find the relative angle between T L and the Plane, how do I do it?
I tried
refVec = cross(vec2 - vec1, vec3 - vec1)
refVector = refVec / norm(refVec)
angleRad = acos(dot(refVector, L - T) / (norm(refVector) \* norm(L - T)));
is this fine? am i dumb? idk i got some angles but other angles were very wrong in some perspectives.
Join Matchmaticians Affiliate Marketing
Program to earn up to a 50% commission on every question that your affiliated users ask or answer.
- unanswered
- 374 views
- Pro Bono
Related Questions
- Diagonal and Similar Matrices
- Can a plane reflection in 3-space be written as the product of 3 line reflections?
- Question about interest earned
- Compute $\lim_{x \rightarrow 0} \frac{1-\arctan (\sin(x)+1)}{e^{x}-1}$
- Find $a,b,c$ so that $\begin{bmatrix} 0 & 1& 0 \\ 0 & 0 & 1\\ a & b & c \end{bmatrix} $ has the characteristic polynomial $-\lambda^3+4\lambda^2+5\lambda+6=0$
- Solve the Spherical Triangle
- Why if $\frac{opp}{adj} =x$, then $x \times hyp =$ The length of a line perpendicular to the hypotenuse with the same height.
- Find the derivative of the function $f(x)=\sqrt{\sin^2x+e^x+1}$
Questions at this level should be offered a bounty.