IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 36065


Ignore:
Timestamp:
Aug 30, 2013, 4:37:29 PM (13 years ago)
Author:
eugene
Message:

some verbosity on dgaussjordan for testing

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ipp-20130711/Ohana/src/libohana/src/gaussj.c

    r24080 r36065  
    11# include <ohana.h>
    22# define GROWTHTEST 0
    3 # define MAX_RANGE 1.0e7
     3# define MAX_RANGE 1.0e9
    44
    55// Gauss-Jordan elimination using full pivots based on Press et al's description.  Substantially
     
    9191    /* rescale by pivot reciprocal */
    9292    double tmpval = 1.0 / A[maxcol][maxcol];
     93    // XXX why is this here (don't I double count this element?) A[maxcol][maxcol] = 1.0;
    9394    A[maxcol][maxcol] = 1.0;
    9495    for (col = 0; col < N; col++) A[maxcol][col] *= tmpval;
     
    117118    }
    118119  }
     120
     121# if (GROWTHTEST)
     122    fprintf (stderr, "final A matrix:\n");
     123    for (row = 0; row < N; row++) {
     124        for (col = 0; col < N; col++) {
     125            fprintf (stderr, "%10.3e ", A[row][col]);
     126        }
     127        fprintf (stderr, "\n");
     128    }
     129    fprintf (stderr, "\n");
     130# endif
    119131
    120132  // swap back the inverse matrix based on the row swaps above
Note: See TracChangeset for help on using the changeset viewer.