expressing a matlab statement
Doug Stewart
dastew at sympatico.ca
Thu Mar 6 06:09:43 CST 2008
Dr Preyesh T. Goven Shiba wrote:
> Hi
>
> I'm a beginner with the use of matlab and octave... Can someone please
> help me....How do i express the function y as a amtlab statement for
> the following expression
>
>
> y^2 - 2y = x + 1
>
> Thankx
> Preyesh
>
> Email: drgovenshiba at vodamail.co.za <mailto:drgovenshiba at vodamail.co.za>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Help-octave mailing list
> Help-octave at octave.org
> https://www.cae.wisc.edu/mailman/listinfo/help-octave
>
I assume that x is the independent variable.
This is a quadratic in y , therefore there are two solutions for y
y^2 -2y -x-1=0
y= (-b +- sqrt(b^2 -4ac)) /2a the generic solution.
y1=(2+sqrt(4-4*(-x-1)))/2
or y1=1+sqrt(2+x)
and y2=1-sqrt(2+x)
hope this helps.
More information about the Help-octave
mailing list