Message Boards Message Boards

0
|
10519 Views
|
4 Replies
|
1 Total Likes
View groups...
Share
Share this post:

LogPlot. Without Log, there is no problem. But when I try to plot with Log

Posted 9 years ago

Hi, I having hard time with LogPlot.

Please find the attach file. Without Log, there is no problem. But when I try to plot with Log gives a lot of errors I spen a lot of time to see why!! I really apreciate your help Regards Jabir

Attachments:
POSTED BY: jabir Hakami
4 Replies
Posted 9 years ago

But my plot shows AND RE and Im!? Here is a plot of only the imaginary part (this is in fact a rescaled plot of the orange curve above). I do not see the problem...

POSTED BY: Erik Mahieu
Posted 9 years ago

Thank you very much. But this is did not solve the problem. For examble, if we plot just the imaginary part which gives real numbers , the problems still there. Regards Jabir

POSTED BY: jabir Hakami
Posted 9 years ago

Thank you very much. But this is did not solve the problem. For examble, if we plot just the imaginary part which gives real numbers , the problems still there. Regards Jabir

POSTED BY: jabir Hakami
Posted 9 years ago

The log of a negative number is an imaginary number. You can change the sign of the real parts that are negative as follows:

Eps1[\[Omega]_] := (p[\[Omega]][[1]]^2 - p[\[Omega]][[2]]^2) + 
   I*2*(p[\[Omega]][[1]]*p[\[Omega]][[2]]);
LogPlot[{-Re[Eps1[\[Omega]]], Im[Eps1[\[Omega]]]}, {\[Omega], 1, 5}, 
 PlotStyle -> Thick, PlotRange -> All]

POSTED BY: Erik Mahieu
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract