28 #include "snopt_toyprob.h"
30 namespace pagmo {
namespace problem {
38 const double lb[] = {0,-10};
39 const double ub[] = {10,10};
59 c[0] = x[0] * x[0] + 4 * x[1] * x[1] - 4;
60 c[1] = (x[0] - 2) * (x[0] - 2) + x[1] * x[1] - 5;
75 return "SNOPT toy problem";
boost::shared_ptr< base > base_ptr
Alias for shared pointer to base problem.
std::vector< double > decision_vector
Decision vector type.
std::string get_name() const
Get problem's name.
base_ptr clone() const
Clone method.
void set_lb(const decision_vector &)
Set lower bounds from pagmo::decision_vector.
void set_sparsity(int &, std::vector< int > &, std::vector< int > &) const
Implementation of the sparsity structure.
void set_ub(const decision_vector &)
Set upper bounds from pagmo::decision_vector.
std::vector< double > fitness_vector
Fitness vector type.
void estimate_sparsity(const decision_vector &, int &lenG, std::vector< int > &iGfun, std::vector< int > &jGvar) const
Heuristics to estimate the sparsity pattern of the problem.
snopt_toyprob()
Default constructor.
std::vector< double > constraint_vector
Constraint vector type.
void objfun_impl(fitness_vector &, const decision_vector &) const
Implementation of the objective function.
void compute_constraints_impl(constraint_vector &, const decision_vector &) const
Implementation of the constraint function.