# A simple problem related to symbolic calculation

Could anyone let me know how you can define a variable as some function of another variable without specific definition? For example, how can you define theta as some function of x and then differentiate the 'sin(theta)' by x?

The following is my code that doesn't work. I couldn't find how to fix it in reference manuals. Any help will be appreciated.

var('theta, y, f')

y=sin(theta) ; theta=f(x);

y.derivative(x)