MathGroup Archive 2005

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

Search the Archive

Re: Cannot plot this functions

  • To: mathgroup at smc.vnet.net
  • Subject: [mg53852] Re: [mg53830] Cannot plot this functions
  • From: Bob Hanlon <hanlonr at cox.net>
  • Date: Sun, 30 Jan 2005 03:18:13 -0500 (EST)
  • Reply-to: hanlonr at cox.net
  • Sender: owner-wri-mathgroup at wolfram.com

f[x_] := -ArcTan[(-Sqrt[2])*Im[x] - Re[x^2] + 1, Sqrt[2]*Re[x] - Im[x^2]];

-f'[x]//Simplify

-(((Sqrt[2]*Im[x] + Re[x^2] - 1)*(Sqrt[2]*Derivative[1][Re][x] - 
2*x*Derivative[1][Im][x^2]) + 
    (Im[x^2] - Sqrt[2]*Re[x])*(Sqrt[2]*Derivative[1][Im][x] + 
2*x*Derivative[1][Re][x^2]))/
   ((Im[x^2] - Sqrt[2]*Re[x])^2 + (Sqrt[2]*Im[x] + Re[x^2] - 1)^2))

The problem is the terms with the derivative of Re or Im.  However, if you are 
plotting for real x

g[x_] = Simplify[f[x],Element[x, Reals]];

g[x]

-ArcTan[1 - x^2, Sqrt[2]*x]

-g'[x]//Simplify

(Sqrt[2]*(x^2 + 1))/(x^4 + 1)

Plot[{f[x],-g'[x]}, {x,-10,10},
    PlotStyle->{Blue,Red},
    ImageSize->400];


Bob Hanlon

> 
> From: Milind Gupta <milind.gupta at gmail.com>
To: mathgroup at smc.vnet.net
> Date: 2005/01/29 Sat AM 06:02:38 EST
> To: mathgroup at smc.vnet.net
> Subject: [mg53852] [mg53830] Cannot plot this functions
> 
> Hello,
>     I have a function of a phase response like:
> 
> -ArcTan[1 - sqrt(2)* Im[Ï?] - Re[Ï?^2], -Im[Ï?^2] + sqrt(2)* Re[Ï?]]
> 
> I need to plot the negative derivative of this function with respect
> to Ï?. Whne I use plot it gives me the error:
> 
> function is not a machine - size real number at Ï?  
=1.8622242690864824`*^-7
> 
> How can I avoid this problem??
> 
> Milind
> 
> 


  • Prev by Date: Re: Integrate a Piecewise funition, stange behaviour
  • Next by Date: Re: Re: random matrix from row and column sums
  • Previous by thread: Cannot plot this functions
  • Next by thread: Re: Solving matrix equation