Skip to content

Commit

Permalink
reverted some of the more speculative changes
Browse files Browse the repository at this point in the history
  • Loading branch information
ekwan committed Jul 8, 2021
1 parent c553b16 commit 79bb978
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion cctk/quasiclassical.py
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ def apply_vibration(molecule, mode, min_freq=50, temperature=298, verbose=False,
elif velocity != "positive":
raise ValueError(f"unknown value {velocity} for keywork ``velocity`` - must be ``positive``, ``negative``, ``random``, or ``zero``")

text = f"{mode.frequency:.1f} cm-1 ({energy:4.2f} kcal/mol)\t{method}\t Shift {shift:4.2f} of {max_shift:4.2f} Å ({rel_shift:5.0%})"
text = f"{mode.frequency:.1f} cm-1 ({energy:4.2f} kcal/mol)\t{method}\t Shift {shift:5.2f} of {max_shift:4.2f} Å ({rel_shift:5.0%})"
text += f"\tPE = {potential_energy:4.2f} kcal/mol\tKE = {kinetic_energy:4.2f} kcal/mol\tk = {mode.force_constant:.1f} kcal/mol Å^-2"
if not displacement:
text += "\n\t\tDisplacement manually set to zero"
Expand Down
4 changes: 2 additions & 2 deletions cctk/vibrational_mode.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ def random_displacement(self, energy=None, level=0, method="quasiclassical", max
if method == "quasiclassical":
min_val = 0
max_val = self.quantum_distribution_max(level)
max_x = self.classical_turning_point(level=level)
max_x = self.classical_turning_point()

attempts = 0
while attempts < max_attempts:
Expand Down Expand Up @@ -176,7 +176,7 @@ def quantum_distribution_max(self, level=0, num_pts=1e4):
if level == 0:
return self.quantum_distribution_value(0)

max_x = self.classical_turning_point(level=level)
max_x = self.classical_turning_point()

# there is certainly a better way to do this
max_p = 0
Expand Down

0 comments on commit 79bb978

Please sign in to comment.