MathGroup Archive 1998

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

Search the Archive

RealValued functions and derivatives




Hello Mathematica Group!

  I'm having some troubles with some symbolic differential equations
that include functions with real and complex parts.  I'm marking these
functions as RealValued but the mark doesn't seem to remain valid if I
apply derivatives to the function.  Marking them with RealValued
doesn't work, I get a message "Recursion depth of 256 exceeded".

(* begin paste *)
Mathematica 3.0 for Linux
Copyright 1988-96 Wolfram Research, Inc.
 -- Motif graphics initialized -- 

In[1]:= <<Algebra`ReIm`;
In[2]:= Im[t] ^= 0;
In[3]:= RealValued[ux, uy, u1, u2, u3];

Out[3]= {ux, uy, u1, u2, u3}

In[4]:= u = 2/3 (Exp[I phi1] u1[t] + Exp[I phi2] u2[t] + Exp[I phi3]
u3[t])/.
         {phi1->0, phi2->2/3 Pi, phi3->4/3 Pi}

                    (2 I)/3 Pi            u3[t]
        2 (u1[t] + E           u2[t] + -----------)
                                        (2 I)/3 Pi
                                       E Out[4]=
-------------------------------------------
                              3

In[5]:= u = ExpToTrig[u]

        2 u1[t]   u2[t]   I u2[t]   u3[t]   I u3[t] Out[5]= ------- -
----- + ------- - ----- - -------
           3        3     Sqrt[3]     3     Sqrt[3]

In[6]:= us[t_] := Re[u] + I Im[u];

In[7]:= Re[us[t]]

        2 u1[t]   u2[t]   u3[t]
Out[7]= ------- - ----- - -----
           3        3       3

In[8]:= Im[us[t]]

         u2[t]     u3[t]
Out[8]= ------- - -------
        Sqrt[3]   Sqrt[3]

In[9]:= Re[D[us[t],t]]

          Im[u2'[t]]    Im[u3'[t]]   2 Re[u1'[t]]   Re[u2'[t]]  
Re[u3'[t]] Out[9]= -(----------) + ---------- + ------------ -
---------- - ----------
           Sqrt[3]       Sqrt[3]          3             3            3
(* end paste *)

  Is there any way to convince Mathematica that the derivatives are also
real valued?


Thanks in advance.

Ernesto.

-- 
Ernesto Rico-Schmidt           Technology develops from the primitive
ernesto@neneNet.ddns.org       via the complicated to the simple.
http://www.neneNet.ddns.org              --- Antoine de Saint-Exupery



  • Prev by Date: Re: Lists and Plus
  • Next by Date: RE: 3D problem
  • Prev by thread: Bug? Can suddenly not edit with LINUX Frontend
  • Next by thread: Curvature table in NonlinearRegress