<commit_before>package etomica.potential;

import etomica.api.IAtomSet;
import etomica.api.IPotential;
import etomica.api.IVector;
import etomica.atom.AtomAgentManager;
import etomica.integrator.IntegratorBox;

/**
 * Sums the force on each iterated atom and adds it to the integrator agent
 * associated with the atom.
 */
public class PotentialCalculationForceSum implements PotentialCalculation {
        
    private static final long serialVersionUID = 1L;
    protected AtomAgentManager integratorAgentManager;
    protected AtomAgentManager.AgentIterator agentIterator;
    
    public void setAgentManager(AtomAgentManager agentManager) {
        integratorAgentManager = agentManager;
        agentIterator = integratorAgentManager.makeIterator();
    }

    /**
     * Re-zeros the force vectors.
     *
     */<commit_msg>take a leaf atom manager -- if something wants to use molecules, they're going to need to use a torquesum PC anyway.<commit_after>package etomica.potential;

import etomica.api.IAtomSet;
import etomica.api.IPotential;
import etomica.api.IVector;
import etomica.atom.AtomLeafAgentManager;
import etomica.integrator.IntegratorBox;

/**
 * Sums the force on each iterated atom and adds it to the integrator agent
 * associated with the atom.
 */
public class PotentialCalculationForceSum implements PotentialCalculation {
        
    private static final long serialVersionUID = 1L;
    protected AtomLeafAgentManager integratorAgentManager;
    protected AtomLeafAgentManager.AgentIterator agentIterator;
    
    public void setAgentManager(AtomLeafAgentManager agentManager) {
        integratorAgentManager = agentManager;
        agentIterator = integratorAgentManager.makeIterator();
    }

    /**
     * Re-zeros the force vectors.
     *
     */
{'fraction_non_alphanumeric': 0.06330532212885154, 'fraction_numerical': 0.0011204481792717086, 'mean_word_length': 3.9749303621169916, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7053650', 'n_tokens_mistral': 502, 'n_tokens_neox': 485, 'n_words': 138}