Dealing with user-defined functions

I have an HP g50.

Can you define a function f(x), say f(x)=e^Tan(x)? How do you do this, and what is the syntax for using the function? Furthermore, can you use the derivative, f '(x), as a function or do you have to make a new function, say f1(x) and set it equal to d f(x)/dx? Or just use subst?

Lastly, is it possible to construct on expression in terms of f(x)? For example, is there an expression simmilar to f '(x0)(x-x0)+f(x0) to generate the tangent line of f(x) at x0?

Thanks!