Ignore:
Timestamp:
Apr 6, 2009, 12:30:29 PM (15 years ago)
Author:
garnier
Message:

update processes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/processes/hadronic/models/qmd/src/G4QMDSystem.cc

    r819 r962  
    2424// ********************************************************************
    2525//
     26// 081120 Add InsertParticipant Method by T. Koi
     27
    2628#include "G4QMDSystem.hh"
    2729#include <iomanip>
     
    9799   G4cout << "Sum upped Momentum and mag " << p_sum << " " << p_sum.mag() << G4endl;
    98100}
     101
     102
     103
     104void G4QMDSystem::InsertParticipant ( G4QMDParticipant* particle , G4int n )
     105{
     106
     107   if ( (size_t) n > participants.size()+1 )
     108      G4cout << "G4QMDSystem::InsertParticipant size error" << G4endl;
     109
     110   std::vector< G4QMDParticipant* >::iterator it;
     111   it = participants.begin();
     112
     113   for ( G4int i = 0; i < n ; i++ )
     114      it++;
     115
     116   participants.insert( it, particle );
     117}
Note: See TracChangeset for help on using the changeset viewer.