Calculating energy and power of a signal
How do I calculate power for each signal?
Complex Power Calculation
how to calculate power of a matrix
Videos
The Matlab function int needs a symbolic expression as an integrand, and a symbolic variable as an integration variable. In your example s and t are both vectors, and you can't use int in this case. If you want to compute the power or energy of discrete time signals, then you need to use the corresponding definitions:
$$E_x=\sum_{n=-\infty}^{\infty}|x_n|^2\\ P_x=\lim_{N\rightarrow\infty}\frac{1}{2N+1}\sum_{n=-N}^N|x_n|^2$$
In practice you will need to consider finite length signals unless you have an analytic formula for $x_n$ and some software package that can deal with the analytic evaluation of infinite sums. Obviously, finite length signals always have finite energy and $P_x=0$ according to above definition.
Refer this link for calculation of Energy and Power of signal: http://www.mathworks.com/matlabcentral/fileexchange/11202-automatic-gain-control