Search tips

Search tips

Discussion Groups | Matlab DSP | MATLAB Curve fitting-Custom Equation with 2 boundaries

Technical discussion about Matlab and issues related to Digital Signal Processing.

Is this thread worth a thumbs up?

0

MATLAB Curve fitting-Custom Equation with 2 boundaries - "Faisal, Nadimul H" - Jul 9 8:33:13 2009

```Hi Dear
I am wondering if anybody would know how to fit a set of data (x, y) with a
custom equation.
The equation is:

y=k*{2*(a-b)-(sin(2*a)-sin(2*b))}, where 'a' and 'b' is function of 'x' but
both 'a' and 'b' have separate boundary conditions. In effect, the angle 'a'
and 'b' has a phase difference.
'k' is a constant.

I really appreciate your reply. I would like to know if i could used some
other package.

regards
Faisal

```

Re: MATLAB Curve fitting-Custom Equation with 2 boundaries - Tilak Rajesh - Jul 13 8:22:04 2009

```Hi Faisal,

I have done something similar using Mathematica, its very simple, try this
http://reference.wolfram.com/mathematica/ref/FindFit.html

Not sure in Matlab, maybe try fsolve !

Let me know if this helps.

Good luck,
Tilak

On 7/8/09, Faisal, Nadimul H <n...@gmail.com> wrote:
> Hi Dear
> I am wondering if anybody would know how to fit a set of data (x, y) with
a
> custom equation.
> The equation is:
>
> y=k*{2*(a-b)-(sin(2*a)-sin(2*b))}, where 'a' and 'b' is function of 'x'
but
> both 'a' and 'b' have separate boundary conditions. In effect, the angle
'a'
> and 'b' has a phase difference.
> 'k' is a constant.
>
> I really appreciate your reply. I would like to know if i could used some
> other package.
>
> regards
> Faisal
>

```

RE: Log of the image data - hekmat - Jul 17 12:01:07 2009

```Hi
I am trying to take log of an image data, it comes up with an error like

Function 'subsindex' is not defined for values of class 'struct'

I am not sure what actually this error is.