Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
lsqcurvefit and integral

Subject: lsqcurvefit and integral

From: pmassicotte

Date: 13 Mar, 2012 20:07:34

Message: 1 of 6

Hi everyone.

I have a set of differential equations of which one is in the
following form:

dx/dt = F1 + F2 - int(F3,a,b)

I would like to use lsqcurvefit to find optimal parameters (between
specified boundaries). However, I never used lsqcurvefit with an
integral. I was wondering if it was doable or if I should be aware of
anything before going forward.

I hope I have been clear enough in my question.

Regards,
Phil

Subject: lsqcurvefit and integral

From: Roger Stafford

Date: 14 Mar, 2012 02:41:19

Message: 2 of 6

pmassicotte <pmassicotte@hotmail.com> wrote in message <96580354-d8a7-4309-a2ca-faf6924b23f8@i2g2000vbv.googlegroups.com>...
> ......
> I have a set of differential equations of which one is in the
> following form:
>
> dx/dt = F1 + F2 - int(F3,a,b)
> .......
- - - - - - -
  Do F3, a, or b vary with t? I assume F3 also has its own variable of integration independent of t that ranges from a to b.

Roger Stafford

Subject: lsqcurvefit and integral

From: pmassicotte

Date: 14 Mar, 2012 12:00:51

Message: 3 of 6

On Mar 13, 10:41 pm, "Roger Stafford"
<ellieandrogerxy...@mindspring.com.invalid> wrote:
> pmassicotte <pmassico...@hotmail.com> wrote in message <96580354-d8a7-4309-a2ca-faf6924b2...@i2g2000vbv.googlegroups.com>...
> > ......
> > I have a set of differential equations of which one is in the
> > following form:
>
> > dx/dt = F1 + F2 - int(F3,a,b)
> > .......
>
> - - - - - - -
>   Do F3, a, or b vary with t?  I assume F3 also has its own variable of integration independent of t that ranges from a to b.
>
> Roger Stafford

Hi there.

a and b and independent of t. Your assumption is also correct.

Regards,
Phil

Subject: lsqcurvefit and integral

From: Torsten

Date: 14 Mar, 2012 12:11:56

Message: 4 of 6

Am Mittwoch, 14. März 2012 13:00:51 UTC+1 schrieb pmassicotte:
> On Mar 13, 10:41 pm, "Roger Stafford"
> <ellieandrogerxy...@mindspring.com.invalid> wrote:
> > pmassicotte
> wrote in message <96580354-d8a7-4309-a2ca-faf6924b2...@i2g2000vbv.googlegroups.com>...
> > > ......
> > > I have a set of differential equations of which one is in the
> > > following form:
> >
> > > dx/dt = F1 + F2 - int(F3,a,b)
> > > .......
> >
> > - - - - - - -
> >   Do F3, a, or b vary with t?  I assume F3 also has its own variable of integration independent of t that ranges from a to b.
> >
> > Roger Stafford
>
> Hi there.
>
> a and b and independent of t. Your assumption is also correct.
>
> Regards,
> Phil

Is your equation already a part of a discretized partial differential equation ?
Does F3 depend on x ?
If yes: a and b are (fixed) time instances ?
If no: how do you get x for values in between a and b ?

Please explain your problem in more detail.

Best wishes
Torsten.

Subject: lsqcurvefit and integral

From: pmassicotte

Date: 14 Mar, 2012 13:06:59

Message: 5 of 6

On Tuesday, March 13, 2012 4:07:34 PM UTC-4, pmassicotte wrote:
> Hi everyone.
>
> I have a set of differential equations of which one is in the
> following form:
>
> dx/dt = F1 + F2 - int(F3,a,b)
>
> I would like to use lsqcurvefit to find optimal parameters (between
> specified boundaries). However, I never used lsqcurvefit with an
> integral. I was wondering if it was doable or if I should be aware of
> anything before going forward.
>
> I hope I have been clear enough in my question.
>
> Regards,
> Phil

fdg

On Tuesday, March 13, 2012 4:07:34 PM UTC-4, pmassicotte wrote:
> Hi everyone.
>
> I have a set of differential equations of which one is in the
> following form:
>
> dx/dt = F1 + F2 - int(F3,a,b)
>
> I would like to use lsqcurvefit to find optimal parameters (between
> specified boundaries). However, I never used lsqcurvefit with an
> integral. I was wondering if it was doable or if I should be aware of
> anything before going forward.
>
> I hope I have been clear enough in my question.
>
> Regards,
> Phil



On Tuesday, March 13, 2012 4:07:34 PM UTC-4, pmassicotte wrote:
> Hi everyone.
>
> I have a set of differential equations of which one is in the
> following form:
>
> dx/dt = F1 + F2 - int(F3,a,b)
>
> I would like to use lsqcurvefit to find optimal parameters (between
> specified boundaries). However, I never used lsqcurvefit with an
> integral. I was wondering if it was doable or if I should be aware of
> anything before going forward.
>
> I hope I have been clear enough in my question.
>
> Regards,
> Phil



On Tuesday, March 13, 2012 4:07:34 PM UTC-4, pmassicotte wrote:
> Hi everyone.
>
> I have a set of differential equations of which one is in the
> following form:
>
> dx/dt = F1 + F2 - int(F3,a,b)
>
> I would like to use lsqcurvefit to find optimal parameters (between
> specified boundaries). However, I never used lsqcurvefit with an
> integral. I was wondering if it was doable or if I should be aware of
> anything before going forward.
>
> I hope I have been clear enough in my question.
>
> Regards,
> Phil



On Tuesday, March 13, 2012 4:07:34 PM UTC-4, pmassicotte wrote:
> Hi everyone.
>
> I have a set of differential equations of which one is in the
> following form:
>
> dx/dt = F1 + F2 - int(F3,a,b)
>
> I would like to use lsqcurvefit to find optimal parameters (between
> specified boundaries). However, I never used lsqcurvefit with an
> integral. I was wondering if it was doable or if I should be aware of
> anything before going forward.
>
> I hope I have been clear enough in my question.
>
> Regards,
> Phil

Subject: lsqcurvefit and integral

From: pmassicotte

Date: 14 Mar, 2012 13:06:39

Message: 6 of 6

On Wednesday, March 14, 2012 8:11:56 AM UTC-4, Torsten wrote:
> Am Mittwoch, 14. März 2012 13:00:51 UTC+1 schrieb pmassicotte:
> > On Mar 13, 10:41 pm, "Roger Stafford"
> > <ellieandrogerxy...@mindspring.com.invalid> wrote:
> > > pmassicotte
> > wrote in message <96580354-d8a7-4309-a2ca-faf6924b2...@i2g2000vbv.googlegroups.com>...
> > > > ......
> > > > I have a set of differential equations of which one is in the
> > > > following form:
> > >
> > > > dx/dt = F1 + F2 - int(F3,a,b)
> > > > .......
> > >
> > > - - - - - - -
> > >   Do F3, a, or b vary with t?  I assume F3 also has its own variable of integration independent of t that ranges from a to b.
> > >
> > > Roger Stafford
> >
> > Hi there.
> >
> > a and b and independent of t. Your assumption is also correct.
> >
> > Regards,
> > Phil
>
> Is your equation already a part of a discretized partial differential equation ?
> Does F3 depend on x ?
> If yes: a and b are (fixed) time instances ?
> If no: how do you get x for values in between a and b ?
>
> Please explain your problem in more detail.
>
> Best wishes
> Torsten.

Hi there. Thank you for your answer.

F3 does not depend on x. For instance, F3 is a function that takes values in a table. In fact it was my next question. How to calculate integral that takes its values in a table (measured values). In my case, F3 is:

http://i44.tinypic.com/300cheo.png

where for example Ed(0-,lambda) is the light intensity measured at lambda wavelength.

Once again, I hope I'm clear enough. Don't hesitate to ask me more question.

Your help is very valuable.

Regards,
Phil

Tags for this Thread

No tags are associated with this thread.

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.

Contact us