00001 // 00002 // ******************************************************************** 00003 // * License and Disclaimer * 00004 // * * 00005 // * The Geant4 software is copyright of the Copyright Holders of * 00006 // * the Geant4 Collaboration. It is provided under the terms and * 00007 // * conditions of the Geant4 Software License, included in the file * 00008 // * LICENSE and available at http://cern.ch/geant4/license . These * 00009 // * include a list of copyright holders. * 00010 // * * 00011 // * Neither the authors of this software system, nor their employing * 00012 // * institutes,nor the agencies providing financial support for this * 00013 // * work make any representation or warranty, express or implied, * 00014 // * regarding this software system or assume any liability for its * 00015 // * use. Please see the license in the file LICENSE and URL above * 00016 // * for the full disclaimer and the limitation of liability. * 00017 // * * 00018 // * This code implementation is the result of the scientific and * 00019 // * technical work of the GEANT4 collaboration. * 00020 // * By using, copying, modifying or distributing the software (or * 00021 // * any work based on the software) you agree to acknowledge its * 00022 // * use in resulting scientific publications, and indicate your * 00023 // * acceptance of all terms of the Geant4 Software license. * 00024 // ******************************************************************** 00025 // 00026 #include "G4NeutronLENDBuilder.hh" 00027 #include "G4SystemOfUnits.hh" 00028 #include "G4ParticleDefinition.hh" 00029 #include "G4ParticleTable.hh" 00030 #include "G4ProcessManager.hh" 00031 00032 G4NeutronLENDBuilder:: 00033 G4NeutronLENDBuilder( G4String eva ) 00034 { 00035 theLENDElastic = 0; 00036 theLENDElasticCrossSection = 0; 00037 00038 theLENDFission = 0; 00039 theLENDFissionCrossSection = 0; 00040 00041 theLENDCapture = 0; 00042 theLENDCaptureCrossSection = 0; 00043 00044 theLENDInelastic = 0; 00045 theLENDInelasticCrossSection = 0; 00046 00047 theMin = 0; 00048 theIMin = theMin; 00049 theMax = 20*MeV; 00050 theIMax = theMax; 00051 evaluation = eva; 00052 00053 } 00054 00055 G4NeutronLENDBuilder:: 00056 ~G4NeutronLENDBuilder() 00057 { 00058 delete theLENDElasticCrossSection; 00059 delete theLENDFissionCrossSection; 00060 delete theLENDCaptureCrossSection; 00061 delete theLENDInelasticCrossSection; 00062 } 00063 00064 void G4NeutronLENDBuilder:: 00065 Build(G4HadronElasticProcess * aP) 00066 { 00067 if(theLENDElastic==0) theLENDElastic = new G4LENDElastic( G4Neutron::Neutron() ); 00068 theLENDElastic->SetMinEnergy(theMin); 00069 theLENDElastic->SetMaxEnergy(theMax); 00070 00071 if ( evaluation != "" ) theLENDElastic->ChangeDefaultEvaluation( evaluation ); 00072 //theLENDElastic->AllowNaturalAbundanceTarget(); 00073 theLENDElastic->AllowAnyCandidateTarget(); 00074 if(theLENDElasticCrossSection == 0) theLENDElasticCrossSection = new G4LENDElasticCrossSection( G4Neutron::Neutron() ); 00075 if ( evaluation != "" ) theLENDElasticCrossSection->ChangeDefaultEvaluation( evaluation ); 00076 //theLENDElasticCrossSection->AllowNaturalAbundanceTarget(); 00077 theLENDElasticCrossSection->AllowAnyCandidateTarget(); 00078 aP->AddDataSet(theLENDElasticCrossSection); 00079 aP->RegisterMe(theLENDElastic); 00080 } 00081 00082 void G4NeutronLENDBuilder:: 00083 Build(G4HadronFissionProcess * aP) 00084 { 00085 if(theLENDFission == 0) theLENDFission = new G4LENDFission( G4Neutron::Neutron() ); 00086 theLENDFission->SetMinEnergy(theMin); 00087 theLENDFission->SetMaxEnergy(theMax); 00088 if ( evaluation != "" ) theLENDFission->ChangeDefaultEvaluation( evaluation ); 00089 //theLENDFission->AllowNaturalAbundanceTarget(); 00090 theLENDFission->AllowAnyCandidateTarget(); 00091 if(theLENDFissionCrossSection==0) theLENDFissionCrossSection=new G4LENDFissionCrossSection( G4Neutron::Neutron() ); 00092 if ( evaluation != "" ) theLENDFissionCrossSection->ChangeDefaultEvaluation( evaluation ); 00093 //theLENDFissionCrossSection->AllowNaturalAbundanceTarget(); 00094 theLENDFissionCrossSection->AllowAnyCandidateTarget(); 00095 aP->AddDataSet(theLENDFissionCrossSection); 00096 aP->RegisterMe(theLENDFission); 00097 } 00098 00099 void G4NeutronLENDBuilder:: 00100 Build(G4HadronCaptureProcess * aP) 00101 { 00102 if(theLENDCapture==0) theLENDCapture = new G4LENDCapture( G4Neutron::Neutron() ); 00103 theLENDCapture->SetMinEnergy(theMin); 00104 theLENDCapture->SetMaxEnergy(theMax); 00105 if ( evaluation != "" ) theLENDCapture->ChangeDefaultEvaluation( evaluation ); 00106 //theLENDCapture->AllowNaturalAbundanceTarget(); 00107 theLENDCapture->AllowAnyCandidateTarget(); 00108 if(theLENDCaptureCrossSection==0) theLENDCaptureCrossSection = new G4LENDCaptureCrossSection( G4Neutron::Neutron() ); 00109 if ( evaluation != "" ) theLENDCaptureCrossSection->ChangeDefaultEvaluation( evaluation ); 00110 //theLENDCaptureCrossSection->AllowNaturalAbundanceTarget(); 00111 theLENDCaptureCrossSection->AllowAnyCandidateTarget(); 00112 aP->AddDataSet(theLENDCaptureCrossSection); 00113 aP->RegisterMe(theLENDCapture); 00114 } 00115 00116 void G4NeutronLENDBuilder:: 00117 Build(G4NeutronInelasticProcess * aP) 00118 { 00119 if(theLENDInelastic==0) theLENDInelastic = new G4LENDInelastic( G4Neutron::Neutron() ); 00120 theLENDInelastic->SetMinEnergy(theIMin); 00121 theLENDInelastic->SetMaxEnergy(theIMax); 00122 if ( evaluation != "" ) theLENDInelastic->ChangeDefaultEvaluation( evaluation ); 00123 //theLENDInelastic->AllowNaturalAbundanceTarget(); 00124 theLENDInelastic->AllowAnyCandidateTarget(); 00125 if(theLENDInelasticCrossSection==0) theLENDInelasticCrossSection = new G4LENDInelasticCrossSection( G4Neutron::Neutron() ); 00126 if ( evaluation != "" ) theLENDInelasticCrossSection->ChangeDefaultEvaluation( evaluation ); 00127 //theLENDInelasticCrossSection->AllowNaturalAbundanceTarget(); 00128 theLENDInelasticCrossSection->AllowAnyCandidateTarget(); 00129 aP->AddDataSet(theLENDInelasticCrossSection); 00130 aP->RegisterMe(theLENDInelastic); 00131 }