23 #if !defined (octave_Range_h)
24 #define octave_Range_h 1
38 : rng_base (0), rng_limit (0), rng_inc (0), rng_nelem (0),
cache (1, 0) { }
41 : rng_base (r.rng_base), rng_limit (r.rng_limit), rng_inc (r.rng_inc),
45 : rng_base (b), rng_limit (l), rng_inc (1),
46 rng_nelem (nelem_internal ()),
cache () { }
48 Range (
double b,
double l,
double i)
49 : rng_base (b), rng_limit (l), rng_inc (i),
50 rng_nelem (nelem_internal ()),
cache () { }
54 : rng_base (b), rng_limit (b + (n-1) * i), rng_inc (i),
55 rng_nelem (n),
cache ()
61 double base (
void)
const {
return rng_base; }
62 double limit (
void)
const {
return rng_limit; }
63 double inc (
void)
const {
return rng_inc; }
66 bool all_elements_are_ints (
void)
const;
68 Matrix matrix_value (
void)
const;
70 double min (
void)
const;
71 double max (
void)
const;
73 void sort_internal (
bool ascending =
true);
93 void set_base (
double b)
102 void set_limit (
double l)
111 void set_inc (
double i)
120 friend OCTAVE_API std::ostream&
operator << (std::ostream& os,
132 void print_range (
void);