IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Oct 24, 2006, 2:27:29 PM (20 years ago)
Author:
Paul Price
Message:

Changed definition of psVectorAlloc and psArrayAlloc

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/stac/src/stacInvertMaps.c

    r8783 r9740  
    1818    int nMaps = maps->n;                // Number of maps
    1919    psArray *inverted = psArrayAlloc(nMaps); // Array of inverted maps for output
    20     inverted->n = nMaps;
    2120
    2221    psTrace("stac.invertMaps", 1, "Inverting maps....\n");
     
    5049        psVector *xOut = psVectorAlloc(NUM_GRID * NUM_GRID, PS_TYPE_F32);
    5150        psVector *yOut = psVectorAlloc(NUM_GRID * NUM_GRID, PS_TYPE_F32);
    52         xIn->n = NUM_GRID * NUM_GRID;
    53         yIn->n = NUM_GRID * NUM_GRID;
    54         xOut->n = NUM_GRID * NUM_GRID;
    55         yOut->n = NUM_GRID * NUM_GRID;
    5651
    5752        // Create grid of points
     
    7570        psVector *xVector = psVectorAlloc(nCoeff, PS_TYPE_F64); // Vector for solution in x
    7671        psVector *yVector = psVectorAlloc(nCoeff, PS_TYPE_F64); // Vector for solution in y
    77         xVector->n = nCoeff;
    78         yVector->n = nCoeff;
    7972        for (int i = 0; i < nCoeff; i++) {
    8073            for (int j = 0; j < nCoeff; j++) {
     
    115108        // Solution via LU Decomposition
    116109        psVector *permutation = psVectorAlloc(nCoeff, PS_TYPE_F64); // Permutation vector for LU Decomposition
    117         permutation->n = nCoeff;
    118110        psImage *luMatrix = psMatrixLUD(NULL, &permutation, matrix); // LU decomposed matrix
    119111        psVector *xSolution = psMatrixLUSolve(NULL, luMatrix, xVector, permutation); // Solution in x
Note: See TracChangeset for help on using the changeset viewer.