Undefined function 'symsum' for input arguments of type 'uint8'

1 view (last 30 days)
for i = 1 : m
for c = 1 : n
for k = 1 : w
for j = (((k - 1)* arr(k)+1) : (k * arr(k)))
total(i,k) =symsum(image1(i,c),j) / arr(k);
end;
end;
end;
end;
this is a preview of the equation i typed it on matlab but i get an error as "Undefined function 'symsum' for input arguments of type 'uint8'" .
this is the actual equation.
where [m n] = size of the image
arr(k) = width of the kth stripe
j = j = (k - 1)* arr(k)+1) : k * arr(k)
image(i,c) = gray value at the ith row and cth column
can you help with with an equation for this?

Accepted Answer

Steven Lord
Steven Lord on 3 Jun 2020
Nowhere in your code do you define any symbolic variables so symsum is not the right tool to use in this situation. Use sum and specify the dimension over which you want to sum.
A = randi(10, 5, 5)
sum(A, 1) % sum down columns
sum(A, 2) % sum across rows

More Answers (0)

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!