Psi4
shellrotation.h
Go to the documentation of this file.
1 /*
2  * @BEGIN LICENSE
3  *
4  * Psi4: an open-source quantum chemistry software package
5  *
6  * Copyright (c) 2007-2018 The Psi4 Developers.
7  *
8  * The copyrights for code used from other parties are included in
9  * the corresponding files.
10  *
11  * This file is part of Psi4.
12  *
13  * Psi4 is free software; you can redistribute it and/or modify
14  * it under the terms of the GNU Lesser General Public License as published by
15  * the Free Software Foundation, version 3.
16  *
17  * Psi4 is distributed in the hope that it will be useful,
18  * but WITHOUT ANY WARRANTY; without even the implied warranty of
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20  * GNU Lesser General Public License for more details.
21  *
22  * You should have received a copy of the GNU Lesser General Public License along
23  * with Psi4; if not, write to the Free Software Foundation, Inc.,
24  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
25  *
26  * @END LICENSE
27  */
28 
29 #ifndef _psi_src_lib_libmints_shellrotation_h_
30 #define _psi_src_lib_libmints_shellrotation_h_
31 
32 namespace psi {
33 
34 class SymmetryOperation;
35 class IntegralFactory;
36 
38  int n_;
39  int am_;
40  double** r_;
41 
42  void done();
43 
44  public:
46  ShellRotation(int n);
50  ShellRotation(int a, SymmetryOperation&, const IntegralFactory*, int pure = 0);
51  virtual ~ShellRotation();
52 
55 
58  void init(int a, SymmetryOperation&, const IntegralFactory*);
61  void init_pure(int a, SymmetryOperation&, const IntegralFactory*);
62 
64  int am() const { return am_; }
66  int dim() const { return n_; }
67 
69  double& operator()(int i, int j) { return r_[i][j]; }
71  double* operator[](int i) { return r_[i]; }
72 
74  ShellRotation operate(const ShellRotation& rot) const;
76  ShellRotation transform(const ShellRotation& rot) const;
77 
79  double trace() const;
80 
82  void print() const;
83 };
84 
85 } // namespace psi
86 
87 #endif // _psi_src_lib_libmints_shellrotation_h_
double & operator()(int i, int j)
Return an element of the transform matrix.
Definition: shellrotation.h:69
double ** r_
Definition: shellrotation.h:40
Definition: shellrotation.h:37
int n_
Definition: shellrotation.h:38
ShellRotation operate(const ShellRotation &rot) const
Returns the result of rot*this.
Definition: shellrotation.cc:233
void init_pure(int a, SymmetryOperation &, const IntegralFactory *)
Definition: shellrotation.cc:167
virtual ~ShellRotation()
Definition: shellrotation.cc:86
Definition: pointgrp.h:104
int am_
Definition: shellrotation.h:39
ShellRotation transform(const ShellRotation &rot) const
Returns the result of rot*this*transpose(rot).
Definition: shellrotation.cc:252
double trace() const
Return the trace of the transformation.
Definition: shellrotation.cc:283
ShellRotation & operator=(const ShellRotation &)
Assign this to another shell rotation.
Definition: shellrotation.cc:88
int am() const
Return the angular momentum.
Definition: shellrotation.h:64
void print() const
Print the object.
Definition: shellrotation.cc:289
Definition: integral.h:374
ShellRotation(int n)
Initialize this ShellRotation to hold a n by n transformation.
Definition: shellrotation.cc:69
void init(int a, SymmetryOperation &, const IntegralFactory *)
Definition: shellrotation.cc:116
double * operator[](int i)
Return a row of the transform matrix.
Definition: shellrotation.h:71
Definition: pointgrp.h:137
int dim() const
Return the number of functions in a shell.
Definition: shellrotation.h:66
void done()
Definition: shellrotation.cc:105