Expression of y as a function of x for trigonometric equation

Hello everyone,
How can I come up with a expression of y as a function of x for the following equation ?
arccos(1-2y)-2(1-2y)(y-y^2)^0.5-X = 0
Or If I have X values stored in a file, how can I find y value for those x? Thanks in advance. Tanjina

1 comentario

MATLAB is case sensitive. Is your X the same as your x? What is the value of y and big X that you put in?

Iniciar sesión para comentar.

Respuestas (1)

Torsten
Torsten el 21 de Oct. de 2015
Editada: Torsten el 21 de Oct. de 2015
f=@(y,x)acos(1-2*y)-2*(1-2*y)*(y-y^2)^0.5-x;
fun=@(y)f(y,x);
y0 = [0 1];
for k=1:numel(X)
x=X(k);
Y(k)=fzero(fun,y0);
end
where X is the array in which your x-values are stored.
Best wishes
Torsten.

Preguntada:

el 20 de Oct. de 2015

Editada:

el 21 de Oct. de 2015

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by