# Location of a point in 3D

#### joinforfun89

Hi,

Let's think about 4 points A,B,C,D.
I need to locate the points in 3D Cartesian coordinates provided the following parameters are given about the point:
1] Distance between A and B.
2] Distance between B and C
3] The angle between A B and C.
4] The angle between B C and D.
5] The torsion angle A-B-C-D.

I want to program this up so that in my simulation I can attach atoms to each other provided the bond-lengths, bond angles and torsion angles are specified. I need help with the math. We know that we must start by setting up the coordinate system. So for the first set of 4 atoms, we can place A at the origin, B along any of the coordinate axes and finally C in a chosen plane. But once we are through with the first set, what is a general formulation for the solution of the problem ?

Please let me know if you know of any books/articles which deal with similar issues.

#### HallsofIvy

Homework Helper
Hi,

Let's think about 4 points A,B,C,D.
I need to locate the points in 3D Cartesian coordinates provided the following parameters are given about the point:
1] Distance between A and B.
2] Distance between B and C
3] The angle between A B and C.
4] The angle between B C and D.
5] The torsion angle A-B-C-D.
I don't understand what you mean by these. Three points, A, B, and C, don't have a single angle. Assuming you meant the ray, AB, there still is no one angle between a line or ray and a point. Did you mean the angle between rays AB and AC? By "the torsion angle A-B-C-D" I think you mean "the angle around line AB that maps line AC onto AB" but I'm not sure of that.

I want to program this up so that in my simulation I can attach atoms to each other provided the bond-lengths, bond angles and torsion angles are specified. I need help with the math. We know that we must start by setting up the coordinate system. So for the first set of 4 atoms, we can place A at the origin, B along any of the coordinate axes and finally C in a chosen plane. But once we are through with the first set, what is a general formulation for the solution of the problem ?

Please let me know if you know of any books/articles which deal with similar issues.

#### joinforfun89

I don't understand what you mean by these. Three points, A, B, and C, don't have a single angle. Assuming you meant the ray, AB, there still is no one angle between a line or ray and a point. Did you mean the angle between rays AB and AC? By "the torsion angle A-B-C-D" I think you mean "the angle around line AB that maps line AC onto AB" but I'm not sure of that.
Yes I mean the ray AB and AC and the smaller angle that is made. The torsion angle can be thought of as the angle around line BC that maps line AB on to CD. In other words, the angle between the planes defined by points A,B,C and the plane defined by points B,C and D.

Thanks.

#### Tac-Tics

Distances between two points A and B can be found by taking the vector A - B and finding its length.

The smallest angle between two vectors can be found using using the dot product. Wiki it. It's a pretty straightforward formula.