Question: error in calculatting partial derivative

I want to calculate (partialH/partialq). But I encountered an error when I evaluate it.

restart;
with(PDEtools);
with(linalg);
alias(q = q(x, t), p = p(x, t));
                              q, p
H := lambda*p*q+conjugate(lambda)*conjugate(p)*conjugate(q)+(1/2*(p^2+conjugate(q)^2))*(conjugate(p)^2+q^2);
                                      
diff(H, q(x, t));

maple shows error:

Error, invalid input: diff received q(x, t), which is not valid for its 2nd argument
How to fix this issue?

 

Please Wait...