MPQC  3.0.0-alpha
array.h
1 //
2 // array.h
3 //
4 // Copyright (C) 1996 Limit Point Systems, Inc.
5 //
6 // Author: Curtis Janssen <cljanss@limitpt.com>
7 // Maintainer: LPS
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 #ifndef _chemistry_qc_intv3_array_h
29 #define _chemistry_qc_intv3_array_h
30 
31 #include <iostream>
32 
33 namespace sc {
34 
36  private:
37  int n1_, n2_;
38  double **data_;
39  public:
42  void set_dim(int n1, int n2);
43  double &operator()(int i,int j) { return data_[i][j]; }
44  void print(std::ostream &);
45  int nbyte() const;
46 };
47 
49  private:
50  int n1_, n2_, n3_;
51  double ***data_;
52  public:
55  void set_dim(int n1, int n2, int n3);
56  double *operator()(int i,int j) { return data_[i][j]; }
57  double &operator()(int i,int j,int k) { return data_[i][j][k]; }
58  void print(std::ostream &);
59  int nbyte() const;
60 };
61 
63  private:
64  int n1_, n2_;
65  double ***data_;
66  public:
69  void set_dim(int n1, int n2);
70  double *&operator()(int i,int j) { return data_[i][j]; }
71  void print(std::ostream &);
72  int nbyte() const;
73 };
74 
76  private:
77  int n1_, n2_, n3_;
78  double ****data_;
79  public:
82  int n1() const { return n1_; }
83  int n2() const { return n2_; }
84  int n3() const { return n3_; }
85  void delete_data();
86  void set_dim(int n1, int n2, int n3);
87  double *&operator()(int i,int j,int k) { return data_[i][j][k]; }
88  double **operator()(int i,int j) { return data_[i][j]; }
89  double ***operator()(int i) { return data_[i]; }
90  void print(std::ostream &);
91  int nbyte() const;
92 };
93 
95  private:
96  int n1_, n2_, n3_, n4_;
97  double *****data_;
98  public:
101  void set_dim(int n1, int n2, int n3, int n4);
102  double *&operator()(int i,int j,int k,int l) { return data_[i][j][k][l]; }
103  void print(std::ostream &);
104  int nbyte() const;
105  double *****data() { return data_; }
106 };
107 
109  private:
110  int n1_, n2_, n3_;
111  int ***data_;
112  public:
113  IntV3Arrayint3();
114  ~IntV3Arrayint3();
115  void set_dim(int n1, int n2, int n3);
116  int &operator()(int i,int j,int k) { return data_[i][j][k]; }
117  int *operator()(int i,int j) { return data_[i][j]; }
118  int **operator()(int i) { return data_[i]; }
119  void print(std::ostream &);
120  int nbyte() const;
121 };
122 
124  private:
125  int n1_, n2_, n3_, n4_;
126  int ****data_;
127  public:
128  IntV3Arrayint4();
129  ~IntV3Arrayint4();
130  void set_dim(int n1, int n2, int n3, int n4);
131  int &operator()(int i,int j,int k,int l) { return data_[i][j][k][l]; }
132  void print(std::ostream &);
133  int nbyte() const;
134 };
135 
136 }
137 
138 #endif
139 
140 // Local Variables:
141 // mode: c++
142 // c-file-style: "CLJ"
143 // End:
sc::IntV3Arrayint3
Definition: array.h:108
sc::IntV3Arraydoublep3
Definition: array.h:75
sc::IntV3Arraydouble2
Definition: array.h:35
sc::IntV3Arraydoublep4
Definition: array.h:94
sc::IntV3Arraydoublep2
Definition: array.h:62
sc::IntV3Arrayint4
Definition: array.h:123
sc::IntV3Arraydouble3
Definition: array.h:48
sc
Contains all MPQC code up to version 3.
Definition: mpqcin.h:14

Generated at Sun Jan 26 2020 23:23:57 for MPQC 3.0.0-alpha using the documentation package Doxygen 1.8.16.