org.openscience.cdk.geometry

## Class ZMatrixTools

• ```public class ZMatrixTools
extends Object```
A set of static utility classes for dealing with Z matrices.
Source code:
master
Belongs to CDK module:
io
Keywords:
Z-matrix
Created on:
2004-02-09
• ### Constructor Summary

Constructors
Constructor and Description
`ZMatrixTools()`
• ### Method Summary

Methods
Modifier and Type Method and Description
`static javax.vecmath.Point3d[]` ```zmatrixToCartesian(double[] distances, int[] first_atoms, double[] angles, int[] second_atoms, double[] dihedrals, int[] third_atoms)```
Takes the given Z Matrix coordinates and converts them to cartesian coordinates.
• ### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`
• ### Constructor Detail

• #### ZMatrixTools

`public ZMatrixTools()`
• ### Method Detail

• #### zmatrixToCartesian

```public static javax.vecmath.Point3d[] zmatrixToCartesian(double[] distances,
int[] first_atoms,
double[] angles,
int[] second_atoms,
double[] dihedrals,
int[] third_atoms)```
Takes the given Z Matrix coordinates and converts them to cartesian coordinates. The first Atom end up in the origin, the second on on the x axis, and the third one in the XY plane. The rest is added by applying the Zmatrix distances, angles and dihedrals. Angles are in degrees.
Parameters:
`distances` - Array of distance variables of the Z matrix
`angles` - Array of angle variables of the Z matrix
`dihedrals` - Array of distance variables of the Z matrix
`first_atoms` - Array of atom ids of the first invoked atom in distance, angle and dihedral
`second_atoms` - Array of atom ids of the second invoked atom in angle and dihedral
`third_atoms` - Array of atom ids of the third invoked atom in dihedral
Dictionary pointer(s):
zmatrixCoordinatesIntoCartesianCoordinates in the Blue Obelisk Chemoinformatics Dictionary [blue-obelisk:zmatrixCoordinatesIntoCartesianCoordinates]