gpt4 book ai didi

org.openscience.cdk.geometry.ZMatrixTools类的使用及代码示例

转载 作者:知者 更新时间:2024-03-20 19:16:31 26 4
gpt4 key购买 nike

本文整理了Java中org.openscience.cdk.geometry.ZMatrixTools类的一些代码示例,展示了ZMatrixTools类的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ZMatrixTools类的具体详情如下:
包路径:org.openscience.cdk.geometry.ZMatrixTools
类名称:ZMatrixTools

ZMatrixTools介绍

[英]A set of static utility classes for dealing with Z matrices.
[中]一组用于处理Z矩阵的静态实用程序类。

代码示例

代码示例来源:origin: cdk/cdk

Point3d[] cartCoords = ZMatrixTools.zmatrixToCartesian(d, d_atom, a, a_atom, da, da_atom);

代码示例来源:origin: cdk/cdk

n1.cross(cd, bc);
Vector3d n2 = rotate(n1, bc, -dihedrals[index]);
Vector3d ba = rotate(bc, n2, -angles[index]);

代码示例来源:origin: org.openscience.cdk/cdk-io

n1.cross(cd, bc);
Vector3d n2 = rotate(n1, bc, -dihedrals[index]);
Vector3d ba = rotate(bc, n2, -angles[index]);

代码示例来源:origin: cdk/cdk

@Test
public void testZmatrixToCartesian_arraydouble_arrayint_arraydouble_arrayint_arraydouble_arrayint() {
  // acetaldehyde example from http://www.shodor.org/chemviz/zmatrices/babelex.html
  int[] first_atoms = {0, 0, 0, 0, 3, 3, 3};
  double[] distances = {0, 1.2, 1.1, 1.5, 1.1, 1.1, 1.1};
  int[] second_atoms = {0, 0, 1, 1, 0, 0, 0};
  double[] angles = {0, 0, 120, 120, 110, 110, 110};
  int[] third_atoms = {0, 0, 0, 2, 1, 1, 1};
  double[] dihedrals = {0, 0, 0, 180, 0, 120, -120};
  Point3d points[] = ZMatrixTools.zmatrixToCartesian(distances, first_atoms, angles, second_atoms, dihedrals,
      third_atoms);
  Assert.assertEquals(-0.5500, points[2].x, 0.0001);
  Assert.assertEquals(-1.3664, points[5].y, 0.0001);
  Assert.assertEquals(-0.8952, points[6].z, 0.0001);
}

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com