reduce2.example.p.7 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688
  1. REDUCE2(15-SEP-72 (UM 1-JUNE-73)) ...
  2. COMMENT SOME EXAMPLES OF THE F O R STATEMENT;
  3. COMMENT SUMMING THE SQUARES OF THE EVEN POSITIVE INTEGERS THROUGH 50;
  4. FOR I:=2 STEP 2 UNTIL 50 SUM I**2;
  5. 22100
  6. COMMENT TO SET XXX TO THE FACTORIAL OF 10;
  7. XXX:=FOR I:=1:10 PRODUCT I;
  8. XXX:=3628800
  9. COMMENT ALTERNATIVELY, WE COULD SET THE ELEMENTS A(I) OF THE ARRAY A TO THE FACTORIAL OF I BY THE STATEMENTS;
  10. ARRAY A(10);
  11. A(0):=1$
  12. FOR I:=1:10 DO A(I):=I*A(I - 1);
  13. COMMENT THE ABOVE VERSION OF THE F O R STATEMENT DOES NOT RETURN AN ALGEBRAIC VALUE, BUT WE CAN NOW USE THESE
  14. ARRAY ELEMENTS AS FACTORIALS IN EXPRESSIONS, E. G.;
  15. 1 + A(5);
  16. 121
  17. COMMENT WE COULD HAVE PRINTED THE VALUES OF EACH A(I) AS THEY WERE COMPUTED BY REPLACING THE F O R STATEMENT BY;
  18. FOR I:=1:10 DO WRITE A(I):=I*A(I - 1);
  19. A(1):=1
  20. A(2):=2
  21. A(3):=6
  22. A(4):=24
  23. A(5):=120
  24. A(6):=720
  25. A(7):=5040
  26. A(8):=40320
  27. A(9):=362880
  28. A(10):=3628800
  29. COMMENT ANOTHER WAY TO USE FACTORIALS WOULD BE TO INTRODUCE AN OPERATOR FAC BY AN INTEGER PROCEDURE AS FOLLOWS;
  30. INTEGER PROCEDURE FAC(N);
  31. BEGIN INTEGER M,N;
  32. M:=1;
  33. L1:IF N=0 THEN RETURN M;
  34. M:=M*N;
  35. N:=N - 1;
  36. GO TO L1 END;
  37. COMMENT WE CAN NOW USE FAC AS AN OPERATOR IN EXPRESSIONS, E. G. ;
  38. Z**2 + FAC(4) - 2*FAC 2*Y;
  39. 2
  40. - (4*Y - Z - 24)
  41. COMMENT NOTE IN THE ABOVE EXAMPLE THAT THE PARENTHESES AROUND THE ARGUMENTS OF FAC MAY BE OMITTED SINCE FAC IS A
  42. UNARY OPERATOR;
  43. COMMENT THE FOLLOWING EXAMPLES ILLUSTRATE THE SOLUTION OF SOME COMPLETE PROBLEMS;
  44. COMMENT THE F AND G SERIES (REF SCONZO, P., LESCHACK, A. R. AND TOBEY, R. G., ASTRONOMICAL JOURNAL, VOL 70 (MAY
  45. 1965);
  46. SCALAR F1,F2,G1,G2;
  47. DEPS:= - SIG*(MU + 2*EPS)$
  48. DMU:= - 3*MU*SIG$
  49. DSIG:=EPS - 2*SIG**2$
  50. F1:=1$
  51. G1:=0$
  52. FOR I:=1:8 DO BEGIN F2:= - MU*G1 + DEPS*DF(F1,EPS) + DMU*DF(F1,MU) + DSIG*DF(F1,SIG)$
  53. WRITE"F(",I,") := ",F2;
  54. G2:=F1 + DEPS*DF(G1,EPS) + DMU*DF(G1,MU) + DSIG*DF(G1,SIG)$
  55. WRITE"G(",I,") := ",G2;
  56. F1:=F2$
  57. G1:=G2 END;
  58. F(1) := 0
  59. G(1) := 1
  60. F(2) := - MU
  61. G(2) := 0
  62. F(3) := 3*MU*SIG
  63. G(3) := - MU
  64. 2
  65. F(4) := MU*(MU - 15*SIG + 3*EPS)
  66. G(4) := 6*MU*SIG
  67. 2
  68. F(5) := - 15*MU*SIG*(MU - 7*SIG + 3*EPS)
  69. 2
  70. G(5) := MU*(MU - 45*SIG + 9*EPS)
  71. 2 2 4 2 2
  72. F(6) := - MU*(MU - 210*MU*SIG + 24*MU*EPS + 945*SIG - 630*SIG *EPS + 45*EPS )
  73. 2
  74. G(6) := - 30*MU*SIG*(MU - 14*SIG + 6*EPS)
  75. 2 2 4 2 2
  76. F(7) := 63*MU*SIG*(MU - 50*MU*SIG + 14*MU*EPS + 165*SIG - 150*SIG *EPS + 25*EPS )
  77. 2 2 4 2 2
  78. G(7) := - MU*(MU - 630*MU*SIG + 54*MU*EPS + 4725*SIG - 3150*SIG *EPS + 225*EPS )
  79. 3 2 2 2 4 2 2 6
  80. F(8) := MU*(MU - 2205*MU *SIG + 117*MU *EPS + 51975*MU*SIG - 24570*MU*SIG *EPS + 1107*MU*EPS - 135135*SIG +
  81. 4 2 2 3
  82. 155925*SIG *EPS - 42525*SIG *EPS + 1575*EPS )
  83. 2 2 4 2 2
  84. G(8) := 126*MU*SIG*(MU - 100*MU*SIG + 24*MU*EPS + 495*SIG - 450*SIG *EPS + 75*EPS )
  85. COMMENT A PROBLEM IN FOURIER ANALYSIS;
  86. FOR ALL X,Y LET COS(X)*COS(Y)=(COS(X + Y) + COS(X - Y))/2,COS(X)*SIN(Y)=(SIN(X + Y) - SIN(X - Y))/2,SIN(X)*SIN(Y)
  87. =(COS(X - Y) - COS(X + Y))/2;
  88. FACTOR COS,SIN;
  89. ON LIST;
  90. (A1*COS(WT) + A3*COS(3*WT) + B1*SIN(WT) + B3*SIN(3*WT))**3;
  91. 3 3
  92. (4*SIN(WT) *B1
  93. 2
  94. + 3*SIN(WT)*(2*B3 *B1
  95. 2
  96. - B3*B1
  97. 2
  98. + B3*A1
  99. 2
  100. + 2*B1*A3
  101. - 2*B1*A3*A1
  102. 2
  103. + B1*A1 )
  104. 2
  105. + 3*SIN(9*WT)*B3*A3
  106. 2
  107. - 3*SIN(7*WT)*(B3 *B1
  108. - 2*B3*A3*A1
  109. 2
  110. - B1*A3 )
  111. 2
  112. + 3*SIN(5*WT)*(B3 *B1
  113. 2
  114. - B3*B1
  115. + 2*B3*A3*A1
  116. 2
  117. + B3*A1
  118. 2
  119. - B1*A3
  120. + 2*B1*A3*A1)
  121. 3 3
  122. + 4*SIN(3*WT) *B3
  123. 2
  124. + 3*SIN(3*WT)*(2*B3*B1
  125. 2
  126. + B3*A3
  127. 2
  128. + 2*B3*A1
  129. 2
  130. + B1*A1 )
  131. 3 3
  132. + 4*COS(WT) *A1
  133. 2
  134. + 3*COS(WT)*(2*B3 *A1
  135. + 2*B3*B1*A1
  136. 2
  137. - B1 *A3
  138. 2
  139. + B1 *A1
  140. 2
  141. + 2*A3 *A1
  142. 2
  143. + A3*A1 )
  144. 2
  145. - 3*COS(9*WT)*B3 *A3
  146. 2
  147. - 3*COS(7*WT)*(B3 *A1
  148. + 2*B3*B1*A3
  149. 2
  150. - A3 *A1)
  151. 2
  152. - 3*COS(5*WT)*(B3 *A1
  153. - 2*B3*B1*A3
  154. + 2*B3*B1*A1
  155. 2
  156. + B1 *A3
  157. 2
  158. - A3 *A1
  159. 2
  160. - A3*A1 )
  161. 3 3
  162. + 4*COS(3*WT) *A3
  163. 2
  164. + 3*COS(3*WT)*(B3 *A3
  165. 2
  166. + 2*B1 *A3
  167. 2
  168. - B1 *A1
  169. 2
  170. + 2*A3*A1 ))
  171. /4
  172. COMMENT END OF FOURIER ANALYSIS EXAMPLE ;
  173. OFF LIST;
  174. FOR ALL X,Y CLEAR COS X*COS Y,COS X*SIN Y,SIN X*SIN Y;
  175. COMMENT LEAVING SUCH REPLACEMENTS ACTIVE WOULD SLOW DOWN SUBSEQUENT COMPUTATION;
  176. COMMENT AN EXAMPLE USING THE MATRIX FACILITY;
  177. MATRIX XX,YY;
  178. LET XX=MAT((A11,A12),(A21,A22)),YY=MAT((Y1),(Y2));
  179. 2*DET XX - 3*XXX;
  180. 2*(A22*A11 - A21*A12 - 5443200)
  181. ZZ:=SOLVE(XX,YY);
  182. ZZ(1,1)=(Y1*A22 - Y2*A12)/(A22*A11 - A21*A12)
  183. ZZ(2,1)=( - (Y1*A21 - Y2*A11))/(A22*A11 - A21*A12)
  184. 1/XX**2;
  185. 2 2 2 2 2
  186. MAT(1,1)=(A22 + A21*A12)/(A22 *A11 - 2*A22*A21*A12*A11 + A21 *A12 )
  187. 2 2 2 2
  188. MAT(1,2)=( - A12*(A22 + A11))/(A22 *A11 - 2*A22*A21*A12*A11 + A21 *A12 )
  189. 2 2 2 2
  190. MAT(2,1)=( - A21*(A22 + A11))/(A22 *A11 - 2*A22*A21*A12*A11 + A21 *A12 )
  191. 2 2 2 2 2
  192. MAT(2,2)=(A21*A12 + A11 )/(A22 *A11 - 2*A22*A21*A12*A11 + A21 *A12 )
  193. COMMENT END OF MATRIX EXAMPLES;
  194. COMMENT THE FOLLOWING EXAMPLES WILL FAIL UNLESS THE FUNCTIONS NEEDED FOR PROBLEMS IN HIGH ENERGY PHYSICS HAVE
  195. BEEN LOADED;
  196. COMMENT A PHYSICS EXAMPLE;
  197. ON DIV;
  198. COMMENT THIS GIVES US OUTPUT IN SAME FORM AS BJORKEN AND DRELL;
  199. MASS KI=0,KF=0,PI=M,PF=M;
  200. VECTOR EI,EF;
  201. MSHELL KI,KF,PI,PF;
  202. LET PI.EI=0,PI.EF=0,PI.PF=M**2 + KI.KF,PI.KI=M*K,PI.KF=M*KP,PF.EI= - KF.EI,PF.EF=KI.EF,PF.KI=M*KP,PF.KF=M*K,KI.EI
  203. =0,KI.KF=M*(K - KP),KF.EF=0,EI.EI= - 1,EF.EF= - 1;
  204. FOR ALL P LET GP(P)=G(L,P) + M;
  205. COMMENT THIS IS JUST TO SAVE US A LOT OF WRITING;
  206. GP(PF)*(G(L,EF,EI,KI)/(2*KI.PI) + G(L,EI,EF,KF)/(2*KF.PI))*GP(PI)*(G(L,KI,EI,EF)/(2*KI.PI) + G(L,KF,EF,EI)/(2*KF.
  207. PI))$
  208. WRITE"THE COMPTON CROSS-SECTION IS ",*ANS;
  209. (-1) (-1) 2 2 2
  210. THE COMPTON CROSS-SECTION IS 1/2*K *KP *(K + 4*K*KP*EF.EI - 2*K*KP + KP )
  211. COMMENT END OF FIRST PHYSICS EXAMPLE;
  212. OFF DIV;
  213. COMMENT ANOTHER PHYSICS EXAMPLE;
  214. FACTOR MM,P1.P3;
  215. INDEX X1,Y1,Z;
  216. MASS P1=MM,P2=MM,P3=MM,P4=MM,K1=0;
  217. MSHELL P1,P2,P3,P4,K1;
  218. VECTOR Q1,Q2;
  219. FOR ALL P LET GA(P)=G(LA,P) + MM,GB(P)=G(LB,P) + MM;
  220. GA( - P2)*G(LA,X1)*GA( - P4)*G(LA,Y1)*(GB(P3)*G(LB,X1)*GB(Q1)*G(LB,Z)*GB(P1)*G(LB,Y1)*GB(Q2)*G(LB,Z) + GB(P3)*G(
  221. LB,Z)*GB(Q2)*G(LB,X1)*GB(P1)*G(LB,Z)*GB(Q1)*G(LB,Y1))$
  222. LET Q1=P1 - K1,Q2=P3 + K1;
  223. COMMENT IT IS USUALLY FASTER TO MAKE SUCH SUBSTITUTIONS AFTER ALL TRACE ALGEBRA IS DONE;
  224. WRITE"CXN = ",*ANS;
  225. 4 4 2 2 2 2
  226. CXN = 32*MM *P3.P1 - 8*MM *(P3.K1 - P1.K1) - 16*MM *P3.P1 - 16*MM *P3.P1*(P4.P2 - P3.K1 + P1.K1) + 8*MM *(P4.P2*
  227. P3.K1 - P4.P2*P1.K1 - 2*P4.K1*P2.K1) + 8*P3.P1*(2*P4.P3*P2.P1 - P4.P3*P2.K1 + 2*P4.P1*P2.P3 + P4.P1*P2.K1
  228. - P4.K1*P2.P3 + P4.K1*P2.P1) + 8*(2*P4.P3*P2.P3*P1.K1 - P4.P3*P2.P1*P3.K1 + P4.P3*P2.P1*P1.K1 - P4.P1*P2.
  229. P3*P3.K1 + P4.P1*P2.P3*P1.K1 - 2*P4.P1*P2.P1*P3.K1)
  230. COMMENT END OF SECOND PHYSICS EXAMPLE;
  231. COMMENT THE FOLLOWING RATHER LONG PROGRAM IS A COMPLETE ROUTINE FOR CALCULATING THE RICCI SCALAR. IT WAS
  232. DEVELOPED IN COLLABORATION WITH DAVID BARTON AND JOHN FITCH;
  233. COMMENT FIRST WE INHIBIT DIAGNOSTIC MESSAGE PRINTING AND THE PRINTING OF ZERO ELEMENTS OF ARRAYS;
  234. OFF MSG$
  235. ON NERO$
  236. COMMENT HERE WE INTRODUCE THE COVARIANT AND CONTRAVARIANT METRICS;
  237. ARRAY GG(3,3),H(3,3),X(3)$
  238. FOR I:=0:3 DO FOR J:=0:3 DO GG(I,J):=H(I,J):=0$
  239. GG(0,0):=E**(Q1(X(1)))$
  240. GG(1,1):= - E**(P1(X(1)))$
  241. GG(2,2):= - X(1)**2$
  242. GG(3,3):= - X(1)**2*SIN(X(2))**2$
  243. FOR I:=0:3 DO H(I,I):=1/GG(I,I)$
  244. IF I~=J LET DF(P1(X(I)),X(J))=0,DF(Q1(X(I)),X(J))=0;
  245. COMMENT GENERATE CHRISTOFFEL SYMBOLS AND STORE IN ARRAYS CS1 AND CS2;
  246. ARRAY CS1(3,3,3)$
  247. FOR I:=0:3 DO FOR J:=I:3 DO FOR K:=0:3 DO CS1(J,I,K):=CS1(I,J,K):=(DF(GG(I,K),X(J)) + DF(GG(J,K),X(I)) - DF(GG(I,
  248. J),X(K)))/2$
  249. ARRAY CS2(3,3,3)$
  250. FOR I:=0:3 DO FOR J:=I:3 DO FOR K:=0:3 DO CS2(J,I,K):=CS2(I,J,K):=FOR P:=0:3 SUM H(K,P)*CS1(I,J,P)$
  251. COMMENT NOW CALCULATE THE DERIVATIVES OF THE CHRISTOFFEL SYMBOLS AND STORE IN DC2(I,J,K,L);
  252. ARRAY DC2(3,3,3,3)$
  253. FOR I:=0:3 DO FOR J:=I:3 DO FOR K:=0:3 DO FOR L:=0:3 DO DC2(J,I,K,L):=DC2(I,J,K,L):=DF(CS2(I,J,K),X(L))$
  254. COMMENT NOW STORE THE SUMS OF PRODUCTS OF THE CS2 IN SPCS2;
  255. ARRAY SPCS2(3,3,3,3)$
  256. FOR I:=0:3 DO FOR J:=I:3 DO FOR K:=0:3 DO FOR L:=0:3 DO SPCS2(J,I,K,L):=SPCS2(I,J,K,L):=FOR P:=0:3 SUM CS2(P,L,K)
  257. *CS2(I,J,P)$
  258. COMMENT NOW COMPUTE THE RIEMANN TENSOR AND STORE IN R(I,J,K,L);
  259. ARRAY R(3,3,3,3)$
  260. FOR I:=0:3 DO FOR J:=I + 1:3 DO FOR K:=I:3 DO FOR L:=K + 1:IF K=I THEN J ELSE 3 DO BEGIN R(J,I,L,K):=R(I,J,K,L):=
  261. FOR Q:=0:3 SUM GG(I,Q)*(DC2(K,J,Q,L) - DC2(J,L,Q,K) + SPCS2(K,J,Q,L) - SPCS2(L,J,Q,K))$
  262. R(I,J,L,K):=R(J,I,K,L):= - R(I,J,K,L)$
  263. IF I=K&J=L THEN GO TO A$
  264. R(K,L,I,J):=R(L,K,J,I):=R(I,J,K,L)$
  265. R(L,K,I,J):=R(K,L,J,I):= - R(I,J,K,L)$
  266. A:END$
  267. COMMENT NOW COMPUTE AND PRINT THE RICCI TENSOR;
  268. ARRAY RICCI(3,3)$
  269. FOR I:=0:3 DO FOR J:=0:3 DO WRITE RICCI(J,I):=RICCI(I,J):=FOR P:=0:3 SUM FOR Q:=0:3 SUM H(P,Q)*R(Q,I,P,J);
  270. ( - Q1(X(1))) ( - (P1(X(1)) - Q1(X(1))))
  271. RICCI(0,0):=RICCI(0,0):=(4*R(0,0,0,0)*X(1)*E + X(1)*E *DF(P1(X(1)),X(1))*DF
  272. ( - (P1(X(1)) - Q1(X(1)))) 2 ( - (P1(X(1)) - Q1(X(1))))
  273. (Q1(X(1)),X(1)) - X(1)*E *DF(Q1(X(1)),X(1)) - 2*X(1)*E *DF(Q1(
  274. ( - (P1(X(1)) - Q1(X(1))))
  275. X(1)),X(1),X(1)) - 4*E *DF(Q1(X(1)),X(1)))/(4*X(1))
  276. ( - P1(X(1))) ( - Q1(X(1)))
  277. RICCI(1,0):=RICCI(0,1):= - (R(1,0,1,1)*E - R(0,0,0,1)*E )
  278. 2 ( - Q1(X(1))) 2
  279. RICCI(2,0):=RICCI(0,2):=( - (R(2,0,2,2) - R(0,0,0,2)*X(1) *E ))/X(1)
  280. 2 2 ( - Q1(X(1))) 2 2
  281. RICCI(3,0):=RICCI(0,3):=(SIN(X(2)) *R(0,0,0,3)*X(1) *E - R(3,0,3,3))/(SIN(X(2)) *X(1) )
  282. ( - P1(X(1))) ( - Q1(X(1)))
  283. RICCI(0,1):=RICCI(1,0):= - (R(1,1,1,0)*E - R(0,1,0,0)*E )
  284. ( - P1(X(1)))
  285. RICCI(1,1):=RICCI(1,1):=( - (4*R(1,1,1,1)*X(1)*E + X(1)*DF(P1(X(1)),X(1))*DF(Q1(X(1)),X(1)) - X(1)*
  286. 2
  287. DF(Q1(X(1)),X(1)) - 2*X(1)*DF(Q1(X(1)),X(1),X(1)) + 4*DF(P1(X(1)),X(1))))/(4*X(1))
  288. 2 ( - P1(X(1))) 2
  289. RICCI(2,1):=RICCI(1,2):=( - (R(2,1,2,2) + R(1,1,1,2)*X(1) *E ))/X(1)
  290. 2 2 ( - P1(X(1))) 2 2
  291. RICCI(3,1):=RICCI(1,3):=( - SIN(X(2)) *R(1,1,1,3)*X(1) *E - R(3,1,3,3))/(SIN(X(2)) *X(1) )
  292. 2 ( - Q1(X(1))) 2
  293. RICCI(0,2):=RICCI(2,0):=( - (R(2,2,2,0) - R(0,2,0,0)*X(1) *E ))/X(1)
  294. 2 ( - P1(X(1))) 2
  295. RICCI(1,2):=RICCI(2,1):=( - (R(2,2,2,1) + R(1,2,1,1)*X(1) *E ))/X(1)
  296. 3 ( - P1(X(1))) 3 ( - P1(X(1)))
  297. RICCI(2,2):=RICCI(2,2):=( - (2*R(2,2,2,2) + X(1) *E *DF(P1(X(1)),X(1)) - X(1) *E *DF(Q1(X
  298. 2 ( - P1(X(1))) 2 2
  299. (1)),X(1)) - 2*X(1) *E + 2*X(1) ))/(2*X(1) )
  300. 2 2 2
  301. RICCI(3,2):=RICCI(2,3):=( - SIN(X(2)) *R(2,2,2,3) - R(3,2,3,3))/(SIN(X(2)) *X(1) )
  302. 2 2 ( - Q1(X(1))) 2 2
  303. RICCI(0,3):=RICCI(3,0):=(SIN(X(2)) *R(0,3,0,0)*X(1) *E - R(3,3,3,0))/(SIN(X(2)) *X(1) )
  304. 2 2 ( - P1(X(1))) 2 2
  305. RICCI(1,3):=RICCI(3,1):=( - SIN(X(2)) *R(1,3,1,1)*X(1) *E - R(3,3,3,1))/(SIN(X(2)) *X(1) )
  306. 2 2 2
  307. RICCI(2,3):=RICCI(3,2):=( - SIN(X(2)) *R(2,3,2,2) - R(3,3,3,2))/(SIN(X(2)) *X(1) )
  308. 4 2 ( - P1(X(1))) ( - P1(X(1)))
  309. RICCI(3,3):=RICCI(3,3):=( - SIN(X(2)) *X(1) *(X(1)*E *DF(P1(X(1)),X(1)) - X(1)*E *DF(Q1(X
  310. ( - P1(X(1))) 2 2
  311. (1)),X(1)) - 2*E + 2) - 2*R(3,3,3,3))/(2*SIN(X(2)) *X(1) )
  312. COMMENT FINALLY COMPUTE AND PRINT THE RICCI SCALAR;
  313. R:=FOR I:=0:3 SUM FOR J:=0:3 SUM H(I,J)*RICCI(I,J);
  314. 4 4 ( - 2*P1(X(1))) 4 ( - 2*Q1(X(1))) 4
  315. R:=(SIN(X(2)) *(2*R(2,2,2,2) + 2*R(1,1,1,1)*X(1) *E + 2*R(0,0,0,0)*X(1) *E + X(1) *
  316. ( - P1(X(1))) 4 ( - P1(X(1))) 2 4 ( -
  317. E *DF(P1(X(1)),X(1))*DF(Q1(X(1)),X(1)) - X(1) *E *DF(Q1(X(1)),X(1)) - 2*X(1) *E
  318. P1(X(1))) 3 ( - P1(X(1))) 3 ( - P1(X(1)))
  319. *DF(Q1(X(1)),X(1),X(1)) + 4*X(1) *E *DF(P1(X(1)),X(1)) - 4*X(1) *E *DF(Q1(X(
  320. 2 ( - P1(X(1))) 2 4 4
  321. 1)),X(1)) - 4*X(1) *E + 4*X(1) ) + 2*R(3,3,3,3))/(2*SIN(X(2)) *X(1) )
  322. END OF RICCI TENSOR AND SCALAR CALCULATION;
  323. LEAVING REDUCE ...
  324. ***