Bugfix in AliPoints2Memory
[u/mrichter/AliRoot.git] / GEANT321 / ggeom / grmul.F
CommitLineData
fe4da5cc 1*
2* $Id$
3*
4* $Log$
5* Revision 1.1.1.1 1995/10/24 10:20:54 cernlib
6* Geant
7*
8*
9#include "geant321/pilot.h"
10*CMZ : 3.21/02 29/03/94 15.41.30 by S.Giani
11*-- Author :
12 SUBROUTINE GRMUL(RMAT,IROT,RMATN)
13C.
14C. ******************************************************************
15C. * *
16C * ROUTINE MULTIPLIES ROTATION MATRIX RMAT BY THE *
17C * IROT TH MATRIX IN THE GEANT ROTATION MATRIX BANK *
18C * TO PRODUCE THE MATRIX RMATN SUCH THAT RMATN IS *
19C * THE RESULT OF FIRST RMAT THEN IROT. *
20C * *
21C. * ==>Called by : GTRMUL *
22C. * Author A.McPherson ********* *
23C. * *
24C. ******************************************************************
25C.
26#include "geant321/gcbank.inc"
27 DIMENSION RMAT(10),RMATN(10)
28C.
29C. ------------------------------------------------------------------
30C.
31 IF(IROT.EQ.0) THEN
32 DO 10 I=1,10
33 RMATN(I)=RMAT(I)
34 10 CONTINUE
35 ELSE
36 JR=LQ(JROTM-IROT)
37 RMATN(10)=1.
38 IF(RMAT(10).EQ.0.0) THEN
39 DO 20 I=1,9
40 RMATN(I)=Q(JR+I)
41 20 CONTINUE
42 ELSE
43C
44 DO 30 KO=1,9
45 RMATN(KO)=0.0
46C
47 KO1=(KO-1)/3+1
48 KO2=KO-(KO1-1)*3
49C
50 DO 30 IN=1,3
51 KI1=KO2+(IN-1)*3
52 KI2=IN+(KO1-1)*3
53 RMATN(KO)=RMATN(KO)+RMAT(KI1)*Q(JR+KI2)
54 30 CONTINUE
55 ENDIF
56 ENDIF
57 END