Skip to main content
Log in

Sorting by Swaps with Noisy Comparisons

  • Published:
Algorithmica Aims and scope Submit manuscript

Abstract

We study sorting of permutations by random swaps if each comparison gives the wrong result with some fixed probability \(p<1/2\). We use this process as prototype for the behaviour of randomized, comparison-based optimization heuristics in the presence of noisy comparisons. As quality measure, we compute the expected fitness of the stationary distribution. To measure the runtime, we compute the minimal number of steps after which the average fitness approximates the expected fitness of the stationary distribution. We study the process where in each round a random pair of elements at distance at most r are compared. We give theoretical results for the extreme cases \(r=1\) and \(r=n\), and experimental results for the intermediate cases. We find a trade-off between faster convergence (for large r) and better quality of the solution after convergence (for small r).

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7

Similar content being viewed by others

Notes

  1. Using W or D as the energy leads to different, less local error probability functions.

  2. Generally not a sorting network since the resulting networks are generally not sorting every input.

  3. That is with probability at least \(1-1/n\).

  4. Observe that the decrease of the total number of inversions is \((1+2m)\).

  5. That is with probability at least \(1-1/n\).

  6. By Lemma 7, \( W(\pi ) = \sum _{i\in \{1,\dots ,n\}}i(i-\pi (i))\). Furthermore, since \(\pi \) is a permutation of the numbers \(\{1,\dots ,n\}\), \(\sum _{i\in \{1,\dots ,n\}}i^2 = \sum _{i\in \{1,\dots ,n\}}\pi (i)^2\).

  7. https://github.com/gavento/swap-sorting-experiments.

  8. Experiments show that the convergence behavior of \(W(\pi )\) is very similar and the convergence would differ by less than \(5\%\).

References

  1. Akimoto, Y., Morales, S.A., Teytaud, O.: Analysis of runtime of optimization algorithms for noisy functions over discrete codomains. Theor. Comput. Sci. 605, 42–50 (2015). https://doi.org/10.1016/j.tcs.2015.04.008

    Article  MathSciNet  MATH  Google Scholar 

  2. Assaf, S., Upfal, E.: Fault tolerant sorting networks. SIAM J. Discrete Math. 4(4), 472–480 (1991). https://doi.org/10.1137/0404042

    Article  MathSciNet  MATH  Google Scholar 

  3. Astete-Morales, S., Cauwet, M., Liu, J., Teytaud, O.: Simple and cumulative regret for continuous noisy optimization. Theor. Comput. Sci. 617, 12–27 (2016). https://doi.org/10.1016/j.tcs.2015.09.032

    Article  MathSciNet  MATH  Google Scholar 

  4. Astete-Morales, S., Cauwet, M., Teytaud, O.: Evolution strategies with additive noise: a convergence rate lower bound. In: He, J., Jansen, T., Ochoa, G., Zarges, C. (eds.) Proceedings of the 2015 ACM Conference on Foundations of Genetic Algorithms XIII, Aberystwyth, United Kingdom, January 17–20, 2015, pp. 76–84. ACM (2015). https://doi.org/10.1145/2725494.2725500

  5. Astete-Morales, S., Cauwet, M., Teytaud, O.: Analysis of different types of regret in continuous noisy optimization. In: Friedrich, T., Neumann, F., Sutton A.M. (eds.) Proceedings of the 2016 on Genetic and Evolutionary Computation Conference, Denver, CO, USA, July 20–24, 2016, pp. 205–212. ACM (2016). https://doi.org/10.1145/2908812.2908933

  6. Auger, A., Doerr, B.: Theory of Randomized Search Heuristics: Foundations and Recent Developments, Series on Theoretical Computer Science, vol. 1. World Scientific Publishing Co. Inc., River Edge (2011)

    MATH  Google Scholar 

  7. Benjamini, I., Berger, N., Hoffman, C., Mossel, E.: Mixing times of the biased card shuffling and the asymmetric exclusion process. Trans. Am. Math. Soc. 357(8), 3013–3029 (2005). http://www.jstor.org/stable/3845086

  8. Beyer, H.G.: Evolutionary algorithms in noisy environments: theoretical issues and guidelines for practice. Comput. Methods Aappl. Mech. Eng. 186(2), 239–267 (2000). https://doi.org/10.1016/s0045-7825(99)00386-2

    Article  MATH  Google Scholar 

  9. Cauwet, M., Liu, J., Rozière, B., Teytaud, O.: Algorithm portfolios for noisy optimization. Ann. Math. Artif. Intell. 76(1–2), 143–172 (2016). https://doi.org/10.1007/s10472-015-9486-2

    Article  MathSciNet  MATH  Google Scholar 

  10. Dang, D., Jansen, T., Lehre, P.K.: Populations can be essential in tracking dynamic optima. Algorithmica 78(2), 660–680 (2017). https://doi.org/10.1007/s00453-016-0187-y

    Article  MathSciNet  MATH  Google Scholar 

  11. Dasgupta, D., Michalewicz, Z.: Evolutionary Algorithms in Engineering Applications, 1st edn. Springer, Secaucus (1997). https://doi.org/10.1007/978-3-662-03423-1

    Book  MATH  Google Scholar 

  12. Diaconis, P.: Group Representations in Probability and Statistics, vol. 11. Institute of Mathematical Statistics (1998). http://www.jstor.org/stable/4355560

  13. Diaconis, P., Graham, R.L.: Spearman’s footrule as a measure of disarray. J. R. Stat. Soc. Ser. B (Methodol.) 39(2), 262–268 (1977). http://www.jstor.org/stable/2984804

  14. Doerr, B., Happ, E.: Directed trees: a powerful representation for sorting and ordering problems. In: Proceedings of the IEEE Congress on Evolutionary Computation, CEC 2008, June 1–6, 2008, Hong Kong, China, pp. 3606–3613. IEEE (2008). https://doi.org/10.1109/CEC.2008.4631286

  15. Droste, S.: Analysis of the (1\(+\)1) EA for a noisy OneMax. In: Deb, K., Poli, R., Banzhaf, W., Beyer, H., Burke, E.K., Darwen, P.J., Dasgupta, D., Floreano, D., Foster, J.A., Harman, M., Holland, O., Lanzi, P.L., Spector, L., Tettamanzi, A., Thierens, D., Tyrrell, A.M. (eds.) Genetic and Evolutionary Computation—GECCO 2004, Genetic and Evolutionary Computation Conference, Seattle, WA, USA, June 26–30, 2004, Proceedings, Part I, Lecture Notes in Computer Science, vol. 3102, pp. 1088–1099. Springer (2004). https://doi.org/10.1007/978-3-540-24854-5_107

  16. Friedrich, T., Kötzing, T., Krejca, M.S., Sutton, A.M.: The compact genetic algorithm is efficient under extreme gaussian noise. IEEE Trans. Evol. Comput. 21(3), 477–490 (2017). https://doi.org/10.1109/TEVC.2016.2613739

    Google Scholar 

  17. Gavenciak, T., Geissmann, B., Lengler, J.: Sorting by swaps with noisy comparisons. In: Proceedings of the Genetic and Evolutionary Computation Conference, GECCO 2017, Berlin, Germany, July 15–19, 2017, pp. 1375–1382 (2017). https://doi.org/10.1145/3071178.3071242

  18. Geissmann, B., Penna, P.: Sort well with energy-constrained comparisons. ArXiv e-prints (2016). arxiv:1610.09223

  19. Giesen, J., Schuberth, E., Stojaković, M.: Approximate sorting. Fundam. Inform. 90(1–2), 67–72 (2009). https://doi.org/10.3233/FI-2009-0005

    MathSciNet  MATH  Google Scholar 

  20. Gießen, C., Kötzing, T.: Robustness of populations in stochastic environments. Algorithmica 75(3), 462–489 (2016). https://doi.org/10.1007/s00453-015-0072-0

    Article  MathSciNet  MATH  Google Scholar 

  21. Graham, R.L., Knuth, D.E., Patashnik, O.: Concrete Mathematics: A Foundation for Computer Science, 2nd edn. Addison-Wesley Professional, Reading (1994)

    MATH  Google Scholar 

  22. Hadjicostas, P., Monico, C.: A new inequality related to the Diaconis-Graham inequalities and a new characterisation of the dihedral group. Australas. J. Comb. 63(2), 226–245 (2015). https://ajc.maths.uq.edu.au/pdf/63/ajc_v63_p226.pdf

  23. Jansen, T.: Analyzing Evolutionary Algorithms—The Computer Science Perspective. Natural Computing Series. Springer Science & Business Media (2013). https://doi.org/10.1007/978-3-642-17339-4

  24. Kelly, F.: Reversibility and stochastic networks. Wiley Series in Probability and Mathematical Statistics: Tracts on Probability and Statistics. Wiley (1979). http://www.statslab.cam.ac.uk/~frank/BOOKS/kelly_book.html

  25. Kötzing, T., Lissovoi, A., Witt, C.: (1\(+\)1) EA on generalized dynamic OneMax. In: Proceedings of the 2015 ACM Conference on Foundations of Genetic Algorithms XIII, Aberystwyth, United Kingdom, January 17–20, 2015, pp. 40–51 (2015). https://doi.org/10.1145/2725494.2725502

  26. Levin, D., Peres, Y.: Markov Chains and Mixing Times, 2nd edn. MBK. American Mathematical Society (2017). http://pages.uoregon.edu/dlevin/MARKOV/mcmt2e.pdf

  27. Liu, J., St-Pierre, D.L., Teytaud, O.: A mathematically derived number of resamplings for noisy optimization. In: Proceedings of the Companion Publication of the 2014 Annual Conference on Genetic and Evolutionary Computation, GECCO Comp ’14, pp. 61–62. ACM, New York, NY, USA (2014). https://doi.org/10.1145/2598394.2598458

  28. Ma, Y.: Fault-tolerant sorting networks. Ph.D. thesis, Massachusetts Institute of Technology (1994). http://hdl.handle.net/1721.1/28131

  29. Merelo, J., Chelly, Z., Mora, A., Fernández-Ares, A., Esparcia-Alcázar, A.I., Cotta, C., de las Cuevas, P., Rico, N.: A statistical approach to dealing with noisy fitness in evolutionary algorithms. In: Computational Intelligence: International Joint Conference, IJCCI 2014 Rome, Italy, October 22–24, 2014 Revised Selected Papers, pp. 79–95. Springer (2016). https://doi.org/10.1007/978-3-319-26393-9_6

  30. Mitchell, L.H.: Maximal total absolute displacement of a permutation. Discrete Math 274(1–3), 319–321 (2004). https://doi.org/10.1016/S0012-365X(03)00205-X

    Article  MathSciNet  MATH  Google Scholar 

  31. Neumann, F., Witt, C.: Bioinspired Comptation in Combinatorial Optimization: Algorithms and Their Computational Complexity, 1st edn. Springer, New York (2010). https://doi.org/10.1007/978-3-642-16544-3

  32. Nix, A.E., Vose, M.D.: Modeling genetic algorithms with markov chains. Ann. Math. Artif. Intell. 5(1), 77–88 (1992). https://doi.org/10.1007/BF01530781

    Article  MathSciNet  MATH  Google Scholar 

  33. Qian, C., Yu, Y., Jin, Y., Zhou, Z.: On the effectiveness of sampling for evolutionary optimization in noisy environments.8672, 302–311 (2014). https://doi.org/10.1007/978-3-319-10762-2_30

  34. Qian, C., Yu, Y., Zhou, Z.H.: Analyzing evolutionary optimization in noisy environments. Evol. Comput. (2015). https://doi.org/10.1162/EVCO_a_00170

  35. Rakshit, P., Konar, A., Das, S.: Noisy evolutionary optimization algorithms—a comprehensive survey. Swarm Evol. Comput. 33, 18–45 (2017). https://doi.org/10.1016/j.swevo.2016.09.002

    Article  Google Scholar 

  36. Safe, M.D., Carballido, J.A., Ponzoni, I., Brignole, N.B.: On stopping criteria for genetic algorithms. In: Advances in Artificial Intelligence—SBIA 2004, 17th Brazilian Symposium on Artificial Intelligence, São Luis, Maranhão, Brazil, September 29—October 1, 2004, Proceedings, pp. 405–413 (2004). https://doi.org/10.1007/978-3-540-28645-5_41

  37. Scharnow, J., Tinnefeld, K., Wegener, I.: The analysis of evolutionary algorithms on sorting and shortest paths problems. J. Math. Model. Algorithms 3(4), 349–366 (2004). https://doi.org/10.1007/s10852-005-2584-0

    Article  MathSciNet  MATH  Google Scholar 

  38. Spitzer, F.: Interaction of markov processes. Adv. Math. 5(2), 246–290 (1970). https://doi.org/10.1016/0001-8708(70)90034-4

    Article  MathSciNet  MATH  Google Scholar 

  39. Tracy, C.A., Widom, H.: Asymptotics in asep with step initial condition. Commun. Math. Phys. 290(1), 129–154 (2009). https://doi.org/10.1007/s00220-009-0761-0

    Article  MathSciNet  MATH  Google Scholar 

Download references

Acknowledgements

We would like to thank all the anonymous reviewers for their careful and attentive reading, as well as their numerous helpful comments to improve this paper. Tomáš Gavenčiak was supported by the Czech Science Foundation (GAČR) Project 17-10090Y “Network optimization”. Barbara Geissmann was supported by the Swiss National Science Foundation (SNSF), Project Number 200021_165524.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Johannes Lengler.

Additional information

An extended abstract of this paper has been presented at Genetic and Evolutionary Computation Conference (GECCO 2017).

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Gavenčiak, T., Geissmann, B. & Lengler, J. Sorting by Swaps with Noisy Comparisons. Algorithmica 81, 796–827 (2019). https://doi.org/10.1007/s00453-018-0429-2

Download citation

  • Received:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s00453-018-0429-2

Keywords

Navigation