[Coin-discuss] loading a CoinPackedMatrix

Kish Shen kish.shen at crosscoreop.com
Tue Dec 6 16:00:31 EST 2005


Hi,

I have been trying to interface from our Constraint Logic Programming 
language ECLiPSe to the OSI interface. I have been creating the problem by
adding to the CoinPackMatrix one column at a time, but this seems to be
quite slow for big problems, and I assume this is due to the problem of having 
to keep expanding the packed matrix.

I think one way around this problem is to construct the matrix at once, when 
calling the constructor. Looking at the Doxygen documentation, the 
constructor has the following arguments:

CoinPackedMatrix::CoinPackedMatrix  	(   	const bool   	 colordered,
		const int  	minor,
		const int  	major,
		const CoinBigIndex  	numels,
		const double *  	elem,
		const int *  	ind,
		const CoinBigIndex *  	start,
		const int *  	len,
		const double  	extraMajor,
		const double  	extraGap
	)  
I was not able to find any detailed description of the meaning of the 
arguments (is there such documentation available?), but am I correct in 
thinking that elem, ind, start, len describes the matrix in a similar way to 
that used by CPLEX/Xpress? That is, elem, ind are arrays of size elem, and 
specifies the non-zero elements for each column (if colordered is true), 
start and len are of size number of columns, and start specifies the start of 
each column in elem and ind, while len gives the number of non-zero element 
in that column.  Is this correct?

Thanks in advance for any help!

Cheers,

Kish Shen





More information about the Coin-discuss mailing list