Code covered by the BSD License  

Highlights from
Hamilton-Jacobi solver on unstructured triangular grids

image thumbnail
from Hamilton-Jacobi solver on unstructured triangular grids by Shawn Walker
Solves a class of static HJB equations on general triangular grids.

d=dist_circle(p,xc,yc,r)
function d=dist_circle(p,xc,yc,r)

%   analytic formula for the oriented distance function of a circle
%   Note: negative inside.

d=sqrt((p(:,1)-xc).^2+(p(:,2)-yc).^2)-r;

Contact us at files@mathworks.com