Exemplo n.º 1
0
  void 
  OPCContactMap::initialise()
  {
    for (const shared_ptr<Topology>& plugPtr : Sim->topology)
      if (std::dynamic_pointer_cast<TChain>(plugPtr))
	chains.push_back(Cdata(static_cast<const TChain*>(plugPtr.get()), 
			       plugPtr->getMolecules().front()->size()));
  }
Exemplo n.º 2
0
  void 
  OPChainBondAngles::initialise()
  {
    for(const shared_ptr<Topology>& plugPtr : Sim->topology)
      if (std::dynamic_pointer_cast<TChain>(plugPtr))
	chains.push_back(Cdata(plugPtr->getID(), plugPtr->getMolecules().front()->size(),
			       binwidth));
  }
Exemplo n.º 3
0
    chainID(ID)
  {
    BondLengths.resize(CL-1, magnet::math::Histogram<>(0.0001));
  }

  OPChainBondLength::OPChainBondLength(const dynamo::Simulation* tmp, const magnet::xml::Node&):
    OPTicker(tmp,"ChainBondLength")
  {}

  void 
  OPChainBondLength::initialise()
  {
    BOOST_FOREACH(const shared_ptr<Topology>& plugPtr, 
		  Sim->topology)
      if (std::tr1::dynamic_pointer_cast<TChain>(plugPtr))
	chains.push_back(Cdata(plugPtr->getID(), plugPtr->getMolecules().front()->size()));
  }

  void 
  OPChainBondLength::changeSystem(OutputPlugin* OPPlug)
  {
    std::swap(Sim, static_cast<OPChainBondLength*>(OPPlug)->Sim);
  }

  void 
  OPChainBondLength::ticker()
  {
    BOOST_FOREACH(Cdata& dat, chains)
      BOOST_FOREACH(const shared_ptr<IDRange>& range, 
		    Sim->topology[dat.chainID]->getMolecules())
      if (range->size() > 2)