"wrappers/vscode:/vscode.git/clone" did not exist on "e59e15b243ebfc1b1a76ffd11c2783a485185b60"
Commit 17b7569a authored by Jason Swails's avatar Jason Swails
Browse files

Update the CHARMM example.

parent 895f9a6f
......@@ -4,20 +4,17 @@ from simtk.unit import *
from sys import stdout
# Read the PSF
psf = CharmmPSF.load_from_psf('ala_ala_ala.psf')
psf = CharmmPsfFile('ala_ala_ala.psf')
# Get the coordinates from the PDB
pdb = PDBFile('ala_ala_ala.pdb')
# Read and condense the parameter set
params = CharmmParameterSet.load_set(tfile='charmm22.rtf',
pfile='charmm22.par').condense()
# Load the parameter set !! do not forget this !!
psf.load_parameters(params)
params = CharmmParameterSet('charmm22.rtf', 'charmm22.par')
# Instantiate the system
system = psf.createSystem(nonbondedMethod=NoCutoff, nonbondedCutoff=None)
system = psf.createSystem(params, nonbondedMethod=NoCutoff,
nonbondedCutoff=None)
integrator = LangevinIntegrator(300*kelvin, 1/picosecond, 0.002*picoseconds)
simulation = Simulation(psf.topology, system, integrator)
simulation.context.setPositions(pdb.getPositions())
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment