# Differential equations expressed in operator form [duplicate]

Is it possible to make a workable operator representation of differential equations in Mathematica?

I think it would make solving my differential equations easier, but I have no idea how to do it. For example, I would like this: • What kinds of assumptions can we make about the functions u and w? Depending on how general you want this, the answer might be simple or it might be complicated. I can write a simple answer in the case where u and w are both functions of x and y. – march Jan 20 '16 at 17:51
• @march I already upvoted your answer too - then looked at the question and found it lacking specifics (that would make it different from the earlier one). – Jens Jan 20 '16 at 19:11

Depending on your use-case, there are different possibilities. I typically think of operators as taking functions to functions, rather than functions to values, so I will define the operators as taking the functions u and w to pure functions, and you can attach variables after the fact. Here's one possibility:

ClearAll[L22, L11, u, w]
L11[u_] := D[u[##], {#1, 2}] + (1 - mu)/2 D[u[##], {#2, 2}] &
L22[w_] := mu/R D[w[##], #1] &
L11[u]
L11[u][x, y]
L22[w]
L22[w][x, y]
0 == L11[u][x, y] + L22[w][x, y] Alternatively, you can give the functions and the variables together:

L11[u_[x_, y_]] := D[u[x, y], {x, 2}] + (1 - mu)/2 D[u[x, y], {y, 2}]
L22[w_[x_, y_]] := mu/R D[w[x, y], x]
0 == L11[u[x, y]] + L22[w[x, y]] 