CASM
AClustersApproachtoStatisticalMechanics
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules
LatticeIsEquivalent.hh
Go to the documentation of this file.
1 #ifndef CASM_LatticeIsEquivalent
2 #define CASM_LatticeIsEquivalent
3 
4 #include "casm/external/Eigen/Dense"
6 
7 namespace CASM {
8 
15 
16  public:
17 
18  LatticeIsEquivalent(const Lattice &lat, double _tol = TOL);
19 
20 
22  bool operator()(const Lattice &B) const;
23 
25  bool operator()(const SymOp &op) const;
26 
28  bool operator()(const Eigen::Matrix3d &cart_op) const;
29 
31  bool operator()(const Eigen::Matrix3i &tfrac_op) const;
32 
33  const Lattice &lat() const;
34 
36  double map_error() const;
37 
39  Eigen::Matrix3d cart_op() const;
40 
42  SymOp sym_op() const;
43 
44  private:
45 
47  bool _check(const Eigen::Matrix3d &tfrac_op) const;
48 
49  const Eigen::Matrix3d &lat_column_mat() const;
50 
51  const Eigen::Matrix3d &inv_lat_column_mat() const;
52 
54  double m_tol;
55  mutable double m_map_error;
57 
58  };
59 
60 }
61 
62 #endif
63 
SymOp sym_op() const
Return the SymOp, constructed from the map_error and cart_op stored after performing an equivalence c...
bool operator()(const Lattice &B) const
Is this lattice the same, even if they have different lattice vectors.
Main CASM namespace.
Definition: complete.cpp:8
const double TOL
Putting all the Lattice comparisons in one place.
SymOp is the Coordinate representation of a symmetry operation it keeps fraction (FRAC) and Cartesian...
Definition: SymOp.hh:28
const Lattice & lat() const
const Eigen::Matrix3d & lat_column_mat() const
LatticeIsEquivalent(const Lattice &lat, double _tol=TOL)
bool _check(const Eigen::Matrix3d &tfrac_op) const
Find the effect of applying symmetry to the lattice vectors.
double map_error() const
Return the mapping error, calculated after performing an equivalence check.
Eigen::Matrix3d Matrix3d
const Eigen::Matrix3d & inv_lat_column_mat() const
Eigen::Matrix3d cart_op() const
Return the cartesian SymOp matrix, stored after performing an equivalence check.