[root] / trunk / geom / geom / src / TGeoGlobalMagField.cxx Repository:
ViewVC logotype

Log of /trunk/geom/geom/src/TGeoGlobalMagField.cxx

Parent Directory Parent Directory


Links to HEAD: (view) (download) (as text) (annotate)
Sticky Revision:

Revision 43895 - (view) (download) (as text) (annotate) - [select for diffs]
Modified Mon Apr 23 07:03:47 2012 UTC (2 years, 9 months ago) by agheata
File length: 4499 byte(s)
Diff to previous 27191
Fixed statics accessed from inlined functions, causing problems on Windows

Revision 27191 - (view) (download) (as text) (annotate) - [select for diffs]
Modified Tue Jan 20 08:09:20 2009 UTC (6 years ago) by brun
File length: 4284 byte(s)
Diff to previous 27096
From Andrei:
- Added possibility to lock the global field via the global field manager:
 TGeoGlobalMagField::Instance()->SetField(myField)
 TGeoGlobalMagField::Instance()->Lock();
Can be checked via IsLocked() method and unlocking is protected (similar to TGeoManager locking mechanism)

Revision 27096 - (view) (download) (as text) (annotate) - [select for diffs]
Added Wed Jan 7 11:09:44 2009 UTC (6 years ago) by brun
File length: 3535 byte(s)
From Andrei:
New development for magnetic field description. The classes are described below:

TVirtualMagField - Abstract base class for magnetic fields. Derived field classes are encouraged to use the base class named constructor and have to implement the method:
   void Field(const Double_t *x, Double_t *B);
where: x is an input array of 3 space coordinates and B is an output array of the 3 magnetic field components at x position.
   Magnetic fields can be made global via the static pointer of the global field manager:
   TGeoGlobalMagField::Instance()->SetField(field)
Important usage note:
---------------------
A global field is owned by the global field manager but can be replaced using the method above (or simply deleted if providing a NULL argument). Any replaced global field is deleted for safety reasons, while direct deletion of a global field or creation of a new global field manager while a global field is active aborts with <Fatal>. The global field is automatically cleaned up at the end of the root session. Non-global magnetic fields are managed by user.

TGeoUniformMagField - Provided implementation for a uniform magnetic field. Can be built using the three constant field components.

TGeoGlobalMagField - Manager for the global magnetic field. Should be accessed via its static access function:
   TGeoGlobalMagField::Instance()
Use the setter to declare a magnetic field as global and the getter to retrieve it. Becomes owner of the global magnetic field which is cleaned up upon replacement or in the destructor. To get the magnetic field B[3] in a point x[3] one can use:
   TGeoGlobalMagField::Instance()->Field(x,B)
Magnetic field classes can be used standalone or via VMC. Local fields can be connected to TGeoVolume objects.

Thanks to: R.Brun, F.Carminati, C.Cheshkov, A.Gheata, M.Gheata, P.Hristov, A.Morsch, R.Shahoyan

This form allows you to request diffs between any two revisions of this file. For each of the two "sides" of the diff, enter a numeric revision.

  Diffs between and
  Type of Diff should be a

Sort log by:

Subversion Admin
ViewVC Help
Powered by ViewVC 1.0.9