MPQC  2.3.1
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 #ifdef __GNUC__
29 #pragma interface
30 #endif
31 
32 #ifndef _chemistry_qc_intv3_array_h
33 #define _chemistry_qc_intv3_array_h
34 
35 #include <iostream>
36 
37 namespace sc {
38 
40  private:
41  int n1_, n2_;
42  double **data_;
43  public:
46  void set_dim(int n1, int n2);
47  double &operator()(int i,int j) { return data_[i][j]; }
48  void print(std::ostream &);
49  int nbyte() const;
50 };
51 
53  private:
54  int n1_, n2_, n3_;
55  double ***data_;
56  public:
59  void set_dim(int n1, int n2, int n3);
60  double *operator()(int i,int j) { return data_[i][j]; }
61  double &operator()(int i,int j,int k) { return data_[i][j][k]; }
62  void print(std::ostream &);
63  int nbyte() const;
64 };
65 
67  private:
68  int n1_, n2_;
69  double ***data_;
70  public:
73  void set_dim(int n1, int n2);
74  double *&operator()(int i,int j) { return data_[i][j]; }
75  void print(std::ostream &);
76  int nbyte() const;
77 };
78 
80  private:
81  int n1_, n2_, n3_;
82  double ****data_;
83  public:
86  int n1() const { return n1_; }
87  int n2() const { return n2_; }
88  int n3() const { return n3_; }
89  void delete_data();
90  void set_dim(int n1, int n2, int n3);
91  double *&operator()(int i,int j,int k) { return data_[i][j][k]; }
92  double **operator()(int i,int j) { return data_[i][j]; }
93  double ***operator()(int i) { return data_[i]; }
94  void print(std::ostream &);
95  int nbyte() const;
96 };
97 
99  private:
100  int n1_, n2_, n3_, n4_;
101  double *****data_;
102  public:
105  void set_dim(int n1, int n2, int n3, int n4);
106  double *&operator()(int i,int j,int k,int l) { return data_[i][j][k][l]; }
107  void print(std::ostream &);
108  int nbyte() const;
109  double *****data() { return data_; }
110 };
111 
113  private:
114  int n1_, n2_, n3_;
115  int ***data_;
116  public:
117  IntV3Arrayint3();
118  ~IntV3Arrayint3();
119  void set_dim(int n1, int n2, int n3);
120  int &operator()(int i,int j,int k) { return data_[i][j][k]; }
121  int *operator()(int i,int j) { return data_[i][j]; }
122  int **operator()(int i) { return data_[i]; }
123  void print(std::ostream &);
124  int nbyte() const;
125 };
126 
128  private:
129  int n1_, n2_, n3_, n4_;
130  int ****data_;
131  public:
132  IntV3Arrayint4();
133  ~IntV3Arrayint4();
134  void set_dim(int n1, int n2, int n3, int n4);
135  int &operator()(int i,int j,int k,int l) { return data_[i][j][k][l]; }
136  void print(std::ostream &);
137  int nbyte() const;
138 };
139 
140 }
141 
142 #endif
143 
144 // Local Variables:
145 // mode: c++
146 // c-file-style: "CLJ"
147 // End:
sc::IntV3Arrayint3
Definition: array.h:112
sc::IntV3Arraydoublep3
Definition: array.h:79
sc::IntV3Arraydouble2
Definition: array.h:39
sc::IntV3Arraydoublep4
Definition: array.h:98
sc::IntV3Arraydoublep2
Definition: array.h:66
sc::IntV3Arrayint4
Definition: array.h:127
sc::IntV3Arraydouble3
Definition: array.h:52

Generated at Sun Jan 26 2020 23:33:03 for MPQC 2.3.1 using the documentation package Doxygen 1.8.16.