File: hs71.mod

package info (click to toggle)
coinor-ipopt 3.14.19-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 8,796 kB
  • sloc: cpp: 97,169; sh: 4,802; ansic: 2,537; java: 1,289; makefile: 821; fortran: 224; xml: 210
file content (37 lines) | stat: -rw-r--r-- 861 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
# Copyright (C) 2009, International Business Machines
#
# This file is part of the Ipopt open source package, published under
# the Eclipse Public License
#
# Author:  Andreas Waechter         IBM       2009-04-03

# This is a model of Example 71 from
#
# Hock, W, and Schittkowski, K,
# Test Examples for Nonlinear Programming Codes,
# Lecture Notes in Economics and Mathematical Systems.
# Springer Verlag, 1981.

##############################################################################

# Definition of the variables with bounds
var x {i in 1..4}, >= 1, <= 5;

# objective function
minimize obj:
  x[1]*x[4]*(x[1] + x[2] + x[3]) + x[3];

# and the constraints
subject to c1:
  x[1]*x[2]*x[3]*x[4] >= 25;

subject to c2:
  x[1]^2+x[2]^2+x[3]^2+x[4]^2 = 40;

# Now we set the starting point:

let x[1] := 1;
let x[2] := 5;
let x[3] := 5;
let x[4] := 1;