Skip to content

Commit

Permalink
Merge pull request #63 from open2c/henrik-dahl-pinholt-patch-2
Browse files Browse the repository at this point in the history
Fixed spherical well
  • Loading branch information
henrik-dahl-pinholt authored Feb 6, 2023
2 parents b589c53 + 9c84c07 commit d8f39d2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion polychrom/forces.py
Original file line number Diff line number Diff line change
Expand Up @@ -850,7 +850,7 @@ def spherical_well(sim_object, particles, r, center=[0, 0, 0], width=1, depth=1,
"""

force = openmm.CustomExternalForce(
"step(1+d) * step(1-d) * SPHWELLdepth * (1 - cos(3.1415926536*d)) / 2;"
"step(1+d) * step(1-d) * SPHWELLdepth * (1 + cos(3.1415926536*d)) / 2;"
"d = (sqrt((x-SPHWELLx)^2 + (y-SPHWELLy)^2 + (z-SPHWELLz)^2) - SPHWELLradius) / SPHWELLwidth"
)

Expand Down

0 comments on commit d8f39d2

Please sign in to comment.