Changeset 20512


Ignore:
Timestamp:
04/14/16 19:41:00 (9 years ago)
Author:
Mathieu Morlighem
Message:

BUG: take care of case vx=vy=0

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk-jpl/src/m/exp/flowlines.m

    r20502 r20512  
    8888
    8989        %velocity of the current triangle and norm it
    90         ut=u(tria); vt=v(tria); normv=sqrt(ut.^2+vt.^2);
     90        ut=u(tria); vt=v(tria); normv=max(eps,sqrt(ut.^2+vt.^2));
    9191        ut=ut./normv;vt=vt./normv;
    9292
     
    138138
    139139        %velocity of the current triangle and norm it
    140         ut=-u(tria); vt=-v(tria); normv=sqrt(ut.^2+vt.^2);
     140        ut=-u(tria); vt=-v(tria); normv=max(eps,sqrt(ut.^2+vt.^2));
    141141        ut=ut./normv;vt=vt./normv;
    142142
Note: See TracChangeset for help on using the changeset viewer.