16 class FunctionVisitor;
22 namespace BasisSet_impl {
23 class ArgList :
public std::vector<BasisSet const *> {
25 using std::vector<BasisSet const *>::push_back;
29 template <
typename BSetResolvable>
37 void add(std::vector<BasisSet>
const &BB);
39 void add(std::vector<BasisSet const *>
const &BB);
48 public std::enable_shared_from_this<BasisSet> {
76 std::vector<std::shared_ptr<BasisSet> >
const &
arguments()
const {
94 return std::make_shared<BasisSet>(*
this);
142 void set_dof_IDs(
const std::vector<Index> &new_IDs);
161 std::vector<Index>
const &compatibility_map);
180 const DiscreteDoF &allowed_occs,
const std::vector<double> &occ_probs,
197 Index min_order,
bool even_only);
235 template <
typename IteratorType>
236 void remote_eval_to(IteratorType result_begin, IteratorType result_end)
const;
240 template <
typename IteratorType>
241 void remote_deval_to(IteratorType result_begin, IteratorType result_end,
284 static Index ID_COUNT(0);
301 const std::vector<Index> &after_IDs);
312 jsonParser &
to_json(
const BasisSet &
bset, jsonParser &json);
322 template <
typename IteratorType>
324 IteratorType result_end)
const {
328 for (; result_begin != result_end; ++result_begin) {
338 template <
typename IteratorType>
340 IteratorType result_end,
346 for (; result_begin != result_end; ++result_begin) {
Basic std::vector like container (deprecated)
const T & operator[](Index ind) const
Function * & at(Index ind)
ArgList(BSetResolvable const &B)
void add(BasisSet const &B)
void add(BasisSet const *B)
void construct_invariant_polynomials(ArgList const &tsubs, const SymGroup &head_sym_group, Index order, Index min_dof_order=1)
void _deval_to_cache(const DoF::RemoteHandle &_dvar) const
void from_json(const jsonParser &json)
void construct_polynomials_by_order(ArgList const &tsubs, Index order)
std::vector< std::shared_ptr< BasisSet > > m_argument
void remote_eval_and_add_to(Array< double > &cumulant) const
SymGroupRepID basis_symrep_ID() const
std::vector< Index > m_dof_IDs
friend BasisSet direct_sum(BasisSet::ArgList const &_subs)
const Array< SubBasis > & dof_sub_bases() const
Function const * back() const
void set_basis_symrep_ID(SymGroupRepID new_ID)
bool compare(const BasisSet &RHS) const
bool _update_dof_IDs(const std::vector< Index > before_IDs, const std::vector< Index > &after_IDs)
BasisSet calc_normal_basis(const SymGroup &head_sym_group, Eigen::MatrixXd &trans_mat) const
void append(const BasisSet &RHS, std::function< Function *(Function *)> const &transform=CASM_TMP::UnaryIdentity< Function * >())
Append contents of.
bool satisfies_exponent_constraints(const Array< Index > &expons) const
void remote_eval_to(IteratorType result_begin, IteratorType result_end) const
void construct_harmonic_polynomials(const ArgList &tsubs, Index order, Index min_order, bool even_only)
void set_variable_basis(const DoFSet &_dof_set)
Define the basis set to contain only variables (e.g., x,y,z)
void set_dof_IDs(const std::vector< Index > &new_IDs)
std::vector< std::set< Index > > independent_sub_bases() const
void calc_invariant_functions(const SymGroup &head_sym_group)
void _eval_to_cache() const
const Array< PolyConstraint > & max_poly_constraints() const
void remote_deval_and_add_to(Array< double > &cumulant, const DoF::RemoteHandle &dvar) const
BasisSet(const std::string &name="", ArgList const &_args=ArgList())
std::pair< SubBasis, Index > PolyConstraint
Array< PolyConstraint > & _min_poly_constraints()
const std::vector< Index > & dof_IDs() const
void _set_arguments(const std::vector< std::shared_ptr< BasisSet > > &new_args)
std::vector< double > m_deval_cache
int dependency_layer() const
jsonParser & to_json(jsonParser &json) const
void set_name(const std::string &new_name)
Function * _linear_combination(const Eigen::VectorXd &coeffs) const
bool accept(const FunctionVisitor &visitor)
void push_back(Function *new_func)
void add_min_poly_constraint(const Array< Index > &expons, Index expon_sum)
void construct_orthonormal_discrete_functions(const DiscreteDoF &allowed_occs, const Eigen::MatrixXd &gram_mat, Index basis_ind, const SymGroup &symgroup)
const SubBasis & dof_sub_basis(Index i) const
Array< PolyConstraint > m_min_poly_constraints
Index min_poly_order() const
const double & eval_cache(Index i) const
const std::string & name() const
BasisSet poly_quotient_set(const Function *divisor) const
Array< SubBasis > m_dof_subbases
void get_symmetry_representation(const SymGroup &head_sym_group) const
BasisSet transform_copy(const Eigen::MatrixXd &trans_mat) const
Index max_poly_order() const
int register_remotes(const std::vector< DoF::RemoteHandle > &remote_handles)
bool make_orthogonal_to(Function const *ortho_func)
BasisSet_impl::ArgList ArgList
Array< PolyConstraint > & _max_poly_constraints()
SymGroupRepID m_basis_symrep_ID
std::vector< std::shared_ptr< BasisSet > > const & arguments() const
std::shared_ptr< BasisSet > shared_copy() const
void _set_arguments(const ArgList &new_args)
void reshape_and_append(const BasisSet &RHS, std::vector< Index > const &compatibility_map)
Array< PolyConstraint > m_max_poly_constraints
BasisSet & apply_sym(const SymOp &op, int dependency_layer=1)
const double & deval_cache(Index i) const
const BasisSet & operator=(const BasisSet &RHS)
std::vector< double > m_eval_cache
void add_max_poly_constraint(const Array< Index > &expons, Index expon_sum)
const Array< PolyConstraint > & min_poly_constraints() const
Function const * operator[](Index i) const
void remote_deval_to(IteratorType result_begin, IteratorType result_end, const DoF::RemoteHandle &dvar) const
virtual double cache_eval() const =0
virtual double cache_deval(const DoF::RemoteHandle &dvar) const =0
SymGroup is a collection of symmetry operations that satisfy the group property The symmetry operatio...
Type-safe ID object for communicating and accessing Symmetry representation info.
SymOp is the Coordinate representation of a symmetry operation it keeps fraction (FRAC) and Cartesian...
void push_back(const T &toPush)
jsonParser & to_json(const ClexDescription &desc, jsonParser &json)
BasisSet direct_sum(BasisSet::ArgList const &_subs)
BasisSet operator*(const SymOp &LHS, const BasisSet &RHS)
void from_json(ClexDescription &desc, const jsonParser &json)
INDEX_TYPE Index
For long integer indexing:
Unary transformation that behaves as Identity (i.e. transform(arg) == arg is true)