computing the adjoint of operator $T$ on the space $P_2(\mathbb{R})$ Suppose that the inner product on $P_2(\mathbb{R})$ is defined by $$\langle f,g \rangle:= f(-1)g(-1)+f(0)g(0)+f(1)g(1).$$
Consider the operator $T \in B(P_2(\mathbb{R}))$ which is defined as $Tf=f'$, so the derivative of $f$. Find the adjoint of $T$.
I am trying to find the adjoint in the following way.
Since $\langle Tf, g\rangle = \langle f, T^*g\rangle$ then we have that 
$\langle f, T^*g\rangle = f'(-1)g(-1) + f'(0)g(0) + f'(1)g(1)$. How do I continue now since I don't know how $T^*$ looks like? I appreciate your help.
 A: I don't think you can get it directly. But you can do the following. Consider an orthonormal basis. For instance, 
$$\tag1
\frac{1}{\sqrt3},\ \frac{x}{\sqrt2},\ \frac{\sqrt3}{\sqrt2}\,(x^2-\frac23).
$$
We have 
$$
T(\frac1{\sqrt3})=0,\ \ T(\frac{x}{\sqrt2})=\frac1{\sqrt2}=\frac{\sqrt3}{\sqrt2}\,\frac1{\sqrt3},\ T(\frac{\sqrt3}{\sqrt2}\,(x^2-2/3))=\frac{\sqrt3}{\sqrt2}(2x)=2\sqrt3\,\frac{x}{\sqrt2}.
$$
So the matrix of $T$ with respect to the orthonormal basis $(1)$ is 
$$
T=\begin{bmatrix} 0&\sqrt3/\sqrt2&0\\ 0&0&2\sqrt3\\  0&0&0\end{bmatrix},
$$
and so $T^*$ has matrix 
$$
T^*=\begin{bmatrix} 0&0&0\\ \sqrt3/\sqrt2&0&0\\ 0&2\sqrt3&0\end{bmatrix}.
$$
This tells us that 
$$
T^*1=\sqrt3\,T^*(\frac1{\sqrt3})=\sqrt3\,\frac{\sqrt3}{\sqrt2}\,\frac{x}{\sqrt2}=\frac{3}2\,x,
$$
$$
T^*x=\sqrt2\,T^*(\frac{x}{\sqrt2})=\sqrt2\,\,2\sqrt3\,\frac{\sqrt3}{\sqrt2}(x^2-2/3)=6x^2-4,
$$
$$
T^*x^2=T^*(x^2-\frac23)+T^*(\frac23)=T^*(\frac23)=\frac23\,T^*1=\frac23\,\frac{3}2\,x={x}{}.
$$
In summary, 
$$
T^*(ax^2+bx+c)={ax}{}+b(6x^2-4)+\frac{3 c x}2
=6bx^2+\left(a{}+\frac{3 c}2 \right)x-4b.
$$
A: Every $f\in P_2$ can be written as
$$
    f=f(-1)\frac{1}{2}x(x-1)+f(0)(1-x^2)+f(1)\frac{1}{2}x(x+1)$$
Therefore,
$$
   f'(x)=f(-1)(x-\frac{1}{2})-2f(0)x+f(1)(x+\frac{1}{2})
$$
which gives
\begin{align}
   f'(-1)&=-\frac{3}{2}f(-1)+2f(0)-\frac{1}{2}f(1) \\
   f'(0)&=-\frac{1}{2}f(-1)+\frac{1}{2}f(1) \\
   f'(1)&=\frac{1}{2}f(-1)-2f(0)+\frac{3}{2}f(1)
\end{align}
So
$$
   \left[\begin{array}{c}(Tf)(-1)\\ (Tf)(0)\\ (Tf)(1)\end{array}\right]
   = \left[\begin{array}{ccc}-\frac{3}{2} & 2 & -\frac{1}{2} \\
     -\frac{1}{2} & 0 & \frac{1}{2} \\
      \frac{1}{2} & -2 & \frac{3}{2}\end{array}\right]\left[\begin{array}{c} f(-1)\\f(0)\\f(1)\end{array}\right]
$$
Therefore, $T^*$ is represented by the transpose
$$
   \left[\begin{array}{c}(T^*f)(-1)\\ (T^*f)(0)\\ (T^*f)(1)\end{array}\right]
   = \left[\begin{array}{ccc}-\frac{3}{2} & -\frac{1}{2} & \frac{1}{2} \\
     2 & 0 & -2 \\
      -\frac{1}{2} & \frac{1}{2} & \frac{3}{2}\end{array}\right]\left[\begin{array}{c} f(-1)\\f(0)\\f(1)\end{array}\right]
$$
Therefore,
\begin{align}
   T^*f &= (T^*f)(-1)\frac{1}{2}x(x-1) \\ & +(T^*f)(0)(1-x^2)\\ &+(T^*f)(1)\frac{1}{2}x(x+1) \\
 &= \left(-\frac{3}{2}f(-1)-\frac{1}{2}f(0)+\frac{1}{2}f(1)\right)\frac{1}{2}x(x+1) \\
 &+2\left(f(-1)-f(1)\right)(1-x^2) \\
 &+\left(-\frac{1}{2}f(-1)+\frac{1}{2}f(0)+\frac{3}{2}f(1)\right)\frac{1}{2}x(x-1) \\
 &= f(-1)A(x)+f(0)B(x)+f(1)C(x).
\end{align}
I'll let you write $A,B,C$.
