Skip to main content
GameDev.net gamedev.net
🔒 Locked

Square root

Started by idinkin Jun 29, 2003 at 4:06 PM 52 replies 8.4k views
Original Post
idinkin
idinkin
Hello everybody! Can you tell me please if a square root of a natural number may be negative? Thanx.
Sometimes movement is a result of a kick in the ass!
Ready4Dis
Ready4Dis
No, if you take the sqrt of a negative, it''s an irrational number, but never negative.
Painless
Painless
quote:
Original post by Anonymous Poster
Actually, yes... every natural number has two square roots... the positive and negative "version" if you will. For instance, the square roots of 4 ar +2 and -2.

The square root of a negative number is imaginary, not irrational. Irrational just means that the decimal part is neither terminating nor repeating.


Beep, wrong. A square root is defined to be positive.
Nervo
Nervo
I think you might be mis-interpreting the question. The orginal poster is asking about the square root of a natural number which is inherently positive. Of course you have a number that is both positive and negative. Remember solving quadratic equations where you used the formula and got 2 possible choices?
Well, R2D22U2..
rohde
rohde
quote:
Original post by Painless
quote:
Original post by Anonymous Poster
Actually, yes... every natural number has two square roots... the positive and negative "version" if you will. For instance, the square roots of 4 ar +2 and -2.

The square root of a negative number is imaginary, not irrational. Irrational just means that the decimal part is neither terminating nor repeating.


Beep, wrong. A square root is defined to be positive.


No beep you.

MathWorld

-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
Any intelligent fool can make things bigger, more complex, and more violent. It takes a touch of genius -- and a lot of courage -- to move in the opposite direction.
"We confess our little faults to persuade people that we have no large ones." -Francois de La Rochefoucauld (1613 - 1680). | My blog
DekuTree64
DekuTree64
quote:
Original post by Painless
Beep, wrong. A square root is defined to be positive.


Anonymous is right, it can be negative. It's just the number you're taking the square root OF that has to be positive. If you take -2 * -2, you get 4, so it works. You can get different solutions to problems by working it twice, once with the positive sqrt and once with the negative, and they'll still work in the original equation.

EDIT: Ack, 2 replies while I was typing that^_^;

[edited by - dekutree64 on June 29, 2003 5:45:53 PM]
ApochPiQ
ApochPiQ
quote:
Original post by Painless
quote:
Original post by Anonymous Poster
Actually, yes... every natural number has two square roots... the positive and negative "version" if you will. For instance, the square roots of 4 ar +2 and -2.

The square root of a negative number is imaginary, not irrational. Irrational just means that the decimal part is neither terminating nor repeating.


Beep, wrong. A square root is defined to be positive.



No, you''re wrong. "The" square root, represented by the radical symbol, is defined as the positive second root. However, all numbers have two solutions to the equation x*x = n, and therefore two second roots: x = +- sqrt(n).
vanillacoke
vanillacoke
There is a slight difference between the analytical square root function, and the plain ol'' square root. It depends on which one OP was asking about, but chances are he doesn''t really know.
You know what I never noticed before?
Cedric
Cedric
Does it really matter? Why not wait for more information from the OP?

quote:
Original post by vanillacoke
but chances are he doesn''t really know.

Such tact
Mastaba
Mastaba
It is really sad to see the number of people that don''t know that the square root function is indeed DEFINED to always to be positive. So the sqrt(4) is always 2. It is only when you do a symbolic sqrt that you get 2 possible answers. Go ahead, try it. Load up Maple, or Mathematic and try solving for the sqrt of 4. It''ll only give you 2 as the answer. Try the sqrt(x*x) and then you''ll get -x and +x.
jamessharpe
jamessharpe
quote:
Original post by Anonymous Poster
Therefore the square root of 16 is -4 and +4, and the square root of -16 is 4i.


In fact the square root of -16 is 4i or -4i (the complex conjugate roots).

Cedric
Cedric
quote:
Original post by Mastaba
It is really sad to see the number of people that don''t know that the square root function is indeed DEFINED to always to be positive. So the sqrt(4) is always 2. It is only when you do a symbolic sqrt that you get 2 possible answers. Go ahead, try it. Load up Maple, or Mathematic and try solving for the sqrt of 4. It''ll only give you 2 as the answer. Try the sqrt(x*x) and then you''ll get -x and +x.

Grrr... Read the MathWorld link. As vanillacoke said, a number may have multiple square roots ("symbolic" doesn''t have anything to do with it). BUT, the square root FUNCTION is defined to be only the positive value (at least, in the reals).

Of course, a function is a one-to-one mapping. It can''t have multiple images for a given value.

Cédric
vanillacoke
vanillacoke
Cedricl, you took the words right out of my mouth.
You know what I never noticed before?
Cedric
Cedric
Nyahaha! Fear the Gamedever who has nothing to do but click Refresh!
vanillacoke
vanillacoke
I''m afraid, all right.
You know what I never noticed before?
stevie56
stevie56
"Can you tell me please if a square root of a natural number may be negative?"

No mention of a FUNCTION defined anywhare in MATHEMATICA or anywhere else is referred to by the question.

So, the answer to the question that was actually asked is YES.

You may define what you like in your software tools, but mathematical questions deserve mathematical answers.



Stevie

Don''t follow me, I''m lost.
StevieDon't follow me, I'm lost.
idinkin
idinkin
So... What I understand from this discussion is:
The square roots of 4 are -sqrt(4), sqrt(4). So square root is always positive. If I'm wrong tell me where my mistake is?

[edited by - idinkin on June 30, 2003 1:00:31 PM]
Sometimes movement is a result of a kick in the ass!
Nervo
Nervo
idinkin you are correct. The square root of 4 for instance is sqrt(4) and -sqrt(4) with answers 2 and -2. Therefore it is a combination of two functions just like for example graphing a circle with x^2+y^2=r^2. It would like like a parabola placed on its side.

[edited by - nervo on June 30, 2003 1:11:31 PM]
Well, R2D22U2..
idinkin
idinkin
OK. Thanx!
Sometimes movement is a result of a kick in the ass!
JohnBolton
JohnBolton
quote:
Original post by idinkin
So... What I understand from this discussion is:
The square roots of 4 are -sqrt(4), sqrt(4). So square root is always positive. If I''m wrong tell me where my mistake is?



Not quite, but let me try to end this silly thread.

"square root": The following statement can be accepted as true:
    The square roots of a positive number n are sqrt(n) and -sqrt(n).  
Anyone that doesn''t accept that statement is just quibbling over the meanings of some terms. If you (or anyone else) accept that statement, then you must agree with this statement:
    There are two square roots of a positve number - one is positive, one is negative.  


sqrt(), the C function: According to the C standard, sqrt() return a positive value or 0 if the parameter is not negative.

The square root symbol: As far as I know, the sign of the value of the square root symbol depends on the context. I''ve seen it written with "+/-" and without. Generally, when it doesn''t have "+/-", the author assumes you know whether he means both roots or just the positive root. I don''t know if there is a notation standard for it, but that is what I''ve seen.

I hope that answers your question, once and for all. If the definition of the term "square root" is really what you want then look it up in an authoritative source and ignore anyone here that does not quote directly from an authoritative source.
John BoltonLocomotive Games (THQ)Current Project: Destroy All Humans (Wii). IN STORES NOW!

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.