Package ffx.potential.parsers
Class BARFilter
java.lang.Object
ffx.potential.parsers.BARFilter
The BARFilter class parses TINKER bar(*.BAR) files.
- Since:
- 1.0
- Author:
- Rose A. Gogal
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondouble[]
getE1l1()
Return the potential energy for each snapshot of ensemble 1 at lambda 1.double[]
getE1l2()
Return the potential energy for each snapshot of ensemble 1 at lambda 2.double[]
getE2l1()
Return the potential energy for each snapshot of ensemble 2 at lambda 1.double[]
getE2l2()
Return the potential energy for each snapshot of ensemble 2 at lambda 2.getFile()
Return the number of snapshots in the BAR file.int
Return the number of snapshots in the BAR file.double
Returns the temperature for ensemble 1.double
Returns the temperature for ensemble 2.double[]
Return the volume for each snapshot of ensemble 1.double[]
Return the volume for each snapshot of ensemble 2.boolean
readFile()
Read TINKER bar files and parse the snapshots into energy arraysboolean
Write TINKER bar filesboolean
Write TINKER bar files
-
Constructor Details
-
BARFilter
BARFilter constructor- Parameters:
barFile
- aList
object.
-
BARFilter
BARFilter constructor -
BARFilter
public BARFilter(File xyzFile, double[] e1l1, double[] e1l2, double[] e2l1, double[] e2l2, double[] volume1, double[] volume2, double temperature1, double temperature2) BARFilter constructor- Parameters:
xyzFile
- aList
object.e1l1
- energy in ensemble 1 at lambda 1e1l2
- energy in ensemble 1 at lambda 2e2l1
- energy in ensemble 2 at lambda 1e2l2
- energy in ensemble 2 at lambda 2volume1
- volume in ensemble 1volume2
- volume in ensemble 2temperature1
- temperature of ensemble 1temperature2
- temperature of ensemble 2
-
-
Method Details
-
readFile
public boolean readFile()Read TINKER bar files and parse the snapshots into energy arrays- Returns:
- True if the file was read successfully.
-
writeFile
Write TINKER bar files- Parameters:
saveFile
- The file to write to.isPBC
- include volume in the output file.- Returns:
- True if successful.
-
writeFile
Write TINKER bar files- Parameters:
saveFile
- The file to write to.isPBC
- include volume in the output file.append
- If the append flag is true, "saveFile" will be appended to. Otherwise, the default versioning scheme will be applied.- Returns:
- True if successful.
-
getTemperature1
public double getTemperature1()Returns the temperature for ensemble 1.- Returns:
- The temperature.
-
getTemperature2
public double getTemperature2()Returns the temperature for ensemble 2.- Returns:
- The temperature.
-
getE1l1
public double[] getE1l1()Return the potential energy for each snapshot of ensemble 1 at lambda 1.- Returns:
- The potential energy for each snapshot of ensemble 1 at lambda 1.
-
getE1l2
public double[] getE1l2()Return the potential energy for each snapshot of ensemble 1 at lambda 2.- Returns:
- The potential energy for each snapshot of ensemble 1 at lambda 2.
-
getE2l1
public double[] getE2l1()Return the potential energy for each snapshot of ensemble 2 at lambda 1.- Returns:
- The potential energy for each snapshot of ensemble 2 at lambda 1.
-
getE2l2
public double[] getE2l2()Return the potential energy for each snapshot of ensemble 2 at lambda 2.- Returns:
- The potential energy for each snapshot of ensemble 2 at lambda 2.
-
getVolume1
public double[] getVolume1()Return the volume for each snapshot of ensemble 1.- Returns:
- The volume for each snapshot of ensemble 1.
-
getVolume2
public double[] getVolume2()Return the volume for each snapshot of ensemble 2.- Returns:
- The volume for each snapshot of ensemble 2.
-
getNumberOfSnapshots
public int getNumberOfSnapshots()Return the number of snapshots in the BAR file.- Returns:
- The number of snapshots in the BAR file.
-
getFile
Return the number of snapshots in the BAR file.- Returns:
- The number of snapshots in the BAR file.
-