| 234 |
|
template<typename T> double NPTf<T>::getConservedQuantity(void){ |
| 235 |
|
|
| 236 |
|
double conservedQuantity; |
| 237 |
< |
double Energy; |
| 237 |
> |
double totalEnergy; |
| 238 |
|
double thermostat_kinetic; |
| 239 |
|
double thermostat_potential; |
| 240 |
|
double barostat_kinetic; |
| 242 |
|
double trEta; |
| 243 |
|
double a[3][3], b[3][3]; |
| 244 |
|
|
| 245 |
< |
Energy = tStats->getTotalE(); |
| 245 |
> |
totalEnergy = tStats->getTotalE(); |
| 246 |
|
|
| 247 |
|
thermostat_kinetic = fkBT* tt2 * chi * chi / |
| 248 |
|
(2.0 * eConvert); |
| 259 |
|
barostat_potential = (targetPressure * tStats->getVolume() / p_convert) / |
| 260 |
|
eConvert; |
| 261 |
|
|
| 262 |
< |
conservedQuantity = Energy + thermostat_kinetic + thermostat_potential + |
| 262 |
> |
conservedQuantity = totalEnergy + thermostat_kinetic + thermostat_potential + |
| 263 |
|
barostat_kinetic + barostat_potential; |
| 264 |
|
|
| 265 |
|
// cout.width(8); |