Leo Liberti
email: liberti@lix.polytechnique.fr

Sonia Cafieri
email: sonia.cafieri@enac.fr

David Savourey
email: savourey@lix.polytechnique.fr

The Reformulation-Optimization Software Engine ⋆

Keywords:

Most optimization software performs numerical computation, in the sense that the main interest is to find numerical values to assign to the decision variables, e.g. a solution to an optimization problem. In mathematical programming, however, a considerable amount of symbolic transformation is essential to solving difficult optimization problems, e.g. relaxation or decomposition techniques. This step is usually carried out by hand, involves human ingenuity, and often constitutes the "theoretical contribution" of some research papers. We describe a Reformulation-Optimization Software Engine (ROSE) for performing (automatic) symbolic computation on mathematical programming formulations.

Introduction

The aim of this paper is to describe a new optimization software called Reformulation-Optimization Software Engine (ROSE). Its main purpose is to allow the symbolic analysis and reformulation of Mathematical Programs (MP), although ROSE can also interface with numerical solvers. In practice, ROSE is used either as a pre-processor or is called iteratively within numerical solvers; it can be used either stand-alone or as an AMPL [START_REF] Fourer | The AMPL Book[END_REF] solver. ROSE addresses MPs in the following very general form:

min f (x) g L ≤ g(x) ≤ g U x L ≤ x ≤ x U ∀i ∈ Z x i ∈ Z,        (1)
⋆ Supported by grants: ANR 07-JCJC-0151 "ARS", Digiteo 2009-14D "RMNCCO", Digiteo 2009-55D "ARM". We acknowledge the contributions of Dr. C. D'Ambrosio (University of Bologna) and of Mr. P. Janes (Australian National University); to appear in an LNCS volume containing the Proceedings of the International Congress of Mathematical Software, 2010. ⋆⋆ Corresponding author.

where x is a vector of n decision variables, x L , x U ∈ R n , Z ⊆ {1, . . . , n}, g L , g U ∈ R m , f : R n → R and g : R n → R m . MPs in the form [START_REF] Fourer | The AMPL Book[END_REF] are known as Mixed-Integer Nonlinear Programs (MINLP). The restriction on f, g is that they should be representable as strings of a certain formal language (more details in Sect. 2 below).

Changing the formal description of optimization problems has an impact on the applicability and efficiency of the corresponding solution methods. Difficult problems are routinely decomposed, relaxed or transformed into simpler subproblems that we know how to solve efficiently, and which preserve some of the interesting mathematical properties of the original problem. Such transformations, called reformulations, almost always depend on the "mathematical structure" of the problem. Considering MP as a formal language, each formulation is a valid sentence in the language. A reformulation is a sequence of some basic symbolic transformations (such as add, modify or delete a variable, an objective or a constraint). In order to be useful, a reformulation must preserve some mathematical property: for example, all optima of the reformulation might be required to be also optima of the original formulation. Since the basic "atomic" reformulations (adding, modifying, deleting a formulation element) are in principle easy to conceive and implement, the absence of a generic software package for carrying out automatic reformulations in MP might come as a surprise. ROSE moves a few steps in this direction, providing a set of reformulators that can act on MP formulations. The roadmap for ROSE is to facilitate the implementation of a heuristically driven search for the best reformulation for a given solver.

ROSE consists of around 50Klines of GNU C++ code and is covered by the Common Public License (CPL). We are currently preparing its distribution through COIN-OR [START_REF] Lougee-Heimer | The common optimization interface for operations research: Promoting open-source software in the operations research community[END_REF] and finalizing documentation and examples. At the moment the software can be obtained through http://www.lix.polytechnique. fr/ ~liberti/rose.tar.gz. This paper announces the first public distribution of ROSE, which provides symbolic (as opposed to numerical) methods for manipulating MPs. Currently, ROSE can perform basic and complex symbolic analysis and manipulation tasks on all formulation elements, including all expressions appearing in objective(s) and constraints in (1). These tasks have been put together in higher-level reformulation solvers, e.g. writing a (linear) convex relaxation of a MINLP automatically [START_REF] Liberti | Writing global optimization software[END_REF][START_REF] Belotti | Branching and bounds tightening techniques for non-convex MINLP[END_REF]; writing a DAG representation of an AMPL-encoded MINLP [START_REF] Schichl | Interval analysis on directed acyclic graphs for global optimization[END_REF][START_REF] Belotti | Branching and bounds tightening techniques for non-convex MINLP[END_REF]; writing a cdd [START_REF] Fukuda | Double description method revisited[END_REF] or Porta [START_REF] Christof | The porta manual page[END_REF] representation of an AMPL-encoded LP. A list of applications of ROSE is given in Sect. 5.

The rest of this paper is organized as follows. We review existing work in Sect. 1.1, give two motivating examples in Sect. 1.2, survey the theory that ROSE is built on in Sect. 2, explain ROSE's architecture in Sect. 3, show how ROSE helps solving the motivating examples in Sect. 4 and discuss ROSE's main applications in Sect. 5, which concludes the paper.

Existing work

Currently, optimization software focuses on solvers (implementations of solution algorithms), each of which includes the necessary layers of reformulation capa-bilities. For example, all spatial Branch-and-Bound (sBB) MINLP solvers are able to construct a convex relaxation automatically [START_REF] Sahinidis | BARON 7.2.5: Global Optimization of Mixed-Integer Nonlinear Programs[END_REF][START_REF] Belotti | Branching and bounds tightening techniques for non-convex MINLP[END_REF].

Solvers typically require their input in a non-quantified format: complex jagged arrays of variables and constraints must be transformed into flat lists thereof. This creates the need for "translators" that automatically convert quantified constraints to flat constraints. For example, ∀i ∈ {1, 2, 3} j =i x i = 1 is converted to the flat form

x 1 + x 2 = 1 ∧ x 1 + x 3 = 1 ∧ x 2 + x 3 = 1.
Since different solvers read the flat form input according to different encodings, translators also include wrappers for most existing solvers, so that users can safely ignore the technicalities of the calling procedure. The two best known MP translators are AMPL and GAMS [START_REF] Brook | GAMS, a user's guide[END_REF]: both optionally perform reformulations on the input MP before "flattening" it and passing it to the solver.

In general, the reformulation layers of existing solvers and translators cannot be accessed or modified by the user. Apart from ROSE we are aware of no user-accessible software for carrying out MP reformulations with such generality. Notwithstanding, at least two codes are available that perform symbolic analysis and reformulation to a certain extent. Dr. AMPL [START_REF] Orban | AMPL: a meta solver for optimization[END_REF] is an analysis tool for MP formulations aimed to the automatic choice of an appropriate solver for the given formulation. The software described in [START_REF] Colombo | A structureconveying modelling language for mathematical and stochastic programming[END_REF] enriches the AMPL language with primitives for providing solvers with specific block-diagonal information about the problem.

Motivating examples

The need for a generic reformulation software layer is given by the mounting complexity of optimization software needed to solve ever more difficult problems.

Subproblems in sBB. In sBB, for example, a branching procedure constructs a search tree, each node of which represents a pair of reformulations (Q, Q) of the original problem P . The formulation Q is obtained from P by restricting the variable bounds; Q is a relaxation of Q where each nonlinear term is replaced by linear lower and upper bounding functions. A possible sBB implementation might wish to solve Q using a MINLP heuristic and Q using a MILP solver. In turn, the MINLP heuristic might alternate between solving a continuous Nonlinear Programming (NLP) reformulation and an auxiliary MILP reformulation of Q, whereas the MILP solver is a standard BB algorithm which needs to call MILP heuristics and a Linear Programming (LP) solver such as the simplex algorithm. Testing new ideas in this complex calling chain often requires changing the reformulation algorithms, which is impossible as long as these are hard-coded into the solver.

The Kissing Number Problem. Given positive integers D, N , the KNP [START_REF] Kucherenko | New formulations for the kissing number problem[END_REF] asks for the maximum number (between 1 and N ) of spheres of unit radius that can be arranged in R D around a unit sphere centered in the origin so that their interiors are disjoint. The MP formulation [START_REF] Maculan | Bounds on the kissing numbers in R n : Mathematical programming formulations[END_REF] is:

max P i≤ N yi ∀i ≤ N xi 2 = 4yi ∀i < j ≤ N xi -xj 2 ≥ 4yiyj ∀i ≤ N xi ∈ R D , yi ∈ {0, 1}. 9 > > > = > > > ;
(2)

Attempting to solve (2) directly with a MINLP solver such as BARON [START_REF] Sahinidis | BARON 7.2.5: Global Optimization of Mixed-Integer Nonlinear Programs[END_REF] or Couenne [START_REF] Belotti | Branching and bounds tightening techniques for non-convex MINLP[END_REF] results in the trivial solution with y = 0 standing for incumbent (i.e. best optimum so far) for several days of computation as soon as D 3 and N 13. We dispense with binary variables by transforming (2) into the corresponding decision problem: can N ≤ N spheres be arranged around the central one? The MP formulation is:

∀i ≤ N xi 2 = 4 ∧ ∀i < j ≤ N xi -xj 2 ≥ 4.
(

) 3
If (3) has a solution, then the instance (D, N ) is a YES one. Since both BARON and Couenne identify a feasible solution by calling a local NLP subsolver (e.g. SNOPT [START_REF] Gill | User's guide for SNOPT version 7[END_REF]), both are only as reliable as the subsolver. Computational experience shows that most local NLP solvers have difficulties in finding a local optimum of a heavily nonlinear MP if no feasible starting point is supplied. Again, days of computation will not yield any solution even for small instances. Inserting a tolerance to feasibility improves this situation:

max x,α∈[0,1] α s.t. ∀i ≤ N xi 2 = 4 ∧ ∀i < j ≤ N xi -xj 2 ≥ 4α. (4)
As shown in [START_REF] Kucherenko | New formulations for the kissing number problem[END_REF], ( 4) is computationally amenable to local NLP solution within a heuristic Global Optimization (GO) solver such as Variable Neighbourhood Search (VNS). Because of the large number of symmetric optima, however, sBB solvers are still far from finding any nontrivial solution. A study of the formulation group of (4) suggests adjoining the symmetry breaking constraints ∀i ≤ N {1} x i-1,1 ≤ x i1 to (4), yielding a reformulation for which sBB makes considerably more progress [START_REF] Liberti | Symmetry in mathematical programming[END_REF]. Identifying this reformulation chain, which leads to a more easily solvable MP, required considerable effort and resources. ROSE alleviates the situation by providing a uniform C++ interface to several reformulation needs. It is interesting to remark that other types of reformulations were recently instrumental in solving some high dimensional KNP instances [START_REF] Bachoc | New upper bounds for kissing numbers from semidefinite programming[END_REF].

Reformulations: formal definitions

We define MPs as valid sentences of a certain formal language. Instead of giving its syntax, i.e. the explicit grammar of this language (see the Appendix to [START_REF] Fourer | The AMPL Book[END_REF] for an example), we describe the image of its semantic function, i.e. the data structure needed to encode a MP.

A parameter is a real number p (in its floating point computer representation). A decision variable is a symbol x i indexed by some positive integer i. Consider a finite set O of operators {⊕ 1 , ⊕ 2 , . . .} of given arities. An expression is defined recursively as follows:

1. parameters are expressions; 2. decision variables are expressions; 3. if e 1 , . . . , e k are expressions and ⊕ ∈ O has arity k, then ⊕(e 1 , . . . , e k ) is an expression. Let E be the set of all such expressions. We remark that each expression e(p, x) ∈ E involving parameters p = (p 1 , . . . , p t ) and decision variables x = (x 1 , . . . , x n ) corresponds to a function f e (p, x), which associates to x the evaluation of e(p, •) at x. An objective function is a pair (d, e) ∈ {-1, 1} × E where d is the optimization direction: (-1, e(p, x)) corresponds to min f e (p, x) and (1, e(p, x)

) to max f e (p, x). A constraint is a triplet (g L , e, g U ) ∈ R × E × R encoding the dou- ble inequality g L ≤ f e (p, x) ≤ g U . A range constraint is a triplet (x L i , x i , x U i ) ∈ R × E × R encoding the restriction x L i ≤ x i ≤ x U i .
An integrality constraint is a positive integer i which encodes the restriction x i ∈ Z. A mathematical program is a 7-tuple (p, x, E, O, C, B, Z) such that for all e ∈ E, e depends on no further parameters (resp. decision variables) than p (resp. x), O is a set of s objective functions (d, e) with e ∈ E, C is a set of m constraints (g L , e, g U ) with e ∈ E, B is a set of n range constraints, and Z ⊆ {1, . . . , n} is a set of integrality constraints. An element of any component set in the 7-tuple is also called an entity of the MP. Semidefinite and multilevel programming can be dealt with by letting constant and/or variables symbols range over sets of matrices or other mathematical programs.

Flat and structured MPs

MPs can be given either in structured form (i.e. by using quantifiers over indices) or flat form. Flat MPs are those corresponding to the definition of Sect. 2. We now define structured MPs.

Given a sequence I = {I i ⊆ N | i ≤ α} of finite subsets of integers and a multi-index i = (i 1 , . . . , i α ) where i β ∈ I β for all β ≤ α, a structured parameter p is a jagged array of (scalar) parameter symbols p i (with i ∈ I) with an assigned (scalar) value p i . A structured decision variable x is defined similarly for scalar variable symbols x i . Structured expressions, resting on an operator set O ′ enriched with the quantifier operators , , are defined recursively similarly to flat expressions, but with parameters and variables replaced by their structured versions. A structured constraint is a triplet (g L ij , f e (p i , x j ), g U ij ) where all multiindices i, j are universally quantified over some subsets of I. Structured range and integrality constraints are defined similarly. A MP defined over structured entities is a structured MP. Given a structured MP P with multi-indices i 1 , . . . , i γ ranging over set families I = {I 1 , . . . , I γ }, and the jagged array of values p to be assigned to all parameter symbols, a translator (such as AMPL or GAMS) is able to write a flat MP P corresponding to the triplet (P, I, p). In general, an operator ⊕ ∈ O ′ acts on structured entities in a componentwise fashion. Different operator semantics can be defined by simply adding new operators to O ′ . In the terminology of complexity analysis, flat MPs correspond to instances and structured MPs to problems defined as instance sets, each instance being given by the pair (I, p).

Flat reformulations

Reformulations may occur either at the flat or structured level. Because of a technical limitation of AMPL (i.e. the AMPL API only allows user access to the flat, rather than structured, MP), ROSE only performs flat reformulations; we therefore only define these. Structured reformulations would essentially require hooking reformulation primitives at the AMPL grammar parsing level.

Let MP F be the class of all flat MPs; for P ∈ MP F we denote the feasible region of P by F(P ), the set of local optima of P by L(P ) and the set of global optima of P by G(P ).

Definition

A flat reformulation is a relation ֒→ on MP F such that there exists a formula ψ with two free variables for which

∀P, Q ∈ MP F ( P ֒→ Q ⇒ ψ(P, Q) ).
(

) 5
The invariance scope of ֒→ is the class S(֒→) of all ψ for which (5) holds.

We distinguish three remarkable types of reformulations. 1. Exact reformulations, denoted by ≡: S(≡) contains the formula "there is a function ϕ : F(Q) → F(P ) such that ϕ| L(Q) is onto L(P ) and ϕ| G(Q) is onto G(P )"; 2. Narrowings, denoted by ⊲: S(⊲) contains the formula "there is a function ϕ : F(Q) → F(P ) such that ϕ(G(Q)) ⊆ G(P )"; 3. Relaxations, denoted by ≥: S(≥) contains the formula "F(Q) ⊇ F(P ) and O(Q) = {(-1, e ′ )} and O(P ) = {(-1, e)} and, for all x ∈ F(P ), f e ′ (p, x) ≤ f e (p, x)".

Theorem ([17])

The relations ≡, ⊲, ≥ are all transitive. Furthermore, ≡ ⊆ ⊲ and ≡ ⊆ ≥.

Thus, if P ≡ Q 1 ⊲ Q 2 then P ⊲ Q 2 ; if P ≡ Q 1 ≥ Q 2 then P ≥ Q 2 .
This allows the construction of reformulation chains with invariant properties. We only consider reformulations corresponding to computable relations. A taxonomy of useful flat reformulations is given in [START_REF] Liberti | Reformulations in mathematical programming: A computational approach[END_REF].

Example

The ProdBinCont exact reformulation [START_REF] Liberti | Reformulations in mathematical programming: A computational approach[END_REF] replaces every product xy where x ∈ {0, 1} and y ∈ [y L , y U ] with an added variable w, which is constrained by the natural extension of Fortet's inequalities [START_REF] Fortet | Applications de l'algèbre de Boole en recherche opérationelle[END_REF]:

w ≤ y U x, w ≥ y L x, w ≤ y -(1 -x)y L , w ≥ y -(1 -x)y U .

ROSE architecture

ROSE consists of a simple modular architecture based on two main classes (Problem and Solver) and a separate library (Ev3) for storing and manipulating expressions in E. The overall architecture is depicted graphically in Fig. 1. More detailed information about ROSE's and Ev3's architecture, capabilities and Application Programming Interface (API) can be found in [START_REF] Liberti | Reformulations in mathematical programming: A computational approach[END_REF], Sect. 5.2-5.3.

The Problem class contains lists of Variable, Objective and Constraint structures. Structures of Variable type include information about decision variables such as index, current and optimal value, and range and integrality constraints; Objectives include information about objective functions such as index, current and optimal value, corresponding expression and optimization direction; Constraints include information about constraints such as index, current and optimal value, corresponding expression and bound restrictions. The Problem class also stores information about problem cardinalities, feasibility of a current solution with respect to the constraints, a reference to a previous Problem object in a reformulation chain, and other useful information. It has methods for accessing data, adding or deleting decision variables, objective functions and constraints, evaluating expressions appearing in objectives or constraints, parse a given input file (a description of an MP) into its data structures, and so on.

The Solver class is a virtual class whose implementations are either numerical solvers or reformulators; the latter are recognizable because their names are prefixed by R-(e.g. Rprodbincont). All Solver objects maintain: a pointer to the Problem object being solved, numerical information about current and optimal points, information about linear and nonlinear cuts and a few other items mainly used by numerical solvers. Reformulators are allowed to change the Problem they reference; problems can be duplicated before being changed by a reformulator by using the special Rcopy reformulator. Basic reformulation steps for adding or deleting problem entities are implemented in Problem; modification of expressions occurs via interfacing with the Ev3 expression library (Sect. 3.3). Many methods in Problems and Solvers can be configured by user-defined parameters that passed to Problem and Solver objects via a unique object of the class ParameterBlob.

MP input

ROSE can read an MP via either its own intuitive flat MP format (see [START_REF] Liberti | Writing global optimization software[END_REF] p. 238) or via interfacing with the AMPL interpreter [START_REF] Fourer | The AMPL Book[END_REF]. Each MP entity is assigned two integer scalar indices: a unique entity ID (which is preserved across reformulations) and a local index (which is an ordinal running from 1 to the number of entities of a given type within a Problem object). Methods are provided for switching from ID to local indices.

MP output

Since the AMPL API does not offer primitives for modifying the current MP, the only possibility for ROSE is to output its reformulations to a flat MP written to an AMPL formatted file. Users can then instruct AMPL to read this file. This situation is far from optimal, as it requires hard disk access, but there is no way around it -according to the AMPL authors, it is unlikely that AMPL will ever have an API which is sufficiently flexible as to allow modification of the internal data. Developers can also choose to have individual reformulators write their output to whatever syntax they wish, bypassing the default output.

Expression tree library

Following the recursive definition of expressions given in Sect. 2, an expression e ∈ E is encoded in a tree data structure T e = (V e , A e ): leaf nodes of V e are labelled by parameters in p and by decision variables in x, and intermediate nodes are labelled by operators in ⊕ ∈ O. A k-ary operator node has k subnodes in its star. An arc (u, v) is in A e if v is a subnode of u.

An Expression is synonym to a Pointer<BasicExpression> template class. The Pointer<T> class is used to perform automatic memory management (i.e. automatic deallocation) from a node of type T. A BasicExpression inherits from Operand and from Tree<BasicExpression>. The Operand class simply includes information concerning a particular node (whether leaf or nonleaf, operator label, variable index, parameter value, and so on). The Tree<T> class includes a list of nodes of type Pointer<T>, and is used to represent a list of subnodes of a given node; it has methods for accessing and editing nodes. This complex architecture for expression trees makes it easy to edit, move or copy entire subtrees recursively, but floating point evaluation of the expression is slow. To circumvent this problem, expressions are also encoded in much simpler C-style tree structures (called FastEvalTrees) without any memory management in order to speed up evaluation. Their activation and use is completely transparent to the user.

ROSE's existing applications

ROSE's current role is to help automatize flat MP reformulations which would be too long to perform by hand, but which are necessary to implement and test research ideas. ROSE was and is instrumental to several past and current research projects: in some cases it is key to their success, in other cases it allows research teams to quickly weed out bad ideas; it is sometimes influential to other software, in that ideas found in ROSE are re-implemented (for practical reasons) in other codes.

-Fundamentals of reformulation theory [START_REF] Liberti | Reformulations in mathematical programming: Definitions and systematics[END_REF][START_REF] Liberti | Reformulations in mathematical programming: A computational approach[END_REF], where ROSE served as a proof of concept (successful). -Experiments on spherical cuts for Binary Linear Programs (BLPs) [START_REF] Liberti | Spherical cuts for integer programming problems[END_REF] (successful). -An investigation of the convex relaxation of quadrilinear terms [START_REF] Cafieri | Comparison of convex relaxations of quadrilinear terms[END_REF][START_REF] Cafieri | On convex relaxations of quadrilinear terms[END_REF], where ROSE was used both to produce the convex relaxation and to automatically write input data to other software packages (e.g. cdd [START_REF] Fukuda | Double description method revisited[END_REF]) (successful). -Experiments with symmetry-breaking narrowing reformulations [START_REF] Liberti | Reformulations in mathematical programming: Automatic symmetry detection and exploitation[END_REF][START_REF] Liberti | Symmetry in mathematical programming[END_REF][START_REF] Costa | Formulation symmetries in circle packing[END_REF][START_REF] Costa | Static symmetry breaking in circle packing[END_REF] (successful). -The FPMINLP heuristic [START_REF] D'ambrosio | Experiments with a feasibility pump approach for nonconvex MINLPs[END_REF], where ROSE is used both to analyze MINLPs (e.g. to find convex constraints), and to reformulate them, i.e. to build the Feasibility Pump subproblems (successful). -The RECIPE MINLP heuristic [START_REF] Liberti | A good recipe for solving MINLPs[END_REF] was implemented independently of ROSE with what was essentially ROSE code (influential). -The conception of the Couenne [START_REF] Belotti | Branching and bounds tightening techniques for non-convex MINLP[END_REF] solver code that builds the convex relaxation was heavily influenced by ideas implemented in ROSE (influential). -Reduced RLT-based relaxations for polynomial programs (current work, unpublished). -A general-purpose MINLP Tabu Search heuristic based on tabu spheres (unsuccessful, unpublished). -A general-purpose MINLP feasibility heuristic based on branching with no bounding until a feasible solution is found (unsuccessful, unpublished).

Fig. 1 .

 1 Fig. 1. ROSE architecture. Rectangles indicate classes (with dashed meaning virtual), rounded boxes indicates structs, relation links conform to UML: void diamonds indicate aggregation (to maintain a reference of), filled diamonds indicate composition (to maintain a copy of), triangles indicate inheritance.

The Ev3 library capabilities include simplification of expressions, reduction to (partial) normal form, identification of subexpressions of certain structures, conditional editing of subexpressions, recognition and separation of linear and nonlinear parts in a given expression, symbolic differentiation and many others. Since they act on trees, most methods are recursive, and consist of two functions: the "recursion start" and the "recursion step". In the case of Example 2.3, the ProdBinCont reformulator is implemented according to the pseudocode below.

How ROSE helps solving the motivating examples

Subproblems in sBB. ROSE can construct a convex relaxation of (1) automatically from its Smith reformulation [START_REF] Smith | A symbolic reformulation/spatial branch-and-bound algorithm for the global optimisation of nonconvex MINLPs[END_REF], which isolates all the nonlinearities of the problem in constraints with a simple structure; these are then replaced by appropriate convex relaxations [START_REF] Liberti | Writing global optimization software[END_REF]. The ROSE Rsmith reformulator (tasked with constructing the Smith reformulation) calls a recursive Ev3 procedure which looks for subtrees of an Expression e having a certain "shape" in order to replace them with an added variable w; the constraint w = e is then added to the formulation. The shape of an expression is defined as an expression schema, i.e. an expression tree search pattern whose variable nodes are labelled by a wildcard "?" with the meaning of "any variable". Thus, for example, the tree ? ←×→? represents a generic product of two variables, and it matches every tree x i ←×→ x j (for any i, j). The pseudocode above shows the essential functionality of the Rsmith reformulator and the corresponding Ev3 recursive auxiliary function. ROSE has several relaxation reformulators (e.g. Rconvexifier, RQuarticConvex) which are chained to the Rsmith reformulator as per Thm. 2.2.

KNP. Solving the KNP formulation (2) requires several reformulations:

1. derive a restriction of (2) to certain neighbourhoods (in order to solve the KNP using heuristics); 2. convert the optimization problem to the corresponding decision problem for a given objective function value (3) 3. relax some constraints by means of a multiplicative tolerance; 4. adjoin an objective that maximizes the tolerance (4); 5. derive a symmetry-free narrowing and a convex relaxation of (4) (in order to solve via sBB).

The two heuristics tested on (2) are VNS and the MINLP Feasibility Pump (FPMINLP) [START_REF] D'ambrosio | Experiments with a feasibility pump approach for nonconvex MINLPs[END_REF]. Both rely on certain subproblems of (2) obtained by adjoining appropriate constraints: VNS requires Local Branching type constraint [START_REF] Fischetti | Local branching[END_REF], whilst FPMINLP requires a specific outer approximation. The reformulations listed in 2.-4. above can be implemented using the basic reformulations encoded in ROSE. The symmetry-free narrowing in 5. is obtained automatically using a chain of software packages (i.e. AMPL, ROSE, nauty [START_REF] Mckay | nauty User's Guide (Version 2.4)[END_REF], GAP [START_REF]GAP -Groups, Algorithms, and Programming[END_REF]) held together via Unix scripts. In particular, ROSE is used to analyze an AMPL flat MP and produce its Directed Acyclic Graph (DAG) encoding [START_REF] Belotti | Branching and bounds tightening techniques for non-convex MINLP[END_REF][START_REF] Schichl | Interval analysis on directed acyclic graphs for global optimization[END_REF], which is then fed into nauty in order to derive its symmetry group. ROSE can also obtain a convex relaxation of (4) based on the ideas given in [START_REF] Smith | A symbolic reformulation/spatial branch-and-bound algorithm for the global optimisation of nonconvex MINLPs[END_REF][START_REF] Liberti | Writing global optimization software[END_REF][START_REF] Belotti | Branching and bounds tightening techniques for non-convex MINLP[END_REF]. Computational results for sBB on (4) are reported in [START_REF] Liberti | Symmetry in mathematical programming[END_REF]. It may be noted that the above examples were chosen arbitrarily by a large set of ROSE applications (see Sect. 5). We believe that the first example shows how ROSE can be useful per se, whereas the second demonstrates ROSE's ability to interface with other tools in order to perform complex reformulating tasks.