12 #ifndef MATERIAL_METRICS_HPP 13 #define MATERIAL_METRICS_HPP 57 std::vector<double> &random_positions,
58 std::vector<double> &random_rotations)
59 : particle_shape_({length_x, length_y, length_z}),
60 number_of_particles_(random_positions.size() / 3
u)
62 Initialize(random_positions, random_rotations);
73 void Initialize(std::vector<double> &random_positions,
74 std::vector<double> &random_rotations);
76 std::vector<Vector> particle_positions_;
77 std::vector<DenseMatrix> particle_orientations_;
78 Vector particle_shape_;
79 size_t number_of_particles_;
98 void CreatePeriodicPoints(
const Vector &x,
99 std::vector<Vector> &periodic_points)
const;
101 std::vector<Vector> points_;
102 std::vector<Edge> edges_;
107 #endif // MATERIAL_METRICS_HPP
Virtual class to define the interface for defining the material topology.
double GetDistanceTo(const Vector &x) const
Compute the distance between a point and the edge.
virtual ~MaterialTopology()=default
Class that implements an edge defined by a start and end point.
Class that implements the particle topology.
virtual double ComputeMetric(const Vector &x)=0
Compute the metric rho describing the material topology.
ParticleTopology(double length_x, double length_y, double length_z, std::vector< double > &random_positions, std::vector< double > &random_rotations)
double ComputeMetric(const Vector &x) final
Compute the metric rho describing the material topology.
Edge(const Vector &start, const Vector &end)
double u(const Vector &xvec)
double ComputeMetric(const Vector &x) final