We would like the procedure to take as arguments an algebraic expression and a variable and to return the derivative of the expression with respect to the variable.
Symbolic differentiation is of special historical significance in Lisp.
It was one of the motivating examples behind the development of a computer language for symbol manipulation. Furthermore, it marked the beginning of the line of research that led to the development of powerful systems for symbolic mathematical work, which are currently being used by a growing number of applied mathematicians and physicists. Only afterward will we address the representation problem. In order to keep things simple, we will consider a very simple symbolic-differentiation program that handles expressions that are built up using only the operations of addition and multiplication with two arguments. Observe that the latter two rules are recursive in nature.