~ubuntu-branches/ubuntu/quantal/psicode/quantal

« back to all changes in this revision

Viewing changes to src/bin/ccdensity/Gabcd.cc

  • Committer: Bazaar Package Importer
  • Author(s): Michael Banck, Michael Banck, Daniel Leidert
  • Date: 2009-02-23 00:12:02 UTC
  • mfrom: (1.1.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20090223001202-rutldoy3dimfpesc
Tags: 3.4.0-1
* New upstream release.

[ Michael Banck ]
* debian/patches/01_DESTDIR.dpatch: Refreshed.
* debian/patches/02_FHS.dpatch: Removed, applied upstream.
* debian/patches/03_debian_docdir: Likewise.
* debian/patches/04_man.dpatch: Likewise.
* debian/patches/06_466828_fix_gcc_43_ftbfs.dpatch: Likewise.
* debian/patches/07_464867_move_executables: Fixed and refreshed.
* debian/patches/00list: Adjusted.
* debian/control: Improved description.
* debian/patches-held: Removed.
* debian/rules (install/psi3): Do not ship the ruby bindings for now.

[ Daniel Leidert ]
* debian/rules: Fix txtdir via DEB_MAKE_INSTALL_TARGET.
* debian/patches/01_DESTDIR.dpatch: Refreshed.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*! \file
 
2
    \ingroup CCDENSITY
 
3
    \brief Enter brief description of file here 
 
4
*/
 
5
#include <cstdio>
 
6
#include <libdpd/dpd.h>
 
7
#include "MOInfo.h"
 
8
#include "Params.h"
 
9
#include "Frozen.h"
 
10
#define EXTERN
 
11
#include "globals.h"
 
12
 
 
13
namespace psi { namespace ccdensity {
 
14
 
 
15
void Gabcd(void)
 
16
{
 
17
  dpdbuf4 G, L, T;
 
18
  int G_irr;
 
19
  G_irr = params.G_irr;
 
20
 
 
21
  if(params.ref == 0) { /** RHF **/
 
22
    dpd_buf4_init(&G, CC_GAMMA, G_irr, 5, 5, 5, 5, 0, "GAbCd");
 
23
    dpd_buf4_init(&L, CC_GLG, G_irr, 0, 5, 0, 5, 0, "LIjAb");
 
24
    dpd_buf4_init(&T, CC_TAMPS, 0, 0, 5, 0, 5, 0, "tauIjAb");
 
25
    dpd_contract444(&L, &T, &G, 1, 1, 1.0, 0.0);
 
26
    dpd_buf4_close(&T);
 
27
    dpd_buf4_close(&L);
 
28
    if (params.ground)
 
29
      dpd_buf4_symm(&G);
 
30
    dpd_buf4_close(&G);
 
31
  }
 
32
  else if(params.ref == 1) { /** RHF/ROHF **/
 
33
 
 
34
    dpd_buf4_init(&G, CC_GAMMA, G_irr, 7, 7, 7, 7, 0, "GABCD");
 
35
    dpd_buf4_init(&L, CC_GLG, G_irr, 2, 7, 2, 7, 0, "LIJAB");
 
36
    dpd_buf4_init(&T, CC_TAMPS, 0, 2, 7, 2, 7, 0, "tauIJAB");
 
37
    dpd_contract444(&L, &T, &G, 1, 1, 1.0, 0.0);
 
38
    dpd_buf4_close(&T);
 
39
    dpd_buf4_close(&L);
 
40
    if (params.ground)
 
41
      dpd_buf4_symm(&G);
 
42
    dpd_buf4_close(&G);
 
43
 
 
44
    dpd_buf4_init(&G, CC_GAMMA, G_irr, 7, 7, 7, 7, 0, "Gabcd");
 
45
    dpd_buf4_init(&L, CC_GLG, G_irr, 2, 7, 2, 7, 0, "Lijab");
 
46
    dpd_buf4_init(&T, CC_TAMPS, 0, 2, 7, 2, 7, 0, "tauijab");
 
47
    dpd_contract444(&L, &T, &G, 1, 1, 1.0, 0.0);
 
48
    dpd_buf4_close(&T);
 
49
    dpd_buf4_close(&L);
 
50
    if (params.ground)
 
51
      dpd_buf4_symm(&G);
 
52
    dpd_buf4_close(&G);
 
53
 
 
54
    dpd_buf4_init(&G, CC_GAMMA, G_irr, 5, 5, 5, 5, 0, "GAbCd");
 
55
    dpd_buf4_init(&L, CC_GLG, G_irr, 0, 5, 0, 5, 0, "LIjAb");
 
56
    dpd_buf4_init(&T, CC_TAMPS, 0, 0, 5, 0, 5, 0, "tauIjAb");
 
57
    dpd_contract444(&L, &T, &G, 1, 1, 1.0, 0.0);
 
58
    dpd_buf4_close(&T);
 
59
    dpd_buf4_close(&L);
 
60
    if (params.ground)
 
61
      dpd_buf4_symm(&G);
 
62
    dpd_buf4_close(&G);
 
63
  }
 
64
  else if(params.ref == 2) { /** UHF **/
 
65
    dpd_buf4_init(&G, CC_GAMMA, G_irr, 7, 7, 7, 7, 0, "GABCD");
 
66
    dpd_buf4_init(&L, CC_GLG, G_irr, 2, 7, 2, 7, 0, "LIJAB");
 
67
    dpd_buf4_init(&T, CC_TAMPS, 0, 2, 7, 2, 7, 0, "tauIJAB");
 
68
    dpd_contract444(&L, &T, &G, 1, 1, 1.0, 0.0);
 
69
    dpd_buf4_close(&T);
 
70
    dpd_buf4_close(&L);
 
71
    dpd_buf4_symm(&G);
 
72
    dpd_buf4_close(&G);
 
73
 
 
74
    dpd_buf4_init(&G, CC_GAMMA, G_irr, 17, 17, 17, 17, 0, "Gabcd");
 
75
    dpd_buf4_init(&L, CC_GLG, G_irr, 12, 17, 12, 17, 0, "Lijab");
 
76
    dpd_buf4_init(&T, CC_TAMPS, 0, 12, 17, 12, 17, 0, "tauijab");
 
77
    dpd_contract444(&L, &T, &G, 1, 1, 1.0, 0.0);
 
78
    dpd_buf4_close(&T);
 
79
    dpd_buf4_close(&L);
 
80
    dpd_buf4_symm(&G);
 
81
    dpd_buf4_close(&G);
 
82
 
 
83
    dpd_buf4_init(&G, CC_GAMMA, G_irr, 28, 28, 28, 28, 0, "GAbCd");
 
84
    dpd_buf4_init(&L, CC_GLG, G_irr, 22, 28, 22, 28, 0, "LIjAb");
 
85
    dpd_buf4_init(&T, CC_TAMPS, 0, 22, 28, 22, 28, 0, "tauIjAb");
 
86
    dpd_contract444(&L, &T, &G, 1, 1, 1.0, 0.0);
 
87
    dpd_buf4_close(&T);
 
88
    dpd_buf4_close(&L);
 
89
    dpd_buf4_symm(&G);
 
90
    dpd_buf4_close(&G);
 
91
  }
 
92
}
 
93
 
 
94
}} // namespace psi::ccdensity