| 133 | } |
| 134 | |
| 135 | void AMPLModel::evaluate_constraints(const Vector<double>& x, Vector<double>& constraints) const { |
| 136 | fint error_flag = 0; |
| 137 | this->asl->p.Conval(this->asl, const_cast<double*>(x.data()), constraints.data(), &error_flag); |
| 138 | if (0 < error_flag) { |
| 139 | throw FunctionEvaluationError(); |
| 140 | } |
| 141 | ++this->number_model_evaluations.constraints; |
| 142 | } |
| 143 | |
| 144 | // dense gradient |
| 145 | void AMPLModel::evaluate_objective_gradient(const Vector<double>& x, Vector<double>& gradient) const { |
nothing calls this directly
no test coverage detected