My favorites | Sign in
Project Logo
                
Search
for
Updated Jun 08, 2008 by brendanarnold
Labels: Featured
Overview  
Overview of python-xrd library

Introduction

A Python module that can be imported (import xrd) that contains various functions, constants and classes useful to x-ray diffraction (XRD) calculations

Details

Constants

COMMON_XRAY_WAVELENGTHS

A dictionary of common x-ray wavelengths in metres. Keys include

Functions

parse_miller_indices(

<iterable>
)

Pass in an iterable (incl. a string) of length 3 or 4. Tries to convert each index to an integer and returns a tuple h, k, l

Usage: parse_miller_indices(h,k,(j),l)

calc_volume_cubic(a=None)

Pass in a to get volume of unit cell

Usage: calc_volume_cubic(a)

calc_volume_tetragonal(a=None, c=None)

Pass in a, c to get volume of unit cell

Usage: calc_volume_tetragonal(a, c)

calc_volume_hexagonal(a=None, c=None)

Pass in a, c to get volume of unit cell

Usage: calc_volume_hexagonal(a, c)

calc_volume_rhombohedral(a=None, alpha=None)

Pass in a, alpha to get volume of unit cell

Usage: calc_volume_rhombohedral(a, alpha)

calc_volume_orthorhombic(a=None, b=None, c=None)

Pass in a, b, c to get volume of unit cell

Usage: calc_volume_orthorhombic(a, b, c)

calc_volume_monoclinic(a=None, b=None, c=None, beta=None)

Pass in a, b, c, beta to get volume of unit cell

Usage: calc_volume_monoclinic(a, b, c, beta)

calc_volume_triclinic(a=None, b=None, c=None, alpha=None, beta=None, gamma=None)

Pass in a, b, c, alpha, beta, gamma to get volume of unit cell

Usage: calc_volume_triclinic(a, b, c, alpha, beta, gamma)

calc_plane_spacing_cubic(p=None, a=None)

Pass in a plane h,k,l and a to get the plane spacing d

Usage: calc_plane_spacing_cubic(h,k,l, a)

calc_plane_spacing_tetragonal(p=None, a=None, c=None)

Pass in a plane h,k,l, a and c to get the plane spacing d

Usage: calc_plane_spacing_tetragonal(h,k,l, a, c)

calc_plane_spacing_hexagonal(p=None, a=None, c=None)

Pass in a plane h,k,l, a and c to get the plane spacing d

Usage: calc_plane_spacing_hexagonal(h,k,l, a, c)"""

calc_plane_spacing_rhombohedral(p=None, a=None, alpha=None)

Pass in a plane h,k,l, a and alpha to get the plane spacing d

Usage: calc_plane_spacing_rhombohedral(h,k,l, a, alpha)

calc_plane_spacing_orthorhombic(p=None, a=None, b=None, c=None)

Pass in a plane h,k,l, a, b and c to get the plane spacing d

Usage: calc_plane_spacing_orthorhombic(h,k,l, a, b, c)"""

calc_plane_spacing_monoclinic(p=None, a=None, b=None, c=None, beta=None)

Pass in a plane h,k,l, a, b, c and beta to get the plane spacing d

Usage: calc_plane_spacing_monoclinic(h,k,l, a, b, c, beta)"""

calc_plane_spacing_triclinic(p, a, b, c, alpha, beta, gamma)

Pass in a plane h,k,l, a, b, c, alpha, beta, gamma to get the plane spacing d

Usage: calc_plane_spacing_triclinic(h,k,l, a, b, c, alpha, beta, gamma)

calc_plane_angle_cubic(p1=None, p2=None)

Supply two sets of miller indices, calculates the angle in degrees between each

Usage: calc_plane_angle_cubic(h,k,l, h,k,l)

calc_plane_angle_tetragonal(p1=None, p2=None, a=None, c=None)

Supply two sets of miller indices, calculates the angle in degrees between each, as well as a and c magnitudes

Usage: calc_plane_angle_tetragonal(h,k,l, h,k,l, a, c)

calc_plane_angle_hexagonal(p1=None, p2=None, a=None, c=None)

Supply two sets of miller indices, calculates the angle in degrees between each, as well as a and c magnitudes

Usage: calc_plane_angle_hexagonal(h,k,l, h,k,l, a, c)

calc_plane_angle_rhombohedral(p1=None, p2=None, a=None, alpha=None)

Supply two sets of miller indices, a and alpha to calculate the angle in degrees between each

Usage: calc_plane_angle_rhombohedral(h,k,l, h,k,l, d1, d2, a, alpha)

calc_plane_angle_orthorhombic(p1=None, p2=None, a=None, b=None, c=None)

Supply two sets of miller indices, a, b and c to calculate the angle in degrees between each

Usage: calc_plane_angle_orthorhombic(h,k,l, h,k,l, a, b, c)

calc_plane_angle_monoclinic(p1=None, p2=None, a=None, b=None, c=None, beta=None)

Supply two sets of miller indices, a, b, c and beta to calculate the angle in degrees between each

Usage: calc_plane_angle_monoclinic(h,k,l, h,k,l, d1, d2, a, b, c, beta)

calc_plane_angle_triclinic(p1=None, p2=None, a=None, b=None, c=None, alpha=None, beta=None, gamma=None)

Supply two sets of miller indices, a, b, c, alpha, beta and gamma to calculate the angle in degrees between each

Usage: calc_plane_angle_triclinic(h,k,l, h,k,l, a, b, c, alpha, beta, gamma)

Classes

CubicLattice()

Create cubic lattice object, pass a on creating an instance

TetragonalLattice()

Create tetragonal lattice object, pass a and c on creating an instance

HexagonalLattice()

Create hexagonal lattice object, pass a and c on creating an instance

RhombohedralLattice()

Create rhombohedral lattice object, pass a and alpha on creating an instance

OrthorhombicLattice()

Create orthorhombic lattice object, pass a, b and c on creating an instance

MonoclinicLattice()

Create monoclinic lattice object, pass a, b, c and beta on creating an instance

TriclinicLattice()

Create triclinic lattice object, pass a, b, c, alpha, beta and gamma on creating an instance


Sign in to add a comment
Hosted by Google Code