Aug 27, 2015 at 12:36pm UTC
Dear All
I have tried to include the compton scattering in one of the examples in geant4.10.01.p02
but in the run section it gave me this error
C1PrimaryGeneratorAction.cc:98:5: error: ‘particleName’ was not declared in this scope
if (particleName == "gamma") {
please any help .
thanks
Aug 27, 2015 at 3:23pm UTC
thank you so much,
eventhough I did this definition at the begining ,
but once I define the particel again it works
G4string particleName ;
if(particlename == "gamma"
...
}
Aug 27, 2015 at 3:25pm UTC
but now , if you do not mind , how to create the output file to see the results and to be able to analyse them.
thanks
Aug 27, 2015 at 10:27pm UTC
There isn't enough information here to answer your question.
Aug 27, 2015 at 11:53pm UTC
I meant to create output.txt file
this is my desired data (shown in terminal) but I want them in file.txt
G4cout <<std::setw(6)<<"Energy Desposited--->"<<""<<std::setw(6)<<edepStep<<""
<<G4endl;
it might be easy but I am still crawl .
thank you so much for your thoughts.
Aug 28, 2015 at 5:06am UTC
Your question is a bit too wide-sweeping in nature for a simple answer.
Try http://www.cplusplus.com/doc/tutorial/files/ for a good start but I get the impression you are starting from an earlier position than that so try http://www.cplusplus.com/doc/tutorial/
The tutorials are very helpful.
Cheers and good luck. :)
Last edited on Aug 28, 2015 at 4:24pm UTC
Aug 28, 2015 at 3:22pm UTC
thank you so much kemort
I do appreciate your assistance.