49 if (
I->
a[0] <=
I->
a[1])
51 _warningg(
"Values of semiaxes do not fit the condition for elliptic cylinder (a1 > a2, a3 is ignored). " );
52 std::cout <<
"a1, a2, a3 = " <<
I->
a[0] <<
", " <<
I->
a[1] <<
", " <<
I->
a[2];
64 J[2] = this->
I2(a1, a2, lambda);
65 J[3] = this->
I3(a1, a2, lambda);
73 J[9] = this->
I23(a1, a2, J[2], J[3]);
74 J[8] = this->
I22(a1, J[2], J[3], J[9], lambda);
78 J[12] = this->
I33(a2, J[2], J[3], J[9], lambda);
83 std::cout <<
"J integrals" << std::endl;
84 for (
int i = 0; i < 13; i++)
85 std::cout <<
"J[" << i <<
"] = " << J[i] << std::endl;
86 std::cout << std::endl;
112 const int NUM_ELLIP_INT = 13;
121 for (
int i = 0; i < 3; i++)
126 point->
dJi[3*i+1] = (J_pert[
_Yp_][i+1] - J_pert[
_Ym_][i+1]) / (2.0 * ndiff);
127 point->
dJi[3*i+2] = (J_pert[
_Zp_][i+1] - J_pert[
_Zm_][i+1]) / (2.0 * ndiff);
136 point->
ddJi[9*i+4] = (J_pert[
_Yp_][i+1] - 2.0 * J_pert[
_CENTER_][i+1] + J_pert[
_Ym_][i+1]) / (ndiff * ndiff);
140 point->
ddJi[9*i+7] = point->
ddJi[9*i+5];
141 point->
ddJi[9*i+8] = (J_pert[
_Zp_][i+1] - 2.0 * J_pert[
_CENTER_][i+1] + J_pert[
_Zm_][i+1]) / (ndiff * ndiff);
145 for (
int i = 0; i < 9; i++)
149 point->
dJij[i] = (J_pert[
_Xp_][i+4] - J_pert[
_Xm_][i+4]) / (2.0 * ndiff);
150 point->
dJij[i+9] = (J_pert[
_Yp_][i+4] - J_pert[
_Ym_][i+4]) / (2.0 * ndiff);
151 point->
dJij[i+18] = (J_pert[
_Zp_][i+4] - J_pert[
_Zm_][i+4]) / (2.0 * ndiff);
160 point->
ddJij[9*i+4] = (J_pert[
_Yp_][i+4] - 2.0 * J_pert[
_CENTER_][i+4] + J_pert[
_Ym_][i+4]) / (ndiff * ndiff);
165 point->
ddJij[9*i+8] = (J_pert[
_Zp_][i+4] - 2.0 * J_pert[
_CENTER_][i+4] + J_pert[
_Zm_][i+4]) / (ndiff * ndiff);
171 std::cout <<
"dJi integrals" << std::endl;
172 for (
int i = 0; i < 9; i++)
173 std::cout <<
"dJi[" << i <<
"] = " << point->
dJi[i] << std::endl;
174 std::cout << std::endl;
175 std::cout <<
"dJij integrals" << std::endl;
176 for (
int i = 0; i < 27; i++)
177 std::cout <<
"dJij[" << i <<
"] = " << point->
dJij[i] << std::endl;
178 std::cout << std::endl;
179 std::cout <<
"ddJi integrals" << std::endl;
180 for (
int i = 0; i < 27; i++)
181 std::cout <<
"ddJi[" << i <<
"] = " << point->
ddJi[i] << std::endl;
182 std::cout << std::endl;
183 std::cout <<
"ddJij integrals" << std::endl;
184 for (
int i = 0; i < 81; i++)
185 std::cout <<
"ddJij[" << i <<
"] = " << point->
ddJij[i] << std::endl;
186 std::cout << std::endl;
193 return _4PI_ * a1 * a2 / (
SQR(a2) -
SQR(a1)) * (sqrt(
SQR(a2) + lambda) / sqrt(
SQR(a1) + lambda) - 1.0);
198 return _4PI_ * a1 * a2 / (
SQR(a1) -
SQR(a2)) * (sqrt(
SQR(a1) + lambda) / sqrt(
SQR(a2) + lambda) - 1.0);
202 return ((I2 + I3) / (
SQR(a1) + lambda) - I23) / 3.0;
206 return (I3 - I2) / (
SQR(a1) -
SQR(a2));
210 return ((I2 + I3) / (
SQR(a2) + lambda) - I23) / 3.0;
220 double D =
SQR(b) - 4.0 * c;
221 if (D < 0.0) {
_errorr(
"Discriminant is less than zero in eshelbySoluEllipticIntegralsEllipticCylinder::getLambda()"); }
223 return (-b + sqrt(D)) / 2.0;
double I3(double a1, double a2, double lambda)
double loc_x[3]
Local coordinates of a point.
const InclusionRecord3D * I
double I33(double a2, double I2, double I3, double I23, double lambda)
double I2(double a1, double a2, double lambda)
The header file of usefull macros.
void getPerturbatedLambdas(double *lambdas, const double loc_x[3])
Helper function.
Collection of the functions of basic manipulations, some of them can be used instead of their counter...
double ddJij[81]
Second derivatives of elliptic integral Iij.
Single Point data structure - contribution from Single inclusion.
double I23(double a1, double a2, double I2, double I3)
double ndiff_1
derivative step for the first derivations
void giveDerivativesOfEllipticIntegrals(Point *point, bool intpoint)
Function gives the values of Ferers-Dyson's elliptic integral derivatives of the inclusion this->I...
Class inclusion contains and handles all inclusion data.
double getLambda(const double a[3], double x1, double x2, double x3)
Returns lambda for a given point (x1, x2, x3)
double dJi[9]
First derivatives of elliptic integral Ii.
double * a
Inclusion semiaxes' dimensions in global arrangement.
double ddJi[27]
Second derivatives of elliptic integral Ii.
double dJij[27]
First derivatives of elliptic integral Iij.
Class eshelbySoluEllipticIntegralsEllipticCylinder.
void giveEllipticIntegrals(double J[13], double lambda, bool intpoint)
Function gives the values of Ferers-Dyson's elliptic integrals of the inclusion this->I.
double I22(double a1, double I2, double I3, double I23, double lambda)
void CleanVector(double *a, long n)
Functin cleans a 'double' vector, initialize each value being 0-zero.