From e9d09ce6a1a877039b0bd97668c95459d50ccf39 Mon Sep 17 00:00:00 2001 From: jthorn Date: Tue, 26 Jun 2001 08:39:53 +0000 Subject: rename in_range() --> is_in_range() git-svn-id: http://svn.einsteintoolkit.org/cactus/EinsteinAnalysis/AHFinderDirect/trunk@114 f88db872-0e4f-0410-b76b-b9085cfa78c5 --- src/jtutil/linear_map.cc | 4 ++-- src/jtutil/linear_map.hh | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'src/jtutil') diff --git a/src/jtutil/linear_map.cc b/src/jtutil/linear_map.cc index b3b6e60..281bed4 100644 --- a/src/jtutil/linear_map.cc +++ b/src/jtutil/linear_map.cc @@ -47,7 +47,7 @@ linear_map::linear_map(const linear_map &lm_in, : delta_(lm_in.delta_fp()), inverse_delta_(lm_in.inverse_delta_fp()), min_int_(min_int_in), max_int_(max_int_in) { -if (! (in_range(min_int_in) && in_range(max_int_in)) ) +if (! (is_in_range(min_int_in) && is_in_range(max_int_in)) ) then error_exit(ERROR_EXIT, "***** linear_map::linear_map:\n" " min_int_in=%d and/or max_int_in=%d\n" @@ -103,7 +103,7 @@ template fpt linear_map::fp_int_of_fp(fpt x) const { -if (! in_range(x)) +if (! is_in_range(x)) then error_exit(ERROR_EXIT, "***** linear_map::fp_int_of_fp:\n" " fpt value x=%g is (fuzzily) outside the grid!\n" diff --git a/src/jtutil/linear_map.hh b/src/jtutil/linear_map.hh index 10495c1..020a506 100644 --- a/src/jtutil/linear_map.hh +++ b/src/jtutil/linear_map.hh @@ -33,7 +33,7 @@ public: int max_int() const { return max_int_; } int N_points() const { return jtutil::how_many_in_range(min_int_,max_int_); } - bool in_range(int i) const + bool is_in_range(int i) const { return (i >= min_int()) && (i <= max_int()); } int clamp(int i) const { @@ -49,7 +49,7 @@ public: { return offset_ + delta_*i; } fpt fp_of_int(int i) const { - assert(in_range(i)); + assert(is_in_range(i)); return fp_of_int_unchecked(i); } @@ -62,7 +62,7 @@ public: fpt delta_fp() const { return delta_; } fpt inverse_delta_fp() const { return inverse_delta_; } fpt max_fp() const { return fp_of_int_unchecked(max_int_); } - bool in_range(fpt x) const + bool is_in_range(fpt x) const { return fuzzy::GE(x,min_fp()) && fuzzy::LE(x,max_fp()); -- cgit v1.2.3