Message: Re: no matching function for call to G4PVReplica::G4PVReplica(const char [7], G4LogicalVolume*&, G4LogicalVolume*&, G4doubl Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

More Re: no matching function for call to G4PVReplica::G4PVReplica(const char [7], G4LogicalVolume*&, G4LogicalVolume*&, G4doubl 

Forum: Geometry
Re: Question no matching function for call to G4PVReplica::G4PVReplica(const char [7], G4LogicalVolume*&, G4LogicalVolume*&, G4doubl (Maluba Vernon)
Date: 15 Jul, 2014
From: Gabriele Cosmo <Gabriele Cosmo>

Hi Maluba,

This line:

>                   &RSlicesLV,          // placed inside other replica

should likely look like:

>                   RSlicesLV,          // placed inside other replica

Cheers, Gabriele

-------------
On Fri, 11 Jul 2014 14:21:12 GMT, Maluba Vernon wrote:
> Hi All, I am trying to build slices in a cylinder both along the z-axis
> as well as it's radius, here is the replication part of my code:
> 
>   //                                 
>   // Rings from centre of mother
>   //
>   G4VSolid* RSlices 
>     = new G4Tubs("RSlice",           // its name
>                  0.,SliceThicknessR,phantomZ/2,0.*deg, 360.*deg); // its size
> 
>   G4LogicalVolume* RSlicesLV
>     = new G4LogicalVolume(RSlices,           // its solid
>                           phantomMaterial,   // its material
>                          "RSlice",0,0,0);    // its name
> 
>   new G4PVReplica("RSlice",          // its name
>                  RSlicesLV,          // its logical volume
>                  phantomLV,          // its mother logical volume
>                  phantomR,           // axis of replication
>                  NofSlicesAlongR,        // number of replica
>                  SliceThicknessR);  // witdth of replica
>                  //offset = 0);
> 
>   //                                 
>   // Rings along Z-axis
>   //
>   G4VSolid* ZSlices 
>     = new G4Tubs("ZSlice",           // its name
>                  0.,SliceThicknessR,SliceThicknessZ,0.*deg, 360.*deg); // its size
> 
>   G4LogicalVolume* ZSlicesLV
>     = new G4LogicalVolume(ZSlices,           // its solid
>                           phantomMaterial,  // its material
>                          "ZSlice",0,0,0);         // its name
> 
>   new G4PVReplica("ZSlice",          // its name
>                   ZSlicesLV,          // its logical volume
>                   &RSlicesLV,          // placed inside other replica
>                   phantomZ,           // axis of replication
>                   NofSlicesAlongZ,        // number of replica
>                   SliceThicknessZ);  // witdth of replica
>                   //offset = 0);
> 
> When I try building it I get this error:
> 
> error: no matching function for call to &#65533;G4PVReplica::G4PVReplica(const
> char [7], G4LogicalVolume*&, G4LogicalVolume*&, G4double&, G4int&,
> G4double&)&#65533;
> /home/richard/Geant4.10-work/VJHadrontherapy/vernon/src/HDetectorConstruction.cc:232:34:
> note: candidates are:
> /home/richard/Geant4.10-work/geant4.10.00-install/include/Geant4/G4PVReplica.hh:200:5:
> note: G4PVReplica::G4PVReplica(const G4PVReplica&)
> /home/richard/Geant4.10-work/geant4.10.00-install/include/Geant4/G4PVReplica.hh:200:5:
> note: candidate expects 1 argument, 6 provided
> /home/richard/Geant4.10-work/geant4.10.00-install/include/Geant4/G4PVReplica.hh:141:5:
> note: G4PVReplica::G4PVReplica(__void__&)
> /home/richard/Geant4.10-work/geant4.10.00-install/include/Geant4/G4PVReplica.hh:141:5:
> note: candidate expects 1 argument, 6 provided
> /home/richard/Geant4.10-work/geant4.10.00-install/include/Geant4/G4PVReplica.hh:133:5:
> note: G4PVReplica::G4PVReplica(const G4String&, G4LogicalVolume*,
> G4VPhysicalVolume*, EAxis, G4int, G4double, G4double)
> /home/richard/Geant4.10-work/geant4.10.00-install/include/Geant4/G4PVReplica.hh:133:5:
> note: no known conversion for argument 3 from &#65533;G4LogicalVolume*&#65533; to
> &#65533;G4VPhysicalVolume*&#65533;
> /home/richard/Geant4.10-work/geant4.10.00-install/include/Geant4/G4PVReplica.hh:123:5:
> note: G4PVReplica::G4PVReplica(const G4String&, G4LogicalVolume*,
> G4LogicalVolume*, EAxis, G4int, G4double, G4double)
> /home/richard/Geant4.10-work/geant4.10.00-install/include/Geant4/G4PVReplica.hh:123:5:
> note: no known conversion for argument 4 from &#65533;G4double {aka double}&#65533; to
> &#65533;EAxis&#65533; X2(for both parts where G4PVReplica is called)
> 
> If you have an idea on how to solve this kind of problem, please, I will
> appreciate.
> 
> Thanks, maluba
> 

 Add Message Add Message
to: "Re: no matching function for call to G4PVReplica::G4PVReplica(const char [7], G4LogicalVolume*&, G4LogicalVolume*&, G4doubl"

 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 ]