Тестовые функции для оптимизации
В прикладной математике, тестовые функции, известные как искусственные ландшафты, являются полезными для оценки характеристик алгоритмов оптимизации, таких как:
- Скорость сходимости.
- Точность.
- Робастность.
- Общая производительность.
В статье представлены некоторые тестовые функции с целью дать представление о различных ситуациях, с которыми приходится сталкиваться при преодолении подобных проблем.
В статье представлены общая формула уравнения, участок целевой функции, границы переменных и координаты глобального минимума.
Тестовые функции для одной цели оптимизации
Название | Рисунок | Формула | Глобальный минимум | Метод поиска |
---|---|---|---|---|
Функция Растригина | [math]\displaystyle{ f(\mathbf{x}) = A n + \sum_{i=1}^n \left[x_i^2 - A\cos(2 \pi x_i)\right] }[/math]
[math]\displaystyle{ \text{where: } A=10 }[/math] |
[math]\displaystyle{ f(0, \dots, 0) = 0 }[/math] | [math]\displaystyle{ -5.12\le x_{i} \le 5.12 }[/math] | |
Функция Экли | [math]\displaystyle{ f(x,y) = -20\exp\left[-0.2\sqrt{0.5\left(x^{2}+y^{2}\right)}\right] }[/math]
[math]\displaystyle{ -\exp\left[0.5\left(\cos (2\pi x) + \cos (2\pi y) \right)\right] + e + 20 }[/math] |
[math]\displaystyle{ f(0,0) = 0 }[/math] | [math]\displaystyle{ -5\le x,y \le 5 }[/math] | |
Функция сферы | [math]\displaystyle{ f(\boldsymbol{x}) = \sum_{i=1}^{n} x_{i}^{2} }[/math] | [math]\displaystyle{ f(x_{1}, \dots, x_{n}) = f(0, \dots, 0) = 0 }[/math] | [math]\displaystyle{ -\infty \le x_{i} \le \infty }[/math], [math]\displaystyle{ 1 \le i \le n }[/math] | |
Функция Розенброка | [math]\displaystyle{ f(\boldsymbol{x}) = \sum_{i=1}^{n-1} \left[ 100 \left(x_{i+1} - x_{i}^{2}\right)^{2} + \left(x_{i} - 1\right)^{2}\right] }[/math] | [math]\displaystyle{ \text{Min} = \begin{cases} n=2 & \rightarrow \quad f(1,1) = 0, \\ n=3 & \rightarrow \quad f(1,1,1) = 0, \\ n\gt 3 & \rightarrow \quad f(\underbrace{1,\dots,1}_{n \text{ times}}) = 0 \\ \end{cases} }[/math] | [math]\displaystyle{ -\infty \le x_{i} \le \infty }[/math], [math]\displaystyle{ 1 \le i \le n }[/math] | |
Функция Била | [math]\displaystyle{ f(x,y) = \left( 1.5 - x + xy \right)^{2} + \left( 2.25 - x + xy^{2}\right)^{2} }[/math]
[math]\displaystyle{ + \left(2.625 - x+ xy^{3}\right)^{2} }[/math] |
[math]\displaystyle{ f(3, 0.5) = 0 }[/math] | [math]\displaystyle{ -4.5 \le x,y \le 4.5 }[/math] | |
Функция Гольдшейна-Прайса | [math]\displaystyle{ f(x,y) = \left[1+\left(x+y+1\right)^{2}\left(19-14x+3x^{2}-14y+6xy+3y^{2}\right)\right] }[/math]
[math]\displaystyle{ \left[30+\left(2x-3y\right)^{2}\left(18-32x+12x^{2}+48y-36xy+27y^{2}\right)\right] }[/math] |
[math]\displaystyle{ f(0, -1) = 3 }[/math] | [math]\displaystyle{ -2 \le x,y \le 2 }[/math] | |
Функция Бута | [math]\displaystyle{ f(x,y) = \left( x + 2y -7\right)^{2} + \left(2x +y - 5\right)^{2} }[/math] | [math]\displaystyle{ f(1,3) = 0 }[/math] | [math]\displaystyle{ -10 \le x,y \le 10 }[/math] | |
Функция Букина N 6 | [math]\displaystyle{ f(x,y) = 100\sqrt{\left|y - 0.01x^{2}\right|} + 0.01 \left|x+10 \right|.\quad }[/math] | [math]\displaystyle{ f(-10,1) = 0 }[/math] | [math]\displaystyle{ -15\le x \le -5 }[/math], [math]\displaystyle{ -3\le y \le 3 }[/math] | |
Функция Матьяса | [math]\displaystyle{ f(x,y) = 0.26 \left( x^{2} + y^{2}\right) - 0.48 xy }[/math] | [math]\displaystyle{ f(0,0) = 0 }[/math] | [math]\displaystyle{ -10\le x,y \le 10 }[/math] | |
Функция Леви N 13 | [math]\displaystyle{ f(x,y) = \sin^{2} 3\pi x + \left(x-1\right)^{2}\left(1+\sin^{2} 3\pi y\right) }[/math]
[math]\displaystyle{ +\left(y-1\right)^{2}\left(1+\sin^{2} 2\pi y\right) }[/math] |
[math]\displaystyle{ f(1,1) = 0 }[/math] | [math]\displaystyle{ -10\le x,y \le 10 }[/math] | |
Функция Химмельблау | [math]\displaystyle{ f(x, y) = (x^2+y-11)^2 + (x+y^2-7)^2.\quad }[/math] | [math]\displaystyle{ \text{Min} = \begin{cases} f\left(3.0, 2.0\right) & = 0.0 \\ f\left(-2.805118, 3.131312\right) & = 0.0 \\ f\left(-3.779310, -3.283186\right) & = 0.0 \\ f\left(3.584428, -1.848126\right) & = 0.0 \\ \end{cases} }[/math] | [math]\displaystyle{ -5\le x,y \le 5 }[/math] | |
Функция трехгорбого верблюда | [math]\displaystyle{ f(x,y) = 2x^{2} - 1.05x^{4} + \frac{x^{6}}{6} + xy + y^{2} }[/math] | [math]\displaystyle{ f(0,0) = 0 }[/math] | [math]\displaystyle{ -5\le x,y \le 5 }[/math] | |
Функция Изома | [math]\displaystyle{ f(x,y) = -\cos \left(x\right)\cos \left(y\right) \exp\left(-\left(\left(x-\pi\right)^{2} + \left(y-\pi\right)^{2}\right)\right) }[/math] | [math]\displaystyle{ f(\pi , \pi) = -1 }[/math] | [math]\displaystyle{ -100\le x,y \le 100 }[/math] | |
Функция "крест на подносе"
(Cross-in-tray function) |
[math]\displaystyle{ f(x,y) = -0.0001 \left[ \left| \sin x \sin y \exp \left(\left|100 - \frac{\sqrt{x^{2} + y^{2}}}{\pi} \right|\right)\right| + 1 \right]^{0.1} }[/math] | [math]\displaystyle{ \text{Min} = \begin{cases} f\left(1.34941, -1.34941\right) & = -2.06261 \\ f\left(1.34941, 1.34941\right) & = -2.06261 \\ f\left(-1.34941, 1.34941\right) & = -2.06261 \\ f\left(-1.34941,-1.34941\right) & = -2.06261 \\ \end{cases} }[/math] | [math]\displaystyle{ -10\le x,y \le 10 }[/math] | |
Функция "подставка для яиц"
(Eggholder function) |
[math]\displaystyle{ f(x,y) = - \left(y+47\right) \sin \sqrt{\left|\frac{x}{2}+\left(y+47\right)\right|} - x \sin \sqrt{\left|x - \left(y + 47 \right)\right|} }[/math] | [math]\displaystyle{ f(512, 404.2319) = -959.6407 }[/math] | [math]\displaystyle{ -512\le x,y \le 512 }[/math] | |
Табличная функция Хольдера | [math]\displaystyle{ f(x,y) = - \left|\sin x \cos y \exp \left(\left|1 - \frac{\sqrt{x^{2} + y^{2}}}{\pi} \right|\right)\right| }[/math] | [math]\displaystyle{ \text{Min} = \begin{cases} f\left(8.05502, 9.66459\right) & = -19.2085 \\ f\left(-8.05502, 9.66459\right) & = -19.2085 \\ f\left(8.05502,-9.66459\right) & = -19.2085 \\ f\left(-8.05502,-9.66459\right) & = -19.2085 \end{cases} }[/math] | [math]\displaystyle{ -10\le x,y \le 10 }[/math] | |
Функция МакКормика | [math]\displaystyle{ f(x,y) = \sin \left(x+y\right) + \left(x-y\right)^{2} - 1.5x + 2.5y + 1 }[/math] | [math]\displaystyle{ f(-0.54719,-1.54719) = -1.9133 }[/math] | [math]\displaystyle{ -1.5\le x \le 4 }[/math], [math]\displaystyle{ -3\le y \le 4 }[/math] | |
Функция Шаффера N2 | [math]\displaystyle{ f(x,y) = 0.5 + \frac{\sin^{2}\left(x^{2} - y^{2}\right) - 0.5}{\left[1 + 0.001\left(x^{2} + y^{2}\right) \right]^{2}} }[/math] | [math]\displaystyle{ f(0, 0) = 0 }[/math] | [math]\displaystyle{ -100\le x,y \le 100 }[/math] | |
Функция Шаффера N4 | [math]\displaystyle{ f(x,y) = 0.5 + \frac{\cos^{2}\left[\sin \left( \left|x^{2} - y^{2}\right|\right)\right] - 0.5}{\left[1 + 0.001\left(x^{2} + y^{2}\right) \right]^{2}} }[/math] | [math]\displaystyle{ f(0,1.25313) = 0.292579 }[/math] | [math]\displaystyle{ -100\le x,y \le 100 }[/math] | |
Функция Стыбинского-Танга | [math]\displaystyle{ f(\boldsymbol{x}) = \frac{\sum_{i=1}^{n} x_{i}^{4} - 16x_{i}^{2} + 5x_{i}}{2} }[/math] | [math]\displaystyle{ -39.16617n \lt f(\underbrace{-2.903534, \ldots, -2.903534}_{n \text{ times}} ) \lt -39.16616n }[/math] | [math]\displaystyle{ -5\le x_{i} \le 5 }[/math], [math]\displaystyle{ 1\le i \le n }[/math].. |
Тестовые функции для условной оптимизации
Название | Рисунок | Формула | Глобальный минимум | Метод поиска |
---|---|---|---|---|
функция розенброка, ограничена кубической и прямой[1] | [math]\displaystyle{ f(x,y) = (1-x)^2 + 100(y-x^2)^2 }[/math],
subjected to: [math]\displaystyle{ (x-1)^3 - y + 1 \lt 0 \text{ and } x + y - 2 \lt 0 }[/math] |
[math]\displaystyle{ f(1.0,1.0) = 0 }[/math] | [math]\displaystyle{ -1.5\le x \le 1.5 }[/math], [math]\displaystyle{ -0.5\le y \le 2.5 }[/math] | |
Функция Розенброка, ограниченная диском[2] | [math]\displaystyle{ f(x,y) = (1-x)^2 + 100(y-x^2)^2 }[/math],
subjected to: [math]\displaystyle{ x^2 + y^2 \lt 2 }[/math] |
[math]\displaystyle{ f(1.0,1.0) = 0 }[/math] | [math]\displaystyle{ -1.5\le x \le 1.5 }[/math], [math]\displaystyle{ -1.5\le y \le 1.5 }[/math] | |
Ограниченная функция Мишры-Бёрда[3][4] | [math]\displaystyle{ f(x,y) = \sin(y) e^{\left [(1-\cos x)^2\right]} + \cos(x) e^{\left [(1-\sin y)^2 \right]} + (x-y)^2 }[/math],
subjected to: [math]\displaystyle{ (x+5)^2 + (y+5)^2 \lt 25 }[/math] |
[math]\displaystyle{ f(-3.1302468,-1.5821422) = -106.7645367 }[/math] | [math]\displaystyle{ -10\le x \le 0 }[/math], [math]\displaystyle{ -6.5\le y \le 0 }[/math] | |
Модифицированная функция Таусенда[5] | [math]\displaystyle{ f(x,y) = -[\cos((x-0.1)y)]^2 - x \sin(3x+y) }[/math],
subjected to:[math]\displaystyle{ x^2+y^2 \lt \left[2\cos t - \frac 1 2 \cos 2t - \frac 1 4 \cos 3t - \frac 1 8 \cos 4t\right]^2 + [2\sin t]^2 }[/math] where: t = Atan2(x,y) |
[math]\displaystyle{ f(2.0052938,1.1944509) = -2.0239884 }[/math] | [math]\displaystyle{ -2.25\le x \le 2.5 }[/math], [math]\displaystyle{ -2.5\le y \le 1.75 }[/math] | |
Функция Симонескуn[6] | [math]\displaystyle{ f(x,y) = 0.1xy }[/math],
subjected to: [math]\displaystyle{ x^2+y^2\le\left[r_{T}+r_{S}\cos\left(n \arctan \frac{x}{y} \right)\right]^2 }[/math] [math]\displaystyle{ \text{where: } r_{T}=1, r_{S}=0.2 \text{ and } n = 8 }[/math] |
[math]\displaystyle{ f(\pm 0.85586214,\mp 0.85586214) = -0.072625 }[/math] | [math]\displaystyle{ -1.25\le x,y \le 1.25 }[/math] |
Тестовые функции для многокритериальной оптимизации
См. также
Литература
- Пантелеев А. В., Метлицкая Д. В., Е.А. Алешина Методы глобальной оптимизации. Метаэвристические стратегии и алгоритмы // М.: Вузовская книга. 2013. 244 с. ISBN 978-5-9502-0743-3
- Сергиенко А. Б. Тестовые функции для глобальной оптимизации.
Ссылки
Примечания
- ↑ Simionescu, P.A. New Concepts in Graphic Visualization of Objective Functions // (ASME 2002 International Design Engineering Technical Conferences and Computers and Information in Engineering Conference). — Montreal, Canada. — P. 891–897.
- ↑ Solve a Constrained Nonlinear Problem - MATLAB & Simulink . www.mathworks.com. Дата обращения: 29 августа 2017. Архивировано 29 августа 2017 года.
- ↑ Bird Problem (Constrained) | Phoenix Integration (недоступная ссылка). wayback.archive.org. Дата обращения: 29 августа 2017. Архивировано 29 декабря 2016 года.
- ↑ Mishra, Sudhanshu. Some new test functions for global optimization and performance of repulsive particle swarm method (англ.) // MPRA Paper : journal. — 2006. Архивировано 4 ноября 2018 года.
- ↑ Townsend, Alex Constrained optimization in Chebfun . chebfun.org (январь 2014). Дата обращения: 29 августа 2017. Архивировано 29 августа 2017 года.
- ↑ Simionescu, P.A. Computer Aided Graphing and Simulation Tools for AutoCAD Users (англ.). — 1st. — Boca Raton, FL: CRC Press, 2014. — ISBN 978-1-4822-5290-3.