~ubuntu-branches/ubuntu/vivid/psicode/vivid

« back to all changes in this revision

Viewing changes to src/bin/cceom/check_sum.c

  • Committer: Bazaar Package Importer
  • Author(s): Michael Banck
  • Date: 2008-06-07 16:49:57 UTC
  • mfrom: (2.1.2 hardy)
  • Revision ID: james.westby@ubuntu.com-20080607164957-8pifvb133yjlkagn
Tags: 3.3.0-3
* debian/rules (DEB_MAKE_CHECK_TARGET): Do not abort test suite on
  failures.
* debian/rules (DEB_CONFIGURE_EXTRA_FLAGS): Set ${bindir} to /usr/lib/psi.
* debian/rules (install/psi3): Move psi3 file to /usr/bin.
* debian/patches/07_464867_move_executables.dpatch: New patch, add
  /usr/lib/psi to the $PATH, so that the moved executables are found.
  (closes: #464867)
* debian/patches/00list: Adjusted.

Show diffs side-by-side

added added

removed removed

Lines of Context:
6
6
 
7
7
extern double norm_C(dpdfile2 *CME, dpdfile2 *Cme,
8
8
    dpdbuf4 *CMNEF, dpdbuf4 *Cmnef, dpdbuf4 *CMnEf);
9
 
 
 
9
extern double norm_C_full(double C0, dpdfile2 *CME, dpdfile2 *Cme,
 
10
    dpdbuf4 *CMNEF, dpdbuf4 *Cmnef, dpdbuf4 *CMnEf);
10
11
extern double norm_C_rhf(dpdfile2 *CME, dpdbuf4 *CMnEf, dpdbuf4 *CMnfE);
 
12
extern double norm_C_rhf_full(double C0, dpdfile2 *CME, dpdbuf4 *CMnEf, dpdbuf4 *CMnfE);
11
13
 
12
14
void check_sum(char *term_lbl, int index, int irrep) {
13
15
  int save_params_ref;
14
16
  dpdfile2 Sia, SIA;
15
17
  dpdbuf4 SIJAB, Sijab, SIjAb, SIjbA;
16
18
  static double old_norm=0;
17
 
  double norm,dotval;
 
19
  double norm,dotval,S0;
18
20
  char lbl[80];
19
21
 
20
22
  if (!strcmp(term_lbl,"reset"))  {
34
36
    dpd_buf4_sort(&SIjAb, EOM_SIjAb, pqsr, 0, 5, "SIjbA"); 
35
37
    dpd_buf4_init(&SIjbA, EOM_SIjAb, irrep, 0, 5, 0, 5, 0, "SIjbA");
36
38
 
37
 
    norm = norm_C_rhf(&SIA, &SIjAb, &SIjbA);
 
39
    if (!params.full_matrix) {
 
40
      norm = norm_C_rhf(&SIA, &SIjAb, &SIjbA);
 
41
                }
 
42
    else {
 
43
      sprintf(lbl, "%s %d", "S0", index);
 
44
      psio_read_entry(EOM_SIA, lbl, (char *) &S0, sizeof(double));
 
45
      norm = norm_C_rhf_full(S0, &SIA, &SIjAb, &SIjbA);
 
46
                }
38
47
 
39
48
    dpd_file2_close(&SIA);
40
49
    dpd_buf4_close(&SIjAb);