From: Sara Mouro <sara_at_gmesintra.com>

Date: Sat 15 Oct 2005 - 02:05:41 EST

R-help@stat.math.ethz.ch mailing list

https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Sat Oct 15 02:17:58 2005

Date: Sat 15 Oct 2005 - 02:05:41 EST

Dear all,

I am a beginner with lpSolve package (and not an expert in the others). I can not understand why I am doing wrong, and I would be very grateful if anyone could please help me on this.

I am trying to optimize ("min") the sum of columns/variables, constrained to

*>=1. Each column/variables has its weight - given by values at f.obj.
*

The matrix for numeric constraint coefficients is given by "DadosM" (from my
Dados file).

Here is what I have done:

*>
*

Dados<-read.table("C:/SARA/PhD/Analise-GRAPHs/DadosInput_Componente1.txt",he
ad=T)

*> DadosM=as.matrix(Dados)
*

*> f.obj<-c(1,2,2,2,2,2,2,2,4,4,4,4,4,4,4,4,6,6,6,6,8,8,8)
*

*> f.dir<-array(c(">="),dim=c(1,379))
**>
**> f.rhs<-array(1,dim=c(1,23))
*

*> lp ("min", f.obj, DadosM, f.dir, f.rhs, transpose.constraints = TRUE,
*

presolve=0, compute.sens=0)

Error: no feasible solution found

Mensagem de aviso: number of columns of result not a multiple of vector
length (arg 2) in: rbind(const.mat, const.dir.num, const.rhs)

I imagine that there are some arguments I am not defining properly. Is it? Which one(s)? I really could not understand more than this from the help file.

Hope you have some time to help me on this. Thank you in advance.

Sara Mouro

[[alternative HTML version deleted]]

R-help@stat.math.ethz.ch mailing list

https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Sat Oct 15 02:17:58 2005

*
This archive was generated by hypermail 2.1.8
: Sun 23 Oct 2005 - 18:54:14 EST
*