while in its equilibrium position a uniform string stretched between the points (0,0) and (ℓ,0) (hint cn=0 since equilibruim)


while in its equilibrium position a uniform string stretched between the points (0,0) and (ℓ,0) (hint cn=0 since equilibruim)


I take it you mean the wave equation should be solved here, which it more or less has. Your job is to match the boundary condition given. You can start by taking the time derivative of your given solution:
$$\dot{y}(x,t) = \sum_{n=1}^{\infty} \frac{n \pi a}{\ell} \sin{\left ( \frac{n \pi x}{\ell} \right)} \left [-C_n \sin{\left ( \frac{n \pi a t}{\ell} \right)} + D_n \cos{\left ( \frac{n \pi a t}{\ell} \right)}\right ] $$
This means that
$$\dot{y}(x,0) = \sum_{n=1}^{\infty} \frac{n \pi a}{\ell} D_n \sin{\left ( \frac{n \pi x}{\ell} \right)} = g(x)$$
This is a Fourier series, so you find the coefficients as follows:
$$\frac{n \pi a}{\ell} D_n = \frac{\displaystyle \int_0^{\ell} dx \, g(x) \, \sin{\left ( \frac{n \pi x}{\ell} \right)}}{\displaystyle \int_0^{\ell} dx \, \sin^2{\left ( \frac{n \pi x}{\ell} \right)}}$$
Now, I suspect your definition of $g$ is not right because the dimensions don't line up; I will take
$$g(x) = \begin{cases} \frac{a x}{\ell} & 0 \le x \le \frac{\ell}{2} \\ a \left ( 1-\frac{x}{\ell}\right) & \frac{\ell}{2} \lt x \le \ell \end{cases} $$
I will let you handle the details of the integration; I get
$$D_n = 2 \ell \frac{(-1)^n}{n}$$
This leaves $C_n$; this should clearly be zero for all $n$ because the string is initially in the equilibrium position. Thus the solution is
$$y(x,t) = 2 \ell \sum_{n=1}^{\infty} \frac{(-1)^n}{n} \sin{\left ( \frac{n \pi x}{\ell} \right)} \sin{\left ( \frac{n \pi a t}{\ell} \right)} $$