Hello! I having some problems writing the P matrix in the C interface. I have the following matrix:

I’m writing it like this:

And it works, but the solutions are not good and I’m pretty sure that the P_p vector is wrong and it should be like:

P_p[10] = {1, 2, 3, 4, 5, 6, 7, 9};

But I get an error saying that the P matrix is not upper triangular.

What I’m doing wrong? am I misunderstanding the column pointer of sparse structure?

Thank you!