title: Convert numbers within a range to numbers within another range
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/929103/convert-a-number-range-to-another-range-maintaining-ratio">Convert a number range to another range, maintaining ratio</a>  </p>
  </blockquote>
  
  
  
  <p>So I have a function that returns values within 0 and 255 and I need to convert these values to something between -255 and 255
  So 200 would be roughly 145, 150 would be roughly 45 and so on..
  I have looked at <a href="https://stackoverflow.com/questions/929103/convert-a-number-range-to-another-range-maintaining-ratio">Convert a number range to another range, maintaining ratio</a> but the formulas there won't work.
  Any other formula I could use?</p>