f

#### numerical solution to a set of non-liner equations

Hi, Maple experts,

I have two non-linear equations as follows:

tau := 1 - (1-p)^(1/9);

tau := 2(1-2*p)/ ((1-2*p)*33 + p*32*(1-(2*p)^5));

p and tau are both on the interval of (0,1), and we know there is a unique
(p, tau) pair solution.

Which Maple function/command can be used to solve the above two equations?
I have tried "solve" but it doesn't work.

Xinhua 0  Xinhua
2/1/2005 2:54:37 AM comp.soft-sys.math.maple  4344 articles. 3 followers. 6 Replies 422 Views Similar Articles

[PageSpeed] 13

In article <ctmr3f$b1g$1@rumours.uwaterloo.ca>,
Xinhua Ling <x2ling@bbcr.uwaterloo.ca> wrote:

|>I have two non-linear equations as follows:

|>tau := 1 - (1-p)^(1/9);

|>tau := 2(1-2*p)/ ((1-2*p)*33 + p*32*(1-(2*p)^5));

These are not equations, they are assignments.  This is not what you
want, you want tau to be a variable.  You're also missing the "*"
after the first 2 in the second equation.

|>p and tau are both on the interval of (0,1), and we know there is a
unique
|>(p, tau) pair solution.

|>Which Maple function/command can be used to solve the above two
equations?
|>I have tried "solve" but it doesn't work.

The command for numerical solution of an equation or a system of
equations is "fsolve".  The "solve" command does symbolic
(closed-form) solutions.  Actually it does work in this case if
you do it properly.

> eqs:= {tau = 1 - (1-p)^(1/9),
tau = 2*(1-2*p)/ ((1-2*p)*33 + p*32*(1-(2*p)^5))};

> fsolve(eqs,{tau=0..1,p=0..1});

{tau = 0.03730507995, p = 0.2897714582}

> solve(eqs union {tau>0,tau<1,p>0,p<1});

9          18
{tau = 1 - (RootOf(1023 - 1025 _Z - 4128 _Z  + 7104 _Z

27          36         45          10          19
- 6272 _Z   + 2816 _Z   - 512 _Z   + 4128 _Z   - 7104 _Z

28          37         46               9 (1/9)
+ 6272 _Z   - 2816 _Z   + 512 _Z  , 0.9626949200) )     , p

9          18
= 1 - RootOf(1023 - 1025 _Z - 4128 _Z  + 7104 _Z

27          36         45          10          19
- 6272 _Z   + 2816 _Z   - 512 _Z   + 4128 _Z   - 7104 _Z

28          37         46               9
+ 6272 _Z   - 2816 _Z   + 512 _Z  , 0.9626949200) }

> evalf(%, 30);

{p = 0.289771458222600677923267166561,

tau = 0.037305079954568141337854862393}

Robert Israel                                israel@math.ubc.ca
Department of Mathematics        http://www.math.ubc.ca/~israel
University of British Columbia            Vancouver, BC, Canada 0  israel
2/1/2005 5:41:01 AM
"Xinhua Ling" <x2ling@bbcr.uwaterloo.ca> writes:

> I have two non-linear equations as follows:
>
> tau := 1 - (1-p)^(1/9);
>
> tau := 2(1-2*p)/ ((1-2*p)*33 + p*32*(1-(2*p)^5));
>
> p and tau are both on the interval of (0,1), and we know there is a unique
> (p, tau) pair solution.
>
> Which Maple function/command can be used to solve the above two equations?
> I have tried "solve" but it doesn't work.

You want to use fsolve.  However, your second equation is not well-formed,
it is missing the multiplication symbol after the 2.

eq1 := tau = 1 - (1-p)^(1/9):
eq2 := tau = 2*(1-2*p)/ ((1-2*p)*33 + p*32*(1-(2*p)^5)):

Here's a numerical solution:

fsolve({eq1,eq2},{tau=0..1,p=0..1});
{p = 0.2897714582, tau = 0.03730507995}

I think a symbolic solution is unlikely.

Joe 0  Joe
2/1/2005 5:52:54 AM
>> eqs:= {tau = 1 - (1-p)^(1/9),
>         tau = 2*(1-2*p)/ ((1-2*p)*33 + p*32*(1-(2*p)^5))};
>
>> fsolve(eqs,{tau=0..1,p=0..1});
>
>               {tau = 0.03730507995, p = 0.2897714582}
>
This is great!  Thanks very much!

Another question is, after the above two steps, I want to use these two
values of tau and p in my follow up codes.  But when I type

>p;
p
it seems Maple does not retain the variables in the first 2 steps.  I also
tried

> myp:=fsolve(eqs,{tau=0..1,p=0..1});
myp := {p = 0.2897714582, tau = 0.03730507995}
> myp;
p = 0.2897714582
> evalf(myp);
p = 0.2897714582
> p;
p

I looked up in Maple's HELP but still got lost, even couldn't figure out in
which category this kind of problem lies.  Maple is powerful yet really
difficult to learn :-)

Xinhua
E&CE Dept.
Univ. Waterloo 0  Xinhua
2/1/2005 3:33:19 PM
Xinhua Ling wrote:

> it seems Maple does not retain the variables in the first 2 steps.  I also
> tried
>
>
>>myp:=fsolve(eqs,{tau=0..1,p=0..1});
>
>          myp := {p = 0.2897714582, tau = 0.03730507995}

p and tau have not been assigned values after fsolve.

You could use
assign(myp);
after which p and tau are assigned the values above.

However, my preferred metod is
pt:=subs(myp, [p,tau]);
after which pt is a list of the two numbers found above. To get the
value for p (the first in the list) do
pt;
To get the value for tau do
pt;

Preben Alsholm 0  Preben
2/1/2005 4:03:55 PM
In article <cto98k$uq8$1@news.net.uni-c.dk>,
Preben Alsholm  <P.K.Alsholm@mat.dtu.dk> wrote:

>However, my preferred metod is
>pt:=subs(myp, [p,tau]);
>after which pt is a list of the two numbers found above. To get the
>value for p (the first in the list) do
>pt;
>To get the value for tau do
>pt;

Or you could try

pt:= table(myp);

after which pt[p] and pt[tau] are the values of p and tau in this
solution.  This is especially useful in cases where there are
lots of variables and you don't want to have to remember what
order you put them in.

Robert Israel                                israel@math.ubc.ca
Department of Mathematics        http://www.math.ubc.ca/~israel
University of British Columbia            Vancouver, BC, Canada 0  israel
2/1/2005 10:46:14 PM
* Xinhua Ling writes:

> I looked up in Maple's HELP but still got lost, even couldn't figure out in
> which category this kind of problem lies.  Maple is powerful yet really
> difficult to learn :-)

> Thanks again for your help!

> Xinhua
> E&CE Dept.
> Univ. Waterloo
^^^^^^^^^^^^^^^^

This is what I would call "coming full circle".

SCNR

--
Space - the final frontier 0  Oliver
2/2/2005 12:46:14 PM Similar Artilces:

Numerical solution of quadratic equations set.
Dear MathGroup experts! I've got a system of quadratic equations with many (57) variables. Number of equations is less (38), so there may be an infinite set of solutions. Also I've got an aproximate solution that gives a good discrepancy. I want Mathematica to find some solution or/and improve the existing one. I'm interested in real (not complex) solutions. Here's what I've tried with no result: NSolve[eq == 0, var] - gives no solutions. FindInstance[eq==0,var,Reals] - gives no solutions. FindRoot[] says that there's not enough equations (yes, ...

numerical solutions to two non algebraic equations.
Hello, I am trying to get the decimal expansion of solution to sin(x)-exp(-x)=0 around pi, its about 3.093639, and the decimal expansion of solution to x^(9^x)=9, its about 1.179. Thank you for your time and consideration. Bob. FindRoot[Sin[x]-Exp[-x]==0,{x,3}] {x -> 3.0963639324106462} FindRoot[x^(9^x)==9,{x,1}] {x -> 1.1790679941305466} Bob Hanlon > > From: "Robert G. Wilson v" <rgwv@rgwv.com> > Date: 2005/03/26 Sat AM 02:39:22 EST > To: mathgroup@smc.vnet.net > Subject: numerical solutions to two non algebraic equa...

numerical solution to a set of equations with hypergeometric function
Hi, i ran into some trouble solving the following set of equations http://imageshack.us/photo/my-images/337/gleichungen.jpg/ for N and M, all other variables are known. I think the problem lies within the F- function. It's supposed to be the hypergeometric function. I used FindRoot and the hypergeometric2f1regularized command at first, but all i got were some errors. When i tried to solve it with the integral representation and the power series of the function I still didn't get any results. If i insert all the values it does look like this: FindRoot[{((0.5*0.5 + 0.5*0.5)...

Finding all possible solutions to this set of non-linear equations
Hi, I have a function: function F=myfun2(x) F(1)=sin(x(1))+x(2)^2+log(x(3))-7 F(2)=3*x(1)+2^x(2)+1-x(3)^3 F(3)=x(1)+x(2)+x(3)-5 After using many initial guesses using the fsolve command, the 7 set of solutions that I have found are: -0.0889 + 3.7533i 3.9071 - 2.6197i 1.1819 - 1.1336i -0.0889 - 3.7533i 3.9071 + 2.6197i 1.1819 + 1.1336i 3.2793 - 1.6331i 2.6598 - 0.8224i -0.9390 + 2.4555i 5.1004 + 0.0000i -2.6442 - 0.0000i 2.5438 + 0.0000i 5.1004 - 0.0000i -2.6442 + 0.0000i 2.5438 - 0.0000i 5.1004 -2.6442 2.5438 0.5991 2.3959 2.0050 Can anyo...

How can I numerically solve non-linear sets of equations?
Hi, I have a large set of variables (about 10K), and a corresponding set of equations, a significant part of which are non-linear (currently, quadratic), for example (sorry for the latex-like syntax :-) ): [linear]: Y=\sum(y_i) [non-linear]: Y \times y_i = <some fixed value based on i> In addition, how can I restrict the value a variable take? i.e., since the above are mostly probabilities, I'd like to add something like 0 <= y_i <= 1. Thanks! "Amir Nahir" <nahir_amir@hotmail.com> wrote in message <h0dd0k$505$1@fred.mathworks.com>... > Hi, &...

Maple 9 is unable to solve numerically this equation but Maple 5 does it!
Well, just for the records: Maple 9 is unable to execute this: fsolve(min(x+51580800.0,5652700000.0,x+51580800.0+.8585358682e13/x^(1/2)) = 4368842661., x, 1684100000.0 .. 5652700000.0); It gives up with the following error message: Error, (in PiecewiseTools:-Convert) unable to convert On the other hand, Maple V and Maple 6 does it well. I'm trying to convert an old Maple V worksheet to Maple 9 and this work is not being easy! Black boxes, black boxes ... Greetings, Humberto. Humberto Jose Bortolossi wrote: > fsolve(min(x+51580800.0,5652700000.0,x+51580800.0+.8...

handling exact solution from solve vs numerical solution from fsolve for same equation
hello; I am asking for the difference between > Digits:=200; > > eq:=-x^3+6*x^2-6*x-1: > fsolve(eq=0,x); > > solve(eq=0,x); > evalf(%); The result of evalf(%) above contains a complex part. No matter how large I make Digits to be. the result of fsolve contains only real part. The question is, would you consider this equation to have complex or real roots? thanks, Nasser In article <rXV3f.2604\$tV6.1659@newssvr27.news.prodigy.net>, Nasser Abbasi <nma@12000.org> wrote: |>I am asking for the difference between ...

numerical solution of equation
I'm starting with Matlab and I don't know what to do to solve numerically x+e*sin(x)=omega*t where e, omega and t are calculated earlier in the program. Many thanks, tania In article <eefb68a.-1@webx.raydaftYaTP>, Tania <tania.re@wanadoo.fr> wrote: > I'm starting with Matlab and I don't know what to do to solve > numerically > > x+e*sin(x)=omega*t > > where e, omega and t are calculated earlier in the program. > > Many thanks, > > tania ------ Hello Tania, Do you have the Symbolic Math Toolbox? If so, try that with 'so...

non-linear equation solution
hi, is there anyway in matlab to solve a non-linear equation in one variable..... f(D)=0 where f(D) is non-linear. please also give the syntax... In article <ef4a6f1.-1@webcrossing.raydaftYaTP>, srikanth <srikanth_aero@yahoo.co.in> wrote: > hi, > > is there anyway in matlab to solve a non-linear equation in one > variable..... > > f(D)=0 > > where f(D) is non-linear. > please also give the syntax... Use fzero. Sorry though, the syntax is given by "help fzero" or "doc fzero". You should read it. HTH, John -- The best mater...

numerical solution of schrodinger equation
please describe the details of shooting method to solve schrodinger equation for an electron confined in a 1D infinite-Quantum well with width d.thank youe very much. Define vector x first, with length n and solve for y(x).Set y(1)=0;y(2)=1; and vary E until you obtain y(n)==0 or abs(y(n))<1e-6. Simply "integrate" the SE to obtain y(3) from y(2) and y(1) and so on. But you better use FEMLAB if you have that. /Per reza mohseni wrote: > > > please describe the details of shooting method to solve schrodinger > equation for an electron confined in a 1D infinite-Qu...

Palatino numerals in maths equations?
I'm trying to consistently use Palatino fonts in my thesis. That includes all numerals. In the main body of text, writing '2' returns a '2' in the Palatino font once complied, but in math mode the '2' is in Times Roman font I think. I've tried using the packages (stabbing in the dark basically). mathpple mathpazo palatinomath palatino palatcm with no luck. Any ideas? Thanks. Chrisr <chrisr@es.co.nz> writes: > mathpple > mathpazo > palatinomath > palatino > palatcm The correct way to use Palatino is mathpazo.sty (see FAQ, psnfss...

non linear equations solution
I am trying to solve nonlinear equations containing elliptical integrals.Is it possible to try with 'solve' or I need to go for 'fsolve' or maple . can some one please help me in this regard What is the equation? Try to convert it to ODE by ger derivative. What solution you need symbolic or numericle. dsolve from symbolic toolbox solve ODEs sybolicly. symbolic toolbox is maple inside matlab. ode45 solve ODE numericly. ------------------------------------ Maxim Vedenev, Matlab freelancer http://simulations.narod.ru/ Thank you for the quick response provided. preferabl...

numerical solution for cubic equation
hello, I am now trying to solve a cubic equation like this: Z^3 + A*Z^2 +B*Z +C = 0 while A, B and C have some value. I want to solve the equation. but when I use the command: solve('Z^3 + A*Z^2 +B*Z +C = 0','Z') it only gives out simbolic solution, while i need the numerical solution. Is there anyway to get the numerical solution? thanks Done/ roots.m will help Zhuoyang Lian wrote: > > > hello, I am now trying to solve a cubic equation like this: > Z^3 + A*Z^2 +B*Z +C = 0 > while A, B and C have some value. I want to solve the equation. but > when I use the...

Numerical solution of a differential equation
Halloechen! I have the following DE: (r(t)-diff(r(t),t,t))^2 + (diff(r(t),t))^2 = 0. I want to solve this numerically. But every time I call dsolve I get the following error message: dsolve((r(t)-diff(r(t),t,t))^2+(diff(r(t),t))^2,r(t),numeric); Error, (in DEtools/convertsys) unable to convert to an explicit first-order system How can I solve the equation? Tschoe, Torsten. -- Torsten Bronger, aquisgrana, europa vetus On Sat, 7 Feb 2004, Torsten Bronger wrote: > (r(t)-diff(r(t),t,t))^2 + (diff(r(t),t))^2 = 0. > I want to solve this numerically. But every ti... Web resources about - numerical solution to a set of non-liner equations - comp.soft-sys.math.maple

Numerical - Wikipedia, the free encyclopedia
Text is available under the Creative Commons Attribution-ShareAlike License ;additional terms may apply. By using this site, you agree to the ... Numerical Simulation of Nix's Rotation - YouTube
This is a numerical simulation of the orientation of Nix as seen from the center of the Pluto system. It has been sped up so that one orbit of ... Gillian Heinrich’s has numerical advantage at Sunday’s Gold Coast races
THERE will be a Chris Waller-like feel at the Gold Coast races on Sunday when local trainer Gillian Heinrich saddles up four of the 10 runners ... Today’s Best Apps: Numerical, The Tonight Show, Digestable And R-TYPE II
... simply tap an item for more information, such as manufacturing process and any common side effects, typically stated in layman’s terms. Numerical: ... Numerical: Calculator Without Equal
Holen Sie sich „Numerical: Calculator Without Equal“ im App Store. Sehen Sie sich Screenshots, Bewertungen und Kundenrezensionen dazu an. Download this app right now: Numerical for iPhone and iPad is now free
... deals on well-designed apps, however, we'll also bring them to your attention individually — and such is the case with Andrew J Clark's " Numerical ...

FOMC Minutes: "Most participants agreed numerical thresholds could be useful"
... response to incoming data on the economy . Many participants thought that more-effective forward guidance could be provided by specifying numerical ... Quentin Tarantino's Next Western Reportedly Has A Numerical Title
Quentin Tarantino is a filmmaker who is known for making particular kinds of films, with adrenaline and testosterone always on full display, ... Divided Fed considers numerical triggers for rates policy
AFP Divided Fed considers numerical triggers for rates policy CNBC.com WASHINGTON (Reuters) - The US Federal Reserve may adopt numerical thresholds ...

Resources last updated: 2/13/2016 1:41:24 PM