Problems in PyGMO are objects, first constructed and then used in conjunction to an algorithm. The user can implement its own problem directly in Python, in which case he needs to inherit from PyGMO.problem.base or PyGMO.problem.base_stochastic class. You may see Tutorial 1: Coding an optimization problem in Python or Tutorial 2: Coding a stochastic optimization problem in Python
| Common Name | Name in PyGMO | Comments |
|---|---|---|
| Rotated | PyGMO.problem.rotated | from V1.1.5 |
| Shifted | PyGMO.problem.shifted | from V1.1.5 |
| Normalized | PyGMO.problem.normalized | from V1.1.5 |
| Common Name | Name in PyGMO | Comments |
|---|---|---|
| Ackley | PyGMO.problem.ackley | |
| Bukin F6 | PyGMO.problem.bukin | A difficult bi-dimensional problem |
| Branin | PyGMO.problem.branin | Bi-dimensional problem |
| CEC2013 | PyGMO.problem.cec2013 | 28 problems part of CEC2013 Competition |
| De Jong | PyGMO.problem.dejong | |
| De Jong | PyGMO.problem.py_example | Implemented directly in Python |
| Griewank | PyGMO.problem.griewank | |
| Himmelblau | PyGMO.problem.himmelblau | Bi-dimensional problem |
| Lennard-Jones | PyGMO.problem.lennard_jones | |
| Michalewicz | PyGMO.problem.michalewicz | |
| Rosenbrock | PyGMO.problem.rosenbrock | |
| Rastrigin | PyGMO.problem.rastrigin | |
| Schwefel | PyGMO.problem.schwefel | |
| MGA-1DSM (tof encoding) | PyGMO.problem.mga_1dsm_tof | Requires the GTOP database option active |
| MGA-1DSM (alpha encoding) | PyGMO.problem.mga_1dsm_alpha | Requires the GTOP database option active |
| Cassini 1 | PyGMO.problem.cassini_1 | Requires the GTOP database option active |
| Cassini 2 | PyGMO.problem.cassini_2 | Requires the GTOP database option active |
| Rosetta | PyGMO.problem.rosetta | Requires the GTOP database option active |
| Tandem | PyGMO.problem.tandem | Requires the GTOP database option active |
| Laplace | PyGMO.problem.tandem | Requires the GTOP database option active |
| Messenger (Full Problem) | PyGMO.problem.messenger_full | Requires the GTOP database option active |
| GTOC1 | PyGMO.problem.gtoc_1 | Requires the GTOP database option active |
| Sagas | PyGMO.problem.sagas | Requires the GTOP database option active |
| Common Name | Name in PyGMO | Comments |
|---|---|---|
| Kursawe’s study | PyGMO.problem.kur | |
| Fonseca and Fleming’s study | PyGMO.problem.fon | |
| Poloni’s study | PyGMO.problem.pol | |
| Shaffer’s study | PyGMO.problem.sch | |
| ZDT1 | PyGMO.problem.zdt1 | |
| ZDT2 | PyGMO.problem.zdt2 | |
| ZDT3 | PyGMO.problem.zdt3 | |
| ZDT4 | PyGMO.problem.zdt4 | |
| ZDT5 | PyGMO.problem.zdt5 | |
| ZDT6 | PyGMO.problem.zdt6 | |
| DTLZ1 | PyGMO.problem.dtlz1 | |
| DTLZ2 | PyGMO.problem.dtlz2 | |
| DTLZ3 | PyGMO.problem.dtlz3 | |
| DTLZ4 | PyGMO.problem.dtlz4 | |
| DTLZ5 | PyGMO.problem.dtlz5 | |
| DTLZ6 | PyGMO.problem.dtlz6 | |
| DTLZ7 | PyGMO.problem.dtlz7 | |
| MGA-1DSM (tof encoding) | PyGMO.problem.mga_1dsm_tof | Requires the GTOP database option active |
| MGA-1DSM (alpha encoding) | PyGMO.problem.mga_1dsm_alpha | Requires the GTOP database option active |
| Cassini 1 | PyGMO.problem.cassini_1 | Requires the GTOP database option active |
| Common Name | Name in PyGMO | Comments |
|---|---|---|
| Luksan Vlcek 1 | PyGMO.problem.luksan_vlcek_1 | |
| Luksan Vlcek 2 | PyGMO.problem.luksan_vlcek_2 | |
| Luksan Vlcek 3 | PyGMO.problem.luksan_vlcek_3 | |
| Planet to Planet LT Transfer | PyGMO.problem.py_pl2pl | Requires PyKEP. Implemented in Python |
| SNOPT Toy-Problem | PyGMO.problem.snopt_toyprob | |
| GTOC2 (Full Problem) | PyGMO.problem.gtoc_2 | Requires the GTOP database option active |
| Common Name | Name in PyGMO | Comments |
|---|---|---|
| String Match | PyGMO.problem.string_match |
| Common Name | Name in PyGMO | Comments |
|---|---|---|
| Golomb Ruler | PyGMO.problem.golomb_ruler | |
| Traveling Salesman | PyGMO.problem.tsp | |
| Knapsack | PyGMO.problem.knapsack |
| Common Name | Name in PyGMO | Comments |
|---|---|---|
| Inventory Problem | PyGMO.problem.inventory | |
| MIT SPHERES | PyGMO.problem.mit_spheres | |
| Noisy De Jong | PyGMO.problem.py_example_stochastic |
This class is the base class for all non-stochastic optimization problems. When defining an optimization problem in PyGMO, the user needs to write a class that inherits from this base class and needs to call its constructor. He will then need to re-implement a number of virtual functions that define the problem objectives and constraints, as well as defining the box-bounds on the decision vector.
Base problem constructor. It must be called from within the derived class constructor __init__()
USAGE: super(derived_class_name,self).__init__(dim, i_dim, n_obj, c_dim, c_ineq_dim, c_tol)
This is a virtual function tham must be re-implemented in the derived class and must return a tuple packing as many numbers as the problem objectives (n_obj)
This is a virtual function tham can must be re-implemented in the derived class (if c_dim>0) and must return a tuple packing as many numbers as the declared dimension of the problem constraints (c_dim). Inequality constarints need to be packed at last.
Resets the internal caching system of PyGMO. This needs to be called whenever the state of the problem is changed i.e. the seed in a stochastic optimization problem or the trajectory model in a low-thrust optimization etc..
Set all bounds to the input values.
Determine feasibility of decision vector.
Determine feasibility of constraint vector.
Shifted problem
Shifts a problem.
USAGE: problem.(problem=PyGMO.ackley(1), shift = a random vector)
The shift vector defining the new problem
Returns the de-shifted decision vector
Rotated problem
Rotates a problem. (also reflections are possible) The new objective function will be f(Rx_{normal}), where R is an orthogonal matrix and x_{normal} is the decision vector normailized to [-1,1]
NOTE: To ensure all of the original space is included in the new box-constrained search space, bounds of the normalized variables are expanded to [-sqrt(2),sqrt(2)]. It is still guaranteed theat the original objective function will not be called outside of the original bounds by projecting points outside the original space onto the boundary
USAGE: problem.(problem=PyGMO.ackley(1), rotation = a random orthogonal matrix)
The rotation matrix defining the new problem
Returns the de-rotated decision vector
Normalized problem
Normalizes a problem (e.g. maps all variables to [-1,1])
NOTE: this meta-problem constructs a new problem having normalized bounds/variables
USAGE: problem.(problem=PyGMO.ackley(1))
Returns the de-normalized decision vector
Ackley function.
Constructs a Ackley problem (Box-Constrained Continuous Single-Objective)
USAGE: problem.ackley(dim=10)
Bukin’s f6 function.
Constructs a Bukin’s f6 problem (Box-Constrained Continuous Single-Objective)
USAGE: problem.bukin()
CEC2013 Competition Problems.
Constructs one of the 28 CEC2013 Competition Problems (Box-Constrained Continuous Single-Objective)
USAGE: problem.cec2013(dim = 10, prob_id=1, path=”input_data/”)
Multi-dimensional Rosenbrock function.
Constructs a Rosenbrock problem (Box-Constrained Continuous Single-Objective)
USAGE: problem.rosenbrock(dim=10)
String matching problem.
Constructs a string-match problem (Box-Constrained Integer Single-Objective)
NOTE: This is the problem of matching a string. Transcribed as an optimization problem
USAGE: problem.string_match(string = “mah”)
Returns a string decoding the chromosome
Generalised Rastrigin function.
Constructs a Rastrigin problem (Box-Constrained Continuous Single-Objective)
USAGE: problem.rastrigin(dim=10)
Two-dimensional Schwefel function.
Constructs a Schwefel problem (Box-Constrained Continuous Single-Objective)
USAGE: problem.schwefel(dim=10)
De Jong’s function.
Constructs a De Jong problem (Box-Constrained Continuous Single-Objective)
USAGE: problem.dejong(dim=10)
De Jong (sphere) function implemented purely in Python.
USAGE: py_example(dim = 10)
Griewank function.
Constructs a De Jong problem (Box-Constrained Continuous Single-Objective)
USAGE: problem.dejong(dim=10)
Lennard Jones problem.
Constructs a Lennard-Jones problem (Box-Constrained Continuous Single-Objective)
USAGE: problem.lennard_jones(n_atoms=4)
Branin’s rcos function.
Constructs a Branin problem (Box-Constrained Continuous Single-Objective)
USAGE: problem.branin()
Himmelblau’s function.
Constructs a Himmelblau problem (Box-Constrained Continuous Single-Objective)
USAGE: problem.himmelblau()
Michalewicz’s function.
Constructs a Michalewicz problem (Box-Constrained Continuous Single-Objective)
USAGE: problem.michalewicz(dim=5)
NOTE: Minimum is -4.687 for dim=5 and -9.66 for dim = 10
Kursawe’s study problem.
Constructs a Kursawe’s study problem (Box-Constrained Continuous Multi-Objective)
NOTE: K Deb, A Pratap, S Agarwal: A fast and elitist multiobjective genetic algorithm: NSGA-II, IEEE Transactions on, 2002
USAGE: problem.kur()
Fonseca and Fleming’s study problem.
Constructs a Fonseca and Fleming’s study problem (Box-Constrained Continuous Multi-Objective)
NOTE: K Deb, A Pratap, S Agarwal: A fast and elitist multiobjective genetic algorithm: NSGA-II, IEEE Transactions on, 2002
USAGE: problem.fon()
Poloni’s study problem.
Constructs a Poloni’s study study problem (Box-Constrained Continuous Multi-Objective)
NOTE: K Deb, A Pratap, S Agarwal: A fast and elitist multiobjective genetic algorithm: NSGA-II, IEEE Transactions on, 2002
USAGE: problem.pol()
Shaffer’s study problem.
Constructs a Schaffer’s study problem (Box-Constrained Continuous Multi-Objective)
NOTE: K Deb, A Pratap, S Agarwal: A fast and elitist multiobjective genetic algorithm: NSGA-II, IEEE Transactions on, 2002
USAGE: problem.sch()
ZDT1
Constructs a ZDT1 problem (Box-Constrained Continuous Multi-Objective)
NOTE: K Deb, A Pratap, S Agarwal: A fast and elitist multiobjective genetic algorithm: NSGA-II, IEEE Transactions on, 2002
USAGE: problem.zdt1(dim = 30)
The p distance is a convergence metric measuring the distance of a population from the pareto front. It is 0.0 if all individuals of the population lie on the Pareto-front. The metric is based on the distance function g defined for all dtlz and zdt problems and it is defined in the paper below.
NOTE: M Maertens, D Izzo, The asynchronous island model and NSGA-II: study of a new migration operator and its performance, to be published in GECCO2013
USAGE: x = prob.p_distance(isl.population)
ZDT2
Constructs a ZDT2 problem (Box-Constrained Continuous Multi-Objective)
NOTE: K Deb, A Pratap, S Agarwal: A fast and elitist multiobjective genetic algorithm: NSGA-II, IEEE Transactions on, 2002
USAGE: problem.zdt2(dim = 30)
The p distance is a convergence metric measuring the distance of a population from the pareto front. It is 0.0 if all individuals of the population lie on the Pareto-front. The metric is based on the distance function g defined for all dtlz and zdt problems and it is defined in the paper below.
NOTE: M Maertens, D Izzo, The asynchronous island model and NSGA-II: study of a new migration operator and its performance, to be published in GECCO2013
USAGE: x = prob.p_distance(isl.population)
ZDT3
Constructs a ZDT3 problem (Box-Constrained Continuous Multi-Objective)
NOTE: K Deb, A Pratap, S Agarwal: A fast and elitist multiobjective genetic algorithm: NSGA-II, IEEE Transactions on, 2002
USAGE: problem.zdt3(dim = 30)
The p distance is a convergence metric measuring the distance of a population from the pareto front. It is 0.0 if all individuals of the population lie on the Pareto-front. The metric is based on the distance function g defined for all dtlz and zdt problems and it is defined in the paper below.
NOTE: M Maertens, D Izzo, The asynchronous island model and NSGA-II: study of a new migration operator and its performance, to be published in GECCO2013
USAGE: x = prob.p_distance(isl.population)
ZDT4
Constructs a ZDT4 problem (Box-Constrained Continuous Multi-Objective)
NOTE: K Deb, A Pratap, S Agarwal: A fast and elitist multiobjective genetic algorithm: NSGA-II, IEEE Transactions on, 2002
USAGE: problem.zdt4(dim = 10)
The p distance is a convergence metric measuring the distance of a population from the pareto front. It is 0.0 if all individuals of the population lie on the Pareto-front. The metric is based on the distance function g defined for all dtlz and zdt problems and it is defined in the paper below.
NOTE: M Maertens, D Izzo, The asynchronous island model and NSGA-II: study of a new migration operator and its performance, to be published in GECCO2013
USAGE: x = prob.p_distance(isl.population)
ZDT5
Constructs a ZDT5 problem (Box-Constrained Continuous Multi-Objective)
NOTE: E. Zitzler, K. Deb, L. Thiele: Comparison of Multiobjective Evolutionary Algorithms: Empirical Results, Evolutionary Computation, 2000
USAGE: problem.zdt5(bnr = 11)
The p distance is a convergence metric measuring the distance of a population from the pareto front. It is 0.0 if all individuals of the population lie on the Pareto-front. The metric is based on the distance function g defined for all dtlz and zdt problems and it is defined in the paper below.
NOTE: M Maertens, D Izzo, The asynchronous island model and NSGA-II: study of a new migration operator and its performance, to be published in GECCO2013
USAGE: x = prob.p_distance(isl.population)
ZDT6
Constructs a ZDT6 problem (Box-Constrained Continuous Multi-Objective)
NOTE: K Deb, A Pratap, S Agarwal: A fast and elitist multiobjective genetic algorithm: NSGA-II, IEEE Transactions on, 2002
USAGE: problem.zdt6(dim = 10)
The p distance is a convergence metric measuring the distance of a population from the pareto front. It is 0.0 if all individuals of the population lie on the Pareto-front. The metric is based on the distance function g defined for all dtlz and zdt problems and it is defined in the paper below.
NOTE: M Maertens, D Izzo, The asynchronous island model and NSGA-II: study of a new migration operator and its performance, to be published in GECCO2013
USAGE: x = prob.p_distance(isl.population)
DTLZ1 benchmark problem.
Constructs a DTLZ1 problem (Box-Constrained, continuous, multimodal, scalable multi-objective)
NOTE: K Deb, L Thiele, M Laumanns, E Zitzler, Scalable test problems for evolutionary multiobjective optimization
The optimal pareto front lies on a linear hyperplane with f_1 + f_2 + ... + f_m = 0.5.
USAGE: problem.dt1z1(k = 5, fdim=3)
The p distance is a convergence metric measuring the distance of a population from the pareto front. It is 0.0 if all individuals of the population lie on the Pareto-front. The metric is based on the distance function g defined for all dtlz and zdt problems and it is defined in the paper below.
NOTE: M Maertens, D Izzo, The asynchronous island model and NSGA-II: study of a new migration operator and its performance, to be published in GECCO2013
USAGE: x = prob.p_distance(isl.population)
Generic plot-method for multi-objective optimization problems with more then 2 objectives
USAGE: prob.plot(pop, comp[0,2,3]) * pop: population of solutions to the problem * a: angle of view on which the 3d-plot is created * comp: indexes the fitness dimension for x,y and z axis in that order
DTLZ2 benchmark problem.
Constructs a DTLZ2 problem (Box-Constrained, continuous, unimodal, scalable multi-objective)
NOTE: K Deb, L Thiele, M Laumanns, E Zitzler, Scalable test problems for evolutionary multiobjective optimization
The search space is continous, unimodal and the problem is not deceptive. The Pareto-front is a quarter of a sphere
USAGE: problem.dt1z2(k = 10, fdim=3)
The p distance is a convergence metric measuring the distance of a population from the pareto front. It is 0.0 if all individuals of the population lie on the Pareto-front. The metric is based on the distance function g defined for all dtlz and zdt problems and it is defined in the paper below.
NOTE: M Maertens, D Izzo, The asynchronous island model and NSGA-II: study of a new migration operator and its performance, to be published in GECCO2013
USAGE: x = prob.p_distance(isl.population)
Specific plot-method for the DTLZ2, DTLZ3 and DTLZ4 - plotting also the optimal pareto-front
USAGE: prob.plot(pop, comp[0,2,3])
DTLZ3 benchmark problem.
Constructs a DTLZ3 problem (Box-Constrained, continuous, multimodal, scalable multi-objective)
Same Pareto Front as DTLZ2, but harder to converge towards it
NOTE: K Deb, L Thiele, M Laumanns, E Zitzler, Scalable test problems for evolutionary multiobjective optimization
USAGE: problem.dt1z3(k = 10, fdim=3)
The p distance is a convergence metric measuring the distance of a population from the pareto front. It is 0.0 if all individuals of the population lie on the Pareto-front. The metric is based on the distance function g defined for all dtlz and zdt problems and it is defined in the paper below.
NOTE: M Maertens, D Izzo, The asynchronous island model and NSGA-II: study of a new migration operator and its performance, to be published in GECCO2013
USAGE: x = prob.p_distance(isl.population)
Specific plot-method for the DTLZ2, DTLZ3 and DTLZ4 - plotting also the optimal pareto-front
USAGE: prob.plot(pop, comp[0,2,3])
DTLZ4 benchmark problem.
Constructs a DTLZ4 problem (Box-Constrained, continuous, unimodal, scalable multi-objective)
The search space contains a dense area of solutions next to the f_M/f_1 plane.
NOTE: K Deb, L Thiele, M Laumanns, E Zitzler, Scalable test problems for evolutionary multiobjective optimization
USAGE: problem.dt1z4(k = 10, fdim=3, alpha=100)
The p distance is a convergence metric measuring the distance of a population from the pareto front. It is 0.0 if all individuals of the population lie on the Pareto-front. The metric is based on the distance function g defined for all dtlz and zdt problems and it is defined in the paper below.
NOTE: M Maertens, D Izzo, The asynchronous island model and NSGA-II: study of a new migration operator and its performance, to be published in GECCO2013
USAGE: x = prob.p_distance(isl.population)
Specific plot-method for the DTLZ2, DTLZ3 and DTLZ4 - plotting also the optimal pareto-front
USAGE: prob.plot(pop, comp[0,2,3])
DTLZ5 benchmark problem.
Constructs a DTLZ5 problem (Box-Constrained, continuous, unimodal, scalable multi-objective)
This problem will test an MOEA’s ability to converge to a curve and will also allow an easier way to visually demonstrate (just by plotting f_M with any other objective function) the performance of an MOEA. Since there is a natural bias for solutions close to this Pareto-optimal curve, this problem may be easy for an algorithmn to solve. Because of its simplicity its recommended to use a higher number of objectives.
NOTE: K Deb, L Thiele, M Laumanns, E Zitzler, Scalable test problems for evolutionary multiobjective optimization
USAGE: problem.dt1z5(k = 10, fdim = 3)
The p distance is a convergence metric measuring the distance of a population from the pareto front. It is 0.0 if all individuals of the population lie on the Pareto-front. The metric is based on the distance function g defined for all dtlz and zdt problems and it is defined in the paper below.
NOTE: M Maertens, D Izzo, The asynchronous island model and NSGA-II: study of a new migration operator and its performance, to be published in GECCO2013
USAGE: x = prob.p_distance(isl.population)
Generic plot-method for multi-objective optimization problems with more then 2 objectives
USAGE: prob.plot(pop, comp[0,2,3]) * pop: population of solutions to the problem * a: angle of view on which the 3d-plot is created * comp: indexes the fitness dimension for x,y and z axis in that order
DTLZ6 benchmark problem.
Constructs a DTLZ6 problem (Box-Constrained, continuous, unimodal, scalable multi-objective)
A more difficult version of the DTLZ5 problem: the non-linear distance function g makes it harder to convergence against the pareto optimal curve.
NOTE: K Deb, L Thiele, M Laumanns, E Zitzler, Scalable test problems for evolutionary multiobjective optimization
USAGE: problem.dt1z6(k = 10, fdim = 3)
The p distance is a convergence metric measuring the distance of a population from the pareto front. It is 0.0 if all individuals of the population lie on the Pareto-front. The metric is based on the distance function g defined for all dtlz and zdt problems and it is defined in the paper below.
NOTE: M Maertens, D Izzo, The asynchronous island model and NSGA-II: study of a new migration operator and its performance, to be published in GECCO2013
USAGE: x = prob.p_distance(isl.population)
Generic plot-method for multi-objective optimization problems with more then 2 objectives
USAGE: prob.plot(pop, comp[0,2,3]) * pop: population of solutions to the problem * a: angle of view on which the 3d-plot is created * comp: indexes the fitness dimension for x,y and z axis in that order
DTLZ7 benchmark problem.
Constructs a DTLZ7 problem (Box-Constrained, continuous, scalable multi-objective)
This problem has disconnected Pareto-optimal regions in the search space.
NOTE: K Deb, L Thiele, M Laumanns, E Zitzler, Scalable test problems for evolutionary multiobjective optimization
USAGE: problem.dt1z7(k = 20, fdim = 3)
The p distance is a convergence metric measuring the distance of a population from the pareto front. It is 0.0 if all individuals of the population lie on the Pareto-front. The metric is based on the distance function g defined for all dtlz and zdt problems and it is defined in the paper below.
NOTE: M Maertens, D Izzo, The asynchronous island model and NSGA-II: study of a new migration operator and its performance, to be published in GECCO2013
USAGE: x = prob.p_distance(isl.population)
Generic plot-method for multi-objective optimization problems with more then 2 objectives
USAGE: prob.plot(pop, comp[0,2,3]) * pop: population of solutions to the problem * a: angle of view on which the 3d-plot is created * comp: indexes the fitness dimension for x,y and z axis in that order
Traveling salesman problem
Constructs a Travelling Salesman problem (Constrained Integer Single-Objective)
USAGE: problem.tsp(matrix = [0,1,2],[1,0,5],[2,5,0])
Optimal Golomb ruler search. Constructor from order of the Golomb ruler and maximum distance between consecutive marks.
Constructs a Golomb Ruler problem (Constrained Integer Single-Objective)
NOTE: see http://en.wikipedia.org/wiki/Golomb_ruler
USAGE: problem.golomb_ruler(order = 5, length=10)
Classical 01 knapsack problem. Constructor from vector of values, vector of weights and maximum weight.
Constructs a 0-1 Knapsack Problem (Constrained Integer Single-Objective)
USAGE: problem.knapsack(values = [1,2,3,4,5], weights = [10, 40, 30, 50, 20], max_weight = 100)
Luksan Vlcek problem 1.
Constructs the first Luksan Vlcek problem (Constrained Continuous Single-Objective)
NOTE: L. Luksan and J. Vlcek, “Sparse and Parially Separable Test Problems for Unconstrained and Equality Constrained Optimization”
USAGE: problem.luksan_vlcek_1(dim=3)
Luksan Vlcek problem 2.
Constructs the second Luksan Vlcek problem (Constrained Continuous Single-Objective)
NOTE: L. Luksan and J. Vlcek, “Sparse and Parially Separable Test Problems for Unconstrained and Equality Constrained Optimization”
USAGE: problem.luksan_vlcek_2(dim=16)
Luksan Vlcek problem 3.
Constructs the third Luksan Vlcek problem (Constrained Continuous Single-Objective)
NOTE: L. Luksan and J. Vlcek, “Sparse and Parially Separable Test Problems for Unconstrained and Equality Constrained Optimization”
USAGE: problem.luksan_vlcek_3(dim=8)
SNOPT toy problem.
Constructs SNOPT toy-problem (Box-Constrained Continuous Multi-Objective)
USAGE: problem.snopt_toyprob()
Inventory problem.
Constructs an Inventory Problem (Stochastic Objective Function)
NOTE: see www2.isye.gatech.edu/people/faculty/Alex_Shapiro/SPbook.pdf
USAGE: problem.inventory(weeks = 4, sample_size = 10, seed = 0):
to plan the inventory for.
sample_size: dimension of the sample used to approximate the expected value
pseudorandom sequences used to generate the sample
Noisy De Jong (sphere) function implemented purely in Python.
USAGE: py_example_stochastic(dim = 10, seed=0)
Spheres problem, a neurocontroller for the MIT test-bed (absolute perception-action)
Construct a Neurocontroller Evolution problem that seeks to drive three point masses to form a triangle This problem was used to design a contorller for the MIT SPHERES test bed on boear the ISS
USAGE: problem.mit_spheres(sample_size = 10, n_hidden = 10, ode_prec = 1E-3, seed = 0, symmetric = False, simulation_time = 50.0):
Returns a tuple with the N post evaluation results of chromosome x w.r.t. conditions generated by seed. The returned tuple has the structure [ic, fit] and is sorted by fit. Where ic are the initial conditions and fit the Evaluated fitness.
Returns the SPHERES coordinates as evaluated in one simulation with initial conditions ic and in N points
Requires VPython installed. It opens a graphical display and animate the motion of the three SPHERES as desribed by the world_state tuple (output from the simulate method)
Constructs an mga_1dsm problem (tof-encoding)
USAGE: problem.mga_1dsm(seq = [planet_ss(‘earth’),planet_ss(‘venus’),planet_ss(‘earth’)], t0 = [epoch(0),epoch(1000)], tof = [ [200, 700], [200, 700] ], vinf = [0.5, 2.5], multi_objective = False, add_vinf_dep = False, add_vinf_arr = True)
Plots the trajectory represented by the decision vector x
Resets the tof-bounds by the provided list of epochs. Needs a list consisting of lower/upper bound tuples.
Resets the launch windows to the lower and upper bounds given by tuple t0. Bounds need to be epochs.
Sets the upper bound for vinf to vinf_u
Returns a string with informations about tour encoded by x
Constructs an mga_1dsm problem (alpha-encoding)
USAGE: problem.mga_1dsm(seq = [planet_ss(‘earth’),planet_ss(‘venus’),planet_ss(‘earth’)], t0 = [epoch(0),epoch(1000)], tof = [ [200, 700], [200, 700] ], vinf = [0.5, 2.5], multi_objective = False, add_vinf_dep = False, add_vinf_arr = True)
Plots the trajectory represented by the decision vector x
Resets the tof-bounds by the provided tuple of epochs.
Resets the launch windows to the lower and upper bounds given by tuple t0. Bounds need to be epochs.
Sets the upper bound for vinf to vinf_u
Returns a string with informations about tour encoded by x
Cassini 1 interplanetary trajectory problem.
Constructs a Cassini 1 Problem (Box-Constrained Continuous Single-Objective)
USAGE: problem.cassini_1(objectives = 1)
Cassini 2 interplanetary trajectory problem.
Constructs a Cassini 2 Problem (Box-Constrained Continuous Single-Objective)
It models the same interplanetary trajectory as the cassini_1 problem, but in a more accurate fashion, allowing deep space manouvres
Best known global minimum is at 8.383 [km/s]
USAGE: problem.cassini_2()
Full Messenger problem.
Constructs a Mesenger Full Problem (Box-Constrained Continuous Single-Objective)
NOTE: This problem (MGA-1DSM) belongs to the GTOP database [http://www.esa.int/gsp/ACT/inf/op/globopt.htm]
Best known global minimum is at 2.113
USAGE: problem.messenger_full()
Rosetta problem.
Constructs a Rosetta Problem (Box-Constrained Continuous Single-Objective)
NOTE: This problem (MGA-1DSM) belongs to the GTOP database [http://www.esa.int/gsp/ACT/inf/op/globopt.htm]
Best known global minimum is at 1.343 [km/s]
USAGE: problem.rosetta()
Laplace problem.
Constructs a EJSM-Laplace Problem (Box-Constrained Continuous Single-Objective)
USAGE: problem.laplace(seq = [3,2,3,3,5])
1 - Mercury, 2 - Venus, 3 - Earth, 4 - Mars, 5 - Jupiter, 6 - Saturn. It must start from 3 (Earth) and end with 5 (Jupiter)
Tandem problem.
Constructs a TandEM Problem (Box-Constrained Continuous Single-Objective)
NOTE: This problem (MGA-1DSM) belongs to the GTOP database [http://www.esa.int/gsp/ACT/inf/op/globopt.htm]. The objective function is -log(m_final).
USAGE: problem.tandem(prob_id = 7, max_tof = -1)
GTOC 1 problem (chemical approximation).
Constructs a GTOC 1 Problem (Box-Constrained Continuous Single-Objective)
NOTE: This problem (MGA) belongs to the GTOP database [http://www.esa.int/gsp/ACT/inf/op/globopt.htm]
Best known global minima is at -1,581,950
USAGE: problem.gtoc_1()
GTOC 2 problem (LT model).
__init__( (object)arg1 [, (int)arg2 [, (int)arg3 [, (int)arg4 [, (int)arg5 [, (int)arg6 [, (_gtoc_2_objective)arg7]]]]]]) -> None
This problem represents a low-thrust transfer between a departure planet (default is the earth) and a target planet (default is mars). The spacecraft is described by its starting mass (mass) its engine specific impulse (Isp) and its engine maximum thrust (Tmax). The Sims-Flanagan model is used to describe a trajectory. A variable number of segments (nseg) can be used An initial velocity with respect to the Earth is allowed (Vinf_0) assumed to be given by the launcher A final velocity wrt the target planet is also allowed (Vinf_f) The method high_fidelity allows to use a continuous thrust model rather than impulses
Constructs a low-thrust transfer between a departure planet and a target planet (Constrained Continuous Single-Objective)
NOTE: An impulsive transcription is used to transform into an NLP the Optimal Control Problem
USAGE: problem.py_pl2pl(self,mass=1000,Tmax=0.05,Isp=2500,Vinf_0=3,Vinf_f=0,nseg=10,departure = PyKEP.planet_ss(‘earth’), target = PyKEP.planet_ss(‘mars’))
mass: spacecraft mass at departure [kg]
Tmax: maximum allowed thrust [N]
Isp: spacecarft engine specific impulse [Isp]
Vinf_0: allowed maximum starting velocity [km/s]
(if negative it is interpreted as a minimum arrival velocity)
nseg: number of segments used for the impulsive transcription
departure: departure planet (a PyKEP planet)
target: arrival planet (a PyKEP planet)
Sagas problem.
Constructs a SAGAS Problem (Box-Constrained Continuous Single-Objective)
NOTE: This problem (MGA-1DSM) belongs to the GTOP database [http://www.esa.int/gsp/ACT/inf/op/globopt.htm]
USAGE: problem.sagas()