def mapRangeParam(u, min_u, max_u, min_v, max_v):
  """
  Linearly map a floating point value u in the range [min_u, max_u] to a value 
  v in the range defined by [min_v, max_v].

  Args:
    See description.
  Return:
    Floating point value v 
  """
  assert type(u) is float
  assert type(min_u) is float
  assert type(max_u) is float
  assert type(min_v) is float
  assert type(max_v) is float

  return ((max_v - min_v) * (u - min_u)) / float(max_u - min_u) + min_v