Log of /trunk/geom/geom/src/TGeoMaterial.cxx
Parent Directory
Revision
44507 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Mon Jun 4 12:30:41 2012 UTC (2 years, 7 months ago) by
axel
File length: 34099 byte(s)
Diff to
previous 43155
Remove
using namespace std;
from Riostream.h, which has huge consequences for all of ROOT.
Riostream.h is now a simple wrapper for fstream, iostream, iomanip for backward compatibility; Riosfwd.h simply wraps iosfwd.
Because of templates and their inline functions, Riostream.h needed to be included in headers, too (e.g. TParameter.h), which violated the assumption that Riostream.h is not exposing its using namespace std to headers.
ROOT now requires R__ANSISTREAM, R__SSTREAM, which does not change the set of supported compilers.
Without "using namespace std", several identifiers are now prefixed by std::; e.g. roofit/* source files now have a using namespace std to keep their coding style.
TFile::MakeProject() now generates "using namespace std" to convert the CINT-style class names into C++ ones.
Revision
43155 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Tue Feb 28 14:27:43 2012 UTC (2 years, 10 months ago) by
agheata
File length: 34014 byte(s)
Diff to
previous 36535
Added thread id retrieval via TLS. Faster version of TGeoBranchArray. Added getters for specific activity (in Bq/gram) for radioactive elements and materials/mixtures via GetSpecificActivity().
Revision
33466 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Tue May 11 11:16:52 2010 UTC (4 years, 8 months ago) by
agheata
File length: 32909 byte(s)
Diff to
previous 33196
Effective value for number of nucleons in case of isotopes is used for the printout and for computing the interaction length.
Revision
32733 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Mar 24 16:19:00 2010 UTC (4 years, 10 months ago) by
brun
File length: 32873 byte(s)
Diff to
previous 32690
From Andrei:
a new development along the line of having G4-TGeo material compatibility:
So far TGeoMaterial was computing only the radiation length. The patch adds computation of interaction length for materials and mixtures, using the G4 simplified formula. The radlen and intlen can be always set from outside as before.
Revision
32690 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Sun Mar 21 08:47:56 2010 UTC (4 years, 10 months ago) by
brun
File length: 31503 byte(s)
Diff to
previous 27103
From Andrei:
This patch implements SetPoints for composite shapes, allowing to have a mesh of points for composites. Not having this was limiting the overlap checker to non-composites.
Revision
27103 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Thu Jan 8 09:32:20 2009 UTC (6 years ago) by
brun
File length: 31501 byte(s)
Diff to
previous 23478
From Andrei:
- Defining mixtures using custom elements (i.e. not retrieved via TGeoElementTable) is now supported for usage via TFlukaMCGeometry interface.
Revision
16680 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri Nov 3 21:22:32 2006 UTC (8 years, 2 months ago) by
brun
Original Path:
trunk/geom/src/TGeoMaterial.cxx
File length: 29870 byte(s)
Diff to
previous 16271
From Andrei:
1. Possibility to export/import TGeoVolume objects in a similar way as we
can do it for TGeoManager class. Note that for the moment only the .root and
.C formats are supported (for .gdml I don't know how to do it). One can now
import several volumes from file(s) and connect them to the same TGeoManager
object:
Exporting is straightforward:
module1->Export("file.root"); // by default file is overwritten
module2->Export("file.root","","update"); // to the same file
Importing will append the volume to the current TGeoManager or will create
one:
TGeoManager *geom = new TGeoManager("myGeom", "");
TGeoVolume *top = geom->MakeBox(...);
geom->SetTopVolume(top);
TGeoVolume *module1 = TGeoVolume::Import("file.root", "MOD1"); //
name of volume or key (depending on export usage)
TGeoVolume *module2 = TGeoVolume::Import("file.root", "MOD2");
top->AddNode(module1, 1, new TGeoTranslation(0,0,100));
top->AddNode(module2, 1, new TGeoTranslation(0,0,-100));
geom->CloseGeometry(); // One should close himself the geometry
2. Fix in the overlap checker and functionality extension:
TGeoVolume::CheckOverlaps(Double_t ovlp, Option_t *option)
uses now option="d" or option="d<number>" to perform overlap checking by
sampling the volume with <number> random points (default 1 mil.). It
produces also a picture showing in red the overlapping region and estimates
the volume of the overlaps.
3. TGeoMaterial class takes now as optional arguments the material state,
temperature and pressure for compatibility with GEANT4
4. Few modifications of some navigation flags needed to run correctly G4
navigation interface.
Revision
16271 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Thu Sep 14 17:22:12 2006 UTC (8 years, 4 months ago) by
brun
Original Path:
trunk/geom/src/TGeoMaterial.cxx
File length: 28492 byte(s)
Diff to
previous 15760
From Mihaela Gheata:
a patch implementing the time evolution of a radioactive material/mixture according the Bateman equations. I also attached a macro that demonstrates this.
Below there is a quite detailed description of all new features coming with radionucliudes. The same explanations are in the header of the macro.
_______________________________________________________________________
A radionuclide (TGeoElementRN) derives from the class TGeoElement and
provides additional information related to its radioactive properties and
decay modes.
The radionuclides table is loaded on demand by any call:
TGeoElementRN *TGeoElementTable::GetElementRN(Int_t atomic_number,
Int_t atomic_charge,
Int_t isomeric_number)
The isomeric number is optional and the default value is 0.
To create a radioactive material based on a radionuclide, one should use the
constructor:
TGeoMaterial(const char *name, TGeoElement *elem, Double_t density)
To create a radioactive mixture, one can use radionuclides as well as stable
elements:
TGeoMixture(const char *name, Int_t nelements, Double_t density);
TGeoMixture::AddElement(TGeoElement *elem, Double_t weight_fraction);
Once defined, one can retrieve the time evolution for the radioactive
materials/mixtures by using one of the 2 methods:
void TGeoMaterial::FillMaterialEvolution(TObjArray *population,
Double_t precision=0.001)
To use this method, one has to provide an empty TObjArray object that will
be filled with all elements coming from the decay chain of the initial
radionuclides contained by the material/mixture. The precision represent the
cumulative branching ratio for which decay products are still considered.
The POPULATION list may contain stable elements as well as radionuclides,
depending on the initial elements. To test if an element is a radionuclide:
Bool_t TGeoElement::IsRadioNuclide() const
All radionuclides in the output population list have attached objects that
represent the time evolution of their fraction of nuclei with respect to the
top radionuclide in the decay chain. These objects (Bateman solutions) can be
retrieved and drawn:
TGeoBatemanSol *TGeoElementRN::Ratio();
void TGeoBatemanSol::Draw();
Another method allows to create the evolution of a given radioactive
material/mixture at a given moment in time:
TGeoMaterial::DecayMaterial(Double_t time, Double_t precision=0.001)
The method will create the mixture that result from the decay of a initial
material/mixture at TIME, while all resulting elements having a fractional
weight less than PRECISION are excluded.
Revision
15672 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Mon Jul 3 16:10:46 2006 UTC (8 years, 6 months ago) by
brun
Original Path:
trunk/geom/src/TGeoMaterial.cxx
File length: 21954 byte(s)
Diff to
previous 15395
from Axel:
Change the signature of SavePrimitive from
void SavePrimitive(ofstream &out, Option_t *option);
to
void SavePrimitive(ostream &out, Option_t *option = "");
With this change one can do, eg
myhist.SavePrimitive(std::cout);
WARNING: do rm -f tree/src/*.o
Revision
15395 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Sun Jun 11 12:56:48 2006 UTC (8 years, 7 months ago) by
brun
Original Path:
trunk/geom/src/TGeoMaterial.cxx
File length: 21938 byte(s)
Diff to
previous 15176
From Andrei:
1. Mixtures components can now also be other materials/mixtures:
TGeoMixture::AddElement(TGeoMaterial *mat, Double_t weight);
2. When elements are added via TGeoMixture::AddElement(TGeoElement *elem,...), the list of elements is kept.
3. Some fixes related to visualization within TGeoPainter
Revision
15134 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Tue May 23 04:47:42 2006 UTC (8 years, 8 months ago) by
brun
Original Path:
trunk/geom/src/TGeoMaterial.cxx
File length: 16529 byte(s)
Diff to
previous 13282
From Federico Carminati:
"I have implemented all copy and equal operators needed to silence all
warnings in AliRoot, as requested. I have implemented shallow copies as
would do the default operators synthetized by the compiler.
Most operators are protected. If users complain, you just have to move
them into the public area, but class derivation is of course supported.
It has been a terrible job, I have modified 278 files, but the changes
are backward compabile, and this goes a long way to permitting user to
use the effc++ flag with root headers."
Revision
12400 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Thu Jul 28 11:57:23 2005 UTC (9 years, 5 months ago) by
brun
Original Path:
trunk/geom/src/TGeoMaterial.cxx
File length: 14926 byte(s)
Diff to
previous 12089
From Andrei:
1. TGeoMaterial.cxx (geom.diff) : radiation length is systematically computed in
TGeo whenever a material is created (using G3 formula) except for negative
values where the absolute value is taken (G3 behavior). There are only ~5
materials in MUON that are defined with negative radlen - all others are
positive e.g. ignored by G3/TGeo.
TGeo will store a valid (and the same) radiation length whatever MC is used.
This is not the case for the absorbtion length, because the algorithm used by G3
to compute it is quite complex and I do not know if it worth copying it in TGeo
(anyway as far as I understood is not used in reconstruction)
Revision
12089 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Tue Jun 21 12:16:39 2005 UTC (9 years, 7 months ago) by
brun
Original Path:
trunk/geom/src/TGeoMaterial.cxx
File length: 14567 byte(s)
Diff to
previous 12048
From Andrei Gheata:
Radlen<0 produced recomputation of radlen using G3 algorithm (only in TGeo)
G3 just takes the abs value. Of course when geometry was created via VMC
the TGeo values were ignored and G3 did its job, but when loading from
geometry file, G3 material was created based on the radlen value of TGeo
(which being positive, produces recalculation with G3).
This patch preserves the radlen/abslen values as defined
by users.
Revision
12048 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Tue Jun 14 15:47:02 2005 UTC (9 years, 7 months ago) by
brun
Original Path:
trunk/geom/src/TGeoMaterial.cxx
File length: 14561 byte(s)
Diff to
previous 11638
From Andrei Gheata:
Named constructors for volumes, materials and media strip trailing blanks. Some getters at
the level of TGeoManager using FindObject also strip trailing blanks. This cannot be fully
generalized since the user can always iterate himself and get into problems if the query
string contains blanks.
Revision
11638 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Apr 20 15:22:54 2005 UTC (9 years, 9 months ago) by
brun
Original Path:
trunk/geom/src/TGeoMaterial.cxx
File length: 14483 byte(s)
Diff to
previous 11204
From Andrei Gheata:
- boundary tolerance introduced for spheres
- few corrections related to boundary tolerance in composite shapes
- fix for the problem reported by Sue: now the element table is not a
singleton anymore - it is owned by each TGeoManager class and has to be
retreived by calling gGeoManager->GetElementTable().
- fix for problem with MANY's observed by Andreas Morsch in Alice ITS : some
topologies of MANY leading to different search hypothesys were not
properly checked, resulting in overlapping regions that became invisible
during tracking: now completely fixed.
Revision
11076 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Feb 9 13:30:27 2005 UTC (9 years, 11 months ago) by
brun
Original Path:
trunk/geom/src/TGeoMaterial.cxx
File length: 14475 byte(s)
Diff to
previous 11028
From Mihaela Gheata;
- divisions supporting SavePrimitive
- main SavePrimitive loop implemented at level of TGeoVolume
- user interface: TGeoVolume::SaveAs(const char *filename); having *MENU*
- can be called from the browser for any volume:
the resulting file will have a geometry starting with the selected
volume as TOP.
- should work with TPad::SavePrimitive(ofstream out, Option_t *option)
- not tested however
From Andrei:
I did some changes in TGeoCombiTrans to support a shared rotation matrix.
I also fixed a bug in TGeoTube::GetMakeRuntimeShape (and tube segment)
that produced wrong shapes in case one of the initial parameters was negative.
Revision
11028 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Thu Feb 3 11:40:39 2005 UTC (9 years, 11 months ago) by
brun
Original Path:
trunk/geom/src/TGeoMaterial.cxx
File length: 14100 byte(s)
Diff to
previous 10473
From Andrei Gheata:
The diffs for the changes from Mihaela. They implement the SavePrimitive method for:
- all shapes
- materials, mixtures and media
- matrices
- TGeoVolume - just a first version
What is missing:
Divisions + manager metod to save:
- all geometry
- just the branch corresponding to one volume
The differences compared to g2root are that:
- when saving just a a branch just materials/media/matrices for that branch are created (module encapsulation)
- instead of creating objects with numerical arguments, the coresponding variables are defined and used.
e.g. instead of :
new TGeoBBox("name", 10.,20.,30); the generated code is:
dx = 10.;
dy = 20.;
dz = 30.;
pShape = new TGeoBBox("name", dx,dy,dz);
The diffs contain also 2 shapes with boundary-safe algorithms: TGeoPara and TGeoTrap
Revision
10473 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Thu Nov 4 10:38:21 2004 UTC (10 years, 2 months ago) by
brun
Original Path:
trunk/geom/src/TGeoMaterial.cxx
File length: 12364 byte(s)
Diff to
previous 10310
From Andrei Gheata:
TGeoMixture::DefineElement(Int_t iel, Int_t z, Int_t natoms)
proportion by number of atoms is converted now to proportion by mass.
TGeoManager: safety not computed again if the query point is the same
as for the last computed safety.
Revision
9311 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri Jun 25 11:59:56 2004 UTC (10 years, 7 months ago) by
brun
Original Path:
trunk/geom/src/TGeoMaterial.cxx
File length: 11322 byte(s)
Diff to
previous 8565
From Andrei Gheata:
- TGeoShape::PaintNext() removed from all shapes (for the new
visualization system to be introduced shortly).
The new mechanism is implemented in
TGeoPainter::PaintShape (uses gGeoManager as we discussed), but it also
affect some shapes (TGeoCompositeShape at least)
- New files: TGeoElement.h /.cxx representing a chemical element. This
is very helpful for the implementation of TFluka. Materials/mixtures can
be now built also based on this new class. An element table is kept
always transient in memory.
- Mihaela implemented the TGeoParaboloid shape: new files:
TGeoParaboloid.h/cxx.
Revision
8565 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Tue Apr 13 07:04:42 2004 UTC (10 years, 9 months ago) by
brun
Original Path:
trunk/geom/src/TGeoMaterial.cxx
File length: 9115 byte(s)
Diff to
previous 8078
From Andrei Gheata:
- All shapes.cxx - added shape name in InspectShape() + some corrections
in error messages (Bjorn requirement)
- TGeoAtt.cxx - activity flag added (not yet taken into account by tracking)
- TGeoMaterial/Medium - added Cerenkov properties by Andreas (for FLUKA)
- TGeoVolume.h, TGeoManager.k - added *TOGGLE* 's
- TGeoPhysicalNode - possibility to align a physical node. One can
define a physical node according a path, then change its local
transformation matrix OR shape - the corresponding branch is decoupled
from the logical tree and a new trackable branch is created. A
post-alignment check for overlaps can be perfomed for the aligned node.
Revision
7022 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Thu Jul 31 20:19:33 2003 UTC (11 years, 5 months ago) by
brun
Original Path:
trunk/geom/src/TGeoMaterial.cxx
File length: 8880 byte(s)
Diff to
previous 6136
From Andrei GHeata:
- TGeoManager::FindNormal(Bool_t forward=kTRUE) = global algorithm for
finding the normal to the next/previous crossed surface, from the
current global point/direction. The current point does not necessary
need to be close to the surface, and the normal direction is always
returned so that its dot product with the current direction is positive
defined. One can get the normal after its computation with:
Double_t *TGeoManager::GetNormal()
- Normal computation algorithms for box, arb8, trap, gtra, cone in the
corresponding shape classes.
- New primitive shape fully implemented, from visualization to
computation of distances (except the normal computation, missing also
for several other shapes). Class name: TGeoTorus, representing a torus
segment with :
- R - radius of the circle representing the torus axis
- Rmin - inner radius (like a donut having a hole in the middle)
- Rmax - outer radius (Rmin < Rmax < R)
- Phi1 - start phi
- Dphi - phi range
- Some unused obsolete methods removed from the TGeoShape class.
- modifications in TGeoIdentity default ctor to initialize gGeoIdentity
- TGeoMaterial::IsMixture(),
TGeoMaterial::FindDuplicateMaterial(const TGeoMaterial *mat)
- several other minor changes
Revision
6136 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Mon Feb 17 11:57:31 2003 UTC (11 years, 11 months ago) by
brun
Original Path:
trunk/geom/src/TGeoMaterial.cxx
File length: 8402 byte(s)
Diff to
previous 5848
m andrei;
TGeoManager :
- added TGeoManager::Safety() that computes the global safety for the
current point. This is just the first implementation, since it does not
use yet voxelization. This will be needed for the VMC because for the
time being safety is computed just for the crossed volumes along the
current direction plus the current volume, which of course is not enough
- finding the closest neighbour for a given point has to use a different
algorithm.
- added weight estimation for the top volume
TGeoMaterial :
- material index in the list of materials added as data member (as for
volumes) - I needed this for weight computation, but it will be helpfull
for any other analysis based on material indexing.
TGeoVolume :
- weight estimation method in the context menu of volumes : can be
verbose (default) or not and takes as argument the desired precision.
Prints error (1 x SIGMA)
TGeoChecker:
- implementation of weight estimation based on sampling random points
in the bounding box of a volume. Materials with rho<0.01 g/cm3 (mostly
gases) ignored due to the fact that we generally do not want to weight
the air in the top volume container (it can have quite significant mass)
other modified classes just provide redirection of Weight() method to
the geopainter package.
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.