Class TableRow
java.lang.Object
_global.tri.oxidationstates.webapi.TableRow
- All Implemented Interfaces:
Comparable<TableRow>
This class contains the data in a single row of the table on the web app
-
Constructor Summary
ConstructorsConstructorDescriptionTableRow(LikelihoodCalculator calculator, LikelihoodStateSet stateSet, double gii) Constructs a row based on an OxidationStateSet (calculated by the oxidation state tool we've developed) and the global instability index (gii). -
Method Summary
Modifier and TypeMethodDescriptionintdouble[][]Returns the minimum and maximum boundaries for each ion in this row.Returns a string representation of a CIF file with all oxidation states assigned, or null if no such file could be generated.double[]Returns an array of values indicating the count of each ion in a formula unit for the given material.doubleReturns the global instability index (gii) for the given set of oxidation states applied to a particular structure.doubleReturns the likelihood at the optimal electronic chemical potential for the given set of oxidation states.doubleReturns the value of the mapped potential that maximizes the likelihood of the set of oxidation states coexisting.int[]Returns the oxidation states for each ion in the material.String[]Returns the symbols for each ion in the material.booleanReturns true if the generated oxidation states are "mixed valence", meaning the same element (or polyatomic ion type) is associated with more than one oxidation state.protected voidsetCIFString(String cifString) Sets an optional string representation of a CIF file with all oxidation states assigned.toString()
-
Constructor Details
-
TableRow
Constructs a row based on an OxidationStateSet (calculated by the oxidation state tool we've developed) and the global instability index (gii).- Parameters:
calculator- The Likelihood calculator used to generate the oxidation states. The oxidation state range boundaries will be read from this calculator.stateSet- A class containing information about a particular set of oxidation states.gii- The global instability index.
-
-
Method Details
-
getCounts
public double[] getCounts()Returns an array of values indicating the count of each ion in a formula unit for the given material. Each element in the array corresponds to an ion for which we have calculated oxidation states. The indices in this array match the indices in the arrays returned by thegetOxidationStates()andgetSymbols()methods.- Returns:
- An array of values indicating the count of each ion in a formula unit for the
given material. Each element in the array corresponds to an ion for which we have
calculated oxidation states. The indices in this array match the indices in the arrays returned by the
getOxidationStates()andgetSymbols()methods.
-
getSymbols
Returns the symbols for each ion in the material. Oxidation states are not included in these symbols. The indices in this array match the indices in the arrays returned by thegetCounts()andgetOxidationStates()methods.- Returns:
- the symbols for each ion in the material. Oxidation states are not included in
these symbols. The indices in this array match the indices in the arrays returned by the
getCounts()andgetOxidationStates()methods.
-
getOxidationStates
public int[] getOxidationStates()Returns the oxidation states for each ion in the material. The indices in this array match the indices in the arrays returned by thegetCounts()andgetSymbols()methods.- Returns:
- the oxidation states for each ion in the material. The indices in this array match the indices in the arrays returned by the
getCounts()andgetSymbols()methods.
-
getOptimalLikelihood
public double getOptimalLikelihood()Returns the likelihood at the optimal electronic chemical potential for the given set of oxidation states.- Returns:
- the likelihood at the optimal electronic chemcial potential for the given set of oxidation states.
-
getOptimalMappedPotential
public double getOptimalMappedPotential()Returns the value of the mapped potential that maximizes the likelihood of the set of oxidation states coexisting.- Returns:
- the value of the mapped potential that maximizes the likelihood of the set of oxidation states coexisting.
-
getGlobalInstabilityIndex
public double getGlobalInstabilityIndex()Returns the global instability index (gii) for the given set of oxidation states applied to a particular structure.- Returns:
- the global instability index (gii) for the given set of oxidation states applied to a particular structure.
-
getBoundaryPairs
public double[][] getBoundaryPairs()Returns the minimum and maximum boundaries for each ion in this row.- Returns:
- the minimum and maximum boundaries for each ion in this row. The pairs are arranged as an array pairs of boundary values,
in the same order as the list of ions returned by
getSymbols(). The first element in the pair is the lower bound, and the second element in the pair is the upper bound.
-
setCIFString
Sets an optional string representation of a CIF file with all oxidation states assigned.- Parameters:
cifString- A string containing contents of the CIF file.
-
getCIFString
Returns a string representation of a CIF file with all oxidation states assigned, or null if no such file could be generated.- Returns:
- a string representation of a CIF file with all oxidation states assigned, or null if no such file could be generated.
-
isMixedValence
public boolean isMixedValence()Returns true if the generated oxidation states are "mixed valence", meaning the same element (or polyatomic ion type) is associated with more than one oxidation state.- Returns:
- true if the generated oxidation states are "mixed valence", meaning the same element (or polyatomic ion type) is associated with more than one oxidation state.
-
compareTo
- Specified by:
compareToin interfaceComparable<TableRow>
-
toString
-