Loading...
Searching...
No Matches
MobileAtoms.h
Go to the documentation of this file.
1/*
2** This file is part of eOn.
3**
4** SPDX-License-Identifier: BSD-3-Clause
5**
6** Copyright (c) 2010--present, eOn Development Team
7** All rights reserved.
8**
9** Repo:
10** https://github.com/TheochemUI/eOn
11*/
12#pragma once
13
14#include "Eigen.h"
15#include "Matter.h"
16
17#include <string>
18
19namespace eonc {
20
22VectorXi freeAtomIndices(const Matter *matter);
23
25bool atomListMeansAll(const std::string &atomList);
26
39VectorXi resolveMobileAtoms(const Matter *matter, const std::string &atomList);
40
43VectorXi resolveMobileAtoms(const Matter *matter, const VectorXi &candidates);
44
46VectorXd packMobileRows(const AtomMatrix &full, const VectorXi &mobile);
47
49void unpackMobileRows(const VectorXd &packed, const VectorXi &mobile,
50 AtomMatrix &full);
51
54VectorXd mobileForces(Matter *matter, const VectorXi &mobile);
55
56} // namespace eonc
Eigen::Matrix< double, Eigen::Dynamic, 3, eOnStorageOrder > AtomMatrix
Definition Eigen.h:37
RAII resource manager for the ARTn C library with global synchronization.
bool atomListMeansAll(const std::string &atomList)
Whether atomList means "every free atom" (empty, "all", case-insensitive).
VectorXi resolveMobileAtoms(const Matter *matter, const std::string &atomList)
PHVA-class mobile set for FD Hessian and matrix-free Krylov (Lanczos / Davidson).
void unpackMobileRows(const VectorXd &packed, const VectorXi &mobile, AtomMatrix &full)
Write a 3*n_mobile vector into full AtomMatrix rows (other rows unchanged).
VectorXi freeAtomIndices(const Matter *matter)
Free (unfixed) atom indices in ascending order.
VectorXd packMobileRows(const AtomMatrix &full, const VectorXi &mobile)
Pack full (n_atoms,3) rows of mobile atoms into a 3*n_mobile vector.
VectorXd mobileForces(Matter *matter, const VectorXi &mobile)
Force components on mobile atoms after Matter has a valid force cache (calls getForces under the hood...