|Message: Re: Help setting up an Electric Field||Not Logged In (login)|
Click on the Forum title, e.g. on the "Forums by Category" page, to read a sequence of postings to the Forum and its threads all in one page. If you are only interested in one thread or the thread following a specific posting, click the thread or the posting, which takes you to a smaller page, which contains only the part you are interested in and may be easier to navigate.
Messages are "chained" if there are only replies at the first level, i.e. 1/1.html, 1/1/1.html etc. In case of "chained" messages the message number is replaced by the icon and there is no indentation.
Inline: Display the subject line only or also the text of the posting(s); for the choice "All" the "Outline" choices are switched off.
|1||0||1||no text / full text of posting|
|2||1||All||text for level 1 only / text for All postings|
Outline: Choose the depth of the posting thread, successive toggle controls provide increasing detail.
|1||2||1||2 levels / 1 level (original posting)|
|2||3||2||3 levels / 2 levels|
|3||3||All||3 levels / all levels (all postings)|
Dear Adam, In an application in which you need a local electric field, you should have two field managers: - a global field manager, which holds no field - a local field manager, which holds the electric field and the classes which define the equation of motion for charged particles. If you have copied examples/extended/field/field02 you will need to modify it so that it does not use the GlobalFieldManager, but instead creates only a localFieldManager. You can see this in the field03 example too - but it suffices simply to the calls to GetGlobalFieldManager() in the Setup method and instead add a localFieldManager object in the setup method and create such an object. After that it does not matter in what class you set the logical volume's field manager - so long as it has access to both of xenon_log and the field manager. But a logical place (no pun intended) is to use your detector Construction. Best regards, John. > I added the line: > > ExN02ElectricFieldSetup* field = new ExN02ElectricFieldSetup(); > > to my main. When the simulation starts, it seems as though particles are > leaving the xenon and keep going on forever until they exit the world > volume, which gives me a segmentation fault. I know that to isolate the > field to only the xenon cylinder, I need to use the line: > > xenon_log->SetFieldManager(field->GetGlobalFieldManager(), false); > > Although I would change > Is this right? If it is right, in what class do I put this line? The > documentation isn't very specific about this. Adam wrote: > *** Discussion title: Fields: Magnetic and Otherwise > Email replies to PublicHyperNews@slac.stanford.edu must include: > In-Reply-To: <"/emfields/124/1/1"@geant4-hn.slac.stanford.edu> > Subject: ...change this to be about your reply. > > The segmentation fault is gone. How do I confine the field to inside the > cylinder without having it outside? >
|Inline Depth:||Outline Depth:||Add message:|