Hi everyone. I have a simple geometry: 3 boxes in series. I want to set a uniform electric field in the center one. In my “fieldsetup.cc” and “.hh” I introduced both global and local field, then I set the global to zero and the local along the Z-axe to 5 kV/m.
Then in “detectorconstruction.cc” I wrote:
B1ElectricFieldSetup* fieldSetup = new B1ElectricFieldSetup(); fEmFieldSetup.Put(fieldSetup); fScoringVolume->SetFieldManager(fEmFieldSetup.Get()->GetLocalFieldManager(), true );
But when i try to visualize the electric field, it is still associated to all the world and not to the scoring volume. What is the (possible) problem? I don’t want to send all the code if it is not necessary because it would be too messy.
Thanks to all.