120 p = (*(*(pit.
a)).p)[pit.
i];
131 cerr <<
"trying to delete a NULL optr in ~index_type()" <<
endl;
223 cerr <<
"Incompatible dmatrix bounds in " << __FILE__ <<
':' << __LINE__ <<
".\n";
230 cerr <<
" Error: dmatrix unable to allocate memory in "
231 << __FILE__ <<
':' << __LINE__ <<
'\n';
236 cerr <<
" Error: dmatrix unable to allocate memory in "
237 << __FILE__ <<
':' << __LINE__ <<
'\n';
241 for (
int i = nrl; i <= nrh; ++i)
295 cerr <<
"Incompatible i3_array bounds in " << __FILE__ <<
':' << __LINE__ <<
".\n";
300 cerr <<
" Error: d3_array unable to allocate memory in "
301 << __FILE__ <<
':' << __LINE__ <<
'\n';
306 cerr <<
" Error: d3_array unable to allocate memory in "
307 << __FILE__ <<
':' << __LINE__ <<
'\n';
311 for (
int i = sl; i <= sh; ++i)
313 t[i].
allocate(nrl(i), nrh(i), ncl(i), nch(i));
332 if (
int(sl) >
int(sh))
341 cerr <<
"Incompatible d3_array bounds in " << __FILE__ <<
':' << __LINE__ <<
".\n";
346 cerr <<
" Error: d3_array unable to allocate memory in "
347 << __FILE__ <<
':' << __LINE__ <<
'\n';
352 cerr <<
" Error: d3_array unable to allocate memory in "
353 << __FILE__ <<
':' << __LINE__ <<
'\n';
357 for (
int i = sl; i <= sh; ++i)
359 t[i].
allocate(nrl[i], nrh[i], ncl[i], nch[i]);
385 cerr <<
"Incompatible imatrix bounds in " << __FILE__ <<
':' << __LINE__ <<
".\n";
390 cerr <<
"0 columns - was this intentional?\n" ;
397 unsigned int ss =
static_cast<unsigned int>(nrh - nrl + 1);
400 cerr <<
" Error: imatrix unable to allocate memory in "
401 << __FILE__ <<
':' << __LINE__ <<
'\n';
406 cerr <<
" Error: imatrix unable to allocate memory in "
407 << __FILE__ <<
':' << __LINE__ <<
'\n';
411 for (
int i = nrl; i <= nrh; ++i)
438 static_cast<unsigned int>(nch < ncl ? 0 : nch - ncl + 1);
441 if ((
v =
new double[ss]) == 0)
443 cerr <<
" Error: dvector unable to allocate memory in "
444 << __FILE__ <<
':' << __LINE__ <<
'\n';
447 #if defined(THREAD_SAFE)
448 if ((
shape =
new ts_vector_shapex(ncl, nch,
v)) == NULL)
453 cerr <<
" Error: dvector unable to allocate memory in "
454 << __FILE__ <<
':' << __LINE__ <<
'\n';
460 #ifdef SAFE_INITIALIZE
492 unsigned int ss =
static_cast<unsigned int>(
496 if ((
v =
new int[ss]) == 0)
498 cerr <<
" Error: ivector unable to allocate memory in "
499 << __FILE__ <<
':' << __LINE__ <<
'\n';
504 cerr <<
" Error: ivector unable to allocate memory in "
505 << __FILE__ <<
':' << __LINE__ <<
'\n';
509 #ifdef SAFE_INITIALIZE
index_guts()
Default constructor.
void allocate(void)
Does NOT allocate, but initializes empty d3_array.
double * v
pointer to the data
virtual index_guts * operator[](int i)
vector_index(const ivector &v)
Constructor for ivector.
Uses polymorphism to get index information from various data types to be used in constructing and all...
ivector()
Default constructor.
void allocate(void)
Does not allocate, but initializes imatrix members.
Description not yet available.
dvector()
Construct a dvector without allocating memory.
Description not yet available.
void allocate(void)
Author: David Fournier Copyright (c) 2008-2012 Regents of the University of California.
Derived class of index types for i3_array.
dmatrix(void)
Default constructor.
Vector of double precision numbers.
three_array_shape * shape
int indexmin() const
Get minimum valid index.
~smart_counter()
Destructor.
ad_integer(const int &_d, const adkludge &)
index_type operator()(int i)
Description not yet available.
Derived class of index types for ivector.
void allocate(int ncl, int ncu)
Allocate memory for a dvector.
Description not yet available.
void allocate(void)
Allocate dvector without allocating memory.
Keeps track of total number of copies.
Derived class of index types for i4_array.
Description not yet available.
Derived class of index types for ad_integer.
Abstract base class for different index types.
i3_array(void)
Author: David Fournier Copyright (c) 2008-2012 Regents of the University of California.
d3_array(void)
Default constructor.
Description not yet available.
smart_counter()
Default constructor.
prnstream & endl(prnstream &)
void allocate(void)
Does NOT allocate, but set empty i3_array.
Array of integers(int) with indexes from index_min to indexmax.
virtual ~index_guts()
Destructor.
virtual ~vector_index()
Destructor.
Derived class of index types for imatrix.
int indexmax() const
Get maximum valid index.
Description not yet available.
Description not yet available.
virtual ~matrix_index()
Destructor.
index_type operator[](int i)
Description not yet available.
void allocate()
Does not allocate, but initializes class members.
int index_min
minimum valid subscript
Holds "shape" information for vector objects.
virtual index_guts * operator[](int i)
Description not yet available.
vector_shapex * shape
pointer to vector "shape"
index_type(const int x)
Description not yet available.
three_array_shape * shape
unsigned int rowsize() const
unsigned int slicesize() const
unsigned int slicesize() const
Description not yet available.
int index_max
maximum valid subscript
void allocate(const ad_integer &ncl, const index_type &ncu)
Allocate vector of integers with dimension [_ncl to _nch].