We're back. Kind of. Clearing out the cobwebs. Much stuff broken. Much stuff coming. More details to come. So much spam.
3
Need help with 3D surface plot of complex function
Post Body

Sorry, forgot to put in the title I am using MATLAB.

I'm pretty sure I understand how to code this, the way the instructions are worded for it are confusing me. Here's a screenshot of them: http://i.imgur.com/Y6Rw8y6.png

So I understand I would simply make two vectors for the ranges of sigma and omega.

sig = -8:0.1:0;
omeg = -10:0.1:10;

Then the meshgrid

[X,Y] = meshgrid(sig, omeg);

Not quite sure how to create a vector for parts of the complex variable, a grid for s, or how to determine the magnitude of the function since it asks you to plot the real and imaginary components. I understand the real is sigma and the imaginary is omega, but then why does it add I may need to use the real and imag commands? The only surface plots I've done have been simple where you're given a range of two variables, you simply create the meshgrid, then evaluate the function using the meshgrid and save that as z, then plot it with the surf command. Also how come wn = 5 but then I'm given a range separately as well?

This is what I have right now, I feel like I'm completely missing a large part of this problem:

sigma = -8:0.1:0;
omega = -10:0.1:10;

[x,y] = meshgrid(sigma, omega);

s = x   y;

z = (5^2)./(s.^2   2*0.4*5.*s   5^2);

surf(x,y,z);

Author
FrostyJesus

14 years old ยท 155k karma

Account strength 100%
Age
14 years
Total karma
155k
Comment karma
118k
Signals Verified email Verified flair
View profile
Profile refreshed 1 year ago Posts refreshed 1 year ago

Subreddit

Post Details

We try to extract some basic information from the post title. This is not always successful or accurate, please use your best judgement and compare these values to the post title and body for confirmation.
Posted
12 years ago