/[ascend]/trunk/solvers/ida/ida.c
ViewVC logotype

Diff of /trunk/solvers/ida/ida.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2366 by jpye, Mon Jan 31 01:22:04 2011 UTC revision 2367 by jpye, Mon Jan 31 06:41:54 2011 UTC
# Line 1026  static int integrator_ida_solve( Line 1026  static int integrator_ida_solve(
1026          Asc_SignalHandlerPopDefault(SIGINT);          Asc_SignalHandlerPopDefault(SIGINT);
1027  #endif  #endif
1028    
1029          /* check for roots found */          /* this seems to work, so we can use it to avoid needing 'havecrossed'? */
1030            if(flag == IDA_ROOT_RETURN){
1031                CONSOLE_DEBUG("IDA reports root found!");
1032            }
1033    
1034            /* so we will check for roots found explicitly */
1035          if(enginedata->nbnds){          if(enginedata->nbnds){
1036              rootsfound = ASC_NEW_ARRAY_CLEAR(int,enginedata->nbnds);              rootsfound = ASC_NEW_ARRAY_CLEAR(int,enginedata->nbnds);
1037              havecrossed = 0;              havecrossed = 0;
# Line 1036  static int integrator_ida_solve( Line 1041  static int integrator_ida_solve(
1041                          havecrossed = 1;                          havecrossed = 1;
1042  #ifdef SOLVE_DEBUG  #ifdef SOLVE_DEBUG
1043                          relname = bnd_make_name(integ->system,enginedata->bndlist[i]);                          relname = bnd_make_name(integ->system,enginedata->bndlist[i]);
1044                          ERROR_REPORTER_HERE(ASC_PROG_WARNING,"Boundary '%s' crossed",relname);                          ERROR_REPORTER_HERE(ASC_PROG_WARNING,"Boundary '%s' crossed%s",relname,rootsfound[i]>0?" (increasing)":" (decreasing)");
1045                          ASC_FREE(relname);                          ASC_FREE(relname);
1046  #else  #else
1047                          ERROR_REPORTER_HERE(ASC_PROG_WARNING,"Boundary %d crossed!", i);                          ERROR_REPORTER_HERE(ASC_PROG_WARNING,"Boundary %d crossed!%s", i, ,rootsfound[i]>0?" (increasing)":" (decreasing)");
1048  #endif  #endif
1049                      }                      }
1050                  }                  }

Legend:
Removed from v.2366  
changed lines
  Added in v.2367

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22