<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <title-group>
        <article-title>Towards Improved QUBO Formulations of IR Tasks for Quantum Annealers</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Discussion Paper</string-name>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Riccardo Pellini</string-name>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Maurizio Ferrari Dacrema</string-name>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Paolo Cremonesi</string-name>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Politecnico di Milano</string-name>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Italy</string-name>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Italy</string-name>
        </contrib>
      </contrib-group>
      <abstract>
        <p>In recent years the interest in applying Quantum Computing to Information Retrieval and Recommendation Systems task has increased and several papers have proposed formulations of relevant tasks that can be solved with quantum devices (community detection, feature selection etc.), usually focusing on Quantum Annealers (QA), a special purpose device able to solve combinatorial optimization problems. However, most research only focuses on the mathematical aspect of the formulation, without accounting for the underlying physical processes of the quantum device. Indeed, theoretical studies indicate that certain characteristics make a problem dicfiult to solve on QA, but it is not clear how to use this knowledge to inform the development of better problem formulations that are equivalent but easier to solve on QA. This work presents a preliminary study which approaches this issue with an empirical perspective. We consider several problems both general and related to IR and Recommendation tasks to assess whether we can identify characteristics of the problem formulation or the solution space that afect the efectiveness of QA. The results indicate interesting correlations and suggest that this is a promising area to investigate further. 1</p>
      </abstract>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>1. Introduction</title>
      <p>
        Quantum Computing is a technology that has the potential to accelerate the solution of several
problems that are dificult to solve on traditional hardware. The adoption of this new paradigm
is however a complex endeavour that requires to tackle several challenges, from the
limitation of current quantum computing devices to the development of compatible mathematical
formulations for the problems we want to solve. Indeed, there have already been eforts to
use Quantum Annealers (QA) for Information Retrieval (IR) and Recommendation Systems
(RS) tasks. QA are special-purpose devices that leverage quantum mechanical efects to solve
Quadratic Unconstrained Binary Optimization (QUBO) problems. This QUBO formulation
has been used to represent problems such as graph partitioning [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ], Feature Selection [
        <xref ref-type="bibr" rid="ref2 ref3">2, 3</xref>
        ],
community detection [
        <xref ref-type="bibr" rid="ref4">4</xref>
        ] for recommendation, user interface personalization [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ] and many
others. Furthermore, more general problems such as Maximum Cut and Graph Coloring [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ] are
useful as well since they can be applied to community detection problems.
      </p>
      <p>While most of current works have focused on finding new problems that can be represented
as QUBO, the focus is usually on their pure mathematical representation and does not take into
account the physical processes used by the QA. Indeed, depending on certain characteristics of
the QUBO problem the QA will be more or less sensitive to noise, furthermore when studying
the quantum-mechanical processes analytically one can prove that in certain scenarios QA will
fail to find the optimal solution. Clearly in our eforts to advance the use of quantum devices for
IR and RS tasks we would like to avoid such scenarios and develop QUBO formulations that not
only correctly represent the problem but do so in a way that maximizes the efectiveness of QA.</p>
      <p>While in principle one could model and study the QA physical system analytically, the
complexity of it grows exponentially in the number of problem variables so it is only possible
for very small problems. The goal of this study is to analyse, with an empirical perspective,
which are the QUBO problem characteristics that make it more or less dificult to solve on a QA.
We consider a selection of diferent types of problems in order to provide a suficiently broad
analysis but maintain the focus on IR and RS. We compute features and descriptors of those
instances and study how they correlate with the efectiveness of QA. Our experiments indicate
that certain characteristics correlate well with cases where the QA is efective or inefective and
therefore could be useful to consider when developing new QUBO formulations.</p>
    </sec>
    <sec id="sec-2">
      <title>2. Methodology and Experimental Pipeline</title>
      <p>
        This work is based on the D-Wave Advantage QA, which has 5600 qubits [
        <xref ref-type="bibr" rid="ref7">7</xref>
        ] and represents
the current state-of-the-art QA with the highest number of qubits. This Quantum Annealer
represents the optimization problem as the energy of a physical system, in which the energy
represents the quality of a solution. The device operates by evolving the quantum system from
an initial default configuration to a final one which is strongly dependent on the problem one
desires to solve. Once this process is complete, qubits have reached a state that minimizes the
overall system’s energy and therefore are in an optimal solution. In order to use this QA, the
problem to solve must be represented in the following QUBO formulation:
      </p>
      <p>min  =  
∈{0,1}
(1)
where  is the cost function,  ∈ {0, 1} is a vector of  binary variables and  is an  × 
symmetric matrix that defines the function to optimize. In practice several factors can afect the
quality of the solution found (noise, how slow the evolution was) but also on the problem itself.
The underlying physical system can be represented with a Hamiltonian, which is a 2 × 2
matrix. From quantum mechanics we know that using the eigenvalues of the Hamiltonian
one can compute the solution that the QA will find. In theory one could use this approach to
study whether a QUBO formulation will be robust to noise or not. Unfortunately, given that the
Hamiltonian grows exponentially in the number of variables, it is impractical to compute it for
problems of more than 20 variables and this severely limits the ability to study the behaviour of
QA for applied problems.</p>
      <p>The goal of this study is to assess whether there are characteristics of the problem, i.e., matrix
Q, or the structure of the solution space, that impact the efectiveness of QA and that could be
used to develop better QUBO formulations.</p>
      <sec id="sec-2-1">
        <title>2.1. Features</title>
        <p>Most of the characteristics we study are based on the spectral analysis of either the solution space
of the problem or on matrix Q. In both cases the way we design the QUBO formulation afects
both the solution structure and matrix Q, therefore desirable or undesirable characteristics can
inform the development of new QUBO formulations.</p>
        <p>
          Solution Space Features: These features are computed based on the energy distribution
of the entire solution space. Note that computing these features requires to know the energy
of all the 2 possible allocations of the variable . On the energy distribution of the solution
space we compute Shannon Entropy (ℎ) [
          <xref ref-type="bibr" rid="ref8 ref9">8, 9</xref>
          ], Spectral Flatness ( ) and Spectral Entropy
(). Intuitively, these metrics will allow to distinguish problems that have solutions with a
large number of evenly spaced energies, versus problems with few distinct energy values each
associated to many equivalent solutions.
        </p>
        <p>
          QUBO Features: We can consider matrix Q as an adjacency matrix to indicate which
problem variables are connected. This allows to define a complexity measure [
          <xref ref-type="bibr" rid="ref10">10</xref>
          ], called Graph
Complexity (), based on the diference between the spectrum of  and the spectrum of
a full graph and a null graph. We also include a Graph Density () which indicates how
dense Q matrix is. The denser Q is, the more relations exist between variables and therefore the
more complex the problem could be. We refer to these two measures with the name of QUBO
structural features. Furthermore, we can compute the Graph Fourier Transform of the diagonal
of Q [
          <xref ref-type="bibr" rid="ref11">11</xref>
          ] and find its Graph Spectral Entropy () and its Graph Spectral Flatness ( ).
We refer to these two measures with the name of QUBO spectral features.
        </p>
      </sec>
      <sec id="sec-2-2">
        <title>2.2. Experimental Pipeline</title>
        <p>We consider four satisfiable instances of five diferent optimization problems: Max-Cut and
Minimum Vertex Cover (which can be applied for community detection), as well as Graph
Coloring, Set Partitioning and Number Partitioning problems. These instances have 30-32
variables, which allows to compute the entire solution space and the related features. We
selected these problems in order to provide a suficiently ample selection while maintaining a
focus on IR an RS tasks. We did not include other existing formulations, such as feature selection,
because those depend also on heuristics to compute matrix Q (e.g., Pearson correlation, Mutual
Information) which introduces a further confounding factor in the analysis, so, for the purpose
of this preliminary study we focused on relevant but simpler and more general problems.</p>
        <p>The problem instances are solved with the D-Wave Advantage QA, Simulated Annealing
(SA) [12] and Tabu Search (TS) [13] in order to compare the solution obtained with diferent
methods. To this end, we want to assess whether: (i) QA finds the global optimum, ( ii) QA finds
a suboptimal solution but with an energy within 5% of the global optimum, (iii) QA finds a
better solution compared to the other heuristics SA and TS. Then, the instances are clustered
with agglomerative hierarchical clustering, based on Euclidean distance and average linkage.
Three sets of clusters are considered, identified with the following names:
• Solution Space clustering: instances are clustered according to their ℎ,  and .
• QUBO structural clustering: instances are clustered according to their  and .
• QUBO spectral clustering: instances are clustered according to their  and .</p>
        <p>The clusters are validated using the Silhouette Coeficient and, for each cluster, it is computed
the conditional probability of obtaining a good solution from the QA on an instance given
which cluster it belongs to. We refer to this probability as success rate. We can also compare the
content of diferent sets of clusters with the help of Jaccard coeficient.</p>
      </sec>
    </sec>
    <sec id="sec-3">
      <title>3. Results and Discussion</title>
      <p>As a general comment we can observe that all the solvers (QA, SA, TS) are able to find either
optimal or at least good solutions for most of the problem instances. This is likely due to the
limited size of the instances (30-32 variables) which is due to the need to compute the features on
the solution space. An exception to this is the Minimum Vertex Cover which is more challenging
to solve for both QA and SA. The analysis of the clusters reveals two observations:
• Instances characterized by high values of  or  are always solved either optimally
or well by all the samplers.
• Instances characterized by low-average values of  tend to obtain worse solutions
with QA and SA.</p>
      <p>This indicates that there is a relationship between solution space or QUBO features and the
performance of the diferent solvers, in particular with respect to QA. The diferent clusters are
compared with the Jaccard index to assess whether there are relationships between the clusters
that can be obtained using diferent features. In particular, we see that:
• High values of  correspond to high values of  and .</p>
      <p>•  is related to ℎ.</p>
      <p>These results are also corroborated by considering the simple linear correlation between solution
space features.</p>
      <p>Discussion and Future Works In this work we have studied the impact of some
characteristics of the solution space of a problem and its QUBO formulation on how challenging it is to
solve it with Quantum Annealing. The aim of the analysis is to inform the future development
of new QUBO formulation for IR problems, such as community detection and feature selection.
While this is a preliminary study that considers a limited number of instances, it is possible to
observe that certain features indeed correlate with the efectiveness of QA: Spectral Flatness
( ), Graph Density () and Graph Spectral Flatness ( ). In particular, for instances
characterized by high values of ( ) and () QA is highly efective. We observe also that
QA and SA share a similar behaviour, both perform badly for some values of ( ), while
TS always performs better than them. Indeed, the need to compute features on the solution
space constrains their uses to small problems. It was observed however that ( ) and ()
are strongly correlated, this means that as a future direction the study could be expanded to
focus on features of the QUBO problems that are not based on the solution space and therefore
allow to study much larger problems.
[12] S. Kirkpatrick, C. D. Gelatt Jr, M. P. Vecchi, Optimization by simulated annealing, science
220 (1983) 671–680.
[13] G. Palubeckis, Multistart tabu search strategies for the unconstrained binary quadratic
optimization problem, Annals of Operations Research 131 (2004) 259–282.</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          [1]
          <string-name>
            <given-names>H.</given-names>
            <surname>Ushijima-Mwesigwa</surname>
          </string-name>
          ,
          <string-name>
            <given-names>C. F.</given-names>
            <surname>Negre</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S. M.</given-names>
            <surname>Mniszewski</surname>
          </string-name>
          ,
          <article-title>Graph partitioning using quantum annealing on the d-wave system</article-title>
          ,
          <source>in: Proceedings of the Second International Workshop on Post Moores Era Supercomputing</source>
          ,
          <year>2017</year>
          , pp.
          <fpage>22</fpage>
          -
          <lpage>29</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          [2]
          <string-name>
            <given-names>R.</given-names>
            <surname>Nembrini</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M. Ferrari</given-names>
            <surname>Dacrema</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            <surname>Cremonesi</surname>
          </string-name>
          ,
          <article-title>Feature selection for recommender systems with quantum computing</article-title>
          ,
          <source>Entropy</source>
          <volume>23</volume>
          (
          <year>2021</year>
          )
          <article-title>970</article-title>
          . URL: https://doi.org/10.3390/e23080970. doi:
          <volume>10</volume>
          .3390/e23080970.
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          [3]
          <string-name>
            <given-names>M.</given-names>
            <surname>Ferrari Dacrema</surname>
          </string-name>
          ,
          <string-name>
            <given-names>F.</given-names>
            <surname>Moroni</surname>
          </string-name>
          ,
          <string-name>
            <given-names>R.</given-names>
            <surname>Nembrini</surname>
          </string-name>
          ,
          <string-name>
            <given-names>N.</given-names>
            <surname>Ferro</surname>
          </string-name>
          , G. Faggioli,
          <string-name>
            <given-names>P.</given-names>
            <surname>Cremonesi</surname>
          </string-name>
          ,
          <article-title>Towards feature selection for ranking and classification exploiting quantum annealers</article-title>
          , in: E. Amigó,
          <string-name>
            <given-names>P.</given-names>
            <surname>Castells</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Gonzalo</surname>
          </string-name>
          ,
          <string-name>
            <given-names>B.</given-names>
            <surname>Carterette</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J. S.</given-names>
            <surname>Culpepper</surname>
          </string-name>
          , G. Kazai (Eds.),
          <source>SIGIR '22: The 45th International ACM SIGIR Conference on Research and Development in Information Retrieval</source>
          , Madrid, Spain,
          <source>July 11 - 15</source>
          ,
          <year>2022</year>
          , ACM,
          <year>2022</year>
          , pp.
          <fpage>2814</fpage>
          -
          <lpage>2824</lpage>
          . URL: https://doi. org/10.1145/3477495.3531755. doi:
          <volume>10</volume>
          .1145/3477495.3531755.
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          [4]
          <string-name>
            <given-names>R.</given-names>
            <surname>Nembrini</surname>
          </string-name>
          ,
          <string-name>
            <given-names>C.</given-names>
            <surname>Carugno</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M. Ferrari</given-names>
            <surname>Dacrema</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            <surname>Cremonesi</surname>
          </string-name>
          ,
          <article-title>Towards recommender systems with community detection and quantum computing</article-title>
          , in: J.
          <string-name>
            <surname>Golbeck</surname>
            ,
            <given-names>F. M.</given-names>
          </string-name>
          <string-name>
            <surname>Harper</surname>
            ,
            <given-names>V.</given-names>
          </string-name>
          <string-name>
            <surname>Murdock</surname>
            ,
            <given-names>M. D.</given-names>
          </string-name>
          <string-name>
            <surname>Ekstrand</surname>
            ,
            <given-names>B.</given-names>
          </string-name>
          <string-name>
            <surname>Shapira</surname>
            ,
            <given-names>J.</given-names>
          </string-name>
          <string-name>
            <surname>Basilico</surname>
            ,
            <given-names>K. T.</given-names>
          </string-name>
          <string-name>
            <surname>Lundgaard</surname>
          </string-name>
          , E. Oldridge (Eds.),
          <source>RecSys '22: Sixteenth ACM Conference on Recommender Systems</source>
          , Seattle, WA, USA, September
          <volume>18</volume>
          -
          <issue>23</issue>
          ,
          <year>2022</year>
          , ACM,
          <year>2022</year>
          , pp.
          <fpage>579</fpage>
          -
          <lpage>585</lpage>
          . URL: https://doi.org/10.1145/3523227. 3551478. doi:
          <volume>10</volume>
          .1145/3523227.3551478.
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          [5]
          <string-name>
            <given-names>M.</given-names>
            <surname>Ferrari Dacrema</surname>
          </string-name>
          ,
          <string-name>
            <given-names>N.</given-names>
            <surname>Felicioni</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            <surname>Cremonesi</surname>
          </string-name>
          ,
          <article-title>Optimizing the selection of recommendation carousels with quantum computing</article-title>
          , in: H.
          <string-name>
            <surname>J. C. Pampín</surname>
            ,
            <given-names>M. A.</given-names>
          </string-name>
          <string-name>
            <surname>Larson</surname>
            ,
            <given-names>M. C.</given-names>
          </string-name>
          <string-name>
            <surname>Willemsen</surname>
            ,
            <given-names>J. A.</given-names>
          </string-name>
          <string-name>
            <surname>Konstan</surname>
            ,
            <given-names>J. J.</given-names>
          </string-name>
          <string-name>
            <surname>McAuley</surname>
            ,
            <given-names>J.</given-names>
          </string-name>
          <string-name>
            <surname>Garcia-Gathright</surname>
            ,
            <given-names>B.</given-names>
          </string-name>
          <string-name>
            <surname>Huurnink</surname>
          </string-name>
          , E. Oldridge (Eds.),
          <source>RecSys '21: Fifteenth ACM Conference on Recommender Systems, Amsterdam, The Netherlands, 27 September 2021 - 1 October</source>
          <year>2021</year>
          , ACM,
          <year>2021</year>
          , pp.
          <fpage>691</fpage>
          -
          <lpage>696</lpage>
          . URL: https://doi.org/10.1145/3460231.3478853. doi:
          <volume>10</volume>
          .1145/3460231.3478853.
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          [6]
          <string-name>
            <given-names>M. P.</given-names>
            <surname>Pawan Meena</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Pandey</surname>
          </string-name>
          ,
          <article-title>A survey on community detection algorithm and its applications</article-title>
          ,
          <source>Turkish Journal of Computer and Mathermatics Education</source>
          <volume>12</volume>
          (
          <year>2021</year>
          )
          <fpage>4807</fpage>
          -
          <lpage>4815</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          [7]
          <string-name>
            <given-names>K.</given-names>
            <surname>Boothby</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            <surname>Bunyk</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Raymond</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Roy</surname>
          </string-name>
          ,
          <article-title>Next-generation topology of d-wave quantum processors</article-title>
          , arXiv preprint arXiv:
          <year>2003</year>
          .
          <volume>00133</volume>
          (
          <year>2020</year>
          ).
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          [8]
          <string-name>
            <given-names>C. E.</given-names>
            <surname>Shannon</surname>
          </string-name>
          ,
          <article-title>A mathematical theory of communication, ACM SIGMOBILE mobile computing</article-title>
          and
          <source>communications review 5</source>
          (
          <year>2001</year>
          )
          <fpage>3</fpage>
          -
          <lpage>55</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref9">
        <mixed-citation>
          [9]
          <string-name>
            <given-names>B.</given-names>
            <surname>Boashash</surname>
          </string-name>
          , G. Azemi,
          <string-name>
            <given-names>N. Ali</given-names>
            <surname>Khan</surname>
          </string-name>
          ,
          <article-title>Principles of time-frequency feature extraction for change detection in non-stationary signals: Applications to newborn eeg abnormality detection</article-title>
          ,
          <source>Pattern Recognition</source>
          <volume>48</volume>
          (
          <year>2015</year>
          )
          <fpage>616</fpage>
          -
          <lpage>627</lpage>
          . URL: https://www.sciencedirect.com/science/ article/pii/S0031320314003306. doi:https://doi.org/10.1016/j.patcog.
          <year>2014</year>
          .
          <volume>08</volume>
          . 016.
        </mixed-citation>
      </ref>
      <ref id="ref10">
        <mixed-citation>
          [10]
          <string-name>
            <surname>D. M. Mateos</surname>
            ,
            <given-names>F.</given-names>
          </string-name>
          <string-name>
            <surname>Morana</surname>
            ,
            <given-names>H.</given-names>
          </string-name>
          <string-name>
            <surname>Aimar</surname>
          </string-name>
          ,
          <article-title>A graph complexity measure based on the spectral analysis of the laplace operator</article-title>
          , Chaos,
          <source>Solitons &amp; Fractals</source>
          <volume>156</volume>
          (
          <year>2022</year>
          )
          <article-title>111817</article-title>
          . URL: https://www.sciencedirect.com/science/article/pii/S0960077922000285. doi:https://doi. org/10.1016/j.chaos.
          <year>2022</year>
          .
          <volume>111817</volume>
          .
        </mixed-citation>
      </ref>
      <ref id="ref11">
        <mixed-citation>
          [11]
          <string-name>
            <given-names>A.</given-names>
            <surname>Ortega</surname>
          </string-name>
          , Introduction to Graph Signal Processing, Cambridge University Press,
          <year>2022</year>
          . doi:
          <volume>10</volume>
          .1017/9781108552349.
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>