-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdkN2_square_symmetric.cpp
102 lines (101 loc) · 41.3 KB
/
dkN2_square_symmetric.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
#include <math.h>
#include "GreenAnisotropic2D.hpp"
double medium::dkN2_square_symmetric(double t, int k, int i, int j) {
if ((k==0)&&(i==1)&&(j==1)) {
return (R0*cos(4*Th + 2*t) + T0 + T1*cos(2*t) + T1)/(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1));
}
else if ((k==0)&&(i==2)&&(j==2)) {
return (-R0*cos(4*Th + 2*t) + T0 - T1*cos(2*t) + T1)/(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1));
}
else if ((k==0)&&(i==1)&&(j==2)) {
return (R0*sin(4*Th + 2*t) - T1*sin(2*t))/(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1));
}
else if ((k==0)&&(i==2)&&(j==1)) {
return dkN2_square_symmetric(t,0,1,2);
}
else if ((k==1)&&(i==1)&&(j==1)) {
return -8*R0*T1*(R0*cos(4*Th + 2*t) + T0 + T1*cos(2*t) + T1)*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2) + (-2*R0*sin(4*Th + 2*t) - 2*T1*sin(2*t))/(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1));
}
else if ((k==1)&&(i==2)&&(j==2)) {
return -8*R0*T1*(-R0*cos(4*Th + 2*t) + T0 - T1*cos(2*t) + T1)*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2) + (2*R0*sin(4*Th + 2*t) + 2*T1*sin(2*t))/(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1));
}
else if ((k==1)&&(i==1)&&(j==2)) {
return 8*R0*T1*(R0*sin(4*Th + 2*t) - T1*sin(2*t))*sin(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2) + (2*R0*cos(4*Th + 2*t) - 2*T1*cos(2*t))/(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1));
}
else if ((k==1)&&(i==2)&&(j==1)) {
return dkN2_square_symmetric(t,1,1,2);
}
else if ((k==2)&&(i==1)&&(j==1)) {
return -16*R0*T1*(-2*R0*sin(4*Th + 2*t) - 2*T1*sin(2*t))*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2) + (-4*R0*cos(4*Th + 2*t) - 4*T1*cos(2*t))/(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1)) + (128*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 32*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2))*(R0*cos(4*Th + 2*t) + T0 + T1*cos(2*t) + T1);
}
else if ((k==2)&&(i==2)&&(j==2)) {
return -16*R0*T1*(2*R0*sin(4*Th + 2*t) + 2*T1*sin(2*t))*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2) + (4*R0*cos(4*Th + 2*t) + 4*T1*cos(2*t))/(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1)) + (128*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 32*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2))*(-R0*cos(4*Th + 2*t) + T0 - T1*cos(2*t) + T1);
}
else if ((k==2)&&(i==1)&&(j==2)) {
return 16*R0*T1*(2*R0*cos(4*Th + 2*t) - 2*T1*cos(2*t))*sin(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2) + (-4*R0*sin(4*Th + 2*t) + 4*T1*sin(2*t))/(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1)) + (R0*sin(4*Th + 2*t) - T1*sin(2*t))*(128*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) + 32*R0*T1*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2));
}
else if ((k==2)&&(i==2)&&(j==1)) {
return dkN2_square_symmetric(t,2,1,2);
}
else if ((k==3)&&(i==1)&&(j==1)) {
return -24*R0*T1*(-4*R0*cos(4*Th + 2*t) - 4*T1*cos(2*t))*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2) + (-2*R0*sin(4*Th + 2*t) - 2*T1*sin(2*t))*(384*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 96*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (8*R0*sin(4*Th + 2*t) + 8*T1*sin(2*t))/(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1)) + (-3072*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 1536*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 128*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2))*(R0*cos(4*Th + 2*t) + T0 + T1*cos(2*t) + T1);
}
else if ((k==3)&&(i==2)&&(j==2)) {
return -24*R0*T1*(4*R0*cos(4*Th + 2*t) + 4*T1*cos(2*t))*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2) + (-8*R0*sin(4*Th + 2*t) - 8*T1*sin(2*t))/(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1)) + (2*R0*sin(4*Th + 2*t) + 2*T1*sin(2*t))*(384*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 96*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (-3072*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 1536*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 128*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2))*(-R0*cos(4*Th + 2*t) + T0 - T1*cos(2*t) + T1);
}
else if ((k==3)&&(i==1)&&(j==2)) {
return 24*R0*T1*(-4*R0*sin(4*Th + 2*t) + 4*T1*sin(2*t))*sin(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2) + (R0*sin(4*Th + 2*t) - T1*sin(2*t))*(3072*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) + 1536*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) - 128*R0*T1*sin(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2)) + (-8*R0*cos(4*Th + 2*t) + 8*T1*cos(2*t))/(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1)) + (6*R0*cos(4*Th + 2*t) - 6*T1*cos(2*t))*(128*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) + 32*R0*T1*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2));
}
else if ((k==3)&&(i==2)&&(j==1)) {
return dkN2_square_symmetric(t,3,1,2);
}
else if ((k==4)&&(i==1)&&(j==1)) {
return -32*R0*T1*(8*R0*sin(4*Th + 2*t) + 8*T1*sin(2*t))*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2) + (-2*R0*sin(4*Th + 2*t) - 2*T1*sin(2*t))*(-12288*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 6144*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 512*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (-24*R0*cos(4*Th + 2*t) - 24*T1*cos(2*t))*(128*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 32*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (16*R0*cos(4*Th + 2*t) + 16*T1*cos(2*t))/(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1)) + (R0*cos(4*Th + 2*t) + T0 + T1*cos(2*t) + T1)*(98304*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) - 73728*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 8192*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 6144*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 512*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2));
}
else if ((k==4)&&(i==2)&&(j==2)) {
return -32*R0*T1*(-8*R0*sin(4*Th + 2*t) - 8*T1*sin(2*t))*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2) + (2*R0*sin(4*Th + 2*t) + 2*T1*sin(2*t))*(-12288*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 6144*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 512*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (-16*R0*cos(4*Th + 2*t) - 16*T1*cos(2*t))/(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1)) + (24*R0*cos(4*Th + 2*t) + 24*T1*cos(2*t))*(128*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 32*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (-R0*cos(4*Th + 2*t) + T0 - T1*cos(2*t) + T1)*(98304*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) - 73728*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 8192*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 6144*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 512*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2));
}
else if ((k==4)&&(i==1)&&(j==2)) {
return 32*R0*T1*(-8*R0*cos(4*Th + 2*t) + 8*T1*cos(2*t))*sin(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2) + (-4*R0*sin(4*Th + 2*t) + 4*T1*sin(2*t))*(768*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) + 192*R0*T1*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2)) + (R0*sin(4*Th + 2*t) - T1*sin(2*t))*(98304*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 5) + 73728*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) - 8192*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) + 6144*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) - 512*R0*T1*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2)) + (16*R0*sin(4*Th + 2*t) - 16*T1*sin(2*t))/(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1)) + (8*R0*cos(4*Th + 2*t) - 8*T1*cos(2*t))*(3072*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) + 1536*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) - 128*R0*T1*sin(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2));
}
else if ((k==4)&&(i==2)&&(j==1)) {
return dkN2_square_symmetric(t,4,1,2);
}
else if ((k==5)&&(i==1)&&(j==1)) {
return -40*R0*T1*(16*R0*cos(4*Th + 2*t) + 16*T1*cos(2*t))*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2) + (-32*R0*sin(4*Th + 2*t) - 32*T1*sin(2*t))/(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1)) + (-2*R0*sin(4*Th + 2*t) - 2*T1*sin(2*t))*(491520*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) - 368640*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 40960*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 30720*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 2560*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (8*R0*sin(4*Th + 2*t) + 8*T1*sin(2*t))*(1280*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 320*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (-40*R0*cos(4*Th + 2*t) - 40*T1*cos(2*t))*(-3072*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 1536*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 128*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (R0*cos(4*Th + 2*t) + T0 + T1*cos(2*t) + T1)*(-3932160*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 5)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 6) + 3932160*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 3)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) + 491520*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 737280*pow(R0, 3)*pow(T1, 3)*sin(4*Th + 4*t)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 122880*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 2048*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2));
}
else if ((k==5)&&(i==2)&&(j==2)) {
return -40*R0*T1*(-16*R0*cos(4*Th + 2*t) - 16*T1*cos(2*t))*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2) + (-8*R0*sin(4*Th + 2*t) - 8*T1*sin(2*t))*(1280*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 320*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (2*R0*sin(4*Th + 2*t) + 2*T1*sin(2*t))*(491520*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) - 368640*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 40960*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 30720*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 2560*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (32*R0*sin(4*Th + 2*t) + 32*T1*sin(2*t))/(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1)) + (40*R0*cos(4*Th + 2*t) + 40*T1*cos(2*t))*(-3072*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 1536*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 128*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (-R0*cos(4*Th + 2*t) + T0 - T1*cos(2*t) + T1)*(-3932160*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 5)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 6) + 3932160*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 3)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) + 491520*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 737280*pow(R0, 3)*pow(T1, 3)*sin(4*Th + 4*t)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 122880*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 2048*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2));
}
else if ((k==5)&&(i==1)&&(j==2)) {
return 40*R0*T1*(16*R0*sin(4*Th + 2*t) - 16*T1*sin(2*t))*sin(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2) + (-4*R0*sin(4*Th + 2*t) + 4*T1*sin(2*t))*(30720*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) + 15360*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) - 1280*R0*T1*sin(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2)) + (R0*sin(4*Th + 2*t) - T1*sin(2*t))*(3932160*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 5)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 6) + 3932160*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 3)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 5) - 491520*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) + 737280*pow(R0, 3)*pow(T1, 3)*sin(4*Th + 4*t)*pow(cos(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) - 122880*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) + 2048*R0*T1*sin(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2)) + (-80*R0*cos(4*Th + 2*t) + 80*T1*cos(2*t))*(128*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) + 32*R0*T1*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2)) + (10*R0*cos(4*Th + 2*t) - 10*T1*cos(2*t))*(98304*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 5) + 73728*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) - 8192*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) + 6144*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) - 512*R0*T1*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2)) + (32*R0*cos(4*Th + 2*t) - 32*T1*cos(2*t))/(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1));
}
else if ((k==5)&&(i==2)&&(j==1)) {
return dkN2_square_symmetric(t,5,1,2);
}
else if ((k==6)&&(i==1)&&(j==1)) {
return -48*R0*T1*(-32*R0*sin(4*Th + 2*t) - 32*T1*sin(2*t))*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2) + (-2*R0*sin(4*Th + 2*t) - 2*T1*sin(2*t))*(-23592960*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 5)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 6) + 23592960*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 3)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) + 2949120*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 4423680*pow(R0, 3)*pow(T1, 3)*sin(4*Th + 4*t)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 737280*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 12288*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (8*R0*sin(4*Th + 2*t) + 8*T1*sin(2*t))*(-61440*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 30720*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 2560*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (-64*R0*cos(4*Th + 2*t) - 64*T1*cos(2*t))/(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1)) + (-60*R0*cos(4*Th + 2*t) - 60*T1*cos(2*t))*(98304*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) - 73728*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 8192*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 6144*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 512*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (240*R0*cos(4*Th + 2*t) + 240*T1*cos(2*t))*(128*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 32*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (R0*cos(4*Th + 2*t) + T0 + T1*cos(2*t) + T1)*(188743680*pow(R0, 6)*pow(T1, 6)*pow(sin(4*Th + 4*t), 6)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 7) - 235929600*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 4)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 6) - 31457280*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) + 70778880*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 2)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) + 14745600*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 2949120*pow(R0, 3)*pow(T1, 3)*pow(cos(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 524288*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 491520*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 8192*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2));
}
else if ((k==6)&&(i==2)&&(j==2)) {
return -48*R0*T1*(32*R0*sin(4*Th + 2*t) + 32*T1*sin(2*t))*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2) + (-8*R0*sin(4*Th + 2*t) - 8*T1*sin(2*t))*(-61440*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 30720*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 2560*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (2*R0*sin(4*Th + 2*t) + 2*T1*sin(2*t))*(-23592960*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 5)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 6) + 23592960*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 3)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) + 2949120*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 4423680*pow(R0, 3)*pow(T1, 3)*sin(4*Th + 4*t)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 737280*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 12288*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (-240*R0*cos(4*Th + 2*t) - 240*T1*cos(2*t))*(128*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 32*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (60*R0*cos(4*Th + 2*t) + 60*T1*cos(2*t))*(98304*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) - 73728*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 8192*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 6144*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 512*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (64*R0*cos(4*Th + 2*t) + 64*T1*cos(2*t))/(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1)) + (-R0*cos(4*Th + 2*t) + T0 - T1*cos(2*t) + T1)*(188743680*pow(R0, 6)*pow(T1, 6)*pow(sin(4*Th + 4*t), 6)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 7) - 235929600*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 4)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 6) - 31457280*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) + 70778880*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 2)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) + 14745600*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 2949120*pow(R0, 3)*pow(T1, 3)*pow(cos(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 524288*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 491520*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 8192*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2));
}
else if ((k==6)&&(i==1)&&(j==2)) {
return 48*R0*T1*(32*R0*cos(4*Th + 2*t) - 32*T1*cos(2*t))*sin(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2) + (-64*R0*sin(4*Th + 2*t) + 64*T1*sin(2*t))/(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1)) + (-4*R0*sin(4*Th + 2*t) + 4*T1*sin(2*t))*(1474560*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 5) + 1105920*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) - 122880*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) + 92160*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) - 7680*R0*T1*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2)) + (R0*sin(4*Th + 2*t) - T1*sin(2*t))*(188743680*pow(R0, 6)*pow(T1, 6)*pow(sin(4*Th + 4*t), 6)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 7) + 235929600*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 4)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 6) - 31457280*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 5) + 70778880*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 2)*pow(cos(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 5) - 14745600*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) + 2949120*pow(R0, 3)*pow(T1, 3)*pow(cos(4*Th + 4*t), 3)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) + 524288*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) - 491520*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) + 8192*R0*T1*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2)) + (16*R0*sin(4*Th + 2*t) - 16*T1*sin(2*t))*(1920*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) + 480*R0*T1*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2)) + (-160*R0*cos(4*Th + 2*t) + 160*T1*cos(2*t))*(3072*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) + 1536*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) - 128*R0*T1*sin(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2)) + (12*R0*cos(4*Th + 2*t) - 12*T1*cos(2*t))*(3932160*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 5)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 6) + 3932160*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 3)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 5) - 491520*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) + 737280*pow(R0, 3)*pow(T1, 3)*sin(4*Th + 4*t)*pow(cos(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) - 122880*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) + 2048*R0*T1*sin(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2));
}
else if ((k==6)&&(i==2)&&(j==1)) {
return dkN2_square_symmetric(t,6,1,2);
}
else if ((k==7)&&(i==1)&&(j==1)) {
return -56*R0*T1*(-64*R0*cos(4*Th + 2*t) - 64*T1*cos(2*t))*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2) + (-32*R0*sin(4*Th + 2*t) - 32*T1*sin(2*t))*(2688*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 672*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (-2*R0*sin(4*Th + 2*t) - 2*T1*sin(2*t))*(1321205760*pow(R0, 6)*pow(T1, 6)*pow(sin(4*Th + 4*t), 6)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 7) - 1651507200*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 4)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 6) - 220200960*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) + 495452160*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 2)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) + 103219200*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 20643840*pow(R0, 3)*pow(T1, 3)*pow(cos(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 3670016*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 3440640*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 57344*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (8*R0*sin(4*Th + 2*t) + 8*T1*sin(2*t))*(3440640*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) - 2580480*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 286720*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 215040*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 17920*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (128*R0*sin(4*Th + 2*t) + 128*T1*sin(2*t))/(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1)) + (-84*R0*cos(4*Th + 2*t) - 84*T1*cos(2*t))*(-3932160*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 5)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 6) + 3932160*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 3)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) + 491520*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 737280*pow(R0, 3)*pow(T1, 3)*sin(4*Th + 4*t)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 122880*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 2048*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (560*R0*cos(4*Th + 2*t) + 560*T1*cos(2*t))*(-3072*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 1536*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 128*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (R0*cos(4*Th + 2*t) + T0 + T1*cos(2*t) + T1)*(-10569646080*pow(R0, 7)*pow(T1, 7)*pow(sin(4*Th + 4*t), 7)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 8) + 15854469120*pow(R0, 6)*pow(T1, 6)*pow(sin(4*Th + 4*t), 5)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 7) + 2202009600*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 5)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 6) - 6606028800*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 3)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 6) - 1541406720*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 3)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) + 660602880*pow(R0, 4)*pow(T1, 4)*sin(4*Th + 4*t)*pow(cos(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) - 71565312*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 165150720*pow(R0, 3)*pow(T1, 3)*sin(4*Th + 4*t)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 8257536*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 32768*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2));
}
else if ((k==7)&&(i==2)&&(j==2)) {
return -56*R0*T1*(64*R0*cos(4*Th + 2*t) + 64*T1*cos(2*t))*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2) + (-128*R0*sin(4*Th + 2*t) - 128*T1*sin(2*t))/(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1)) + (-8*R0*sin(4*Th + 2*t) - 8*T1*sin(2*t))*(3440640*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) - 2580480*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 286720*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 215040*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 17920*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (2*R0*sin(4*Th + 2*t) + 2*T1*sin(2*t))*(1321205760*pow(R0, 6)*pow(T1, 6)*pow(sin(4*Th + 4*t), 6)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 7) - 1651507200*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 4)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 6) - 220200960*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) + 495452160*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 2)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) + 103219200*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 20643840*pow(R0, 3)*pow(T1, 3)*pow(cos(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 3670016*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 3440640*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 57344*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (32*R0*sin(4*Th + 2*t) + 32*T1*sin(2*t))*(2688*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 672*R0*T1*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (-560*R0*cos(4*Th + 2*t) - 560*T1*cos(2*t))*(-3072*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 1536*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 128*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (84*R0*cos(4*Th + 2*t) + 84*T1*cos(2*t))*(-3932160*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 5)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 6) + 3932160*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 3)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) + 491520*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 737280*pow(R0, 3)*pow(T1, 3)*sin(4*Th + 4*t)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) - 122880*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) - 2048*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2)) + (-R0*cos(4*Th + 2*t) + T0 - T1*cos(2*t) + T1)*(-10569646080*pow(R0, 7)*pow(T1, 7)*pow(sin(4*Th + 4*t), 7)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 8) + 15854469120*pow(R0, 6)*pow(T1, 6)*pow(sin(4*Th + 4*t), 5)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 7) + 2202009600*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 5)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 6) - 6606028800*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 3)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 6) - 1541406720*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 3)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) + 660602880*pow(R0, 4)*pow(T1, 4)*sin(4*Th + 4*t)*pow(cos(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 5) - 71565312*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 165150720*pow(R0, 3)*pow(T1, 3)*sin(4*Th + 4*t)*pow(cos(4*Th + 4*t), 2)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 4) + 8257536*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 3) + 32768*R0*T1*sin(4*Th + 4*t)/pow(-pow(R0, 2) - 2*R0*T1*cos(4*Th + 4*t) + T0*(T0 + 2*T1), 2));
}
else if ((k==7)&&(i==1)&&(j==2)) {
return 56*R0*T1*(-64*R0*sin(4*Th + 2*t) + 64*T1*sin(2*t))*sin(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2) + (-4*R0*sin(4*Th + 2*t) + 4*T1*sin(2*t))*(82575360*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 5)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 6) + 82575360*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 3)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 5) - 10321920*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) + 15482880*pow(R0, 3)*pow(T1, 3)*sin(4*Th + 4*t)*pow(cos(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) - 2580480*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) + 43008*R0*T1*sin(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2)) + (R0*sin(4*Th + 2*t) - T1*sin(2*t))*(10569646080*pow(R0, 7)*pow(T1, 7)*pow(sin(4*Th + 4*t), 7)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 8) + 15854469120*pow(R0, 6)*pow(T1, 6)*pow(sin(4*Th + 4*t), 5)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 7) - 2202009600*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 5)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 6) + 6606028800*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 3)*pow(cos(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 6) - 1541406720*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 3)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 5) + 660602880*pow(R0, 4)*pow(T1, 4)*sin(4*Th + 4*t)*pow(cos(4*Th + 4*t), 3)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 5) + 71565312*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) - 165150720*pow(R0, 3)*pow(T1, 3)*sin(4*Th + 4*t)*pow(cos(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) + 8257536*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) - 32768*R0*T1*sin(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2)) + (16*R0*sin(4*Th + 2*t) - 16*T1*sin(2*t))*(107520*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 3)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) + 53760*pow(R0, 2)*pow(T1, 2)*sin(4*Th + 4*t)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) - 4480*R0*T1*sin(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2)) + (-280*R0*cos(4*Th + 2*t) + 280*T1*cos(2*t))*(98304*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 5) + 73728*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) - 8192*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) + 6144*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) - 512*R0*T1*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2)) + (-128*R0*cos(4*Th + 2*t) + 128*T1*cos(2*t))/(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1)) + (14*R0*cos(4*Th + 2*t) - 14*T1*cos(2*t))*(188743680*pow(R0, 6)*pow(T1, 6)*pow(sin(4*Th + 4*t), 6)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 7) + 235929600*pow(R0, 5)*pow(T1, 5)*pow(sin(4*Th + 4*t), 4)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 6) - 31457280*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 4)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 5) + 70778880*pow(R0, 4)*pow(T1, 4)*pow(sin(4*Th + 4*t), 2)*pow(cos(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 5) - 14745600*pow(R0, 3)*pow(T1, 3)*pow(sin(4*Th + 4*t), 2)*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) + 2949120*pow(R0, 3)*pow(T1, 3)*pow(cos(4*Th + 4*t), 3)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 4) + 524288*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) - 491520*pow(R0, 2)*pow(T1, 2)*pow(cos(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) + 8192*R0*T1*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2)) + (672*R0*cos(4*Th + 2*t) - 672*T1*cos(2*t))*(128*pow(R0, 2)*pow(T1, 2)*pow(sin(4*Th + 4*t), 2)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 3) + 32*R0*T1*cos(4*Th + 4*t)/pow(pow(R0, 2) + 2*R0*T1*cos(4*Th + 4*t) - T0*(T0 + 2*T1), 2));
}
else if ((k==7)&&(i==2)&&(j==1)) {
return dkN2_square_symmetric(t,7,1,2);
}
return 0;
};