Ticket #13140: trac_13140-rescale-inplace.patch

File trac_13140-rescale-inplace.patch, 673 bytes (added by rbeezer, 7 years ago)
  • sage/matrix/matrix_double_dense.pyx

    # HG changeset patch
    # User Rob Beezer <beezer@ups.edu>
    # Date 1341856211 25200
    # Node ID ded75af0ab5b5b8bc124f82d14c3d38978d2e4ac
    # Parent  959daf22361f611421ec95d3767515fd4459b321
    13140: normalize by rescaling columns inplace
    
    diff --git a/sage/matrix/matrix_double_dense.pyx b/sage/matrix/matrix_double_dense.pyx
    a b  
    40334033                a = M.column(j)[i].real()
    40344034                if a != 0:
    40354035                    if a < 0:
    4036                         M = M.with_rescaled_col(j, -1)
     4036                        M.rescale_col(j, -1)
    40374037                    break
    40384038        return M
    40394039