I'm doing my homework on signal processing in MatLab and I'm stuck on an exercise.
I'm given this signal $x(t)=1 + 2\sin(12\pi t+\frac{\pi}{4})\cos(21\pi t);$ and I have to get the non null complex Fourier coefficients using this expression $$C_{m}=\frac{1}{T_{0}}\int_{-\frac{T_{0}}{2}}^{\frac{T_{0}}{2}}x(t)e^{-im\omega_{0}t}dt$$
Analytically I've found that $\omega_{0} = 2 rad/s$ so $C_{m} = {2,4}$ and $\Theta_{m} = -\pi,\frac{\pi}{3},\frac{\pi}{4}$
Now I have to do this in MatLab. I've created the following script where I'm calculating the integral but now I'm stuck and don't know what to do next. Can you point me in some direction?
This is my script:
function cfc
syms m t;
% Signal
x1 = 1 + 2*sin(12*pi*t+pi/4)*cos(21*pi*t);
%T0 and w0
T01 = 2*pi/3;
w01 = 2*pi/T01;
% Cm
disp('Cm');
Cm1 = 1/T01 * int(x1*exp(-1i*m*w01*t),t,-T01/2,T01/2);
pretty(Cm1);
end