Skip to content

Commit 76655b9

Browse files
committed
finishing up
1 parent da8c8e8 commit 76655b9

File tree

2 files changed

+9
-7
lines changed

2 files changed

+9
-7
lines changed

.travis.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,12 @@ install:
1414
- cd qpOASES
1515
- mkdir build && cd build
1616
- cmake .. -DCMAKE_CXX_FLAGS=-fPIC
17-
- sudo make install
17+
- sudo make install -j8
1818
- cd ../../
1919

2020
script:
2121
- cmake ./cpp
22-
- make && sudo make install
22+
- make -j8 && sudo make install -j8
2323
- mkdir ./cpp/test/build
24-
- cd ./cpp/test/build && cmake .. && make
24+
- cd ./cpp/test/build && cmake .. && make -j8
2525
- ./test_pin

cpp/include/traj_gen2/TrajGen.hpp

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1037,11 +1037,13 @@ namespace trajgen {
10371037
QpForm<T,dim> QpNew(Np,0,Nineq);
10381038
for (uint dd = 0 ; dd < dim ; dd++){
10391039
QpNew.qpBlock[dd].Q = Qpp.sparseView();
1040-
QpNew.qpBlock[dd].H = (QpFormOrig.qpBlock[dd].beq.transpose()*(Qfp+Qpf.transpose())).sparseView();
1041-
QpNew.qpBlock[dd].A = (QpFormOrig.qpBlock[dd].A*AfpInv.block(0,Nf,Nf+Np,Np)).sparseView();
1040+
MatrixRow <T> Htmp = (QpFormOrig.qpBlock[dd].beq.transpose()*(Qfp+Qpf.transpose()));
1041+
QpNew.qpBlock[dd].H = Htmp.sparseView();
1042+
MatrixRow <T> Atmp = (QpFormOrig.qpBlock[dd].A*AfpInv.block(0,Nf,Nf+Np,Np));
1043+
QpNew.qpBlock[dd].A = Atmp.sparseView();
10421044
MatrixRow<T> Af = (QpFormOrig.qpBlock[dd].A*AfpInv).block(0,0,Nineq,Nf);
1043-
QpNew.qpBlock[dd].b = QpFormOrig.qpBlock[dd].b -
1044-
Af.sparseView() *QpFormOrig.qpBlock[dd].beq;
1045+
spMatrixRow<T> AfSparse = Af.sparseView();
1046+
QpNew.qpBlock[dd].b = QpFormOrig.qpBlock[dd].b - spMatrixRow<T>(AfSparse*QpFormOrig.qpBlock[dd].beq);
10451047
}
10461048
return QpNew;
10471049
}

0 commit comments

Comments
 (0)