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

« back to all changes in this revision

Viewing changes to src/lib/libchkpt/snumg.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
/*!
 
2
  \file
 
3
  \ingroup CHKPT
 
4
*/
 
5
 
 
6
#include <cstdio>
 
7
#include <cstdlib>
 
8
#include <psifiles.h>
 
9
#include <libpsio/psio.hpp>
 
10
extern "C" {
 
11
        #include <libchkpt/chkpt.h>
 
12
}
 
13
#include <libchkpt/chkpt.hpp>
 
14
 
 
15
using namespace psi;
 
16
 
 
17
int *Chkpt::rd_snumg(void)
 
18
{
 
19
        int *snumg;
 
20
        int nshell;
 
21
        char *keyword;
 
22
        keyword = build_keyword("Primitives per shell");
 
23
 
 
24
        nshell = rd_nshell();
 
25
        snumg = array<int>(nshell);
 
26
 
 
27
        psio->read_entry(PSIF_CHKPT, keyword, (char *) snumg, nshell*sizeof(int));
 
28
 
 
29
        free(keyword);
 
30
        return snumg;
 
31
}
 
32
 
 
33
void Chkpt::wt_snumg(int *snumg)
 
34
{
 
35
        int nshell;
 
36
        char *keyword;
 
37
        keyword = build_keyword("Primitives per shell");
 
38
 
 
39
        nshell = rd_nshell();
 
40
 
 
41
        psio->write_entry(PSIF_CHKPT, keyword, (char *) snumg, nshell*sizeof(int));
 
42
 
 
43
        free(keyword);
 
44
}
 
45
 
 
46
extern "C" {
 
47
/*!
 
48
** chkpt_rd_snumg()
 
49
**
 
50
** Reads in array of the numbers of the primitive Gaussians in shells.
 
51
**
 
52
**  takes no arguments.
 
53
**
 
54
**  returns: 
 
55
**    snumg = Reads in array of the numbers of the primitive Gaussians
 
56
**            in shells
 
57
**
 
58
** \ingroup CHKPT
 
59
*/
 
60
        int *chkpt_rd_snumg(void)
 
61
        {
 
62
                return _default_chkpt_lib_->rd_snumg();
 
63
        }
 
64
 
 
65
/*!
 
66
** chkpt_wt_snumg()
 
67
**
 
68
** Writes out array of the numbers of the primitive Gaussians in shells.
 
69
**
 
70
**  \param snumg = array of the numbers of the primitive Gaussians
 
71
**                 in shells
 
72
**
 
73
** \ingroup CHKPT
 
74
*/
 
75
        void chkpt_wt_snumg(int *snumg)
 
76
        {
 
77
                _default_chkpt_lib_->wt_snumg(snumg);
 
78
        }
 
79
}