This is my code so far…

`theta = 10:0.5:80Function_x(theta) = 981./cosd(theta)Function_y(theta) = 981./sind(theta)Function_total(theta) = sqrt(Function_x.^2 + Function_y.^2)`

The error is in line 2, but it will happen for all three since they are all defined as the same variable. How do i fix this. The problem asks for the x and y pieces of tension at angle theta, which is between 10 and 80 degrees at a 0.5 degree increments. But i dont know how to fix the error about subscript indices must be real positive integers or logicals. Any help would be fantastic.

## Best Answer