storing of values in matlab

lamda=1 N=6% alpha=60 alpha=deg2rad(alpha); d=0.5 Beta=(2*pi/lamda); theta= 0:0.012:2*pi; w=alpha+Beta*d.*cos(theta); AF=1/N*(sin(N*(w./2))./sin(w./2));
figure polar(theta,AF)
***************** I need the values of theta at different values of AF after plotting.

1 comentario

Andrew Newell
Andrew Newell el 18 de Mzo. de 2011
You already have theta and AF. What do you want to do with them?

Iniciar sesión para comentar.

 Respuesta aceptada

Paulo Silva
Paulo Silva el 18 de Mzo. de 2011

0 votos

change
polar(theta,AF)
to
h=polar(theta,AF)
After that code get the data like this
x=get(h,'Xdata')
y=get(h,'Ydata')
you can plot the data again but without the grid
plot(x,y)

12 comentarios

nitya ...
nitya ... el 18 de Mzo. de 2011
can we do any operations on x, y after plotting
Paulo Silva
Paulo Silva el 18 de Mzo. de 2011
yes
nitya ...
nitya ... el 18 de Mzo. de 2011
how can we catch the values of y at different x values?
nitya ...
nitya ... el 18 de Mzo. de 2011
how can we display the value of x at a particular value of y?
Paulo Silva
Paulo Silva el 18 de Mzo. de 2011
x(y==value)
If the response is empty matrix than the value you tried doesn't exist on the y vector
nitya ...
nitya ... el 18 de Mzo. de 2011
here i want the value of y between 0.7 and 0.8 .
how can i write there?
Paulo Silva
Paulo Silva el 18 de Mzo. de 2011
y(y>=0.7 & y<=0.8)
nitya ...
nitya ... el 18 de Mzo. de 2011
but it gives all values of x again
Jan
Jan el 18 de Mzo. de 2011
As mentioned in your other thread: These basic questions are explained exhautively in the Getting Started sections of the documentation.
nitya ...
nitya ... el 18 de Mzo. de 2011
where i found the documentation?
Paulo Silva
Paulo Silva el 18 de Mzo. de 2011
Like Jan said you just need to execute:
doc
in the command line, F1 does the same, matlab window menu Help and Product Help
nitya ...
nitya ... el 18 de Mzo. de 2011
Thank you very much for your answers.

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Startup and Shutdown en Centro de ayuda y File Exchange.

Productos

Preguntada:

el 18 de Mzo. de 2011

Community Treasure Hunt

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

Start Hunting!

Translated by