Message: Re: newbie question on QGSP_BERT_HP Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None Re: newbie question on QGSP_BERT_HP 

Forum: Physics List
Re: Question newbie question on QGSP_BERT_HP (matthew)
Re: Idea Re: newbie question on QGSP_BERT_HP (Vladimir Ivanchenko)
Date: 19 Sep, 2011
From: matthew <matthew>

Dear VI,

When I make the change you suggest, I run make and get the following error:

$ make
Making dependency for file Gd_Exp_1.cc ...
Compiling Gd_Exp_1.cc ...
Gd_Exp_1.cc
Gd_Exp1.cc(43)  : error C2039: 'RegisterPhysics' : is not a member of
'G4VUserPhysicsList'  ... :see declaration of 'G4VUserPhysicsList'
Gd_Exp_1.cc(43) : error C2061: syntax error : identifier
 'G4RadioactiveDecayPhysics'
make: *** [C:/G4work/temp/WIN32-VC/Gd_Exp_1/exe/Gd_Exp_1.OBJ] Error 2

Any suggestions as to why this is happening?  
The main c-code looks like:

// --------------------------------------------------------------
//      GEANT 4 - Gd Experiment 1
// --------------------------------------------------------------
#include "G4RunManager.hh"
#include "G4UImanager.hh"
#include "GdExp1_DetectorConstruction.hh"
//#include "GdExp1_PhysicsList.hh"
#include "QGSP_BERT_HP.hh"
#include "GdExp1_PrimaryGeneratorAction.hh"
#include "G4VisExecutive.hh"
#include "G4UIExecutive.hh"


int main(int argc,char** argv)
{
  // Construct the default run manager
  //
  G4RunManager* runManager = new G4RunManager;

    // Visualization manager construction
  G4VisManager* visManager = new G4VisExecutive;
  visManager->Initialize();

  // set mandatory initialization classes
  //
  
  G4VUserDetectorConstruction* detector = new GdExp1_DetectorConstruction;
  runManager->SetUserInitialization(detector);
  
  //
  //G4VUserPhysicsList* physics = new GdExp1_PhysicsList;
  G4VUserPhysicsList* physics = new QGSP_BERT_HP;
  runManager->SetUserInitialization(physics);
  physics->RegisterPhysics(new G4RadioactiveDecayPhysics());
  

  // set mandatory user action class
  //
  G4VUserPrimaryGeneratorAction* gen_action = new GdExp1_PrimaryGeneratorAction;
  runManager->SetUserAction(gen_action);
  //
  // set addition user action classes
  // (none used)
 
  // Initialize G4 kernel
  //
  runManager->Initialize();
  

  // Get the pointer to the UI manager and set verbosities
  //
  G4UImanager* UImanager = G4UImanager::GetUIpointer();
  
  // Start a run
  //
  //G4int numberOfEvent = 3;
  //runManager->BeamOn(numberOfEvent);


if(argc>1)
  // execute an argument macro file if exist
  {
    
    G4String command = "/control/execute ";
    G4String fileName = argv[1];
    UImanager->ApplyCommand(command+fileName);

	// Include process to enter interactive mode
	// even when a macro is called
	G4UIExecutive* ui = new G4UIExecutive(argc, argv);
    ui->SessionStart();
    delete ui;
  }
  else
  // start interactive session
  {
    G4UIExecutive* ui = new G4UIExecutive(argc, argv);
    ui->SessionStart();
    delete ui;

  }


  delete visManager;
  delete runManager;
  //delete verbosity;

  return 0;
}

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

1 Idea: Re: newbie question on QGSP_BERT_HP   (Vladimir Ivanchenko - 19 Sep, 2011)
 Add Message Add Message
to: "Re: newbie question on QGSP_BERT_HP"

 Subscribe Subscribe

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


[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]