Sign up ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

I have an acceleration vector in m/s^2 and I am going to use an algorithm that assumes these values are between -1 and 1. I have searched the web and found formulas to get it between 0 and 1.

Especially this formula: $x' = \frac{x - \min}{\max - \min}$ but I think this will give me values between 0 and 1. I do know that $min = -max$, so $x' = \frac{x - \min}{2\cdot \max}$.

My math is really lacking, so I don't know how to get this value to be between -1 and 1.

share|cite|improve this question
homework should not be used as a standalone tag; see tag-wiki and meta. I wasn't able to come up with a more suitable tag, so I've tried algebra-precalculus. If someone has a better idea, please, retag the post. – Martin Sleziak Mar 9 '13 at 9:19

1 Answer 1

If $x \in [0,1]$, then $2x-1 \in [-1,1]$.

share|cite|improve this answer
That's Nice!!+1 :) – Aang Mar 9 '13 at 9:23

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.