public class LocalPropertyDifferenceAttributeGenerator extends BaseAttributeGenerator
where \(f_n\) is the area of the face associated with neighbor n, \(p_{atom}\) the the elemental property of the central atom, and \(p_n\) is the elemental property of the neighbor atom.
For shells past the 1st nearest neighbor shell, the neighbors are identified by finding all of the unique faces on the outside of the polyhedron formed by the previous neighbor shell. This list of faces will faces corresponding to all of the atoms in the desired shell and the total weight for each atom is defined by the total area of the faces corresponding to that atom (there may be more than one).
By default, this class considers the only the 1st nearest neighbor shell.
This parameter is computed for all elemental properties stored in
CompositionDataset.ElementalProperties.
Usage: <shells...>
| Modifier and Type | Field and Description |
|---|---|
protected java.lang.String |
AttrDescription
Property description (used in description output)
|
protected java.lang.String |
AttrName
Property name
|
| Constructor and Description |
|---|
LocalPropertyDifferenceAttributeGenerator()
Create Default attribute generator.
|
LocalPropertyDifferenceAttributeGenerator(int... shells)
Create attribute generator that considers a certain list of shells.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addAttributes(Dataset data)
Generate new attributes for a dataset.
|
void |
addShell(int shell)
Add shell to list of used when computing attributes
|
void |
addShells(java.util.Collection<java.lang.Integer> shells)
Add several shells to list of used when computing attributes
|
void |
clearShells()
Clear list of shells to use when computing attributes
|
protected java.util.List<java.lang.String> |
createNames()
Create names for the attributes
|
protected double[] |
getAtomProperties(vassal.analysis.VoronoiCellBasedAnalysis voro,
org.apache.commons.lang3.tuple.Pair<int[][],double[][]> faceInfo,
double[] propValues)
Provided the Voronoi tessellation and properties of each atom type,
compute the properties of a certain neighbor cell for each atom.
|
java.lang.String |
printDescription(boolean htmlFormat)
Print out description of attributes.
|
java.lang.String |
printUsage()
Print out required format for options.
|
void |
setOptions(java.util.List<java.lang.Object> Options)
Set any options for this object.
|
runCommandprotected java.lang.String AttrName
protected java.lang.String AttrDescription
public LocalPropertyDifferenceAttributeGenerator()
public LocalPropertyDifferenceAttributeGenerator(int... shells)
shells - List of shells to be consideredpublic void setOptions(java.util.List<java.lang.Object> Options)
throws java.lang.Exception
OptionsOptions - Array of options as Objects - can be nulljava.lang.Exception - if problem with inputspublic void clearShells()
public final void addShell(int shell)
shell - Index of nearest neighbor shellpublic void addShells(java.util.Collection<java.lang.Integer> shells)
shells - Indices of nearest neighbor shellspublic java.lang.String printUsage()
Optionspublic void addAttributes(Dataset data) throws java.lang.Exception
BaseAttributeGeneratoraddAttributes in class BaseAttributeGeneratordata - Dataset to be added tojava.lang.ExceptionDataset.addAttribute(java.lang.String, double[])protected double[] getAtomProperties(vassal.analysis.VoronoiCellBasedAnalysis voro,
org.apache.commons.lang3.tuple.Pair<int[][],double[][]> faceInfo,
double[] propValues)
For LocalPropertyDifferenceAttributeGenerator, this produces the local property difference for each atom.
voro - Voronoi tessellationfaceInfo - Areas and types on outside of each face for desired shell. Computed
using VoronoiCellBasedAnalysis.getNeighborShellWeights(int)propValues - Properties of each atom typeprotected java.util.List<java.lang.String> createNames()
public java.lang.String printDescription(boolean htmlFormat)
BaseAttributeGeneratorImplementation Notes
Format should look like
[Full Name of generator]: (Number of attributes) Text description of what these attributes are
For HTML format, omit the ":".
printDescription in class BaseAttributeGeneratorhtmlFormat - Whether to print in HTML format