| 37 | } |
| 38 | |
| 39 | Material::Ptr Material::create_orthotropic(Float density, |
| 40 | const VectorF& young_modulus, |
| 41 | const VectorF& poisson_ratio, |
| 42 | const VectorF& shear_modulus) { |
| 43 | const size_t dim = young_modulus.size(); |
| 44 | if (dim == 2) { |
| 45 | return Ptr(new OrthotropicMaterial<2>( |
| 46 | density, young_modulus, poisson_ratio, shear_modulus)); |
| 47 | } else if (dim == 3) { |
| 48 | return Ptr(new OrthotropicMaterial<3>( |
| 49 | density, young_modulus, poisson_ratio, shear_modulus)); |
| 50 | } else { |
| 51 | std::stringstream err_msg; |
| 52 | err_msg << "Unsupported dimension: " << dim; |
| 53 | throw NotImplementedError(err_msg.str()); |
| 54 | } |
| 55 | } |
| 56 | |
| 57 | Material::Ptr Material::create_periodic( |
| 58 | Material::Ptr mat1, Material::Ptr mat2, VectorF axis, |
nothing calls this directly
no test coverage detected