/[ascend]/trunk/base/generic/solver/slv3.c
ViewVC logotype

Diff of /trunk/base/generic/solver/slv3.c

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

revision 107 by jds, Fri Dec 9 03:49:19 2005 UTC revision 108 by johnpye, Tue Dec 13 05:53:20 2005 UTC
# Line 2178  static void coefs_from_parm( slv3_system Line 2178  static void coefs_from_parm( slv3_system
2178     det = coef[0]*coef[2] - coef[1]*coef[1];     det = coef[0]*coef[2] - coef[1]*coef[1];
2179     if( det < 0.0 )     if( det < 0.0 )
2180    
2181        error_reporter(ASC_PROG_ERROR,NULL,0,"Unexpected negative determinant %g.", det);        /* error_reporter(ASC_PROG_ERROR,NULL,0,"Unexpected negative determinant %f.", det); */
2182                fprintf(stderr,"Unexpected negative determinant %f.\n",det);
2183        FPRINTF(MIF(sys),"%-40s ---> %g\n",  
2184                "    Unexpected negative determinant!",det);        /* FPRINTF(MIF(sys),"%-40s ---> %g\n",
2185                  "    Unexpected negative determinant!",det); */
2186    
2187     if( det <= DETZERO ) {     if( det <= DETZERO ) {
2188        /**        /**
# Line 3975  static void slv3_iterate(slv_system_t se Line 3976  static void slv3_iterate(slv_system_t se
3976        sys->s.inconsistent = TRUE;        sys->s.inconsistent = TRUE;
3977    
3978        error_reporter_start(ASC_PROG_ERROR,NULL,0);        error_reporter_start(ASC_PROG_ERROR,NULL,0);
3979        FPRINTF(mif,"No solution exists within the bounds given for variable '");        FPRINTF(ASCERR,"No solution exists within the bounds given for variable '");
3980        print_var_name(mif,sys,var);        print_var_name(ASCERR,sys,var);
3981        FPRINTF(mif,"' when inverting relation:\n");        FPRINTF(ASCERR,"' when inverting relation:\n");
3982        print_rel_name(mif,sys,rel);        print_rel_name(ASCERR,sys,rel);
3983        error_reporter_end_flush();        error_reporter_end_flush();
3984    
3985        iteration_ends(sys);        iteration_ends(sys);
# Line 3994  static void slv3_iterate(slv_system_t se Line 3995  static void slv3_iterate(slv_system_t se
3995    
3996    scale_system(sys);    scale_system(sys);
3997    
3998    if( !calc_gradient(sys) )    if( !calc_gradient(sys) ){
3999      error_reporter_start(ASC_PROG_ERROR,NULL,0);      error_reporter(ASC_PROG_ERROR,NULL,0,"QRSlv: Gradient calculation errors detected.");
4000      FPRINTF(MIF(sys),"Gradient calculation errors detected.\n");      FPRINTF(MIF(sys),"QRSlv: Gradient calculation errors detected.\n");
4001      error_reporter_end_flush();      error_reporter_end_flush();
4002      }
4003    set_factor_options(sys); /* KHACK: new call to fix lack of proper update */    set_factor_options(sys); /* KHACK: new call to fix lack of proper update */
4004    rank_defect = calc_pivots(sys);    rank_defect = calc_pivots(sys);
4005    if (SAVLIN) {    if (SAVLIN) {
# Line 4265  static void slv3_iterate(slv_system_t se Line 4267  static void slv3_iterate(slv_system_t se
4267  static void slv3_solve(slv_system_t server, SlvClientToken asys)  static void slv3_solve(slv_system_t server, SlvClientToken asys)
4268  {  {
4269    slv3_system_t sys;    slv3_system_t sys;
   fprintf(stderr,"slv3_solve starting\n");  
4270    CONSOLE_DEBUG("starting");    CONSOLE_DEBUG("starting");
4271    sys = SLV3(asys);    sys = SLV3(asys);
4272    if (server == NULL || sys==NULL) return;    if (server == NULL || sys==NULL) return;

Legend:
Removed from v.107  
changed lines
  Added in v.108

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