Plotting a Mesh surface plot

1.PNG
Hello, the above is a function X(z), and i want to plot the mesh surface of X(z) by using x=(-2,2) y=(-2,2) and z axis as 20log(base 10)X(z). Can someone please help me with the code? I'm getting errors while using a few mesh functions. Any new idea of code would really help me.
Thank you

7 comentarios

Shubham Gupta
Shubham Gupta el 30 de Sept. de 2019
Your question is little bit unclear. I am guessing x & y are varying from -2 to 2 as following ?
x = -2:2; % i.e. x = [-2,-1,0,1,2];
y = -2:2; % i.e. y = [-2,-1,0,1,2];
but you have not mentioned how z is varying ? If z is the distance of (x,y) point from the origin, which is the most usual notation, then please mention that in your question.
Please clarify the above mentioned points, then we will be able to help you.
Sri Srujan Gollapudi
Sri Srujan Gollapudi el 30 de Sept. de 2019
The below is the question which i found in a textbook:
In the 3-D mesh plot, use x = (-2, 2), y = (-2, 2), and in the third z-axis use dB unit, i.e., plot
20log10|X(z)| (This is the modulus of X(z)) in the z-axis.
Shubham Gupta
Shubham Gupta el 30 de Sept. de 2019
Something must be mentioned about the variable 'z' otherwise it doesn't make sense (not to me at least). X(z) is function that varies according to 'z', so if 'z' is not mentioned how are we suppose to know the working of this function? Sorry I couldn't be of much help.
Sri Srujan Gollapudi
Sri Srujan Gollapudi el 30 de Sept. de 2019
To give you a clear picture, I will attach the entire question below. Even I couldn't fully understand the limits of 'z'. Neverthless, I'm attaching the question below:
1.PNG
3.PNG
Shubham Gupta
Shubham Gupta el 1 de Oct. de 2019
Can you please share me the book name & author? I am not sure I will be able to solve this without knowing 'z' limits, but I will try to give it a final shot
Sri Srujan Gollapudi
Sri Srujan Gollapudi el 2 de Oct. de 2019
I found a resolution by substituting 'z' as x+iy and solved the equation. Finally i was able to produce a mesh graph.
Thanks for responding to my query.
Shubham Gupta
Shubham Gupta el 2 de Oct. de 2019
Glad you solved it. Sorry I couldn't be of much help.

Respuestas (0)

La pregunta está cerrada.

Preguntada:

el 29 de Sept. de 2019

Cerrada:

el 20 de Ag. de 2021

Community Treasure Hunt

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

Start Hunting!

Translated by