Skip to main content

calcMinimizingMuscleActivationIntegrand.m


% This function is part of the NMSM Pipeline, see file for full license.
%
% This function minimizes the muscle activation for the specified muscle.
%
% (2D matrix, struct, Array of string) -> (Array of number)
%


function cost = calcMinimizingMuscleActivationIntegrand(...
muscleActivations, params, muscleName)

indx = find(strcmp(convertCharsToStrings(params.muscleNames), ...
muscleName));
cost = calcMinimizingCostArrayTerm(muscleActivations(:, indx));
end