Message: Re: biasing muon cross section interaction Not Logged In (login)

Idea Re: biasing muon cross section interaction 

Forum: Biasing and Scoring
Re: Question biasing muon cross section interaction (Sean Turnbull)
Re: Question Re: biasing muon cross section interaction (Stefan E. Mueller)
Date: 15 Apr, 2014
From: C Mos <C Mos>

I would guess maybe because the vector is empty empty as it has not being instantiated. To check if the vector exist:

  if(!vect)  // OR     if(vect!=0)  OR   if(vect!=NULL){
    //Get size here
  }else{
    G4cout << Vector is NULL. It has not being instantiated. Maybe you have to let the RunManager build the physics list first?" << G4cout;
  }

Are you retrieving your data from the main function? If I would change any aspect of my physics list I will do it but creating my own physics list and then redefining the process of interest. There might be some other tricks. Maybe using proper accessors and mutators if available? I will leave other options to the experts.

C Mos

Inline Depth:
 0 0
 All All
Outline Depth:
 1 1
 2 2
 All All
Add message: (add)

Question Re: biasing muon cross section interaction  by Stefan E. Mueller <Stefan E. Mueller>,   16 Apr, 2014
Re: Idea Re: biasing muon cross section interaction (C Mos)
OK,

I try to retrieve the process list for photons now in my G4VPhysicsConstructor-class which I use to add G4GammaConversionToMuons to the list of processes for photons.

Right after I add the process with

     pManager->AddDiscreteProcess(new G4GammaConversionToMuons());

I do

     G4ProcessVector* procVect = new G4ProcessVector();
     procVect = pManager->GetProcessList();
     if(!procVect) {
       G4int length = pManager->GetProcessListLength();
       G4int length2 = procVect->size();
       G4cout << "size " << length << " " << length2 << G4endl;
     } else {
       G4cout << "Vector is NULL. It has not being instantiated. Maybe you have to let the RunManager build the physics list first?" << G4endl;
     }

Code compiles and builds, and also runs, but indeed I get the message that "Vector is NULL...". Trying to do the same in my main.cc (after the runmanager has registered the physics and initialized the physics lists) results in a crash.

Anyway, before coming too off-topic on where, when and how ProcessVectors are filled, my main question is:

How can I set the PIL-factor for the process "G4GammaConversionToMuons" ?

Many thanks for suggestions on how to do that,

Stefan

1 News: Re: biasing muon cross section interaction   (Stefan E. Mueller - 05 May, 2014)
(_ Idea: Re: biasing muon cross section interaction   (Stefan E. Mueller - 05 Jun, 2014)
 Add Message Add Message
to: "Re: biasing muon cross section interaction"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews