in the given base
979889
public static function buildBasedIntRegex($base)
    {
        assert(2 <= $base && $base <= 16);
        $regex = '/(?i:[0-';
        if ($base <= 10) {
            $regex .= (string)$base-1;
        } else {
            $regex .= '9a-' . strtolower(dechex($base-1));
        }
        $regex .= '])+/';
        return $regex;
    }
841940
def get_base(self):
    
    if self._type == 'query':
      return self._observable.get_query_base()
    return self._observable.get_target_base()
701315
def inv(self):
        """"""
        result = Rotation(self.r.transpose())
        result._cache_inv = self
        return result
458400
function (coords) {
        var base = {
                ref: this.ref,
                length: this.length,
                cycles: this.cycles
            },
            position,
            iteration;

        if (!_.isObject(coords)) {
            return _.assign(base, {eof: true, bof: true, empty: this.empty()});
        }
        if (!this.length) {
            return _.assign(base, {eof: true, bof: true, empty: true});
        }

        position = coords.position;
        iteration = coords.iteration;

        // increment position
        position += 1;

        // check if we need to increment cycle
        if (position >= this.length) {
            // set position to 0 and increment iteration
            position = 0;
            iteration += 1;

            if (iteration >= this.cycles) {
                return _.assign(base, {
                    position: this.length - 1,
                    iteration: iteration - 1,
                    eof: true
                });
            }

            return _.assign(base, {
                position: position,
                iteration: iteration,
                cr: true
            });
        }

        return _.assign(base, {position: position, iteration: iteration});
    }
593865
def import_around base
      import_instance_variable(:around_all, base)
      base.around?.each {|(m,p)| self.around(m, &p)}
    end
1011935
public final void setBase(int bx, int by, int bz) {
        this.bx = bx;
        this.by = by;
        this.bz = bz;
    }
1277286
def baseoffset(self):
        """"""
        try:
            return self.parent.baseoffset + self.offset
        except AttributeError:
            return self.offset
916088
function(base) {
    for (var i=1; i < arguments.length; i++) {
      var ext = arguments[i];
      for (var key in ext) {
        if (ext.hasOwnProperty(key)) base[key] = ext[key];
      }
    }
    return base;
  }
904790
function baseEach(iterator, object) {
  var ks = keys(object);

  for (var i = 0; i < ks.length; i += 1) {
    // Break iteration early if `iterator` returns `false`
    if (iterator(object[ks[i]], ks[i], object) === false) {
      break;
    }
  }
}
1085107
def convert_base(arg, from_base, to_base):
    
    return ops.BaseConvert(arg, from_base, to_base).to_expr()
557424
def given(self):
        """"""
        if self._primary.value[0] and self._primary.value[2]:
            return self._primary.value[0] + ' ' + self._primary.value[2]
        return self._primary.value[0] or self._primary.value[2]
720684
def position(self):
        '''
        
        '''
        if self.end != self.start + 1:
            raise ValueError("Not a single base: %s" % str(self))
        return self.start
312424
public static double log(double d, double base) {
        if(base==1.0 || base<=0.0) {
            throw new IllegalArgumentException("Invalid base for logarithm.");
        }
        return Math.log(d)/Math.log(base);
    }
503018
def _compute_base_term(self, C, rup, dists):
        
        c1 = self.CONSTS['c1']
        R = np.sqrt(dists.rrup ** 2 + self.CONSTS['c4'] ** 2)

        base_term = (C['a1'] +
                     C['a8'] * ((8.5 - rup.mag) ** 2) +
                     (C['a2'] + self.CONSTS['a3'] * (rup.mag - c1)) *
                     np.log(R))

        if rup.mag <= c1:
            return base_term + self.CONSTS['a4'] * (rup.mag - c1)
        else:
            return base_term + self.CONSTS['a5'] * (rup.mag - c1)
743777
def bases(self):
        '''
        
        '''
        sequence = self.alignment.query_sequence
        assert self.offset_end <= len(sequence), \
            "End offset=%d > sequence length=%d. CIGAR=%s. SEQUENCE=%s" % (
                self.offset_end,
                len(sequence),
                self.alignment.cigarstring,
                sequence)
        return sequence[self.offset_start:self.offset_end]
782345
function CInt(base, offset, isSet) {
  this.base = base || 0;
  this.offset = offset || 0;
  this.isSet = isSet || false;
}
25210
def baseOn(self, *args):
        
        if isinstance(args[0], dict):
            self.baseOn(*args[0].items())
        else:
            for (param, value) in args:
                self.addGrid(param, [value])

        return self