示例#1
0
//============================================================================
// Return the tag of the event (ie the anti-flavour of the produced 
// B meson). Flip the flavour of the event with probB probability
//============================================================================
void EvtIncoherentMixing::OtherB( EvtParticle * p ,
                                  double & t ,
                                  EvtId & otherb ,
                                  double probB ) 
{
  //if(p->getId() == B0 || p->getId() == B0B) 
  //added by liming Zhang
  enableFlip();
  if ( ( isB0Mixed( p ) ) || ( isBsMixed( p ) ) ) {
    p->getParent()->setLifetime() ;
    t = p->getParent()->getLifetime() ;
  }
  else {
    p->setLifetime() ;
    t = p->getLifetime() ;
  }

  if ( flipIsEnabled() ) {
    //std::cout << " liming << flipIsEnabled " << std::endl;
    // Flip the flavour of the particle with probability probB
    bool isFlipped = ( EvtRandom::Flat( 0. , 1. ) < probB ) ;
    
    if ( isFlipped ) {
      if ( ( isB0Mixed( p ) ) || ( isBsMixed( p ) ) ) {
        p->getParent()
          ->setId( EvtPDL::chargeConj( p->getParent()->getId() ) ) ;
        p->setId( EvtPDL::chargeConj( p->getId() ) ) ;
      }
      else {
        p->setId( EvtPDL::chargeConj( p->getId() ) ) ;
      }
    }
  }
  
  if ( ( isB0Mixed( p ) ) || ( isBsMixed( p ) ) ) {
    // if B has mixed, tag flavour is charge conjugate of parent of B-meson
    otherb = EvtPDL::chargeConj( p->getParent()->getId() ) ;
  }
  else {
    // else it is opposite flavour than this B hadron
    otherb = EvtPDL::chargeConj( p->getId() ) ;
  }

  return ;
}
示例#2
0
//============================================================================
// Return the tag of the event (ie the anti-flavour of the produced 
// B meson). No flip
//============================================================================
void EvtIncoherentMixing::OtherB( EvtParticle * p ,
                                  double & t ,
                                  EvtId & otherb ) 
{
  if ( ( isB0Mixed( p ) ) || ( isBsMixed( p ) ) ) {
    p->getParent()->setLifetime() ;
    t = p->getParent()->getLifetime() ;
  }
  else {
    p->setLifetime() ;
    t = p->getLifetime() ;
  }
  
  if ( ( isB0Mixed( p ) ) || ( isBsMixed( p ) ) ) {
    // if B has mixed, tag flavour is charge conjugate of parent of B-meson
    otherb = EvtPDL::chargeConj( p->getParent()->getId() ) ;
  }
  else {
    // else it is opposite flavour than this B hadron
    otherb = EvtPDL::chargeConj( p->getId() ) ;
  }

  return ;
}
void EvtSSD_DirectCP::decay( EvtParticle *p) {

    bool flip = false ;
    EvtId daugs[2];

    // decide it is B or Bbar:
    if ( EvtRandom::Flat(0.,1.) < ( ( 1. - _acp ) / 2. ) ) {
        // it is a B
        if ( EvtPDL::getStdHep( getParentId() ) < 0 ) flip = true ;
    } else {
        // it is a Bbar
        if ( EvtPDL::getStdHep( getParentId() ) > 0 ) flip = true ;
    }

    if ( flip ) {
        if ( ( isB0Mixed( p ) ) || ( isBsMixed( p ) ) ) {
            p->getParent()
            ->setId( EvtPDL::chargeConj( p->getParent()->getId() ) ) ;
            p->setId( EvtPDL::chargeConj( p->getId() ) ) ;
        }
        else {
            p->setId( EvtPDL::chargeConj( p->getId() ) ) ;
        }
    }

    if (!flip) {
        daugs[0]=getDaug(0);
        daugs[1]=getDaug(1);
    }
    else {
        daugs[0]=EvtPDL::chargeConj(getDaug(0));
        daugs[1]=EvtPDL::chargeConj(getDaug(1));
    }

    EvtParticle *d;
    p->initializePhaseSpace(2, daugs);

    EvtVector4R p4_parent=p->getP4Restframe();
    double m_parent=p4_parent.mass();

    EvtSpinType::spintype d2type=EvtPDL::getSpinType(getDaug(1));

    EvtVector4R momv;
    EvtVector4R moms;

    if (d2type==EvtSpinType::SCALAR) {
        d2type=EvtPDL::getSpinType(getDaug(0));
        d= p->getDaug(0);
        momv = d->getP4();
        moms = p->getDaug(1)->getP4();
    }
    else {
        d= p->getDaug(1);
        momv = d->getP4();
        moms = p->getDaug(0)->getP4();
    }

    if (d2type==EvtSpinType::SCALAR) {
        vertex(1.);
    }

    if (d2type==EvtSpinType::VECTOR) {

        double norm=momv.mass()/(momv.d3mag()*p->mass());

        vertex(0,norm*p4_parent*(d->epsParent(0)));
        vertex(1,norm*p4_parent*(d->epsParent(1)));
        vertex(2,norm*p4_parent*(d->epsParent(2)));

    }

    if (d2type==EvtSpinType::TENSOR) {

        double norm=
            d->mass()*d->mass()/(m_parent*d->getP4().d3mag()*d->getP4().d3mag());


        vertex(0,norm*d->epsTensorParent(0).cont1(p4_parent)*p4_parent);
        vertex(1,norm*d->epsTensorParent(1).cont1(p4_parent)*p4_parent);
        vertex(2,norm*d->epsTensorParent(2).cont1(p4_parent)*p4_parent);
        vertex(3,norm*d->epsTensorParent(3).cont1(p4_parent)*p4_parent);
        vertex(4,norm*d->epsTensorParent(4).cont1(p4_parent)*p4_parent);
    }
}