MPQC 3.0.0-alpha
Loading...
Searching...
No Matches
ccr12_triples.h
1//
2// ccr12_triples.h : computes unconventional triples correction to (T) model
3//
4// Copyright (C) 2009 Toru Shiozaki
5//
6// Author: Toru Shiozaki <shiozaki.toru@gmail.com>
7// Maintainer: TS
8//
9// This file is part of the SC Toolkit.
10//
11// The SC Toolkit is free software; you can redistribute it and/or modify
12// it under the terms of the GNU Library General Public License as published by
13// the Free Software Foundation; either version 2, or (at your option)
14// any later version.
15//
16// The SC Toolkit is distributed in the hope that it will be useful,
17// but WITHOUT ANY WARRANTY; without even the implied warranty of
18// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19// GNU Library General Public License for more details.
20//
21// You should have received a copy of the GNU Library General Public License
22// along with the SC Toolkit; see the file COPYING.LIB. If not, write to
23// the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
24//
25// The U.S. Government is granted a limited license as per AL 91-7.
26//
27
28#pragma once
29#ifndef __chemistry_qc_ccr12_ccr12_triples_h
30#define __chemistry_qc_ccr12_ccr12_triples_h
31
32#include <chemistry/qc/ccr12/ccr12_info.h>
33#include <iostream>
34
35
36//define this when GGspace = ip is to be used.
37#define USE_GG_SPACE_EQ_IP
38
39namespace sc {
40
41class CCR12_Triples : virtual public RefCount {
42 protected:
43 CCR12_Info* z;
44
45 Ref<Tensor> singles_intermediate_;
46 Ref<Tensor> doubles_intermediate_;
47 Ref<Tensor> rhs_intermediate_;
48 Ref<Tensor> lhs_intermediate_;
49
50 // Prediagonalization scheme
51 // only for ii cases.
52 void prediagon();
53 void fill_in_ltensors();
54 int pair_size_;
55
56 RefDiagSCMatrix bdiag_;
57 RefSCMatrix lmatrix_;
58 Ref<Tensor> ltensor1_;
59 Ref<Tensor> ltensor2_;
60
61// Two cases. From here...
62// for GGspace = ii
63 void singles();
64 void doubles();
65 void denom_contraction();
66 void denom_contraction_new();
67 void offset_hhphhh(Ref<Tensor>&);
68 double get_energy();
69// for GGspace = ip
70 void doubles_ig(Ref<Tensor>& out);
71 void singles_ig(Ref<Tensor>& out);
72 void denom_contraction_ig();
73 void offset_hgphhh(Ref<Tensor>&);
74 double get_energy_ig();
75// to here...
76
77 void offset_bphhh(Ref<Tensor>&);
78
79 public:
80 CCR12_Triples(CCR12_Info* inz) : z(inz) {};
81 ~CCR12_Triples() {};
82
83 double compute();
84
85};
86
87}
88
89#endif
90
CCR12_Info is the compilation of members that are used in CC and CC-R12 methods.
Definition ccr12_info.h:50
Definition ccr12_triples.h:41
The base class for all reference counted objects.
Definition ref.h:192
The RefDiagSCMatrix class is a smart pointer to an DiagSCMatrix specialization.
Definition matrix.h:389
The RefSCMatrix class is a smart pointer to an SCMatrix specialization.
Definition matrix.h:135
A template class that maintains references counts.
Definition ref.h:361
Contains all MPQC code up to version 3.
Definition mpqcin.h:14

Generated at Wed Sep 25 2024 02:45:29 for MPQC 3.0.0-alpha using the documentation package Doxygen 1.12.0.