$(f,g) = \sum_{k=0}^n f(\frac{k}{n})g(\frac{k}{n})$, where $f,g \in P_n$, the linear space of all polynomials of degree $\leq n$.
If $f(t) = t$, find all linear polynomials $g$ orthogonal to $f$.
I tried doing $\sum_{t=0}^n \frac{t}{n}\frac{at+b}{n} = 0$. That gave me $\frac{a(2n+1)}{3n} - b = 0$.
This isn't right. I know the answer is $g(t) = a(t-\frac{2n+1}{3n})$, where $a$ is arbitrary.
Yo have a good start!
$$ \sum_{k=0}^{n} \frac{k}{n}\frac{ak+b}{n} = {\frac { \left( n+1 \right) \left( 2\,n+1 \right) a}{6n}}+{ \frac { \left( n+1 \right) b}{2n}}=0. $$
Solve the above equation for $a$ and $b$ (you have one free variable) which gives
$$ a=s,\quad b = -\frac{(2n+1)s}{3}, \quad s\in \mathbb{R}. $$
Now substitute back for the values of $a,b$ in $g(t)$ to get
$$ g(t) = st + \frac{(2n+1)s}{3} = s\left( t - \frac{(2n+1)}{3} \right) = a\left( t - \frac{(2n+1)s}{3} \right) $$
since $s$ is an arbitrary constant.