-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Package: gnumeric Version: 1.10.15-1 Severity: normal
*** Please type your report below this line *** I am attempting to use gnumeric's solver tool on a nonlinear problem, as shown in the attached spreadsheet. Specifically, I marked out nine points giving the boundary of a closed square of area 1 (one point at each corner, one point in the middle of each side, and the start and end points set to be the same). I created computation cells to find the perimeter and area marked out by these boundary points, and I want to use the solver to move the points around so as to minimize the perimeter of the enclosed shape while holding the area constant. The expected result of this minimization is that the points should arrange themselves into a regular octagon with a perimeter approximately equal to the perimeter of a circle of area 1, which is 2*sqrt(pi) ~= 3.54. (This is indeed the result I get when I run a similar computation in Excel or LibreOffice.) Instead, in gnumeric the points simply inch as close together as possible over the entire iterative process, resulting in an irregular polygon with almost zero area. This indicates to me that my constraint has been ignored. In the solver, my settings for this spreadsheet are: Set Target Cell: D12 Equal to: Min By Changing Cells: B3:C10 Model: Non-Linear Model Assume Non-Negative: Off Assume Integer (Discrete): Off Algorithm: Nlsolve Subject to the Constraints: $E$12 = 1 Max Iterations: 1000 Max Time (sec.): 60 Automatic Scaling: On or Off doesn't seem to matter I should note in addition that choosing the "Program" report doesn't seem to give me any different output than not choosing it, so I have no idea what the point of this option is. Anyway, I've tried everything I can think of to debug my spreadsheet and the Solver configuration and I can't see what I could possibly be doing wrong to cause the constraint to be so completely ignored. I don't think it's just my error, as if I try to run the solver with an incorrect value for the total area constraint (e.g. $E$12 = 2), it complains that the initial value doesn't satisfy the constraints, so it seems to at least be looking in the right place. I even tried using $E$12 >= 1 as my constraint (which should give the same result) to see if it was having some difficulty with the exact constraint, but this did not make any difference. - Anne - -- System Information: Debian Release: wheezy/sid APT prefers unstable APT policy: (500, 'unstable'), (500, 'stable') Architecture: amd64 (x86_64) Kernel: Linux 2.6.39-1-amd64 (SMP w/4 CPU cores) Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages gnumeric depends on: ii debconf [de 1.5.40 Debian configuration management sy ii gconf2 2.32.4-1 GNOME configuration database syste ii gnumeric-co 1.10.15-1 spreadsheet application for GNOME ii gsfonts 1:8.11+urwcyr1.0.7~pre44-4.2 Fonts for the Ghostscript interpre ii libatk1.0-0 2.0.1-1 ATK accessibility toolkit ii libc6 2.13-7 Embedded GNU C Library: Shared lib ii libcairo2 1.10.2-6 The Cairo 2D vector graphics libra ii libgdk-pixb 2.23.3-3 GDK Pixbuf library ii libglib2.0- 2.28.6-1 The GLib library of C routines ii libgoffice- 0.8.15-1 Document centric objects library - ii libgsf-1-11 1.14.21-1 Structured File Library - runtime ii libgtk2.0-0 2.24.4-3 The GTK+ graphical user interface ii libpango1.0 1.28.3-6 Layout and rendering of internatio ii libxml2 2.7.8.dfsg-3 GNOME XML library ii procps 1:3.2.8-10 /proc file system utilities ii zlib1g 1:1.2.3.4.dfsg-3 compression library - runtime Versions of packages gnumeric recommends: ii evince 2.30.3-3 Document (PostScript, PDF) viewer ii lp-solve 5.5.0.13-7 Solve (mixed integer) linear progr Versions of packages gnumeric suggests: pn epiphany-browser <none> (no description available) ii gnumeric-doc 1.10.15-1 spreadsheet application for GNOME ii gnumeric-plugins-extra 1.10.15-1 spreadsheet application for GNOME ii ttf-liberation 1.06.0.20100721-1 Fonts with the same metrics as Tim ii ttf-mscorefonts-instal 3.3 Installer for Microsoft TrueType c - -- debconf information: gnumeric/existing-process: false gnumeric/existing-process-title: -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk4Da2AACgkQwi82URPCSX586wCfXAjxCs1smKYZ1Hnh1dJNB4k+ ioMAn0EDEoKzwuY29dVBhRyME2yFP89a =b/jr -----END PGP SIGNATURE-----
square perimeter minimization.gnumeric
Description: application/gnumeric