Re: Using FindRoot

• To: mathgroup at smc.vnet.net
• Subject: [mg24867] Re: [mg24862] Using FindRoot
• From: BobHanlon at aol.com
• Date: Sat, 19 Aug 2000 04:45:44 -0400 (EDT)
• Sender: owner-wri-mathgroup at wolfram.com

```In a message dated 8/16/2000 3:42:05 AM, kd7cyb at mac.com writes:

>Can you solve the exact answer (meaning as close as possible that
>equally satisfies both sides with the same result) to equations like
>these below using FindRoot, and how? Or do you use a better function?
>
>
>(*Can FindRoot get the closest answer possible to this equation or ones
>like it below?*)
>
>x^2==x^3
>(*OR*)
>x^2==x
>

eqn = (x^2 == x^3);

Solve[eqn, x]

{{x -> 0}, {x -> 0}, {x -> 1}}

NSolve[eqn, x]

{{x -> 0.}, {x -> 1.}}

Roots[eqn, x]

x == 1 || x == 0 || x == 0

Reduce[eqn, x]

x == 0 || x == 1

FindRoot[eqn, {x, #}] & /@ {0.1, 1.1}

{{x -> 0.0007006044051493954}, {x -> 1.0000004089369072}}

FindMinimum[Abs[x^3 - x^2], {x, #}][[2]] & /@ {{0.1, 0.2}, {1.1, 1.2}}

{{x -> -8.522617184550385*^-8}, {x -> 1.0000000118290961}}

Bob Hanlon

```

• Prev by Date: Opening files
• Next by Date: Re: Using FindRoot
• Previous by thread: Using FindRoot
• Next by thread: Re: Using FindRoot