ADMB Documentation  -a65f1c97
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
d6arr1.cpp
Go to the documentation of this file.
1 
5 #include "fvar.hpp"
6 
13 d6_array operator/(const d6_array& darray, const double divisor)
14 {
15  d6_array results;
16  results.allocate(darray);
17  for (int i = results.indexmin(); i <= results.indexmax(); ++i)
18  {
19  results.elem(i) = darray.elem(i) / divisor;
20  }
21  return results;
22 }
28 void d6_array::operator/=(const double divisor)
29 {
30  for (int i = indexmin(); i <= indexmax(); ++i)
31  {
32  elem(i) /= divisor;
33  }
34 }
void allocate(int hhsl, int hhsu, int hsl, int hsu, int sl, int sh, int nrl, int nrh, int ncl, int nch, int l6, int u6)
Allocate d6_array with specified dimensions.
Definition: d6arr.cpp:172
int indexmin() const
Definition: fvar.hpp:6812
d5_array & elem(int i)
Definition: fvar.hpp:6828
Description not yet available.
Definition: fvar.hpp:6673
Author: David Fournier Copyright (c) 2008-2012 Regents of the University of California.
int indexmax() const
Definition: fvar.hpp:6816
d3_array operator/(const d3_array &m, const double d)
Author: David Fournier.
Definition: d3arr2b.cpp:14
void operator/=(double d)
Divides all elements of d6_array by divisor.
Definition: d6arr1.cpp:28