Message: Re: Selecting Copy number as mother volume Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question Re: Selecting Copy number as mother volume 

Forum: Geometry
Re: None Selecting Copy number as mother volume (Victor Meldrew)
Date: 15 Jul, 2014
From: Gabriele Cosmo <Gabriele Cosmo>

Hi Victor,

your code snippet looks incomplete... Can you show what is
"logicinnermodule" ?

Cheers, Gabriele

------------
On Tue, 01 Jul 2014 20:50:50 GMT, traveller wrote:
> Hello All,
> 
>    ( I am new to Geant4 )
> 
>    I am trying to place a box inside a mother volume that replicated.
> 
>    Here is the relevant section of my code:
> 
> ...
> ...
> 
> G4LogicalVolume*  logicinnerbox = new
> G4LogicalVolume(solidinnerbox,default_mat,"innerbox");
> 
> for (G4int loop = 0; loop < 10 ; loop++) {
> new G4PVPlacement(0,
> G4ThreeVector(-18.25*mm,0*mm,(loop-1)*solidinnerbox_z ),
>  logicinnerbox,
> "innerbox",
> logicbox,
>  false,
> loop,
> fCheckOverlaps);
> }
> 
> Having created this logicinnerbox, I am trying to place a box inside one of
> the copies. Say I select copy no 5.
> 
> I tried doing this:
> 
> fLogicdetector = new G4LogicalVolume(soliddetector, cryst_mat, "detector");
> new G4PVPlacement(0, G4ThreeVector(), fLogicdetector, "detector",
> logicinnermodule->GetDaughter(4), false, 0, fCheckOverlaps);
> 
> However, that does not work. What am I doing wrong, and how can I fix it?
> 
> Thanks in advance,
> 
> Victor.
> 
>  [ MIME part of type text/html without a name stripped ]
> 

 Add Message Add Message
to: "Re: Selecting Copy number as mother volume"

 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 ]