Changeset 716


Ignore:
Timestamp:
06/02/09 13:39:08 (15 years ago)
Author:
Mathieu Morlighem
Message:

take into account NaN in controlconstraints

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk/src/m/classes/public/isresultconsistent.m

    r684 r716  
    8080
    8181        %check inversed parameter
    82         if any(md.results.control.parameter<md.mincontrolconstraint | md.results.control.parameter>md.maxcontrolconstraint)
    83                 disp(['''control'' result not consistent: inverse parameter out of range [' md.mincontrolconstraint ' ' md.maxcontrolconstraint ']']);
    84                 bool=0; return;
     82        if ~isnan(md.maxcontrolconstraint),
     83                if any(md.results.control.parameter>md.maxcontrolconstraint)
     84                        disp(['''control'' result not consistent: inverse parameter is greater than ' md.maxcontrolconstraint]);
     85                        bool=0; return;
     86                end
     87        end
     88        if ~isnan(md.mincontrolconstraint),
     89                if any(md.results.control.parameter<md.mincontrolconstraint)
     90                        disp(['''control'' result not consistent: inverse parameter is smaller than ' md.mincontrolconstraint]);
     91                        bool=0; return;
     92                end
    8593        end
    8694
Note: See TracChangeset for help on using the changeset viewer.