MathGroup Archive 2005

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Plot difficulties <Error Machine Sized Real Number>

  • To: mathgroup at smc.vnet.net
  • Subject: [mg58000] Re: [mg57974] Plot difficulties <Error Machine Sized Real Number>
  • From: "Eric Curtis" <thelonias at wildox.net>
  • Date: Thu, 16 Jun 2005 05:35:57 -0400 (EDT)
  • Reply-to: <edcurtis at iupui.edu>
  • Sender: owner-wri-mathgroup at wolfram.com

David,

Thanks for the response.  This function is a complex function; as the value
of v2 increases, the first part of the function becomes imaginary.  It is a
plot of energy levels within a quantum dot well.  Well, it will be when I
have the command working right that is.  

I tried to plot the function using Re and Im, but the graphs that I got for
each one were completely unusable.  There should be very few zeros in the
plot range and the results from using Re and Im showed hundreds.  Is there a
way that I can block any value that is completely imaginary, leaving only
the values that are completely real, or that have a real and imaginary part?

Thanks for the help,

Eric

-----Original Message-----
From: David Park [mailto:djmp at earthlink.net] 
To: mathgroup at smc.vnet.net
Subject: [mg58000] Re: [mg57974] Plot difficulties <Error Machine Sized Real Number>

Eric,

It is just what it says. Your function is not real over the plot domain.
(One has to wonder why your plot domain involves such small numbers.) You
can only plot real values so you have to investigate your function, maybe
exploring it with Table, and decide what is is you really want to plot. If
your function is truly a complex function then maybe you want to us Re and
Im  to plot the real and imaginary parts, or Abs to plot the absolute value.

David Park
djmp at earthlink.net
http://home.earthlink.net/~djmp/




From: Eric [mailto:edcurtis at iupui.edu]
To: mathgroup at smc.vnet.net

Hello,

I have a question regarding Plot.  Here is a snip of my code:

Plot[function1, {EE,0 ,2.9*1.6 10^-19}, PlotLabel->"function1"];
Plot:: plnr : function1 is not a machine-sized real number at EE =
6.652531793826348`*^-21
...

function1 evalutates to 0. + 0.00195313i at this point.  In fact, at every
point the plot command gives an error the evaluation is completly imaginary.

Function1 is composed as follows:

Sqrt[1/(k1 Rc)] Sqrt[1/(k2i Rs)] (k2i m1 Rc Cos[k2i (Rc - Rs)] Sin[k1 Rc] -
(k1 m2 Rc Cos[k1 Rc] + (m1 - m2) Sin[k1 Rc]) Sin[k2i (Rc - Rs)])/ (m1
(Sqrt[1/(k2i Rc)] * Sqrt[k1  Rc]  Sqrt[k2i  Rc]  Sqrt[k2i Rs])

Where k2i is completely imaginary, m1>m2, and Rs>Rc

Any Suggestions?

Thanks,
Eric






  • Prev by Date: Re: Randomness Test
  • Next by Date: Re: For Loop and Array related
  • Previous by thread: Re: Plot difficulties <Error Machine Sized Real Number>
  • Next by thread: Randomness Test