From 92be425458cdce3d38ec9532059a3ba05c7a71af Mon Sep 17 00:00:00 2001 From: Joan Sola <jsola@iri.upc.edu> Date: Tue, 15 Dec 2015 09:59:56 +0100 Subject: [PATCH] Replaced uint by unsigned int --- src/examples/solver/test_ccolamd_blocks.cpp | 8 ++++---- src/examples/solver/test_iQR.cpp | 8 ++++---- src/examples/solver/test_iQR_wolf.cpp | 8 ++++---- src/examples/solver/test_incremental_ccolamd_blocks.cpp | 8 ++++---- 4 files changed, 16 insertions(+), 16 deletions(-) diff --git a/src/examples/solver/test_ccolamd_blocks.cpp b/src/examples/solver/test_ccolamd_blocks.cpp index 9f345c7ce..64421f502 100644 --- a/src/examples/solver/test_ccolamd_blocks.cpp +++ b/src/examples/solver/test_ccolamd_blocks.cpp @@ -28,8 +28,8 @@ using namespace Eigen; void eraseSparseBlock(SparseMatrix<double>& original, const unsigned int& row, const unsigned int& Nrows, const unsigned int& col, const unsigned int& Ncols) { - for (uint i = row; i < row + Nrows; i++) - for (uint j = col; j < row + Ncols; j++) + for (unsigned int i = row; i < row + Nrows; i++) + for (unsigned int j = col; j < row + Ncols; j++) original.coeffRef(i,j) = 0.0; original.makeCompressed(); @@ -37,8 +37,8 @@ void eraseSparseBlock(SparseMatrix<double>& original, const unsigned int& row, c void addSparseBlock(const MatrixXd& ins, SparseMatrix<double>& original, const unsigned int& row, const unsigned int& col) { - for (uint r=0; r<ins.rows(); ++r) - for (uint c = 0; c < ins.cols(); c++) + for (unsigned int r=0; r<ins.rows(); ++r) + for (unsigned int c = 0; c < ins.cols(); c++) original.coeffRef(r + row, c + col) += ins(r,c); } diff --git a/src/examples/solver/test_iQR.cpp b/src/examples/solver/test_iQR.cpp index a224fd729..d93cdcce8 100644 --- a/src/examples/solver/test_iQR.cpp +++ b/src/examples/solver/test_iQR.cpp @@ -60,8 +60,8 @@ void eraseSparseBlock(SparseMatrix<double>& original, const unsigned int& row, c block_pruning bp(row, col, Nrows, Ncols); original.prune(bp); -// for (uint i = row; i < row + Nrows; i++) -// for (uint j = col; j < row + Ncols; j++) +// for (unsigned int i = row; i < row + Nrows; i++) +// for (unsigned int j = col; j < row + Ncols; j++) // original.coeffRef(i,j) = 0.0; // // original.prune(0); @@ -69,8 +69,8 @@ void eraseSparseBlock(SparseMatrix<double>& original, const unsigned int& row, c void addSparseBlock(const MatrixXd& ins, SparseMatrix<double>& original, const unsigned int& row, const unsigned int& col) { - for (uint r=0; r<ins.rows(); ++r) - for (uint c = 0; c < ins.cols(); c++) + for (unsigned int r=0; r<ins.rows(); ++r) + for (unsigned int c = 0; c < ins.cols(); c++) if (ins(r,c) != 0) original.coeffRef(r + row, c + col) += ins(r,c); } diff --git a/src/examples/solver/test_iQR_wolf.cpp b/src/examples/solver/test_iQR_wolf.cpp index 71b4e23ae..61892690d 100644 --- a/src/examples/solver/test_iQR_wolf.cpp +++ b/src/examples/solver/test_iQR_wolf.cpp @@ -54,8 +54,8 @@ void eraseSparseBlock(SparseMatrix<double>& original, const unsigned int& row, c block_pruning bp(row, col, Nrows, Ncols); original.prune(bp); -// for (uint i = row; i < row + Nrows; i++) -// for (uint j = col; j < row + Ncols; j++) +// for (unsigned int i = row; i < row + Nrows; i++) +// for (unsigned int j = col; j < row + Ncols; j++) // original.coeffRef(i,j) = 0.0; // // original.prune(0); @@ -63,8 +63,8 @@ void eraseSparseBlock(SparseMatrix<double>& original, const unsigned int& row, c void addSparseBlock(const MatrixXd& ins, SparseMatrix<double>& original, const unsigned int& row, const unsigned int& col) { - for (uint r=0; r<ins.rows(); ++r) - for (uint c = 0; c < ins.cols(); c++) + for (unsigned int r=0; r<ins.rows(); ++r) + for (unsigned int c = 0; c < ins.cols(); c++) if (ins(r,c) != 0) original.coeffRef(r + row, c + col) += ins(r,c); } diff --git a/src/examples/solver/test_incremental_ccolamd_blocks.cpp b/src/examples/solver/test_incremental_ccolamd_blocks.cpp index c82236492..ca39a9d2e 100644 --- a/src/examples/solver/test_incremental_ccolamd_blocks.cpp +++ b/src/examples/solver/test_incremental_ccolamd_blocks.cpp @@ -28,8 +28,8 @@ using namespace Eigen; void eraseSparseBlock(SparseMatrix<double>& original, const unsigned int& row, const unsigned int& Nrows, const unsigned int& col, const unsigned int& Ncols) { - for (uint i = row; i < row + Nrows; i++) - for (uint j = col; j < row + Ncols; j++) + for (unsigned int i = row; i < row + Nrows; i++) + for (unsigned int j = col; j < row + Ncols; j++) original.coeffRef(i,j) = 0.0; original.makeCompressed(); @@ -37,8 +37,8 @@ void eraseSparseBlock(SparseMatrix<double>& original, const unsigned int& row, c void addSparseBlock(const MatrixXd& ins, SparseMatrix<double>& original, const unsigned int& row, const unsigned int& col) { - for (uint r=0; r<ins.rows(); ++r) - for (uint c = 0; c < ins.cols(); c++) + for (unsigned int r=0; r<ins.rows(); ++r) + for (unsigned int c = 0; c < ins.cols(); c++) if (ins(r,c) != 0) original.coeffRef(r + row, c + col) += ins(r,c); } -- GitLab