gov.nist.microanalysis.EPQLibrary
Class XRayTransitionSet

java.lang.Object
  extended by gov.nist.microanalysis.EPQLibrary.XRayTransitionSet
All Implemented Interfaces:
java.lang.Cloneable, java.lang.Comparable

public class XRayTransitionSet
extends java.lang.Object
implements java.lang.Comparable, java.lang.Cloneable

XRayTransitionSet represents a set of XRayTransition objects along with logic to assign the set a common shorthand name.


Field Summary
static java.lang.String ABSOLUTE
          Mode for getWeighiestTransitions
static java.lang.String[] allBasicTransitionSets
           
static java.lang.String COLLECTION
          An undefined collection of transitions associated with a specific element
static java.lang.String ELEMENT
          All transitions associated with a specified element
static java.lang.String EMPTY
          No transitions
static java.lang.String K_ALPHA
          The transitions often referred to as K alpha
static java.lang.String K_BETA
          The transitions often referred to as K beta
static java.lang.String K_FAMILY
          The transitions in the KFamily
static java.lang.String K_SHELL
          The transitions that end in the K-Shell
static java.lang.String L_ALPHA
          The transitions often referred to as L alpha
static java.lang.String L_BETA
          The transitions often referred to as L beta
static java.lang.String L_FAMILY
          The transitions in the LFamily
static java.lang.String L_GAMMA
          The transitions often referred to as L gamma
static java.lang.String L_OTHER
          The transitions in the L family that are not La, Lb or Lg
static java.lang.String LI_SHELL
          The transitions that end in the LI-Shell
static java.lang.String LII_SHELL
          The transitions that end in the LII-Shell
static java.lang.String LIII_SHELL
          The transitions that end in the LIII-Shell
static java.lang.String M_ALPHA
          The transitions often referred to as M alpha
static java.lang.String M_BETA
          The transitions often referred to as M beta
static java.lang.String M_FAMILY
          The transitions in the MFamily
static java.lang.String M_GAMMA
          The transitions often referred to as M gamma
static java.lang.String M_OTHER
          The transitions in the M family that are not Ma, Mb or Mg
static java.lang.String MI_SHELL
          The transitions that end in the MI-Shell
static java.lang.String MII_SHELL
          The transitions that end in the MII-Shell
static java.lang.String MIII_SHELL
          The transitions that end in the MIII-Shell
static java.lang.String MIV_SHELL
          The transitions that end in the MIV-Shell
static java.lang.String MV_SHELL
          The transitions that end in the MV-Shell
static java.lang.String N_FAMILY
          The transitions in the NFamily
static java.lang.String NIV_SHELL
          The transitions that end in the NIV-Shell
static java.lang.String NORMALIZED
          Mode for getWeighiestTransitions
static java.lang.String NV_SHELL
          The transitions that end in the NV-Shell
static java.lang.String TRANSITION
          A single transition
 
Constructor Summary
XRayTransitionSet()
           
XRayTransitionSet(AtomicShell shell)
          Constructs a XRayTransitionSet from an AtomicShell.
XRayTransitionSet(java.util.Collection c)
          Constructs a XRayTransitionSet by adding all the XRayTransition objects in the specified collection.
XRayTransitionSet(Element el)
          Constructs a XRayTransitionSet representing all of an Element's transitions.
XRayTransitionSet(Element el, double e0, double e1)
          Constructs a XRayTransitionSet consisting of all transitions for the specified element between the energy e0 and e1;
XRayTransitionSet(Element el, int family)
          Constructs a XRayTransitionSet from Element and transition family.
XRayTransitionSet(Element el, java.lang.String type)
           
XRayTransitionSet(XRayTransition xrt)
          Constructs a XRayTransitionSet from a single XRayTransition
 
Method Summary
 void add(XRayTransition xrt)
           
 void add(XRayTransitionSet xrts)
          combine - Add the specified XRayTransitionSet into this XRayTransitionSet.
 java.lang.Object clone()
           
 int compareTo(java.lang.Object obj)
           
 boolean contains(XRayTransition xrt)
          contains - Does this XRayTransitionSet contain the specified XRayTransition
 boolean equals(java.lang.Object obj)
           
static java.util.ArrayList getBasicFamilies(Element el, double eB)
          Returns an ArrayList of Strings containing all the transition sets that can be excited by an beam of the specified energy for the specified element.
 Element getElement()
          getElement - Returns the element with which this XRayTransition set is associated.
 java.lang.String getMode()
          getMode - Returns one of EMPTY, TRANSITION, ?_SHELL, ?_FAMILY, ELEMENT, or COLLECTION
 int getSize()
          getSize - The number of XRayTransition objects in the XRayTransitionSet
 java.util.Set getTransitions()
          getTransitions - Get an unmodifiable Set containing the XRayTransition objects represented by this object.
 XRayTransition getWeighiestTransition()
          getWeighiestTransition - Returns the single weightiest transition.
 XRayTransitionSet getWeightiestTransitions(double weight, java.lang.String mode)
          getWeightiestTransitions - Returns the transitions in the set with weight larger than the specified weight.
 int hashCode()
           
 java.util.Iterator iterator()
          iterator - Returns an Iterator to iterate through the XRayTransitions.
 XRayTransition maxEnergy()
          maxEnergy - Returns the transition with the maximum x-ray energy.
 XRayTransition minEnergy()
          minEnergy - Returns the transition with the minimum x-ray energy.
static XRayTransitionSet parseString(java.lang.String str)
          parseString - The inverse of toString.
 void remove(XRayTransition xrt)
          remove - Removes the specified transition from this XRayTransitionSet
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

TRANSITION

public static final java.lang.String TRANSITION
A single transition

See Also:
Constant Field Values

ELEMENT

public static final java.lang.String ELEMENT
All transitions associated with a specified element

See Also:
Constant Field Values

COLLECTION

public static final java.lang.String COLLECTION
An undefined collection of transitions associated with a specific element

See Also:
Constant Field Values

EMPTY

public static final java.lang.String EMPTY
No transitions

See Also:
Constant Field Values

K_ALPHA

public static final java.lang.String K_ALPHA
The transitions often referred to as K alpha

See Also:
Constant Field Values

K_BETA

public static final java.lang.String K_BETA
The transitions often referred to as K beta

See Also:
Constant Field Values

L_ALPHA

public static final java.lang.String L_ALPHA
The transitions often referred to as L alpha

See Also:
Constant Field Values

L_BETA

public static final java.lang.String L_BETA
The transitions often referred to as L beta

See Also:
Constant Field Values

L_GAMMA

public static final java.lang.String L_GAMMA
The transitions often referred to as L gamma

See Also:
Constant Field Values

L_OTHER

public static final java.lang.String L_OTHER
The transitions in the L family that are not La, Lb or Lg

See Also:
Constant Field Values

M_ALPHA

public static final java.lang.String M_ALPHA
The transitions often referred to as M alpha

See Also:
Constant Field Values

M_BETA

public static final java.lang.String M_BETA
The transitions often referred to as M beta

See Also:
Constant Field Values

M_GAMMA

public static final java.lang.String M_GAMMA
The transitions often referred to as M gamma

See Also:
Constant Field Values

M_OTHER

public static final java.lang.String M_OTHER
The transitions in the M family that are not Ma, Mb or Mg

See Also:
Constant Field Values

K_FAMILY

public static final java.lang.String K_FAMILY
The transitions in the KFamily

See Also:
Constant Field Values

L_FAMILY

public static final java.lang.String L_FAMILY
The transitions in the LFamily

See Also:
Constant Field Values

M_FAMILY

public static final java.lang.String M_FAMILY
The transitions in the MFamily

See Also:
Constant Field Values

N_FAMILY

public static final java.lang.String N_FAMILY
The transitions in the NFamily

See Also:
Constant Field Values

K_SHELL

public static final java.lang.String K_SHELL
The transitions that end in the K-Shell

See Also:
Constant Field Values

LI_SHELL

public static final java.lang.String LI_SHELL
The transitions that end in the LI-Shell

See Also:
Constant Field Values

LII_SHELL

public static final java.lang.String LII_SHELL
The transitions that end in the LII-Shell

See Also:
Constant Field Values

LIII_SHELL

public static final java.lang.String LIII_SHELL
The transitions that end in the LIII-Shell

See Also:
Constant Field Values

MI_SHELL

public static final java.lang.String MI_SHELL
The transitions that end in the MI-Shell

See Also:
Constant Field Values

MII_SHELL

public static final java.lang.String MII_SHELL
The transitions that end in the MII-Shell

See Also:
Constant Field Values

MIII_SHELL

public static final java.lang.String MIII_SHELL
The transitions that end in the MIII-Shell

See Also:
Constant Field Values

MIV_SHELL

public static final java.lang.String MIV_SHELL
The transitions that end in the MIV-Shell

See Also:
Constant Field Values

MV_SHELL

public static final java.lang.String MV_SHELL
The transitions that end in the MV-Shell

See Also:
Constant Field Values

NIV_SHELL

public static final java.lang.String NIV_SHELL
The transitions that end in the NIV-Shell

See Also:
Constant Field Values

NV_SHELL

public static final java.lang.String NV_SHELL
The transitions that end in the NV-Shell

See Also:
Constant Field Values

NORMALIZED

public static final java.lang.String NORMALIZED
Mode for getWeighiestTransitions

See Also:
Constant Field Values

ABSOLUTE

public static final java.lang.String ABSOLUTE
Mode for getWeighiestTransitions

See Also:
Constant Field Values

allBasicTransitionSets

public static final java.lang.String[] allBasicTransitionSets
Constructor Detail

XRayTransitionSet

public XRayTransitionSet(Element el,
                         double e0,
                         double e1)
Constructs a XRayTransitionSet consisting of all transitions for the specified element between the energy e0 and e1;

Parameters:
el - The element
e0 - The lower energy bound
e1 - The upper energy bound

XRayTransitionSet

public XRayTransitionSet(Element el,
                         java.lang.String type)

XRayTransitionSet

public XRayTransitionSet(java.util.Collection c)
Constructs a XRayTransitionSet by adding all the XRayTransition objects in the specified collection. They must all be from the same element.

Parameters:
c -

XRayTransitionSet

public XRayTransitionSet(AtomicShell shell)
Constructs a XRayTransitionSet from an AtomicShell. (All transitions into the specified shell.)


XRayTransitionSet

public XRayTransitionSet(Element el,
                         int family)
Constructs a XRayTransitionSet from Element and transition family. (All transitions in the specified family)


XRayTransitionSet

public XRayTransitionSet(XRayTransition xrt)
Constructs a XRayTransitionSet from a single XRayTransition


XRayTransitionSet

public XRayTransitionSet(Element el)
Constructs a XRayTransitionSet representing all of an Element's transitions.


XRayTransitionSet

public XRayTransitionSet()
Method Detail

clone

public java.lang.Object clone()
Overrides:
clone in class java.lang.Object

add

public void add(XRayTransition xrt)

remove

public void remove(XRayTransition xrt)
remove - Removes the specified transition from this XRayTransitionSet

Parameters:
xrt -

add

public void add(XRayTransitionSet xrts)
combine - Add the specified XRayTransitionSet into this XRayTransitionSet.

Parameters:
xrts -

contains

public boolean contains(XRayTransition xrt)
contains - Does this XRayTransitionSet contain the specified XRayTransition

Parameters:
xrt -
Returns:
boolean

getSize

public int getSize()
getSize - The number of XRayTransition objects in the XRayTransitionSet

Returns:
int

getElement

public Element getElement()
getElement - Returns the element with which this XRayTransition set is associated.


toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

parseString

public static XRayTransitionSet parseString(java.lang.String str)
parseString - The inverse of toString.

Parameters:
str -
Returns:
An XRayTransitionSet representing the contents of str

getMode

public java.lang.String getMode()
getMode - Returns one of EMPTY, TRANSITION, ?_SHELL, ?_FAMILY, ELEMENT, or COLLECTION

Returns:
String

getTransitions

public java.util.Set getTransitions()
getTransitions - Get an unmodifiable Set containing the XRayTransition objects represented by this object.

Returns:
An unmodifiable Set of XRayTransition objects

minEnergy

public XRayTransition minEnergy()
minEnergy - Returns the transition with the minimum x-ray energy.

Returns:
XRayTransition

maxEnergy

public XRayTransition maxEnergy()
maxEnergy - Returns the transition with the maximum x-ray energy.

Returns:
XRayTransition

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object

compareTo

public int compareTo(java.lang.Object obj)
Specified by:
compareTo in interface java.lang.Comparable

iterator

public java.util.Iterator iterator()
iterator - Returns an Iterator to iterate through the XRayTransitions.

Returns:
Iterator

getWeightiestTransitions

public XRayTransitionSet getWeightiestTransitions(double weight,
                                                  java.lang.String mode)
getWeightiestTransitions - Returns the transitions in the set with weight larger than the specified weight. The mode determines whether the weights are normalized by the weightiest transition in the set (mode==NORMALIZED) or not (mode==ABSOLUTE).

Parameters:
weight - In [0.0,1.0] (0.0->All, 1.0 & NORMALIZED -> Weightiest)
mode - One of NORMALIZED or ABSOLUTE
Returns:
XRayTransitionSet

getWeighiestTransition

public XRayTransition getWeighiestTransition()
getWeighiestTransition - Returns the single weightiest transition.

Returns:
XRayTransition

getBasicFamilies

public static java.util.ArrayList getBasicFamilies(Element el,
                                                   double eB)
Returns an ArrayList of Strings containing all the transition sets that can be excited by an beam of the specified energy for the specified element.

Parameters:
el - An element
eB - The incident beam energy
Returns:
ArrayList A list of String objects such as K_ALPHA, K_BETA, ..., M_FAMILY