Re: Q: Symbolic manipulation with Mathematica

• Subject: [mg3034] Re: Q: Symbolic manipulation with Mathematica
• From: BobHanlon at aol.com
• Date: 25 Jan 1996 05:41:19 -0600
• Approved: usenet@wri.com
• Distribution: local
• Newsgroups: wri.mathgroup
• Organization: Wolfram Research, Inc.
• Sender: mj at wri.com

```In[1]:=
g[func_] := func + x D[func, x];

In[2]:=
g[f[x]]

Out[2]=
f[x] + x f'[x]

In[3]:=
g[f[x, y]]

Out[3]=
(0,1)    x
f     [x, -]
x                 e     (1,0)    x
f[x, -] + x (------------ + f     [x, -])
e            e                   e

In[4]:=
y = x/e;
g[f[x, y]]

Out[5]=
(0,1)    x
f     [x, -]
x                 e     (1,0)    x
f[x, -] + x (------------ + f     [x, -])
e            e                   e

In[6]:=
Clear[y];
g[f[x, y /. y -> x/e]] /. x/e -> y

Out[7]=
(0,1)
f     [x, y]    (1,0)
f[x, y] + x (------------ + f     [x, y])
e

Bob Hanlon
bobhanlon at aol.com

> Newsgroups: sci.math.symbolic
> From: sergio at sci.ccny.cuny.edu (Sergio Rojas)
To: mathgroup at smc.vnet.net
> Subject: Q: Symbolic manipulation with Mathematica
> Date: Sun, 21 Jan 1996 21:33:57 GMT
>
>  Hi fellows,
>
>  I would like to know whether is possible to do the
> following with Mathematica:
>
> In[15]:= test = f[x] + x*D[f[x],x]
>
> Out[15]= f[x] + x f'[x]
>
> In[16]:= test /. f[x]->f[x,y]
>
> Out[16]= f[x, y] + x f'[x]
>
> However, I would like to get something like:
>
>         f[x,y] + x*D[f[x,y],x]
>
> which then Mathematica can write in the form:
>
>                       (1,0)
> Out[17]= f[x, y] + x f     [x, y]
>
>      Other manipulation I am trying to do is as follows:
>
> In[18]:= y = x/e
>
>          x
> Out[18]= -
>          e
>
> In[19]:= test = f[x,y] + x*D[f[x,y],x]
>
>                        (0,1)    x
>                       f     [x, -]
>               x                 e     (1,0)    x
> Out[19]= f[x, -] + x (------------ + f     [x, -])
>               e            e                   e
>
>       If there any way to get this equation in the form:
>
>                        (0,1)
>                       f     [x, y]    (1,0)
>           f[x, y] + x (------------ + f     [x, y])
>                            e
>
>                                         d f[x,y]              (1,0)
>Finally, is any way to use the notation: --       instead of  f     [x,y]
>                                         dx
>   I'll appreciate any suggestion.
>
> rojas
>
> E-mail: sergio at scisun.sci.ccny.cuny.edu

```

• Prev by Date: Re: Q: Symbolic manipulation with Mathematica
• Next by Date: Re: PowerBook Woes
• Previous by thread: Re: Q: Symbolic manipulation with Mathematica
• Next by thread: Matrix Algebra Weaknesses