Double summation with nested sum
Afficher commentaires plus anciens

I need to write this in Matlab. I need some help.Thanks in advance.
Réponse acceptée
Plus de réponses (1)
Walter Roberson
le 23 Déc 2017
V = @(M) M(:);
part1 = sum(bsxfun( @times, V(x(2:30)), 1:9 ) .* bsxfun(@power, (1:29).'/29, 0:8 ), 2);
part2 = sum(bsxfun( @times, V(x(2:30)), bsxfun(@power, (1:29).'/29, 1:9 )), 2).^2;
part3 = sum((part1 - part2 - 1).^2);
result = part3 + x(1).^2 + (x(2) - x(1).^2 - 1).^2;
Catégories
En savoir plus sur Mathematics dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
