|
occ
|
Lightweight POD struct for multipole coordinate system transformations. More...
#include <coordinate_system.h>
Public Member Functions | |
| Vec3 | raxyz () const |
| Vec3 | rbxyz () const |
| double | rax () const |
| double | ray () const |
| double | raz () const |
| double | rbx () const |
| double | rby () const |
| double | rbz () const |
| double | dx () const |
| double | dy () const |
| double | dz () const |
| double | raw_rax () const |
| double | raw_ray () const |
| double | raw_raz () const |
| double | raw_rbx () const |
| double | raw_rby () const |
| double | raw_rbz () const |
| bool | is_valid (double tolerance=1e-12) const |
| Validate coordinate system consistency Returns true if all computed quantities are consistent. | |
| bool | matches_orient_debug (double orient_rax, double orient_ray, double orient_raz, double orient_rbx, double orient_rby, double orient_rbz, double orient_r, double tolerance=1e-6) const |
| Check if coordinate system matches Orient's debug output Useful for validating against known Orient calculations. | |
Static Public Member Functions | |
| static CoordinateSystem | from_points (const Vec3 &ra_in, const Vec3 &rb_in) |
| Initialize coordinate system from two points Following Orient's mlinfo.f90 exactly: | |
| static CoordinateSystem | from_body_frame (const Vec3 &ra_in, const Vec3 &rb_in, const Mat3 &M_A, const Mat3 &M_B) |
| Initialize coordinate system with body-frame unit vectors (Orient's approach) | |
Public Attributes | |
| Vec3 | ra |
| Vec3 | rb |
| Vec3 | rab |
| double | r |
| Vec3 | er |
| bool | use_body_frame = false |
| Vec3 | e1r_body |
| Vec3 | e2r_body |
| double | cxx |
| double | cxy |
| double | cxz |
| double | cyx |
| double | cyy |
| double | cyz |
| double | czx |
| double | czy |
| double | czz |
Lightweight POD struct for multipole coordinate system transformations.
Coordinate definitions:
OCC convention for unit vector accessors: rax,ray,raz = +er (unit vector from A to B) rbx,rby,rbz = -er (unit vector from B to A)
Note: Orient uses the OPPOSITE sign convention: Orient rax = -er, Orient rbx = +er The S-function kernel code compensates by swapping which accessor it calls (e.g., using rbx() where Orient uses rax), so the numerical results match Orient exactly despite the naming difference.
|
inline |
|
inline |
|
inline |
|
inlinestatic |
Initialize coordinate system with body-frame unit vectors (Orient's approach)
This implements Orient's body-frame approach where:
| ra_in | Position of site A (lab frame) |
| rb_in | Position of site B (lab frame) |
| M_A | Rotation matrix for molecule A (body to lab) |
| M_B | Rotation matrix for molecule B (body to lab) |
|
inlinestatic |
Initialize coordinate system from two points Following Orient's mlinfo.f90 exactly:
|
inline |
Validate coordinate system consistency Returns true if all computed quantities are consistent.
|
inline |
Check if coordinate system matches Orient's debug output Useful for validating against known Orient calculations.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
| double occ::mults::CoordinateSystem::cxx |
| double occ::mults::CoordinateSystem::cxy |
| double occ::mults::CoordinateSystem::cxz |
| double occ::mults::CoordinateSystem::cyx |
| double occ::mults::CoordinateSystem::cyy |
| double occ::mults::CoordinateSystem::cyz |
| double occ::mults::CoordinateSystem::czx |
| double occ::mults::CoordinateSystem::czy |
| double occ::mults::CoordinateSystem::czz |
| Vec3 occ::mults::CoordinateSystem::e1r_body |
| Vec3 occ::mults::CoordinateSystem::e2r_body |
| Vec3 occ::mults::CoordinateSystem::er |
| double occ::mults::CoordinateSystem::r |
| Vec3 occ::mults::CoordinateSystem::ra |
| Vec3 occ::mults::CoordinateSystem::rab |
| Vec3 occ::mults::CoordinateSystem::rb |
| bool occ::mults::CoordinateSystem::use_body_frame = false |