0
$\begingroup$

I have an oscillatory function f(ф, ф'), and I want to differentiate it. function like this:

df(ф, ф')/dф | ф, ф'= 0
df(ф, ф')/dф' | ф, ф'= 0
d^2f(ф, ф')/dф^2 | ф, ф'= 0
d^2f(ф, ф')/dф'^2 | ф, ф'=0
df(ф, ф')/dфdф' | ф, ф'=0

How can I write the above expressions in the Wolfram Language?

$\endgroup$

closed as off-topic by Daniel Lichtblau, Henrik Schumacher, m_goldberg, LCarvalho, István Zachar Nov 5 '18 at 12:26

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "This question arises due to a simple mistake such as a trivial syntax error, incorrect capitalization, spelling mistake, or other typographical error and is unlikely to help any future visitors, or else it is easily found in the documentation." – Daniel Lichtblau, Henrik Schumacher, m_goldberg, LCarvalho, István Zachar
If this question can be reworded to fit the rules in the help center, please edit the question.

  • 1
    $\begingroup$ Have a look at D. $\endgroup$ – b.gates.you.know.what Nov 2 '18 at 13:44
  • 1
    $\begingroup$ In your equations is \[Phi]' intended to symbolize a derivative or is it a second variable? $\endgroup$ – Jack LaVigne Nov 2 '18 at 14:03
2
$\begingroup$

In mathematica the tick mark applied to ϕ' represents the derivative so you need to use a different symbol.

I will simply use x and y in the examples below.

Here is what you are looking for using a general function as well as an example function, x^2 + y2.

The derivative with respect to x evaluated at y=0.

D[f[x, y], x] /. y -> 0
D[x^2 + y^2, x] /. y -> 0

The derivative with respect to y evaluated to y=0

D[f[x, y], y] /. y -> 0
D[x^2 + y^2, y] /. y -> 0

The second derivative with respect to x evaluated at y=0.

D[f[x, y], {x, 2}] /. y -> 0
D[x^2 + y^2, {x, 2}] /. y -> 0

The derivative with respect to x and then y evaluated at y=0

D[f[x, y], x, y] /. y -> 0
D[x^2 + y^2, x, y] /. y -> 0

In all of these examples the first term evaluates the derivative.

The expression /. y -> 0 means take the expression on the left and replace y with 0. This effectively evaluates the expression at y=0.

$\endgroup$
  • $\begingroup$ Thanks. Also the both x (or ф in my example) and y (ф') must be: | ф=0 , ф'=0 I think the final function looks like this: D[f[x, y], {x, 2}] /. y -> 0 /. x->0 $\endgroup$ – Wales Nov 2 '18 at 20:17
  • $\begingroup$ Furthermore with y->0 and x->0 i get the infinite expression encountered error. How can i display the maximal result (with 1/0, yep) with this error? $\endgroup$ – Wales Nov 2 '18 at 20:42
  • $\begingroup$ If you are getting an expression with an error message "Infinite expression 1/0 enountered" that implies you are using a particular function f. You should ask a separate question and include your function in that question. $\endgroup$ – Jack LaVigne Nov 2 '18 at 22:31
2
$\begingroup$

Say your function is:

f[x_, y_] := Sin[x y]

Then, you can use Derivative:

Derivative[1,0][f][0,0]
Derivative[0,1][f][0,0]
Derivative[2,0][f][0,0]
Derivative[1,1][f][0,0]
Derivative[0,2][f][0,0]

0

0

0

1

0

$\endgroup$

Not the answer you're looking for? Browse other questions tagged or ask your own question.