Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

inertia

Moment of Inertia of a Molecular System


Description

Computes the inertia tensor of a molecular system from atomic coordinates and masses.

Usage

inertia(...)

## S3 method for class 'coords'
inertia(x, m = NULL, ...)

## S3 method for class 'atoms'
inertia(x, m = NULL, ...)

## S3 method for class 'pdb'
inertia(x, m = NULL, ...)

Arguments

x

an R object containing atomic coordinates.

m

a numeric vector containing atomic masses.

...

further arguments passed to or from other methods.

Details

inertia is a generic function to compute the inertia tensor of a molecular system. For object of class ‘coords’ both atomic coordinates and masses have to be speifyed. For object of class ‘atoms’ the masses are determined from the elename component of the object (see toSymbols and masses). For object of class ‘pdb’ the atoms component is used.

Value

Return the inertia tensor in a 3x3 matrix.

See Also

Examples

C70 <- read.pdb(system.file("examples/C70.pdb",package="Rpdb"))
inertia(C70)
visualize(C70, mode = NULL)
viewXY()
viewInertia(C70)

Rpdb

Read, Write, Visualize and Manipulate PDB Files

v2.3
GPL
Authors
Julien Idé
Initial release
2014-02-25

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.