`w = 3;t = 0:1:8;Y = (t*sqrt(t.^2+w^2))+((w^2)*log((t+sqrt(t.^2+w^2))/w));P2 = 1-((w^2)/(t^.2+w^2))*cos(Y)*cos(Y);plot(t, P2)`

The equation that I am trying to plot are highlighted in blue.

Please Help.

Skip to content# MATLAB: Error using * Inner matrix dimensions must agree? It also shows an error for Y, but I can’t figure out what it is

###### Related Question

errorinner matrix dimensions

`w = 3;t = 0:1:8;Y = (t*sqrt(t.^2+w^2))+((w^2)*log((t+sqrt(t.^2+w^2))/w));P2 = 1-((w^2)/(t^.2+w^2))*cos(Y)*cos(Y);plot(t, P2)`

The equation that I am trying to plot are highlighted in blue.

Please Help.

- What is the correct equation
- Hi. I have a problem with the convolution (in black) that I don’t know how to fix. The convolution is ok, but it should be transferred 5 units do the left (y+5). what could I do? Thanks!
- Error using * in a simple matlab program
- Plotting Answers to dsolve
- Hello everyone, I wrote a code for computing an equation and plot in 3-D (surf)? but it didn’t give me a right answer! what is the problem? Also the plot is attached.

## Best Answer