From: Mohammad on
"Roger Stafford" <ellieandrogerxyzzy(a)mindspring.com.invalid> wrote in message <i3qfue$d4q$1(a)fred.mathworks.com>...

> x = -.208
> x = -.144
> x = -.016
> x = +.240
> x = +.500
>
> This huge gap misses all the interesting variation in v at the right end and accounts for why the plot is so terribly inaccurate. It is the kind of behavior that functions like quad do in their calls to integrand functions which remain nearly constant for too long an interval.
>
> My advice would be not to use fplot at all on the kind of stuff you're working with. Just use the straight 'plot' function. That way you know exactly what spacing is being used in the plotting. It is not being left up to some algorithm which is trying to be too smart for its own good.
>
> Roger Stafford

How would I use fplot in this situation (I'm kinda new to this...)
From: Roger Stafford on
"Mohammad " <jaber2(a)uni.uiuc.edu> wrote in message <i3s3m0$i5c$1(a)fred.mathworks.com>...
> "Roger Stafford" <ellieandrogerxyzzy(a)mindspring.com.invalid> wrote in message <i3qfue$d4q$1(a)fred.mathworks.com>...
> > .......
> > My advice would be not to use fplot at all on the kind of stuff you're working with. Just use the straight 'plot' function. That way you know exactly what spacing is being used in the plotting. It is not being left up to some algorithm which is trying to be too smart for its own good.
> >
> > Roger Stafford
>
> How would I use fplot in this situation (I'm kinda new to this...)
- - - - - - - - -
As I have said, you should stay strictly away from 'fplot' with your problem! Perhaps you meant ask how you could use 'plot'?

x = linspace(n,o,500).'; % Choose the number of points you want to plot
v = sin(pi*x*(1:r))*Star.'+a-x.^b;
plot(x,v,'y.') % Or plot(x,v,'y-')

Roger Stafford