Skip to content
Snippets Groups Projects
Commit 446072a8 authored by Rene Brun's avatar Rene Brun
Browse files

TGeoRotation::MultiplyBy was buggy. Fixed by Sue Kasahara

git-svn-id: http://root.cern.ch/svn/root/trunk@7551 27541ba8-7e3a-0410-8455-c3a389f83636
parent fdeff9b9
No related branches found
No related tags found
No related merge requests found
// @(#)root/geom:$Name: $:$Id: TGeoMatrix.cxx,v 1.12 2003/09/25 14:50:40 brun Exp $
// @(#)root/geom:$Name: $:$Id: TGeoMatrix.cxx,v 1.13 2003/10/01 17:53:12 brun Exp $
// Author: Andrei Gheata 25/10/01
/*************************************************************************
......@@ -829,7 +829,7 @@ void TGeoRotation::GetInverse(Double_t *invmat) const
void TGeoRotation::MultiplyBy(TGeoRotation *rot, Bool_t after)
{
const Double_t *matleft, *matright;
Double_t newmat[9];
Double_t newmat[9] = {0};
if (after) {
matleft = &fRotationMatrix[0];
matright = rot->GetRotationMatrix();
......@@ -840,7 +840,7 @@ void TGeoRotation::MultiplyBy(TGeoRotation *rot, Bool_t after)
for (Int_t i=0; i<3; i++) {
for (Int_t j=0; j<3; j++) {
for (Int_t k=0; k<3; k++) {
newmat[3*i+j] = matleft[3*i+k] * matright[3*k+j];
newmat[3*i+j] += matleft[3*i+k] * matright[3*k+j];
}
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment