Discussion about math, puzzles, games and fun. Useful symbols: ÷ × ½ √ ∞ ≠ ≤ ≥ ≈ ⇒ ± ∈ Δ θ ∴ ∑ ∫ π -¹ ² ³ °

You are not logged in.

- Topics: Active | Unanswered

Pages: **1**

I will try to compute the absolute value somehow, you ruuuuuuuuuuuuuule!

nik

mathsyperson wrote:

How about |X| ÷ X?

That formula will give 1 if X is positive, -1 if X is negative and won't work if X is 0.

Excuse my ignorance, but if i do X ÷ X I get 1 if X is positive, but if X is negative I still get 1, unless |X| means absolute value which I am not sure it will be recognized on a computer.

I appreciate your help

nik

**nikad**- Replies: 10

I have the following:

a-b=X

I need one single formula (that uses only addition, substraction, multiplication or division) where if X is a positive number the result will be 1 and if X is a negative number the result will be -1 or 0

Is this possible?

Thanx in advance!

nik

Pages: **1**