struct Chem::Dihedral

Overview

A Dihedral provides a canonical representation of a dihedral angle between four bonded atoms.

A dihedral angle is defined by three contiguous bonds:

A       C
  \   /   \
    B      D

It measures the angle between the two planes defined by the atoms (A,B,C) and (B,C,D).

Included Modules

Defined in:

chem/connectivity.cr

Constructors

Instance Method Summary

Instance methods inherited from module Chem::Connectivity({Chem::Atom, Chem::Atom, Chem::Atom, Chem::Atom})

<=>(rhs : self) : Int32 <=>, atoms : {Chem::Atom, Chem::Atom, Chem::Atom, Chem::Atom} atoms, includes?(atom : Atom) : Bool includes?, inspect(io : IO) : Nil inspect, measure : Float64 measure, to_s(io : IO) : Nil to_s

Constructor Detail

def self.new(a1 : Atom, a2 : Atom, a3 : Atom, a4 : Atom) #

Creates a new Dihedral with the given atoms.


[View source]

Instance Method Detail

def measure : Float64 #

Returns the current value of the dihedral angle in radians.


[View source]