Help with nonlinearity in objective function

Hi all,

I am having a frustrating time trying to keep my model an LP problem. I am writing a simple cost function which takes the form:

deftransportcost(a,i,j)… transportcost =e= sum(aij(a,i,j), ctrans(a,i,j)* f(a,i,j));

where deftransportcost is the objective function , ctrans is a parameter, and f(a,i,j) is the free-moving decision variable (x)


The problem is, this formulation means that if any of the arc flows are negative (which is allowed as the arcs represent reversible-flow pipelines), I get negative values for some of the arc flow costs. Using the abs(f(a,i,j) function works, but as abs is a nonlinear function, I then have to change the solver to DNLP and create extra computational time etc. I want to keep the problem linear.

Can anybody advise the simple way to rearrange this equation, or a trick that will alleviate this problem? My maths isn’t great, but I hope it’s something fairly simple.


Thanks in advance,

Stevie


To unsubscribe from this group and stop receiving emails from it, send an email to gamsworld+unsubscribe@googlegroups.com.
To post to this group, send email to gamsworld@googlegroups.com.
Visit this group at http://groups.google.com/group/gamsworld.
For more options, visit https://groups.google.com/d/optout.

Hi Stevie,

Check this link, it may help you to linearize the ABS function.

http://orinanobworld.blogspot.co.uk/2012/07/modeling-absolute-values.html


Cheers,
Pedro

On Mon, Feb 2, 2015 at 10:40 PM, Stevie Lochran wrote:

Hi all,

I am having a frustrating time trying to keep my model an LP problem. I am writing a simple cost function which takes the form:

deftransportcost(a,i,j)… transportcost =e= sum(aij(a,i,j), ctrans(a,i,j)* f(a,i,j));

where deftransportcost is the objective function , ctrans is a parameter, and f(a,i,j) is the free-moving decision variable (x)


The problem is, this formulation means that if any of the arc flows are negative (which is allowed as the arcs represent reversible-flow pipelines), I get negative values for some of the arc flow costs. Using the abs(f(a,i,j) function works, but as abs is a nonlinear function, I then have to change the solver to DNLP and create extra computational time etc. I want to keep the problem linear.

Can anybody advise the simple way to rearrange this equation, or a trick that will alleviate this problem? My maths isn’t great, but I hope it’s something fairly simple.


Thanks in advance,

Stevie


To unsubscribe from this group and stop receiving emails from it, send an email to gamsworld+unsubscribe@googlegroups.com.
To post to this group, send email to gamsworld@googlegroups.com.
Visit this group at http://groups.google.com/group/gamsworld.
For more options, visit https://groups.google.com/d/optout.



\

PEDRO JAVIER RAMÍREZ TORREALBA
Ingeniero Civil Eléctrico PUC
MSc en Ingeniería Eléctrica PUC
Londres, REINO UNIDO

Celular: +44-(0)75-8069-3119


To unsubscribe from this group and stop receiving emails from it, send an email to gamsworld+unsubscribe@googlegroups.com.
To post to this group, send email to gamsworld@googlegroups.com.
Visit this group at http://groups.google.com/group/gamsworld.
For more options, visit https://groups.google.com/d/optout.