Thread Subject:
Equation solution with constrains

Subject: Equation solution with constrains

From: Javier

Date: 19 Sep, 2011 15:03:28

Message: 1 of 4


Hi,

I have a nonlinear system of 4 equations with 4 unknowns like:

y1 = f(x1,x2,x3,x4) = 0;
y2 = f(x1,x2,x3,x4) = 0;
y3 = f(x1,x2,x3,x4) = 0;
y4 = f(x1,x2,x3,x4) = 0;

But I have 4 boundaries: x1-4 are inside [-2e-2, 2e-2]
I want to find the x1-4 inside these boundaries that make y1-4 = 0 or at least that minimises them below 1e-13.

Can I put these constraint in fsolve? Should I use another function?

Thanks.

Subject: Equation solution with constrains

From: Matt J

Date: 19 Sep, 2011 15:19:28

Message: 2 of 4

"Javier" wrote in message <j57lk0$3gc$1@newscl01ah.mathworks.com>...
>
>
> Can I put these constraint in fsolve? Should I use another function?

See LSQNONLIN

Subject: Equation solution with constrains

From: Greg Heath

Date: 19 Sep, 2011 23:17:00

Message: 3 of 4

On Sep 19, 11:03 am, "Javier " <ja...@postal.uv.es> wrote:
> Hi,
>
> I have a nonlinear system of 4 equations with 4 unknowns like:
>
> y1 = f(x1,x2,x3,x4) = 0;
> y2 = f(x1,x2,x3,x4) = 0;
> y3 = f(x1,x2,x3,x4) = 0;
> y4 = f(x1,x2,x3,x4) = 0;
>
> But I have 4 boundaries: x1-4 are inside [-2e-2, 2e-2]
> I want to find the x1-4 inside these boundaries that make y1-4 = 0 or at least that minimises them below 1e-13.
>
> Can I put these constraint in fsolve? Should I use another function?
>
> Thanks.

Did you mean to use 4 different functions f1,f2,f3 and f4?

Hope this helps.

Greg

Subject: Equation solution with constrains

From: Javier

Date: 20 Sep, 2011 08:04:30

Message: 4 of 4

Greg Heath <heath@alumni.brown.edu> wrote in message <af5a3716-8c52-4113-8dfd-4d76905512a7@g31g2000yqh.googlegroups.com>...
> On Sep 19, 11:03 am, "Javier " <ja...@postal.uv.es> wrote:
> > Hi,
> >
> > I have a nonlinear system of 4 equations with 4 unknowns like:
> >
> > y1 = f(x1,x2,x3,x4) = 0;
> > y2 = f(x1,x2,x3,x4) = 0;
> > y3 = f(x1,x2,x3,x4) = 0;
> > y4 = f(x1,x2,x3,x4) = 0;
> >
> > But I have 4 boundaries: x1-4 are inside [-2e-2, 2e-2]
> > I want to find the x1-4 inside these boundaries that make y1-4 = 0 or at least that minimises them below 1e-13.
> >
> > Can I put these constraint in fsolve? Should I use another function?
> >
> > Thanks.
>
> Did you mean to use 4 different functions f1,f2,f3 and f4?
>
> Hope this helps.
>
> Greg


Yes, I didn't write that clear, but I have different f1 to f4 functions.

Tags for this Thread

Everyone's Tags:

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Tag Activity for This Thread
Tag Applied By Date/Time
fsolve Javier 19 Sep, 2011 11:04:33
nonlinear equation... Javier 19 Sep, 2011 11:04:33
rssFeed for this Thread

Contact us