37 #if !defined(R__SOLARIS) && !defined(R__ACC) && !defined(R__FBSD)
43 template<
class Element>
47 Error(
"Inv2x2",
"matrix should be square 2x2");
53 const Double_t det = pM[0] * pM[3] - pM[2] * pM[1];
60 Error(
"Inv2x2",
"matrix is singular");
75 template<
class Element>
79 Error(
"Inv3x3",
"matrix should be square 3x3");
85 const Double_t c00 = pM[4] * pM[8] - pM[5] * pM[7];
86 const Double_t c01 = pM[5] * pM[6] - pM[3] * pM[8];
87 const Double_t c02 = pM[3] * pM[7] - pM[4] * pM[6];
88 const Double_t c10 = pM[7] * pM[2] - pM[8] * pM[1];
89 const Double_t c11 = pM[8] * pM[0] - pM[6] * pM[2];
90 const Double_t c12 = pM[6] * pM[1] - pM[7] * pM[0];
91 const Double_t c20 = pM[1] * pM[5] - pM[2] * pM[4];
92 const Double_t c21 = pM[2] * pM[3] - pM[0] * pM[5];
93 const Double_t c22 = pM[0] * pM[4] - pM[1] * pM[3];
103 det = c12*c01-c11*c02;
106 det = c11*c22-c12*c21;
108 }
else if (t2 >= t1) {
110 det = c12*c01-c11*c02;
113 det = c02*c21-c01*c22;
116 if ( det == 0 || tmp == 0) {
117 Error(
"Inv3x3",
"matrix is singular");
162 template<
class Element>
166 Error(
"Inv4x4",
"matrix should be square 4x4");
196 + pM[
GF02]*det2_12_01;
198 + pM[
GF03]*det2_12_01;
200 + pM[
GF03]*det2_12_02;
202 + pM[
GF03]*det2_12_12;
204 + pM[
GF02]*det2_13_01;
206 + pM[
GF03]*det2_13_01;
208 + pM[
GF03]*det2_13_02;
210 + pM[
GF03]*det2_13_12;
212 + pM[
GF02]*det2_23_01;
214 + pM[
GF03]*det2_23_01;
216 + pM[
GF03]*det2_23_02;
218 + pM[
GF03]*det2_23_12;
220 + pM[
GF12]*det2_23_01;
222 + pM[
GF13]*det2_23_01;
224 + pM[
GF13]*det2_23_02;
226 + pM[
GF13]*det2_23_12;
231 + pM[
GF02]*det3_123_013 - pM[
GF03]*det3_123_012;
236 Error(
"Inv4x4",
"matrix is singular");
240 const Double_t oneOverDet = 1.0/det;
241 const Double_t mn1OverDet = - oneOverDet;
243 pM[
GF00] = det3_123_123 * oneOverDet;
244 pM[
GF01] = det3_023_123 * mn1OverDet;
245 pM[
GF02] = det3_013_123 * oneOverDet;
246 pM[
GF03] = det3_012_123 * mn1OverDet;
248 pM[
GF10] = det3_123_023 * mn1OverDet;
249 pM[
GF11] = det3_023_023 * oneOverDet;
250 pM[
GF12] = det3_013_023 * mn1OverDet;
251 pM[
GF13] = det3_012_023 * oneOverDet;
253 pM[
GF20] = det3_123_013 * oneOverDet;
254 pM[
GF21] = det3_023_013 * mn1OverDet;
255 pM[
GF22] = det3_013_013 * oneOverDet;
256 pM[
GF23] = det3_012_013 * mn1OverDet;
258 pM[
GF30] = det3_123_012 * mn1OverDet;
259 pM[
GF31] = det3_023_012 * oneOverDet;
260 pM[
GF32] = det3_013_012 * mn1OverDet;
261 pM[
GF33] = det3_012_012 * oneOverDet;
300 template<
class Element>
304 Error(
"Inv5x5",
"matrix should be square 5x5");
388 const Double_t det4_0123_0123 = pM[
GM00]*det3_123_123 - pM[
GM01]*det3_123_023
389 + pM[
GM02]*det3_123_013 - pM[
GM03]*det3_123_012;
390 const Double_t det4_0123_0124 = pM[
GM00]*det3_123_124 - pM[
GM01]*det3_123_024
391 + pM[
GM02]*det3_123_014 - pM[
GM04]*det3_123_012;
392 const Double_t det4_0123_0134 = pM[
GM00]*det3_123_134 - pM[
GM01]*det3_123_034
393 + pM[
GM03]*det3_123_014 - pM[
GM04]*det3_123_013;
394 const Double_t det4_0123_0234 = pM[
GM00]*det3_123_234 - pM[
GM02]*det3_123_034
395 + pM[
GM03]*det3_123_024 - pM[
GM04]*det3_123_023;
396 const Double_t det4_0123_1234 = pM[
GM01]*det3_123_234 - pM[
GM02]*det3_123_134
397 + pM[
GM03]*det3_123_124 - pM[
GM04]*det3_123_123;
398 const Double_t det4_0124_0123 = pM[
GM00]*det3_124_123 - pM[
GM01]*det3_124_023
399 + pM[
GM02]*det3_124_013 - pM[
GM03]*det3_124_012;
400 const Double_t det4_0124_0124 = pM[
GM00]*det3_124_124 - pM[
GM01]*det3_124_024
401 + pM[
GM02]*det3_124_014 - pM[
GM04]*det3_124_012;
402 const Double_t det4_0124_0134 = pM[
GM00]*det3_124_134 - pM[
GM01]*det3_124_034
403 + pM[
GM03]*det3_124_014 - pM[
GM04]*det3_124_013;
404 const Double_t det4_0124_0234 = pM[
GM00]*det3_124_234 - pM[
GM02]*det3_124_034
405 + pM[
GM03]*det3_124_024 - pM[
GM04]*det3_124_023;
406 const Double_t det4_0124_1234 = pM[
GM01]*det3_124_234 - pM[
GM02]*det3_124_134
407 + pM[
GM03]*det3_124_124 - pM[
GM04]*det3_124_123;
408 const Double_t det4_0134_0123 = pM[
GM00]*det3_134_123 - pM[
GM01]*det3_134_023
409 + pM[
GM02]*det3_134_013 - pM[
GM03]*det3_134_012;
410 const Double_t det4_0134_0124 = pM[
GM00]*det3_134_124 - pM[
GM01]*det3_134_024
411 + pM[
GM02]*det3_134_014 - pM[
GM04]*det3_134_012;
412 const Double_t det4_0134_0134 = pM[
GM00]*det3_134_134 - pM[
GM01]*det3_134_034
413 + pM[
GM03]*det3_134_014 - pM[
GM04]*det3_134_013;
414 const Double_t det4_0134_0234 = pM[
GM00]*det3_134_234 - pM[
GM02]*det3_134_034
415 + pM[
GM03]*det3_134_024 - pM[
GM04]*det3_134_023;
416 const Double_t det4_0134_1234 = pM[
GM01]*det3_134_234 - pM[
GM02]*det3_134_134
417 + pM[
GM03]*det3_134_124 - pM[
GM04]*det3_134_123;
418 const Double_t det4_0234_0123 = pM[
GM00]*det3_234_123 - pM[
GM01]*det3_234_023
419 + pM[
GM02]*det3_234_013 - pM[
GM03]*det3_234_012;
420 const Double_t det4_0234_0124 = pM[
GM00]*det3_234_124 - pM[
GM01]*det3_234_024
421 + pM[
GM02]*det3_234_014 - pM[
GM04]*det3_234_012;
422 const Double_t det4_0234_0134 = pM[
GM00]*det3_234_134 - pM[
GM01]*det3_234_034
423 + pM[
GM03]*det3_234_014 - pM[
GM04]*det3_234_013;
424 const Double_t det4_0234_0234 = pM[
GM00]*det3_234_234 - pM[
GM02]*det3_234_034
425 + pM[
GM03]*det3_234_024 - pM[
GM04]*det3_234_023;
426 const Double_t det4_0234_1234 = pM[
GM01]*det3_234_234 - pM[
GM02]*det3_234_134
427 + pM[
GM03]*det3_234_124 - pM[
GM04]*det3_234_123;
428 const Double_t det4_1234_0123 = pM[
GM10]*det3_234_123 - pM[
GM11]*det3_234_023
429 + pM[
GM12]*det3_234_013 - pM[
GM13]*det3_234_012;
430 const Double_t det4_1234_0124 = pM[
GM10]*det3_234_124 - pM[
GM11]*det3_234_024
431 + pM[
GM12]*det3_234_014 - pM[
GM14]*det3_234_012;
432 const Double_t det4_1234_0134 = pM[
GM10]*det3_234_134 - pM[
GM11]*det3_234_034
433 + pM[
GM13]*det3_234_014 - pM[
GM14]*det3_234_013;
434 const Double_t det4_1234_0234 = pM[
GM10]*det3_234_234 - pM[
GM12]*det3_234_034
435 + pM[
GM13]*det3_234_024 - pM[
GM14]*det3_234_023;
436 const Double_t det4_1234_1234 = pM[
GM11]*det3_234_234 - pM[
GM12]*det3_234_134
437 + pM[
GM13]*det3_234_124 - pM[
GM14]*det3_234_123;
441 const Double_t det = pM[
GM00]*det4_1234_1234 - pM[
GM01]*det4_1234_0234 + pM[
GM02]*det4_1234_0134
442 - pM[
GM03]*det4_1234_0124 + pM[
GM04]*det4_1234_0123;
447 Error(
"Inv5x5",
"matrix is singular");
451 const Double_t oneOverDet = 1.0/det;
452 const Double_t mn1OverDet = - oneOverDet;
454 pM[
GM00] = det4_1234_1234 * oneOverDet;
455 pM[
GM01] = det4_0234_1234 * mn1OverDet;
456 pM[
GM02] = det4_0134_1234 * oneOverDet;
457 pM[
GM03] = det4_0124_1234 * mn1OverDet;
458 pM[
GM04] = det4_0123_1234 * oneOverDet;
460 pM[
GM10] = det4_1234_0234 * mn1OverDet;
461 pM[
GM11] = det4_0234_0234 * oneOverDet;
462 pM[
GM12] = det4_0134_0234 * mn1OverDet;
463 pM[
GM13] = det4_0124_0234 * oneOverDet;
464 pM[
GM14] = det4_0123_0234 * mn1OverDet;
466 pM[
GM20] = det4_1234_0134 * oneOverDet;
467 pM[
GM21] = det4_0234_0134 * mn1OverDet;
468 pM[
GM22] = det4_0134_0134 * oneOverDet;
469 pM[
GM23] = det4_0124_0134 * mn1OverDet;
470 pM[
GM24] = det4_0123_0134 * oneOverDet;
472 pM[
GM30] = det4_1234_0124 * mn1OverDet;
473 pM[
GM31] = det4_0234_0124 * oneOverDet;
474 pM[
GM32] = det4_0134_0124 * mn1OverDet;
475 pM[
GM33] = det4_0124_0124 * oneOverDet;
476 pM[
GM34] = det4_0123_0124 * mn1OverDet;
478 pM[
GM40] = det4_1234_0123 * oneOverDet;
479 pM[
GM41] = det4_0234_0123 * mn1OverDet;
480 pM[
GM42] = det4_0134_0123 * oneOverDet;
481 pM[
GM43] = det4_0124_0123 * mn1OverDet;
482 pM[
GM44] = det4_0123_0123 * oneOverDet;
533 template<
class Element>
537 Error(
"Inv6x6",
"matrix should be square 6x6");
676 const Double_t det4_1234_0123 = pM[
GA10]*det3_234_123 - pM[
GA11]*det3_234_023
677 + pM[
GA12]*det3_234_013 - pM[
GA13]*det3_234_012;
678 const Double_t det4_1234_0124 = pM[
GA10]*det3_234_124 - pM[
GA11]*det3_234_024
679 + pM[
GA12]*det3_234_014 - pM[
GA14]*det3_234_012;
680 const Double_t det4_1234_0125 = pM[
GA10]*det3_234_125 - pM[
GA11]*det3_234_025
681 + pM[
GA12]*det3_234_015 - pM[
GA15]*det3_234_012;
682 const Double_t det4_1234_0134 = pM[
GA10]*det3_234_134 - pM[
GA11]*det3_234_034
683 + pM[
GA13]*det3_234_014 - pM[
GA14]*det3_234_013;
684 const Double_t det4_1234_0135 = pM[
GA10]*det3_234_135 - pM[
GA11]*det3_234_035
685 + pM[
GA13]*det3_234_015 - pM[
GA15]*det3_234_013;
686 const Double_t det4_1234_0145 = pM[
GA10]*det3_234_145 - pM[
GA11]*det3_234_045
687 + pM[
GA14]*det3_234_015 - pM[
GA15]*det3_234_014;
688 const Double_t det4_1234_0234 = pM[
GA10]*det3_234_234 - pM[
GA12]*det3_234_034
689 + pM[
GA13]*det3_234_024 - pM[
GA14]*det3_234_023;
690 const Double_t det4_1234_0235 = pM[
GA10]*det3_234_235 - pM[
GA12]*det3_234_035
691 + pM[
GA13]*det3_234_025 - pM[
GA15]*det3_234_023;
692 const Double_t det4_1234_0245 = pM[
GA10]*det3_234_245 - pM[
GA12]*det3_234_045
693 + pM[
GA14]*det3_234_025 - pM[
GA15]*det3_234_024;
694 const Double_t det4_1234_0345 = pM[
GA10]*det3_234_345 - pM[
GA13]*det3_234_045
695 + pM[
GA14]*det3_234_035 - pM[
GA15]*det3_234_034;
696 const Double_t det4_1234_1234 = pM[
GA11]*det3_234_234 - pM[
GA12]*det3_234_134
697 + pM[
GA13]*det3_234_124 - pM[
GA14]*det3_234_123;
698 const Double_t det4_1234_1235 = pM[
GA11]*det3_234_235 - pM[
GA12]*det3_234_135
699 + pM[
GA13]*det3_234_125 - pM[
GA15]*det3_234_123;
700 const Double_t det4_1234_1245 = pM[
GA11]*det3_234_245 - pM[
GA12]*det3_234_145
701 + pM[
GA14]*det3_234_125 - pM[
GA15]*det3_234_124;
702 const Double_t det4_1234_1345 = pM[
GA11]*det3_234_345 - pM[
GA13]*det3_234_145
703 + pM[
GA14]*det3_234_135 - pM[
GA15]*det3_234_134;
704 const Double_t det4_1234_2345 = pM[
GA12]*det3_234_345 - pM[
GA13]*det3_234_245
705 + pM[
GA14]*det3_234_235 - pM[
GA15]*det3_234_234;
706 const Double_t det4_1235_0123 = pM[
GA10]*det3_235_123 - pM[
GA11]*det3_235_023
707 + pM[
GA12]*det3_235_013 - pM[
GA13]*det3_235_012;
708 const Double_t det4_1235_0124 = pM[
GA10]*det3_235_124 - pM[
GA11]*det3_235_024
709 + pM[
GA12]*det3_235_014 - pM[
GA14]*det3_235_012;
710 const Double_t det4_1235_0125 = pM[
GA10]*det3_235_125 - pM[
GA11]*det3_235_025
711 + pM[
GA12]*det3_235_015 - pM[
GA15]*det3_235_012;
712 const Double_t det4_1235_0134 = pM[
GA10]*det3_235_134 - pM[
GA11]*det3_235_034
713 + pM[
GA13]*det3_235_014 - pM[
GA14]*det3_235_013;
714 const Double_t det4_1235_0135 = pM[
GA10]*det3_235_135 - pM[
GA11]*det3_235_035
715 + pM[
GA13]*det3_235_015 - pM[
GA15]*det3_235_013;
716 const Double_t det4_1235_0145 = pM[
GA10]*det3_235_145 - pM[
GA11]*det3_235_045
717 + pM[
GA14]*det3_235_015 - pM[
GA15]*det3_235_014;
718 const Double_t det4_1235_0234 = pM[
GA10]*det3_235_234 - pM[
GA12]*det3_235_034
719 + pM[
GA13]*det3_235_024 - pM[
GA14]*det3_235_023;
720 const Double_t det4_1235_0235 = pM[
GA10]*det3_235_235 - pM[
GA12]*det3_235_035
721 + pM[
GA13]*det3_235_025 - pM[
GA15]*det3_235_023;
722 const Double_t det4_1235_0245 = pM[
GA10]*det3_235_245 - pM[
GA12]*det3_235_045
723 + pM[
GA14]*det3_235_025 - pM[
GA15]*det3_235_024;
724 const Double_t det4_1235_0345 = pM[
GA10]*det3_235_345 - pM[
GA13]*det3_235_045
725 + pM[
GA14]*det3_235_035 - pM[
GA15]*det3_235_034;
726 const Double_t det4_1235_1234 = pM[
GA11]*det3_235_234 - pM[
GA12]*det3_235_134
727 + pM[
GA13]*det3_235_124 - pM[
GA14]*det3_235_123;
728 const Double_t det4_1235_1235 = pM[
GA11]*det3_235_235 - pM[
GA12]*det3_235_135
729 + pM[
GA13]*det3_235_125 - pM[
GA15]*det3_235_123;
730 const Double_t det4_1235_1245 = pM[
GA11]*det3_235_245 - pM[
GA12]*det3_235_145
731 + pM[
GA14]*det3_235_125 - pM[
GA15]*det3_235_124;
732 const Double_t det4_1235_1345 = pM[
GA11]*det3_235_345 - pM[
GA13]*det3_235_145
733 + pM[
GA14]*det3_235_135 - pM[
GA15]*det3_235_134;
734 const Double_t det4_1235_2345 = pM[
GA12]*det3_235_345 - pM[
GA13]*det3_235_245
735 + pM[
GA14]*det3_235_235 - pM[
GA15]*det3_235_234;
736 const Double_t det4_1245_0123 = pM[
GA10]*det3_245_123 - pM[
GA11]*det3_245_023
737 + pM[
GA12]*det3_245_013 - pM[
GA13]*det3_245_012;
738 const Double_t det4_1245_0124 = pM[
GA10]*det3_245_124 - pM[
GA11]*det3_245_024
739 + pM[
GA12]*det3_245_014 - pM[
GA14]*det3_245_012;
740 const Double_t det4_1245_0125 = pM[
GA10]*det3_245_125 - pM[
GA11]*det3_245_025
741 + pM[
GA12]*det3_245_015 - pM[
GA15]*det3_245_012;
742 const Double_t det4_1245_0134 = pM[
GA10]*det3_245_134 - pM[
GA11]*det3_245_034
743 + pM[
GA13]*det3_245_014 - pM[
GA14]*det3_245_013;
744 const Double_t det4_1245_0135 = pM[
GA10]*det3_245_135 - pM[
GA11]*det3_245_035
745 + pM[
GA13]*det3_245_015 - pM[
GA15]*det3_245_013;
746 const Double_t det4_1245_0145 = pM[
GA10]*det3_245_145 - pM[
GA11]*det3_245_045
747 + pM[
GA14]*det3_245_015 - pM[
GA15]*det3_245_014;
748 const Double_t det4_1245_0234 = pM[
GA10]*det3_245_234 - pM[
GA12]*det3_245_034
749 + pM[
GA13]*det3_245_024 - pM[
GA14]*det3_245_023;
750 const Double_t det4_1245_0235 = pM[
GA10]*det3_245_235 - pM[
GA12]*det3_245_035
751 + pM[
GA13]*det3_245_025 - pM[
GA15]*det3_245_023;
752 const Double_t det4_1245_0245 = pM[
GA10]*det3_245_245 - pM[
GA12]*det3_245_045
753 + pM[
GA14]*det3_245_025 - pM[
GA15]*det3_245_024;
754 const Double_t det4_1245_0345 = pM[
GA10]*det3_245_345 - pM[
GA13]*det3_245_045
755 + pM[
GA14]*det3_245_035 - pM[
GA15]*det3_245_034;
756 const Double_t det4_1245_1234 = pM[
GA11]*det3_245_234 - pM[
GA12]*det3_245_134
757 + pM[
GA13]*det3_245_124 - pM[
GA14]*det3_245_123;
758 const Double_t det4_1245_1235 = pM[
GA11]*det3_245_235 - pM[
GA12]*det3_245_135
759 + pM[
GA13]*det3_245_125 - pM[
GA15]*det3_245_123;
760 const Double_t det4_1245_1245 = pM[
GA11]*det3_245_245 - pM[
GA12]*det3_245_145
761 + pM[
GA14]*det3_245_125 - pM[
GA15]*det3_245_124;
762 const Double_t det4_1245_1345 = pM[
GA11]*det3_245_345 - pM[
GA13]*det3_245_145
763 + pM[
GA14]*det3_245_135 - pM[
GA15]*det3_245_134;
764 const Double_t det4_1245_2345 = pM[
GA12]*det3_245_345 - pM[
GA13]*det3_245_245
765 + pM[
GA14]*det3_245_235 - pM[
GA15]*det3_245_234;
766 const Double_t det4_1345_0123 = pM[
GA10]*det3_345_123 - pM[
GA11]*det3_345_023
767 + pM[
GA12]*det3_345_013 - pM[
GA13]*det3_345_012;
768 const Double_t det4_1345_0124 = pM[
GA10]*det3_345_124 - pM[
GA11]*det3_345_024
769 + pM[
GA12]*det3_345_014 - pM[
GA14]*det3_345_012;
770 const Double_t det4_1345_0125 = pM[
GA10]*det3_345_125 - pM[
GA11]*det3_345_025
771 + pM[
GA12]*det3_345_015 - pM[
GA15]*det3_345_012;
772 const Double_t det4_1345_0134 = pM[
GA10]*det3_345_134 - pM[
GA11]*det3_345_034
773 + pM[
GA13]*det3_345_014 - pM[
GA14]*det3_345_013;
774 const Double_t det4_1345_0135 = pM[
GA10]*det3_345_135 - pM[
GA11]*det3_345_035
775 + pM[
GA13]*det3_345_015 - pM[
GA15]*det3_345_013;
776 const Double_t det4_1345_0145 = pM[
GA10]*det3_345_145 - pM[
GA11]*det3_345_045
777 + pM[
GA14]*det3_345_015 - pM[
GA15]*det3_345_014;
778 const Double_t det4_1345_0234 = pM[
GA10]*det3_345_234 - pM[
GA12]*det3_345_034
779 + pM[
GA13]*det3_345_024 - pM[
GA14]*det3_345_023;
780 const Double_t det4_1345_0235 = pM[
GA10]*det3_345_235 - pM[
GA12]*det3_345_035
781 + pM[
GA13]*det3_345_025 - pM[
GA15]*det3_345_023;
782 const Double_t det4_1345_0245 = pM[
GA10]*det3_345_245 - pM[
GA12]*det3_345_045
783 + pM[
GA14]*det3_345_025 - pM[
GA15]*det3_345_024;
784 const Double_t det4_1345_0345 = pM[
GA10]*det3_345_345 - pM[
GA13]*det3_345_045
785 + pM[
GA14]*det3_345_035 - pM[
GA15]*det3_345_034;
786 const Double_t det4_1345_1234 = pM[
GA11]*det3_345_234 - pM[
GA12]*det3_345_134
787 + pM[
GA13]*det3_345_124 - pM[
GA14]*det3_345_123;
788 const Double_t det4_1345_1235 = pM[
GA11]*det3_345_235 - pM[
GA12]*det3_345_135
789 + pM[
GA13]*det3_345_125 - pM[
GA15]*det3_345_123;
790 const Double_t det4_1345_1245 = pM[
GA11]*det3_345_245 - pM[
GA12]*det3_345_145
791 + pM[
GA14]*det3_345_125 - pM[
GA15]*det3_345_124;
792 const Double_t det4_1345_1345 = pM[
GA11]*det3_345_345 - pM[
GA13]*det3_345_145
793 + pM[
GA14]*det3_345_135 - pM[
GA15]*det3_345_134;
794 const Double_t det4_1345_2345 = pM[
GA12]*det3_345_345 - pM[
GA13]*det3_345_245
795 + pM[
GA14]*det3_345_235 - pM[
GA15]*det3_345_234;
796 const Double_t det4_2345_0123 = pM[
GA20]*det3_345_123 - pM[
GA21]*det3_345_023
797 + pM[
GA22]*det3_345_013 - pM[
GA23]*det3_345_012;
798 const Double_t det4_2345_0124 = pM[
GA20]*det3_345_124 - pM[
GA21]*det3_345_024
799 + pM[
GA22]*det3_345_014 - pM[
GA24]*det3_345_012;
800 const Double_t det4_2345_0125 = pM[
GA20]*det3_345_125 - pM[
GA21]*det3_345_025
801 + pM[
GA22]*det3_345_015 - pM[
GA25]*det3_345_012;
802 const Double_t det4_2345_0134 = pM[
GA20]*det3_345_134 - pM[
GA21]*det3_345_034
803 + pM[
GA23]*det3_345_014 - pM[
GA24]*det3_345_013;
804 const Double_t det4_2345_0135 = pM[
GA20]*det3_345_135 - pM[
GA21]*det3_345_035
805 + pM[
GA23]*det3_345_015 - pM[
GA25]*det3_345_013;
806 const Double_t det4_2345_0145 = pM[
GA20]*det3_345_145 - pM[
GA21]*det3_345_045
807 + pM[
GA24]*det3_345_015 - pM[
GA25]*det3_345_014;
808 const Double_t det4_2345_0234 = pM[
GA20]*det3_345_234 - pM[
GA22]*det3_345_034
809 + pM[
GA23]*det3_345_024 - pM[
GA24]*det3_345_023;
810 const Double_t det4_2345_0235 = pM[
GA20]*det3_345_235 - pM[
GA22]*det3_345_035
811 + pM[
GA23]*det3_345_025 - pM[
GA25]*det3_345_023;
812 const Double_t det4_2345_0245 = pM[
GA20]*det3_345_245 - pM[
GA22]*det3_345_045
813 + pM[
GA24]*det3_345_025 - pM[
GA25]*det3_345_024;
814 const Double_t det4_2345_0345 = pM[
GA20]*det3_345_345 - pM[
GA23]*det3_345_045
815 + pM[
GA24]*det3_345_035 - pM[
GA25]*det3_345_034;
816 const Double_t det4_2345_1234 = pM[
GA21]*det3_345_234 - pM[
GA22]*det3_345_134
817 + pM[
GA23]*det3_345_124 - pM[
GA24]*det3_345_123;
818 const Double_t det4_2345_1235 = pM[
GA21]*det3_345_235 - pM[
GA22]*det3_345_135
819 + pM[
GA23]*det3_345_125 - pM[
GA25]*det3_345_123;
820 const Double_t det4_2345_1245 = pM[
GA21]*det3_345_245 - pM[
GA22]*det3_345_145
821 + pM[
GA24]*det3_345_125 - pM[
GA25]*det3_345_124;
822 const Double_t det4_2345_1345 = pM[
GA21]*det3_345_345 - pM[
GA23]*det3_345_145
823 + pM[
GA24]*det3_345_135 - pM[
GA25]*det3_345_134;
824 const Double_t det4_2345_2345 = pM[
GA22]*det3_345_345 - pM[
GA23]*det3_345_245
825 + pM[
GA24]*det3_345_235 - pM[
GA25]*det3_345_234;
829 const Double_t det5_01234_01234 = pM[
GA00]*det4_1234_1234 - pM[
GA01]*det4_1234_0234
830 + pM[
GA02]*det4_1234_0134 - pM[
GA03]*det4_1234_0124 + pM[
GA04]*det4_1234_0123;
831 const Double_t det5_01234_01235 = pM[
GA00]*det4_1234_1235 - pM[
GA01]*det4_1234_0235
832 + pM[
GA02]*det4_1234_0135 - pM[
GA03]*det4_1234_0125 + pM[
GA05]*det4_1234_0123;
833 const Double_t det5_01234_01245 = pM[
GA00]*det4_1234_1245 - pM[
GA01]*det4_1234_0245
834 + pM[
GA02]*det4_1234_0145 - pM[
GA04]*det4_1234_0125 + pM[
GA05]*det4_1234_0124;
835 const Double_t det5_01234_01345 = pM[
GA00]*det4_1234_1345 - pM[
GA01]*det4_1234_0345
836 + pM[
GA03]*det4_1234_0145 - pM[
GA04]*det4_1234_0135 + pM[
GA05]*det4_1234_0134;
837 const Double_t det5_01234_02345 = pM[
GA00]*det4_1234_2345 - pM[
GA02]*det4_1234_0345
838 + pM[
GA03]*det4_1234_0245 - pM[
GA04]*det4_1234_0235 + pM[
GA05]*det4_1234_0234;
839 const Double_t det5_01234_12345 = pM[
GA01]*det4_1234_2345 - pM[
GA02]*det4_1234_1345
840 + pM[
GA03]*det4_1234_1245 - pM[
GA04]*det4_1234_1235 + pM[
GA05]*det4_1234_1234;
841 const Double_t det5_01235_01234 = pM[
GA00]*det4_1235_1234 - pM[
GA01]*det4_1235_0234
842 + pM[
GA02]*det4_1235_0134 - pM[
GA03]*det4_1235_0124 + pM[
GA04]*det4_1235_0123;
843 const Double_t det5_01235_01235 = pM[
GA00]*det4_1235_1235 - pM[
GA01]*det4_1235_0235
844 + pM[
GA02]*det4_1235_0135 - pM[
GA03]*det4_1235_0125 + pM[
GA05]*det4_1235_0123;
845 const Double_t det5_01235_01245 = pM[
GA00]*det4_1235_1245 - pM[
GA01]*det4_1235_0245
846 + pM[
GA02]*det4_1235_0145 - pM[
GA04]*det4_1235_0125 + pM[
GA05]*det4_1235_0124;
847 const Double_t det5_01235_01345 = pM[
GA00]*det4_1235_1345 - pM[
GA01]*det4_1235_0345
848 + pM[
GA03]*det4_1235_0145 - pM[
GA04]*det4_1235_0135 + pM[
GA05]*det4_1235_0134;
849 const Double_t det5_01235_02345 = pM[
GA00]*det4_1235_2345 - pM[
GA02]*det4_1235_0345
850 + pM[
GA03]*det4_1235_0245 - pM[
GA04]*det4_1235_0235 + pM[
GA05]*det4_1235_0234;
851 const Double_t det5_01235_12345 = pM[
GA01]*det4_1235_2345 - pM[
GA02]*det4_1235_1345
852 + pM[
GA03]*det4_1235_1245 - pM[
GA04]*det4_1235_1235 + pM[
GA05]*det4_1235_1234;
853 const Double_t det5_01245_01234 = pM[
GA00]*det4_1245_1234 - pM[
GA01]*det4_1245_0234
854 + pM[
GA02]*det4_1245_0134 - pM[
GA03]*det4_1245_0124 + pM[
GA04]*det4_1245_0123;
855 const Double_t det5_01245_01235 = pM[
GA00]*det4_1245_1235 - pM[
GA01]*det4_1245_0235
856 + pM[
GA02]*det4_1245_0135 - pM[
GA03]*det4_1245_0125 + pM[
GA05]*det4_1245_0123;
857 const Double_t det5_01245_01245 = pM[
GA00]*det4_1245_1245 - pM[
GA01]*det4_1245_0245
858 + pM[
GA02]*det4_1245_0145 - pM[
GA04]*det4_1245_0125 + pM[
GA05]*det4_1245_0124;
859 const Double_t det5_01245_01345 = pM[
GA00]*det4_1245_1345 - pM[
GA01]*det4_1245_0345
860 + pM[
GA03]*det4_1245_0145 - pM[
GA04]*det4_1245_0135 + pM[
GA05]*det4_1245_0134;
861 const Double_t det5_01245_02345 = pM[
GA00]*det4_1245_2345 - pM[
GA02]*det4_1245_0345
862 + pM[
GA03]*det4_1245_0245 - pM[
GA04]*det4_1245_0235 + pM[
GA05]*det4_1245_0234;
863 const Double_t det5_01245_12345 = pM[
GA01]*det4_1245_2345 - pM[
GA02]*det4_1245_1345
864 + pM[
GA03]*det4_1245_1245 - pM[
GA04]*det4_1245_1235 + pM[
GA05]*det4_1245_1234;
865 const Double_t det5_01345_01234 = pM[
GA00]*det4_1345_1234 - pM[
GA01]*det4_1345_0234
866 + pM[
GA02]*det4_1345_0134 - pM[
GA03]*det4_1345_0124 + pM[
GA04]*det4_1345_0123;
867 const Double_t det5_01345_01235 = pM[
GA00]*det4_1345_1235 - pM[
GA01]*det4_1345_0235
868 + pM[
GA02]*det4_1345_0135 - pM[
GA03]*det4_1345_0125 + pM[
GA05]*det4_1345_0123;
869 const Double_t det5_01345_01245 = pM[
GA00]*det4_1345_1245 - pM[
GA01]*det4_1345_0245
870 + pM[
GA02]*det4_1345_0145 - pM[
GA04]*det4_1345_0125 + pM[
GA05]*det4_1345_0124;
871 const Double_t det5_01345_01345 = pM[
GA00]*det4_1345_1345 - pM[
GA01]*det4_1345_0345
872 + pM[
GA03]*det4_1345_0145 - pM[
GA04]*det4_1345_0135 + pM[
GA05]*det4_1345_0134;
873 const Double_t det5_01345_02345 = pM[
GA00]*det4_1345_2345 - pM[
GA02]*det4_1345_0345
874 + pM[
GA03]*det4_1345_0245 - pM[
GA04]*det4_1345_0235 + pM[
GA05]*det4_1345_0234;
875 const Double_t det5_01345_12345 = pM[
GA01]*det4_1345_2345 - pM[
GA02]*det4_1345_1345
876 + pM[
GA03]*det4_1345_1245 - pM[
GA04]*det4_1345_1235 + pM[
GA05]*det4_1345_1234;
877 const Double_t det5_02345_01234 = pM[
GA00]*det4_2345_1234 - pM[
GA01]*det4_2345_0234
878 + pM[
GA02]*det4_2345_0134 - pM[
GA03]*det4_2345_0124 + pM[
GA04]*det4_2345_0123;
879 const Double_t det5_02345_01235 = pM[
GA00]*det4_2345_1235 - pM[
GA01]*det4_2345_0235
880 + pM[
GA02]*det4_2345_0135 - pM[
GA03]*det4_2345_0125 + pM[
GA05]*det4_2345_0123;
881 const Double_t det5_02345_01245 = pM[
GA00]*det4_2345_1245 - pM[
GA01]*det4_2345_0245
882 + pM[
GA02]*det4_2345_0145 - pM[
GA04]*det4_2345_0125 + pM[
GA05]*det4_2345_0124;
883 const Double_t det5_02345_01345 = pM[
GA00]*det4_2345_1345 - pM[
GA01]*det4_2345_0345
884 + pM[
GA03]*det4_2345_0145 - pM[
GA04]*det4_2345_0135 + pM[
GA05]*det4_2345_0134;
885 const Double_t det5_02345_02345 = pM[
GA00]*det4_2345_2345 - pM[
GA02]*det4_2345_0345
886 + pM[
GA03]*det4_2345_0245 - pM[
GA04]*det4_2345_0235 + pM[
GA05]*det4_2345_0234;
887 const Double_t det5_02345_12345 = pM[
GA01]*det4_2345_2345 - pM[
GA02]*det4_2345_1345
888 + pM[
GA03]*det4_2345_1245 - pM[
GA04]*det4_2345_1235 + pM[
GA05]*det4_2345_1234;
889 const Double_t det5_12345_01234 = pM[
GA10]*det4_2345_1234 - pM[
GA11]*det4_2345_0234
890 + pM[
GA12]*det4_2345_0134 - pM[
GA13]*det4_2345_0124 + pM[
GA14]*det4_2345_0123;
891 const Double_t det5_12345_01235 = pM[
GA10]*det4_2345_1235 - pM[
GA11]*det4_2345_0235
892 + pM[
GA12]*det4_2345_0135 - pM[
GA13]*det4_2345_0125 + pM[
GA15]*det4_2345_0123;
893 const Double_t det5_12345_01245 = pM[
GA10]*det4_2345_1245 - pM[
GA11]*det4_2345_0245
894 + pM[
GA12]*det4_2345_0145 - pM[
GA14]*det4_2345_0125 + pM[
GA15]*det4_2345_0124;
895 const Double_t det5_12345_01345 = pM[
GA10]*det4_2345_1345 - pM[
GA11]*det4_2345_0345
896 + pM[
GA13]*det4_2345_0145 - pM[
GA14]*det4_2345_0135 + pM[
GA15]*det4_2345_0134;
897 const Double_t det5_12345_02345 = pM[
GA10]*det4_2345_2345 - pM[
GA12]*det4_2345_0345
898 + pM[
GA13]*det4_2345_0245 - pM[
GA14]*det4_2345_0235 + pM[
GA15]*det4_2345_0234;
899 const Double_t det5_12345_12345 = pM[
GA11]*det4_2345_2345 - pM[
GA12]*det4_2345_1345
900 + pM[
GA13]*det4_2345_1245 - pM[
GA14]*det4_2345_1235 + pM[
GA15]*det4_2345_1234;
904 const Double_t det = pM[
GA00]*det5_12345_12345 - pM[
GA01]*det5_12345_02345 + pM[
GA02]*det5_12345_01345
905 - pM[
GA03]*det5_12345_01245 + pM[
GA04]*det5_12345_01235 - pM[
GA05]*det5_12345_01234;
910 Error(
"Inv6x6",
"matrix is singular");
914 const Double_t oneOverDet = 1.0/det;
915 const Double_t mn1OverDet = - oneOverDet;
917 pM[
GA00] = det5_12345_12345*oneOverDet;
918 pM[
GA01] = det5_02345_12345*mn1OverDet;
919 pM[
GA02] = det5_01345_12345*oneOverDet;
920 pM[
GA03] = det5_01245_12345*mn1OverDet;
921 pM[
GA04] = det5_01235_12345*oneOverDet;
922 pM[
GA05] = det5_01234_12345*mn1OverDet;
924 pM[
GA10] = det5_12345_02345*mn1OverDet;
925 pM[
GA11] = det5_02345_02345*oneOverDet;
926 pM[
GA12] = det5_01345_02345*mn1OverDet;
927 pM[
GA13] = det5_01245_02345*oneOverDet;
928 pM[
GA14] = det5_01235_02345*mn1OverDet;
929 pM[
GA15] = det5_01234_02345*oneOverDet;
931 pM[
GA20] = det5_12345_01345*oneOverDet;
932 pM[
GA21] = det5_02345_01345*mn1OverDet;
933 pM[
GA22] = det5_01345_01345*oneOverDet;
934 pM[
GA23] = det5_01245_01345*mn1OverDet;
935 pM[
GA24] = det5_01235_01345*oneOverDet;
936 pM[
GA25] = det5_01234_01345*mn1OverDet;
938 pM[
GA30] = det5_12345_01245*mn1OverDet;
939 pM[
GA31] = det5_02345_01245*oneOverDet;
940 pM[
GA32] = det5_01345_01245*mn1OverDet;
941 pM[
GA33] = det5_01245_01245*oneOverDet;
942 pM[
GA34] = det5_01235_01245*mn1OverDet;
943 pM[
GA35] = det5_01234_01245*oneOverDet;
945 pM[
GA40] = det5_12345_01235*oneOverDet;
946 pM[
GA41] = det5_02345_01235*mn1OverDet;
947 pM[
GA42] = det5_01345_01235*oneOverDet;
948 pM[
GA43] = det5_01245_01235*mn1OverDet;
949 pM[
GA44] = det5_01235_01235*oneOverDet;
950 pM[
GA45] = det5_01234_01235*mn1OverDet;
952 pM[
GA50] = det5_12345_01234*mn1OverDet;
953 pM[
GA51] = det5_02345_01234*oneOverDet;
954 pM[
GA52] = det5_01345_01234*mn1OverDet;
955 pM[
GA53] = det5_01245_01234*oneOverDet;
956 pM[
GA54] = det5_01235_01234*mn1OverDet;
957 pM[
GA55] = det5_01234_01234*oneOverDet;
962 #ifndef ROOT_TMatrixFfwd
972 #ifndef ROOT_TMatrixDfwd
Bool_t Inv5x5(TMatrixT< Element > &m, Double_t *determ)
Bool_t Inv3x3(TMatrixT< Element > &m, Double_t *determ)
void Error(const char *location, const char *msgfmt,...)
virtual const Element * GetMatrixArray() const
NamespaceImp(TMatrixTCramerInv)
Bool_t Inv2x2(TMatrixT< Element > &m, Double_t *determ)
Bool_t Inv6x6(TMatrixT< Element > &m, Double_t *determ)
Bool_t Inv4x4(TMatrixT< Element > &m, Double_t *determ)