Skip to content

Commit

Permalink
refined comments
Browse files Browse the repository at this point in the history
  • Loading branch information
NicolasBoumal committed Jul 5, 2024
1 parent 4894b48 commit abca9e3
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions tests/test_penrose.m
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,14 @@
problem.egrad = @(X) A'*(A*X*B - C)*B'; % grad f(X) in R^(nxn)

% Wrong.
% This code treats Xdot as if it were in the embedding space.
% This code treats the second input of ehess as if it were in
% the embedding space. Optimization algorithms won't be amused.
problem.ehess = @(X, Xdot) A'*(A*Xdot*B)*B';

% Correct.
% This code transforms Omg to X*Omg, which is the direction that is actually
% encoded by Omg, and which we usually refer to as Xdot.
% This code notes that the second input to ehess is a representation of
% a tangent vector. It transforms Omg to X*Omg, which is the direction
% that is actually encoded by Omg, and which we often call Xdot.
% Equivalently, we can call SOn.tangent2ambient(X, Omg) instead of X*Omg.
problem.ehess = @(X, Omg) A'*(A*X*Omg*B)*B';

Expand Down

0 comments on commit abca9e3

Please sign in to comment.