Commit d41ca9e5 authored by Guido Giuntoli's avatar Guido Giuntoli

Testing the Chamis model OK

parent 53a6a56a
......@@ -133,6 +133,7 @@ enum {
MIC_HOMOGENEOUS,
MIC_SPHERE,
MIC_LAYER_Y,
MIC_CILI_FIB_X,
MIC_CILI_FIB_Z,
MIC_CILI_FIB_XZ,
MIC_QUAD_FIB_XYZ,
......
......@@ -487,6 +487,14 @@ int micropp<tdim>::get_elem_type(int ex, int ey, int ez) const
const double width = geo_params[0];
return (coor[1] < width);
} else if (micro_type == MIC_CILI_FIB_X) { // a cilindrical fiber in x dir
const double rad = geo_params[0];
const double center[3] = { lx / 2, ly / 2, lz / 2 }; // 2D lz = 0
const double dir[3] = { 1, 0, 0 };
return point_inside_cilinder_inf(dir, center, rad, coor);
} else if (micro_type == MIC_CILI_FIB_Z) { // a cilindrical fiber in z dir
const double rad = geo_params[0];
......@@ -823,6 +831,9 @@ void micropp<tdim>::print_info() const
case(MIC_LAYER_Y):
cout << "MIC_LAYER_Y" << endl;
break;
case(MIC_CILI_FIB_X):
cout << "MIC_CILI_FIB_X" << endl;
break;
case(MIC_CILI_FIB_Z):
cout << "MIC_CILI_FIB_Z" << endl;
break;
......
......@@ -74,7 +74,7 @@ int main(int argc, char **argv)
mic_params.size[0] = n;
mic_params.size[1] = n;
mic_params.size[2] = n;
mic_params.type = MIC3D_8;
mic_params.type = MIC_CILI_FIB_X;
mic_params.geo_params[0] = 0.1;
mic_params.geo_params[1] = 0.02;
mic_params.geo_params[2] = 0.01;
......@@ -101,7 +101,7 @@ int main(int argc, char **argv)
auto start = high_resolution_clock::now();
double sig[6];
double sig[6], ctan[36];
double eps[6] = { 0. };
cout << scientific;
......@@ -138,6 +138,16 @@ int main(int argc, char **argv)
}
cout << endl;
micro.get_ctan(0, ctan);
cout << "ctan = " << endl;
for (int i = 0; i < 6; ++i) {
for (int j = 0; j < 6; ++j) {
cout << ctan[i * 6 + j] << "\t";
}
cout << endl;
}
cout << endl;
micro.update_vars();
file << setw(14)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment