*----------------------------------------------------------- * Date created: February 6, 2001 * * Ron S. Dembo, * A set of geometric programming test problems and * their solutions. * Mathematical Programming, vol.10, 1976, pp.208-211. * * A 5-stage membrane separation process. * * Dr. Neculai Andrei, * Research Institute for Informatics - Bucharest * 8-10, Averescu Avenue, * 71316 Bucharest - Romania * E-mail: nandrei@u3.ici.ro * web: http://www.ici.ro/camo/neculai/nandrei.htm *----------------------------------------------------------- * subroutine ini(n,m,mb,me,sb,x,icgc,ipgc,icge,ipge, 1 nszc,nsze,nb) * double precision x(n) integer sb(mb) integer icgc(nszc),ipgc(n+1) integer icge(nsze),ipge(n+1) * * Information about the problem. * write(1,10) 10 format(5x,'A 5-stage membrane separation process') write(1,11) 11 format(5x,' February 6, 2001') write(1,12) 12 format(5x,'Dembo, 1976 - pp.208-211',/) * * Dimension of the problem: * n=16 m=21 me=0 mb=32 nszc=78 nsze=0 * * Initial point: * x(1)=0.8d0 x(2)=0.83d0 x(3)=0.85d0 x(4)=0.87d0 x(5)=0.91d0 x(6)=0.09d0 x(7)=0.12d0 x(8)=0.19d0 x(9)=0.25d0 x(10)=0.29d0 x(11)=512.0d0 x(12)=13.1d0 x(13)=71.8d0 x(14)=640.0d0 x(15)=650.0d0 x(16)=5.7d0 * * Index vector for simple bounds: cb >= 0. * j=1 do i=1,n sb(j)=i sb(j+1)=-i j=j+2 end do * * Rows indices of the nonzeros of the Jacobian of the Inequalities * icgc(1)=1 icgc(2)=6 icgc(3)=7 icgc(4)=17 icgc(5)=20 icgc(6)=21 * icgc(7)=2 icgc(8)=7 icgc(9)=8 icgc(10)=16 icgc(11)=17 icgc(12)=20 icgc(13)=21 * icgc(14)=3 icgc(15)=8 icgc(16)=9 icgc(17)= 15 icgc(18)=16 icgc(19)=20 icgc(20)=21 * icgc(21)=4 icgc(22)=9 icgc(23)=10 icgc(24)=11 icgc(25)=14 icgc(26)=15 icgc(27)=20 icgc(28)=21 * icgc(29)=5 icgc(30)=10 icgc(31)=11 icgc(32)=14 icgc(33)=20 icgc(34)=21 * icgc(35)=1 icgc(36)=6 * icgc(37)=2 icgc(38)=6 icgc(39)=7 * icgc(40)=3 icgc(41)=7 icgc(42)=8 icgc(43)=9 icgc(44)=19 * icgc(45)=4 icgc(46)=8 icgc(47)=9 icgc(48)=18 icgc(49)=19 * icgc(50)=5 icgc(51)=9 icgc(52)=10 icgc(53)=18 * icgc(54)=6 icgc(55)=12 icgc(56)=13 icgc(57)=6 icgc(58)=7 icgc(59)=12 icgc(60)=13 icgc(61)=20 icgc(62)=21 * icgc(63)=7 icgc(64)=8 icgc(65)=20 icgc(66)=21 * icgc(67)=8 icgc(68)=9 icgc(69)=20 icgc(70)=21 * icgc(71)=9 icgc(72)=10 icgc(73)=20 icgc(74)=21 * icgc(75)=10 icgc(76)=11 icgc(77)=20 icgc(78)=21 * * Starting address of columns of the Jacobian of the Inequalities * ipgc(1)=1 ipgc(2)=7 ipgc(3)=14 ipgc(4)=21 ipgc(5)=29 ipgc(6)=35 ipgc(7)=37 ipgc(8)=40 ipgc(9)=45 ipgc(10)=50 ipgc(11)=54 ipgc(12)=57 ipgc(13)=63 ipgc(14)=67 ipgc(15)=71 ipgc(16)=75 ipgc(17)=79 * return end * *-------------------------------------------------------------- * 5- stage membrane separation problem * Dembo, 1976, pp.208-211. * February 7, 2001 *-------------------------------------------------------------- * subroutine prob(n,m,mb,me,sb,x,objf,gobj,c,gc,cb,e,ge, 1 nszc,nsze,nb) * * Calculate problem function at iterate x. * double precision x(n),objf,gobj(n),c(m),gc(nszc) double precision cb(mb),e(me),ge(nsze) real*8 a,b, w,d,v,f,g * * Objective function and its gradient: * * a=1.262626d0 b=1.231060d0 w=0.03475d0 d=0.975d0 v=0.00975d0 f=0.002d0 g=500.0d0 * objf = a*(x(12)+x(13)+x(14)+x(15)+x(16)) * -b*(x(1)*x(12) + x(2)*x(13) + * x(3)*x(14) + x(4)*x(15) + * x(5)*x(16) ) * gobj(1)=-b*x(12) gobj(2)=-b*x(13) gobj(3)=-b*x(14) gobj(4)=-b*x(15) gobj(5)=-b*x(16) gobj(6)=0.d0 gobj(7)=0.d0 gobj(8)=0.d0 gobj(9)=0.d0 gobj(10)=0.d0 gobj(11)=0.d0 gobj(12)=a-b*x(1) gobj(13)=a-b*x(2) gobj(14)=a-b*x(3) gobj(15)=a-b*x(4) gobj(16)=a-b*x(5) * * Bounds on variables: * cb(1)=x(1)-0.1d0 cb(2)=0.9d0-x(1) cb(3)=x(2)-0.1d0 cb(4)=0.9d0-x(2) cb(5)=x(3)-0.1d0 cb(6)=0.9d0-x(3) cb(7)=x(4)-0.1d0 cb(8)=0.9d0-x(4) cb(9)=x(5)-0.9d0 cb(10)=1.d0-x(5) cb(11)=x(6)-0.0001d0 cb(12)=0.1d0-x(6) cb(13)=x(7)-0.1d0 cb(14)=0.9d0-x(7) cb(15)=x(8)-0.1d0 cb(16)=0.9d0-x(8) cb(17)=x(9)-0.1d0 cb(18)=0.9d0-x(9) cb(19)=x(10)-0.1d0 cb(20)=0.9d0-x(10) cb(21)=x(11)-1.d0 cb(22)=1000.d0-x(11) cb(23)=x(12)-0.000001d0 cb(24)=500.d0-x(12) cb(25)=x(13)-1.d0 cb(26)=500.d0-x(13) cb(27)=x(14)-500.d0 cb(28)=1000.d0-x(14) cb(29)=x(15)-500.d0 cb(30)=1000.d0-x(15) cb(31)=x(16)-0.000001d0 cb(32)=500.d0-x(16) * * Constraints. (INEqualities): * c(1)=x(6) - w*x(1) - d*x(1)*x(6) + v*x(1)*x(1) c(2)=x(7) - w*x(2) - d*x(2)*x(7) + v*x(2)*x(2) c(3)=x(8) - w*x(3) - d*x(3)*x(8) + v*x(3)*x(3) c(4)=x(9) - w*x(4) - d*x(4)*x(9) + v*x(4)*x(4) c(5)=x(10) - w*x(5) - d*x(5)*x(10) + v*x(5)*x(5) * c(6)=x(7)*x(11) - x(6)*x(11) - x(1)*x(12) +x(6)*x(12) * c(7)=x(8) - x(7) - f*x(7)*x(12) - f*x(2)*x(13) + * f*x(8)*x(13) + f*x(1)*x(12) * c(8)=1.d0 - x(8) - f*x(8)*x(13) - f*x(3)*x(14) - x(9) + * f*x(2)*x(13) + f*x(9)*x(14) * c(9)=x(3)*x(14) - x(9)*x(14) -x(4)*x(15) - g*x(10) + * g*x(9) + x(8)*x(15) * c(10)=x(4)*x(15) - x(5)*x(16) -x(10)*x(15) - g*x(4) + * x(4)*x(16) + g*x(10) * c(11)=x(4) - f*x(4)*x(16) + f*x(5)*x(16) - 0.9d0 * c(12)=1.d0 - f*x(11) + f*x(12) * c(13)=x(11)-x(12) c(14)=x(5)-x(4) c(15)=x(4)-x(3) c(16)=x(3)-x(2) c(17)=x(2)-x(1) c(18)=x(10)-x(9) c(19)=x(9)-x(8) * c(20)=a*(x(12)+x(13)+x(14)+x(15)+x(16))- * b*(x(1)*x(12) + x(2)*x(13)+ * x(3)*x(14) + x(4)*x(15)+ * x(5)*x(16)) - 50.d0 * c(21)=-a*(x(12)+x(13)+x(14)+x(15)+x(16))+ * b*(x(1)*x(12) + x(2)*x(13)+ * x(3)*x(14) + x(4)*x(15)+ * x(5)*x(16)) + 250.d0 * * * Jacobian of the inequalities constraints: * * Col 1 gc(1)=-w - d*x(6) + 2.d0*v*x(1) gc(2)=-x(12) gc(3)=f*x(12) gc(4)=-1.d0 gc(5)=-b*x(12) gc(6)=b*x(12) * Col 2 gc(7)=-w - d*x(7) + 2.d0*v*x(2) gc(8)=-f*x(13) gc(9)=f*x(13) gc(10)=-1.d0 gc(11)=1.d0 gc(12)=-b*x(13) gc(13)=b*x(13) * Col 3 gc(14)=-w - d*x(8) + 2.d0*v*x(3) gc(15)=-f*x(14) gc(16)=x(14) gc(17)=-1.d0 gc(18)=1.d0 gc(19)=-b*x(14) gc(20)=b*x(14) * Col 4 gc(21)=-w - d*x(9) + 2.d0*v*x(4) gc(22)=-x(15) gc(23)=x(15) - g + x(16) gc(24)=1.d0 - f*x(16) gc(25)=-1.d0 gc(26)=1.d0 gc(27)=-b*x(15) gc(28)=b*x(15) * Col 5 gc(29)=-w - d*x(10) + 2.d0*v*x(5) gc(30)=-x(16) gc(31)=f*x(16) gc(32)=1.d0 gc(33)=-b*x(16) gc(34)=b*x(16) * Col 6 gc(35)=1.d0 - d*x(1) gc(36)=-x(11) + x(12) * Col 7 gc(37)=1.d0 - d*x(2) gc(38)=x(11) gc(39)=-1.d0 - f*x(12) * Col 8 gc(40)=1.d0 - d*x(3) gc(41)=1.d0 + f*x(13) gc(42)=-1.d0 - f*x(13) gc(43)=x(15) gc(44)=-1.d0 * Col 9 gc(45)=1.d0 - d*x(4) gc(46)=-1.d0 + f*x(14) gc(47)=-x(14) + g gc(48)=-1.d0 gc(49)=1.d0 * Col 10 gc(50)=1.d0 - d*x(5) gc(51)=-g gc(52)=-x(15) + g gc(53)=1.d0 * Col 11 gc(54)=x(7) - x(6) gc(55)=-f gc(56)=1.d0 * Col 12 gc(57)=-x(1) + x(6) gc(58)=-f*x(7) + f*x(1) gc(59)=f gc(60)=-1.d0 gc(61)=a-b*x(1) gc(62)=-a+b*x(1) * Col 13 gc(63)=-f*x(2) + f*x(8) gc(64)=-f*x(8) + f*x(2) gc(65)=a-b*x(2) gc(66)=-a+b*x(2) * Col 14 gc(67)=-f*x(3) + f*x(9) gc(68)=x(3) - x(9) gc(69)=a-b*x(3) gc(70)=-a+b*x(3) * Col 15 gc(71)=-x(4) + x(8) gc(72)=x(4) - x(10) gc(73)=a-b*x(4) gc(74)=-a+b*x(4) * Col 16 gc(75)=-x(5) + x(4) gc(76)=-f*x(4) + f*x(5) gc(77)=a-b*x(5) gc(78)=-a+b*x(5) * * return end *---------------------------------------------------MSP5.for