[Date Index]
[Thread Index]
[Author Index]
Re: Solve can solve it with some help
*To*: mathgroup at smc.vnet.net
*Subject*: [mg115414] Re: Solve can solve it with some help
*From*: Bob Hanlon <hanlonr at cox.net>
*Date*: Mon, 10 Jan 2011 02:39:57 -0500 (EST)
eqn = {0 == (1/2)*m*vf^2 + 0 - m*g*(R - R*Cos[theta]),
m*(vf^2/R) == m*g*Cos[theta]};
For your Solve you need to specify two variables
theta /. Solve[eqn, {vf, theta}] // Union
Solve::ifun: Inverse functions are being used by Solve, so some solutions may not be found; use Reduce for complete solution information. >>
{-ArcCos[2/3], ArcCos[2/3]}
You can extract from Reduce
Cases[Reduce[eqn, theta],
_?(! FreeQ[#, theta] &), {4}] // Union
{theta == -ArcCos[2/3] + 2 \[Pi] C[1] ||
theta == ArcCos[2/3] + 2 \[Pi] C[1]}
Depending on the complexity of the result you will have to change the level specification for Cases.
Bob Hanlon
---- Eduardo Cavazos <wayo.cavazos at gmail.com> wrote:
=============
Hello,
Solve doesn't come up with anything for these two equations:
{
0 == 1/2*m*vf^2 + 0 - m*g*(R - R*Cos[\[Theta]]),
m*vf^2/R == m*g*Cos[\[Theta]]
};
Solve[%, \[Theta]]
If you manually solve one of them for vf, Solve can take care of the
rest:
0 == 1/2*m*vf^2 + 0 - m*g*(R - R*Cos[\[Theta]]);
% /. Solve[m*vf^2/R == m*g*Cos[\[Theta]], vf][[2]];
Solve[%, \[Theta]]
{{\[Theta] -> -ArcCos[2/3]}, {\[Theta] -> ArcCos[2/3]}}
Of course, Reduce can handle the original set. However, Solve is nice
due to the brevity of output. (Side question: is there a way to extract
an equation from the results of Reduce based on variable name? Sometimes
the results from Reduce can be so verbose, it'd be nice to say "extract
equation for theta".)
My main question: is there a way to get Solve to solve the original set
of two equations without taking the manual approach?
Ed
--
Bob Hanlon
Prev by Date:
**Re: How to change the directory for the docs?**
Next by Date:
**Re: Mathematica will be a new feature of HTML6**
Previous by thread:
**Re: Solve can solve it with some help**
Next by thread:
**Re: Solve can solve it with some help**
| |