# NewtonStep.m

NewtonStep.m — Objective-C source code, 0Kb

## File contents

function dX = NewtonStep(X,F) %%%% PERTURBATION ON THE STATE VARIABLES global delta %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% dy = zeros(length(F),length(X)); for i = 1:1:length(X) X_pert = X; X_pert(i) = X(i)+delta; % perturb one element [tp,Fp,F_pert] = StrideMap(X_pert); % Evaluates StrideMap dy(:,i) = (F_pert-X_pert)-(F-X); end %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % Jacobian of the Stride Map error, G(X) J_g = (dy/delta); dX = -J_g\(F - X);