# Defining a function (Derivative) as a variable

**URL:** <https://community.wolfram.com/t/defining-a-function-derivative-as-a-variable/4174>\
**Category:** Questions\
**Tags:** mathematica, algebra\
**Created:** [December 1, 2014, 2:24am UTC](https://community.wolfram.com/t/defining-a-function-derivative-as-a-variable/4174 "2014-12-01T02:24:29Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ajitesh1020](https://avatars.discourse-cdn.com/v4/letter/a/9de0a6/32.png) [@ajitesh1020](https://community.wolfram.com/u/ajitesh1020)\
**Post date:** [December 1, 2014, 2:24am UTC](https://community.wolfram.com/t/defining-a-function-derivative-as-a-variable/4174/1 "2014-12-01T02:24:29Z")

</div>

Hi,

Generally we write expressions as–  
x = 3;  
y = 8;  
z = x+y;  
and we get the answer (in this case) 11

The same thing I want to write as shown in the picture  
For my problem I have these therms values as given inputs and these will be used further in some calculations.  
Please tell me how I can use (e.g. dy/dx) as a symbol for input like we use x,y,z etc.  
[[I know that these are defined functions and we cannot use it as a symbol but tell me if there is any way to do this]]

 ![Untitled.jpg](https://global.discourse-cdn.com/wolfram/original/3X/6/d/6dbc5ce7bf8ef4b73323978747e3de3baed7f1d2.jpeg)

---

<div class="post-metadata">

**Author:** ![andersongaudio](https://yyz1.discourse-cdn.com/wolfram/user_avatar/community.wolfram.com/andersongaudio/32/17298_2.png) [@andersongaudio](https://community.wolfram.com/u/andersongaudio)\
**Post date:** [December 1, 2014, 12:12pm UTC](https://community.wolfram.com/t/defining-a-function-derivative-as-a-variable/4174/2 "2014-12-01T12:12:53Z")

</div>

If you are only interested in doing the calculation, without being worried if the differential symbols can or cannot be used, one possible way to circumvent this is by using rules. This may not be what you really expect, but it may be a starting point for what you want.

```
dp1 = \[DifferentialD]Subscript[P, 1]/\[DifferentialD]x -> 3;
dp2 = \[DifferentialD]Subscript[P, 2]/\[DifferentialD]x -> 8;
\[DifferentialD]P/\[DifferentialD]x == \[DifferentialD]Subscript[P, 
    1]/\[DifferentialD]x + \[DifferentialD]Subscript[P, 
    2]/\[DifferentialD]x /. {dp1, dp2}

```

The code above was supposed to look like:

 ![6510code.jpg](https://global.discourse-cdn.com/wolfram/original/2X/8/8d41371f2fabca1fed3f192f64109bd4549a8ae9.jpeg)

---

<div class="post-metadata">

**Author:** ![ajitesh1020](https://avatars.discourse-cdn.com/v4/letter/a/9de0a6/32.png) [@ajitesh1020](https://community.wolfram.com/u/ajitesh1020)\
**Post date:** [December 1, 2014, 4:27pm UTC](https://community.wolfram.com/t/defining-a-function-derivative-as-a-variable/4174/3 "2014-12-01T16:27:18Z")

</div>

Thank you sir. It was a great help.
