Skip to content

Torsional Angle #226

@pratik-choudhari

Description

@pratik-choudhari

Feature ✅

Description

You are given four points A,B,C and D in a 3-dimensional Cartesian coordinate system. You are required to print the angle between the plane made by the points A,B,C and B,C,D in degrees(not radians). Let the angle be phi.

cos(phi) = (X.Y)/ |X||Y| where X = AB x BC and Y = BC x CD

Here, X.Y means the dot product of X and Y, AB x BC means the cross product of vectors AB and BC. Also, AB = B - A

Example

Input:
0 4 5
1 7 6
0 5 9
1 7 2

Output:
8.19

Contributors are supposed to mention their coding language while asking for assignment

Metadata

Metadata

Assignees

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions