{"id":311681,"date":"2020-10-19T15:00:27","date_gmt":"2020-10-19T15:00:27","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=311681"},"modified":"-0001-11-30T00:00:00","modified_gmt":"2020-10-19T15:00:27","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=311681","title":{"rendered":"\u041a\u0432\u0430\u043d\u0442\u043e\u0432\u043e\u0435 \u043c\u0430\u0448\u0438\u043d\u043d\u043e\u0435 \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u0435: \u0437\u043d\u0430\u043a\u043e\u043c\u0438\u043c\u0441\u044f \u0441 Tensorflow Quantum"},"content":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\" data-io-article-url=\"https:\/\/habr.com\/ru\/company\/raiffeisenbank\/blog\/523932\/\">\n<p>\u041d\u0430 \u0425\u0430\u0431\u0440\u0435 \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u043d\u0435\u0442 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043f\u0440\u043e \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u043e\u0435 \u043c\u0430\u0448\u0438\u043d\u043d\u043e\u0435 \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u0435 (<strong>Q<\/strong>uantum <strong>M<\/strong>achine <strong>L<\/strong>earning), \u0438 \u0432 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u044f \u043f\u043e\u0441\u0442\u0430\u0440\u0430\u044e\u0441\u044c \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435 \u0440\u0430\u0441\u043a\u0440\u044b\u0442\u044c \u0442\u0435\u043c\u0443. \u0421\u0440\u0430\u0437\u0443 \u0441\u043a\u0430\u0436\u0443, \u0447\u0442\u043e \u043f\u0440\u043e\u043c\u044b\u0448\u043b\u0435\u043d\u043d\u044b\u0445 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0445 \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u043e\u0432 \u0441\u0435\u0433\u043e\u0434\u043d\u044f \u043d\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442, \u0432\u0441\u0435 \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0438 \u0432 \u044d\u0442\u043e\u0439 \u043e\u0431\u043b\u0430\u0441\u0442\u0438 \u043d\u043e\u0441\u044f\u0442 \u0442\u0435\u043e\u0440\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u0445\u0430\u0440\u0430\u043a\u0442\u0435\u0440, \u0430 \u0437\u0430\u0434\u0430\u0447\u0443, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0440\u0430\u0437\u0431\u0438\u0440\u0430\u0442\u044c \u0432 \u0441\u0442\u0430\u0442\u044c\u0435 \u043c\u043e\u0436\u043d\u043e \u0440\u0435\u0448\u0438\u0442\u044c \u00ab\u043f\u043e \u043a\u043b\u0430\u0441\u0441\u0438\u043a\u0435\u00bb \u0437\u0430 \u0434\u043e\u043b\u0438 \u0441\u0435\u043a\u0443\u043d\u0434. \u041d\u043e \u0432\u0435\u0434\u044c \u0435\u0449\u0435 30 \u043b\u0435\u0442 \u043d\u0430\u0437\u0430\u0434 \u0431\u044b\u043b\u0430 \u0442\u0430\u043a \u043d\u0430\u0437\u044b\u0432\u0430\u0435\u043c\u0430\u044f <a href=\"https:\/\/en.wikipedia.org\/wiki\/AI_winter\">\u00ab\u0437\u0438\u043c\u0430 \u0438\u0441\u043a\u0443\u0441\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0433\u043e \u0438\u043d\u0442\u0435\u043b\u043b\u0435\u043a\u0442\u0430\u00bb<\/a>, \u0430 \u0441\u0435\u0433\u043e\u0434\u043d\u044f \u043d\u0435\u0439\u0440\u043e\u043d\u043d\u044b\u0435 \u0441\u0435\u0442\u0438 \u0431\u0443\u043a\u0432\u0430\u043b\u044c\u043d\u043e \u043e\u043a\u0440\u0443\u0436\u0430\u044e\u0442 \u043d\u0430\u0441. \u041a\u0442\u043e \u0437\u043d\u0430\u0435\u0442, \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0432\u0441\u043a\u043e\u0440\u0435 \u0438 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0435 \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u044b \u0441\u0442\u0430\u043d\u0443\u0442 \u043d\u0435\u043e\u0442\u044a\u0435\u043c\u043b\u0435\u043c\u043e\u0439 \u0447\u0430\u0441\u0442\u044c\u044e \u043d\u0430\u0448\u0435\u0439 \u0436\u0438\u0437\u043d\u0438? \u041a \u0442\u043e\u043c\u0443 \u0436\u0435 \u043e\u0431\u043b\u0430\u0441\u0442\u044c \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0445 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u0439, \u0430 \u0442\u0435\u043c \u0431\u043e\u043b\u0435\u0435 \u043e\u0431\u043b\u0430\u0441\u0442\u044c <strong>QML<\/strong>, \u043e\u0431\u043b\u0430\u0434\u0430\u0435\u0442 \u043e\u0441\u043e\u0431\u043e\u0439 \u043f\u0440\u0438\u0442\u044f\u0433\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c\u044e \u0438 \u0442\u0430\u0438\u043d\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0441\u0442\u044c\u044e \u0438, \u043a\u0430\u043a \u043c\u0438\u043d\u0438\u043c\u0443\u043c, \u0441\u0442\u043e\u0438\u0442 \u0431\u044b\u0442\u044c \u0437\u0430\u043c\u0435\u0447\u0435\u043d\u043d\u043e\u0439.<\/p>\n<p>  <\/p>\n<p><a href=\"https:\/\/habr.com\/ru\/company\/raiffeisenbank\/blog\/523932\/\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/rd\/kz\/wt\/rdkzwt7op3gw_boistlpqrjfl3u.jpeg\" alt=\"Head image\"><\/a><\/p>\n<p>  <\/p>\n<p>\u0412 \u0441\u0442\u0430\u0442\u044c\u0435 \u044f \u043f\u043e\u0441\u0442\u0430\u0440\u0430\u043b\u0441\u044f \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u0430\u0442\u044c \u043e <strong>QML<\/strong> \u0432 \u0446\u0435\u043b\u043e\u043c, \u0430 \u0442\u0430\u043a\u0436\u0435 \u043e\u0431 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c \u0441\u0442\u0440\u043e\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u043c \u0431\u043b\u043e\u043a\u0435 <strong>QML<\/strong> \u2014 <strong>V<\/strong>ariational <strong>Q<\/strong>uantum <strong>C<\/strong>ircuit. \u0411\u043e\u043b\u044c\u0448\u0443\u044e \u0447\u0430\u0441\u0442\u044c \u0441\u0442\u0430\u0442\u044c\u0438 \u044f \u043f\u043e\u0441\u0442\u0430\u0440\u0430\u043b\u0441\u044f \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0439, c \u043f\u0440\u0438\u043c\u0435\u0440\u0430\u043c\u0438 \u043a\u043e\u0434\u0430 \u043d\u0430 <a href=\"https:\/\/github.com\/quantumlib\/Cirq\"><em>Cirq<\/em><\/a>, \u0430 \u0432 \u043a\u043e\u043d\u0446\u0435 \u2014 \u0434\u043e\u0431\u0430\u0432\u0438\u043b \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e \u043e\u0434\u043d\u043e\u0433\u043e \u0438\u0437 \u0431\u0430\u0437\u043e\u0432\u044b\u0445 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u043e\u0432 <strong>QML<\/strong> \u043d\u0430 <a href=\"https:\/\/www.tensorflow.org\/quantum\"><em>Tensorflow Quantum<\/em><\/a>.<\/p>\n<p><a name=\"habracut\"><\/a>  <\/p>\n<h2 id=\"vvedenie\">\u0412\u0432\u0435\u0434\u0435\u043d\u0438\u0435<\/h2>\n<p>  <\/p>\n<p>\u0413\u0438\u043f\u043e\u0442\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0438 <strong>QML<\/strong> \u0438\u043c\u0435\u0435\u0442 \u0440\u044f\u0434 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0445 \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432, \u043f\u043e \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044e \u0441 \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0438\u043c \u043c\u0430\u0448\u0438\u043d\u043d\u044b\u043c \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u0435\u043c. <strong>V<\/strong>ariational <strong>Q<\/strong>uantum <strong>C<\/strong>ircuit, \u0438\u043b\u0438 <strong>VQC<\/strong>, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u043e\u0436\u043d\u043e \u043d\u0430\u0437\u0432\u0430\u0442\u044c \u00ab\u0430\u043d\u0430\u043b\u043e\u0433\u043e\u043c\u00bb \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u043f\u043e\u043b\u043d\u043e\u0441\u0432\u044f\u0437\u043d\u044b\u0445 \u0441\u043b\u043e\u0435\u0432 \u0432 \u043e\u0431\u044b\u0447\u043d\u044b\u0445 \u043d\u0435\u0439\u0440\u043e\u043d\u043d\u044b\u0445 \u0441\u0435\u0442\u044f\u0445, \u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u0431\u043e\u043b\u0435\u0435 \u00ab\u0432\u044b\u0440\u0430\u0437\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u043c\u0438\u00bb \u0438 \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442 \u043c\u0435\u043d\u044c\u0448\u0435 \u043e\u0431\u0443\u0447\u0430\u0435\u043c\u044b\u0445 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432. \u0420\u044f\u0434 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0445 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u043e\u0432 \u043f\u043e\u0442\u0435\u043d\u0446\u0438\u0430\u043b\u044c\u043d\u043e \u0442\u0430\u043a\u0436\u0435 \u0434\u0430\u0435\u0442 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u0443\u0441\u043a\u043e\u0440\u0435\u043d\u0438\u0435 \u043f\u043e \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044e \u0441 \u043e\u0431\u044b\u0447\u043d\u044b\u043c\u0438 \u0430\u043d\u0430\u043b\u043e\u0433\u0430\u043c\u0438:<\/p>\n<p>  <\/p>\n<div class=\"scrollable-table\">\n<table>\n<thead>\n<tr>\n<th>\u041c\u0435\u0442\u043e\u0434<\/th>\n<th>\u0423\u0441\u043a\u043e\u0440\u0435\u043d\u0438\u0435<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>Bayesian Inference<\/td>\n<td><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/4bf\/5b9\/aa3\/4bf5b9aa3cf274a87683c5290c902a97.svg\" alt=\"$O(\\sqrt{N})$\" data-tex=\"inline\"><\/math><\/td>\n<\/tr>\n<tr>\n<td>Online Perceptron<\/td>\n<td><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/4bf\/5b9\/aa3\/4bf5b9aa3cf274a87683c5290c902a97.svg\" alt=\"$O(\\sqrt{N})$\" data-tex=\"inline\"><\/math><\/td>\n<\/tr>\n<tr>\n<td>Least Square Fitting<\/td>\n<td><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/f37\/25b\/445\/f3725b445f8f4cd5a193853848c1367e.svg\" alt=\"$O(\\log(N))$\" data-tex=\"inline\"><\/math><\/td>\n<\/tr>\n<tr>\n<td>Classical Boltzman Machine<\/td>\n<td><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/4bf\/5b9\/aa3\/4bf5b9aa3cf274a87683c5290c902a97.svg\" alt=\"$O(\\sqrt{N})$\" data-tex=\"inline\"><\/math><\/td>\n<\/tr>\n<tr>\n<td>Quantum Boltzman Machine<\/td>\n<td><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/f37\/25b\/445\/f3725b445f8f4cd5a193853848c1367e.svg\" alt=\"$O(\\log(N))$\" data-tex=\"inline\"><\/math><\/td>\n<\/tr>\n<tr>\n<td>Quantum PCA<\/td>\n<td><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/f37\/25b\/445\/f3725b445f8f4cd5a193853848c1367e.svg\" alt=\"$O(\\log(N))$\" data-tex=\"inline\"><\/math><\/td>\n<\/tr>\n<tr>\n<td>Quantum SVM<\/td>\n<td><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/f37\/25b\/445\/f3725b445f8f4cd5a193853848c1367e.svg\" alt=\"$O(\\log(N))$\" data-tex=\"inline\"><\/math><\/td>\n<\/tr>\n<tr>\n<td>Quantum RL<\/td>\n<td><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/4bf\/5b9\/aa3\/4bf5b9aa3cf274a87683c5290c902a97.svg\" alt=\"$O(\\sqrt{N})$\" data-tex=\"inline\"><\/math><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u043d\u0430\u0438\u0431\u043e\u043b\u0435\u0435 \u043f\u043e\u043b\u043d\u043e\u0433\u043e \u043e\u0437\u043d\u0430\u043a\u043e\u043c\u043b\u0435\u043d\u0438\u044f \u0441 \u0442\u0435\u043c\u043e\u0439 \u044f \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u044e \u043e\u0431\u0437\u043e\u0440 2017-\u0433\u043e \u0433\u043e\u0434\u0430 \u0432 \u0436\u0443\u0440\u043d\u0430\u043b\u0435 <a href=\"https:\/\/www.nature.com\/articles\/nature23474\">Nature<\/a> \u0438\u043b\u0438 \u043f\u0440\u0435\u043f\u0440\u0438\u043d\u0442 \u0442\u043e\u0439 \u0436\u0435 \u0440\u0430\u0431\u043e\u0442\u044b \u0432 <a href=\"https:\/\/arxiv.org\/pdf\/1611.09347\">arXiv<\/a>. \u0418\u043c\u0435\u043d\u043d\u043e \u0438\u0437 \u044d\u0442\u043e\u0439 \u0440\u0430\u0431\u043e\u0442\u044b \u044f \u0432\u0437\u044f\u043b \u0434\u0430\u043d\u043d\u0443\u044e \u0442\u0430\u0431\u043b\u0438\u0446\u0443. \u0412 \u043d\u0435\u0439 \u0443\u043a\u0430\u0437\u0430\u043d\u043e \u0443\u0441\u043a\u043e\u0440\u0435\u043d\u0438\u0435 \u043f\u043e \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044e \u0441 \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0438\u043c \u0430\u043d\u0430\u043b\u043e\u0433\u043e\u043c. \u0422\u0430\u043a, <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/4bf\/5b9\/aa3\/4bf5b9aa3cf274a87683c5290c902a97.svg\" alt=\"$O(\\sqrt{N})$\" data-tex=\"inline\"><\/math> \u043f\u043e\u0434\u0440\u0430\u0437\u0443\u043c\u0435\u0432\u0430\u0435\u0442, \u0447\u0442\u043e \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0439 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c \u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u043d\u043e \u0431\u044b\u0441\u0442\u0440\u0435\u0435, \u0447\u0435\u043c \u0435\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u0430\u043d\u0430\u043b\u043e\u0433, \u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/f37\/25b\/445\/f3725b445f8f4cd5a193853848c1367e.svg\" alt=\"$O(\\log(N))$\" data-tex=\"inline\"><\/math> \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442 \u044d\u043a\u0441\u043f\u043e\u043d\u0435\u043d\u0446\u0438\u0430\u043b\u044c\u043d\u043e\u0435 \u0443\u0441\u043a\u043e\u0440\u0435\u043d\u0438\u0435.<\/p>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">\u041c\u0430\u043b\u0435\u043d\u044c\u043a\u0430\u044f \u0440\u0435\u043c\u0430\u0440\u043a\u0430 \u043f\u0440\u043e \u0414\u0438\u0440\u0430\u043a\u043e\u0432\u0441\u043a\u0443\u044e \u043d\u043e\u0442\u0430\u0446\u0438\u044e<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<p>\u042f \u043f\u043e\u0441\u0442\u0430\u0440\u0430\u043b\u0441\u044f \u043f\u0438\u0441\u0430\u0442\u044c \u044d\u0442\u0443 \u0441\u0442\u0430\u0442\u044c\u044e \u0441 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u043c \u0447\u0438\u0441\u043b\u043e\u043c \u0444\u043e\u0440\u043c\u0443\u043b, \u043d\u043e \u0432\u0441\u0435 \u0436\u0435 \u0441\u043e\u0432\u0441\u0435\u043c \u0431\u0435\u0437 \u043d\u0438\u0445 \u043d\u0435\u043b\u044c\u0437\u044f. \u0422\u0430\u043a\u0436\u0435 \u0432 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0445 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f\u0445 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0441\u0432\u043e\u044f \u043d\u043e\u0442\u0430\u0446\u0438\u044f \u043b\u0438\u043d\u0435\u0439\u043d\u043e\u0439 \u0430\u043b\u0433\u0435\u0431\u0440\u044b. \u0421\u043b\u043e\u0436\u043d\u043e \u0441\u043a\u0430\u0437\u0430\u0442\u044c, \u0445\u043e\u0440\u043e\u0448\u043e \u044d\u0442\u043e \u0438\u043b\u0438 \u043f\u043b\u043e\u0445\u043e, \u043d\u043e \u044f \u0431\u0443\u0434\u0443 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0438\u043c\u0435\u043d\u043d\u043e \u0414\u0438\u0440\u0430\u043a\u043e\u0432\u0441\u043a\u0443\u044e \u043d\u043e\u0442\u0430\u0446\u0438\u044e, \u0442\u0430\u043a \u043a\u0430\u043a \u0432\u043e \u0432\u0441\u0435\u0445 \u0434\u0440\u0443\u0433\u0438\u0445 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u0430\u0445 \u0438 \u043d\u0430\u0443\u0447\u043d\u044b\u0445 \u0440\u0430\u0431\u043e\u0442\u0430\u0445 \u0431\u0443\u0434\u0435\u0442 \u0438\u043c\u0435\u043d\u043d\u043e \u043e\u043d\u0430, \u2014 \u043b\u0443\u0447\u0448\u0435 \u043f\u0440\u0438\u0432\u044b\u043a\u0430\u0442\u044c \u043a \u043d\u0435\u0439 \u0441 \u0441\u0430\u043c\u043e\u0433\u043e \u043d\u0430\u0447\u0430\u043b\u0430. \u0421\u0440\u0430\u0437\u0443 \u0441\u043a\u0430\u0436\u0443, \u0447\u0442\u043e \u043d\u0438\u0447\u0435\u0433\u043e \u0441\u0442\u0440\u0430\u0448\u043d\u043e\u0433\u043e \u0432 \u0441\u0442\u0430\u0442\u044c\u0435 \u043d\u0435 \u0431\u0443\u0434\u0435\u0442, \u0438 \u0432\u0441\u0435 \u0444\u043e\u0440\u043c\u0443\u043b\u044b \u044f \u0431\u0443\u0434\u0443 \u043f\u044b\u0442\u0430\u0442\u044c\u0441\u044f \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u043e \u043f\u043e\u044f\u0441\u043d\u044f\u0442\u044c \u0441\u043b\u043e\u0432\u0430\u043c\u0438.<\/p>\n<p>  <\/p>\n<ul>\n<li>\u0412\u0435\u043a\u0442\u043e\u0440 \u0441\u0442\u043e\u043b\u0431\u0435\u0446 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/250\/3e6\/139\/2503e6139f4673206ed3da940239a70d.svg\" alt=\"$\\vec{\\Psi} := \\left | \\Psi \\right &gt;$\" data-tex=\"inline\"><\/math><\/li>\n<li>\u0412\u0435\u043a\u0442\u043e\u0440 \u0441\u0442\u0440\u043e\u043a\u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/681\/8c7\/465\/6818c7465ae9c90f38e49ccad111d901.svg\" alt=\"$\\vec{\\Psi}^T := \\left &lt; \\Psi \\right |$\" data-tex=\"inline\"><\/math><\/li>\n<li>\u0421\u043a\u0430\u043b\u044f\u0440\u043d\u043e\u0435 \u043f\u0440\u043e\u0438\u0437\u0432\u0435\u0434\u0435\u043d\u0438\u0435 \u044d\u0442\u043e <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/8c6\/114\/1fe\/8c61141fed2b33d0232faf3b9a3ad9a5.svg\" alt=\"$\\vec{\\Psi}^T\\cdot\\vec{\\Phi} := \\left &lt; \\Psi \\Phi \\right &gt;$\" data-tex=\"inline\"><\/math><\/li>\n<li>\u0423\u043c\u043d\u043e\u0436\u0435\u043d\u0438\u0435 \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u043d\u0430 \u0432\u0435\u043a\u0442\u043e\u0440 \u0438\u043b\u0438 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 \u043d\u0430 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/698\/c40\/e2e\/698c40e2e389cf7e43bdf176eb5caab0.svg\" alt=\"$ \\mathbf{H}\\cdot \\vec{\\Psi} := \\hat{\\mathbf{H}}\\left | \\Psi \\right &gt;$\" data-tex=\"inline\"><\/math><\/li>\n<li>\u041e\u0436\u0438\u0434\u0430\u0435\u043c\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 \u0432 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/434\/c58\/8fa\/434c588fa590022950a1bf8ae486cb70.svg\" alt=\"$\\vec{\\Psi}^T\\cdot\\mathbf{H}\\cdot\\vec{\\Psi} := \\left &lt; \\Psi \\right | \\hat{\\mathbf{H}} \\left | \\Psi \\right &gt; $\" data-tex=\"inline\"><\/math><\/li>\n<\/ul>\n<\/div><\/div>\n<p>  <\/p>\n<h2 id=\"osnova-qml\">\u041e\u0441\u043d\u043e\u0432\u0430 QML<\/h2>\n<p>  <\/p>\n<p>\u041a\u0430\u043a \u044f \u0443\u0436\u0435 \u0433\u043e\u0432\u043e\u0440\u0438\u043b, \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u00ab\u0441\u0442\u0440\u043e\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u0431\u043b\u043e\u043a\u00bb \u0432 <strong>QML<\/strong> \u2014 \u044d\u0442\u043e <strong>V<\/strong>ariational <strong>Q<\/strong>uantum <strong>C<\/strong>ircuit. \u0418\u0445 \u043c\u044b \u0434\u0435\u0442\u0430\u043b\u044c\u043d\u043e \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0447\u0443\u0442\u044c \u043f\u043e\u0437\u0436\u0435, \u043d\u043e \u0432 \u0446\u0435\u043b\u043e\u043c \u043b\u044e\u0431\u0430\u044f \u0441\u0442\u0430\u0442\u044c\u044f \u0438\u043b\u0438 \u043b\u044e\u0431\u043e\u0439 \u043d\u043e\u0432\u044b\u0439 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c \u043f\u043e <strong>QML<\/strong> \u0431\u0443\u0434\u0435\u0442 \u0442\u0430\u043a \u0438\u043b\u0438 \u0438\u043d\u0430\u0447\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442\u044c \u043d\u0430\u0431\u043e\u0440 <strong>VQC<\/strong> \u0438\u043b\u0438 \u0438\u0445 \u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439. \u0422\u0430\u043a\u0438\u0435 \u0431\u043b\u043e\u043a\u0438 \u043d\u0435 \u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u0447\u0438\u0441\u0442\u043e \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u043c\u0438 \u0441\u0445\u0435\u043c\u0430\u043c\u0438, \u0438 \u0432 \u044d\u0442\u043e\u043c \u043e\u043d\u0438 \u0441\u0438\u043b\u044c\u043d\u043e \u043e\u0442\u043b\u0438\u0447\u0430\u044e\u0442\u0441\u044f, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043e\u0442 \u0448\u0438\u0440\u043e\u043a\u043e \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b\u0445 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0445 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u043e\u0432 \u0428\u043e\u0440\u0430 \u0438\u043b\u0438 \u0413\u0440\u043e\u0432\u0435\u0440\u0430. \u0412 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c <strong>QML<\/strong> \u0441\u0442\u0440\u043e\u0438\u0442\u0441\u044f \u043f\u043e \u00ab\u0433\u0438\u0431\u0440\u0438\u0434\u043d\u043e\u0439\u00bb \u0441\u0445\u0435\u043c\u0435, \u043a\u043e\u0433\u0434\u0430 \u0443 \u043d\u0430\u0441 \u0435\u0441\u0442\u044c \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0435 \u0441\u0445\u0435\u043c\u044b, \u0442\u0430\u043a\u0438\u0435 \u043a\u0430\u043a <strong>VQC<\/strong>, \u0438 \u043e\u043d\u0438 \u0441\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u044e\u0442 \u0441\u043e\u0431\u043e\u0439 \u00ab\u043a\u0432\u0430\u043d\u0442\u043e\u0432\u0443\u044e\u00bb \u0447\u0430\u0441\u0442\u044c. \u00ab\u041a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0430\u044f\u00bb \u0447\u0430\u0441\u0442\u044c \u043e\u0431\u044b\u0447\u043d\u043e \u043e\u0442\u0432\u0435\u0447\u0430\u0435\u0442 \u0437\u0430 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0446\u0438\u044e \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0445 \u0441\u0445\u0435\u043c, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0433\u0440\u0430\u0434\u0438\u0435\u043d\u0442\u043d\u044b\u043c\u0438 \u043c\u0435\u0442\u043e\u0434\u0430\u043c\u0438, \u0442\u0430\u043a, \u0447\u0442\u043e\u0431\u044b <strong>VQC<\/strong>, \u043f\u043e\u0434\u043e\u0431\u043d\u043e \u0441\u043b\u043e\u044f\u043c \u043d\u0435\u0439\u0440\u043e\u043d\u043d\u044b\u0445 \u0441\u0435\u0442\u0435\u0439, \u00ab\u0432\u044b\u0443\u0447\u0438\u0432\u0430\u043b\u0438\u00bb \u043d\u0443\u0436\u043d\u044b\u0435 \u043d\u0430\u043c \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0432\u0445\u043e\u0434\u043d\u044b\u0445 \u0434\u0430\u043d\u043d\u044b\u0445. \u0418\u043c\u0435\u043d\u043d\u043e \u0442\u0430\u043a \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u0430 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 <em>Tensorflow Quantum<\/em>, \u0433\u0434\u0435 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0435 \u00ab\u0441\u043b\u043e\u0438\u00bb \u0441\u043e\u0447\u0435\u0442\u0430\u044e\u0442\u0441\u044f \u0441 \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0438\u043c\u0438, \u0430 \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u0435 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u043a\u0430\u043a \u0432 \u043e\u0431\u044b\u0447\u043d\u044b\u0445 \u043d\u0435\u0439\u0440\u043e\u043d\u043d\u044b\u0445 \u0441\u0435\u0442\u044f\u0445.<\/p>\n<p>  <\/p>\n<h2 id=\"variational-quantum-circuit\">Variational Quantum Circuit<\/h2>\n<p>  <\/p>\n<p><strong>VQC<\/strong> \u2014 \u044d\u0442\u043e \u043f\u0440\u043e\u0441\u0442\u0435\u0439\u0448\u0438\u0439 \u044d\u043b\u0435\u043c\u0435\u043d\u0442 \u0441\u0438\u0441\u0442\u0435\u043c \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u043e-\u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u044f. \u0412 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u043c \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0435 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0441\u043e\u0431\u043e\u0439 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u0443\u044e \u0441\u0445\u0435\u043c\u0443, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043a\u043e\u0434\u0438\u0440\u0443\u0435\u0442 \u0432\u0445\u043e\u0434\u043d\u044b\u043c \u0432\u0435\u043a\u0442\u043e\u0440\u043e\u043c \u0434\u0430\u043d\u043d\u044b\u0445 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/d21\/b28\/d4c\/d21b28d4c63ebec4752c55fecef80b52.svg\" alt=\"$\\vec{X}$\" data-tex=\"inline\"><\/math> \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u043e\u0435 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/8fe\/2d1\/95d\/8fe2d195de16ae766f518a330c4db8b1.svg\" alt=\"$\\left | {\\Psi} \\right &gt;$\" data-tex=\"inline\"><\/math> \u0438 \u0434\u0430\u043b\u0435\u0435 \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0435\u0442 \u043a \u044d\u0442\u043e\u043c\u0443 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044e \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430\u043c\u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/ff2\/c64\/99d\/ff2c6499d038a61a41d7ce75cd78788f.svg\" alt=\"$\\theta$\" data-tex=\"inline\"><\/math> \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u044b. \u0415\u0441\u043b\u0438 \u043f\u0440\u043e\u0432\u043e\u0434\u0438\u0442\u044c \u0430\u043d\u0430\u043b\u043e\u0433\u0438\u044e \u0441 \u043e\u0431\u044b\u0447\u043d\u044b\u043c\u0438 \u043d\u0435\u0439\u0440\u043e\u043d\u043d\u044b\u043c\u0438 \u0441\u0435\u0442\u044f\u043c\u0438, \u0442\u043e \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0441\u0435\u0431\u0435 <strong>VQC<\/strong> \u043a\u0430\u043a \u043d\u0435\u043a\u0438\u0439 \u00ab\u0447\u0435\u0440\u043d\u044b\u0439 \u044f\u0449\u0438\u043a\u00bb, \u0438\u043b\u0438 \u00ab\u0441\u043b\u043e\u0439\u00bb, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u0432\u0445\u043e\u0434\u043d\u044b\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/d21\/b28\/d4c\/d21b28d4c63ebec4752c55fecef80b52.svg\" alt=\"$\\vec{X}$\" data-tex=\"inline\"><\/math> \u0432 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043e\u0442 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/ff2\/c64\/99d\/ff2c6499d038a61a41d7ce75cd78788f.svg\" alt=\"$\\theta$\" data-tex=\"inline\"><\/math>. \u0418 \u0442\u043e\u0433\u0434\u0430, \u043c\u043e\u0436\u043d\u043e \u0441\u043a\u0430\u0437\u0430\u0442\u044c, \u0447\u0442\u043e <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/ff2\/c64\/99d\/ff2c6499d038a61a41d7ce75cd78788f.svg\" alt=\"$\\theta$\" data-tex=\"inline\"><\/math> \u2014 \u044d\u0442\u043e \u0430\u043d\u0430\u043b\u043e\u0433 \u00ab\u0432\u0435\u0441\u043e\u0432\u00bb \u0432 \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u043d\u0435\u0439\u0440\u043e\u043d\u043d\u044b\u0445 \u0441\u0435\u0442\u044f\u0445.<\/p>\n<p>  <\/p>\n<p>\u0412\u043e\u0442 \u0442\u0430\u043a \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043f\u0440\u043e\u0441\u0442\u0435\u0439\u0448\u0430\u044f <strong>VQS<\/strong>, \u0433\u0434\u0435 \u0432\u0435\u043a\u0442\u043e\u0440 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/d21\/b28\/d4c\/d21b28d4c63ebec4752c55fecef80b52.svg\" alt=\"$\\vec{X}$\" data-tex=\"inline\"><\/math> \u043a\u043e\u0434\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u0447\u0435\u0440\u0435\u0437 \u0432\u0440\u0430\u0449\u0435\u043d\u0438\u044f \u043a\u0443\u0431\u0438\u0442\u043e\u0432 \u0432\u043e\u043a\u0440\u0443\u0433 \u043e\u0441\u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/0a0\/e0d\/784\/0a0e0d784e2055ff8c9c5631d8abdb6b.svg\" alt=\"$\\mathbf{Z}$\" data-tex=\"inline\"><\/math>, \u0430 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/ff2\/c64\/99d\/ff2c6499d038a61a41d7ce75cd78788f.svg\" alt=\"$\\theta$\" data-tex=\"inline\"><\/math> \u043a\u043e\u0434\u0438\u0440\u0443\u044e\u0442 \u0432\u0440\u0430\u0449\u0435\u043d\u0438\u044f \u0432\u043e\u043a\u0440\u0443\u0433 \u043e\u0441\u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/31a\/a7d\/07e\/31aa7d07e27cfae0ac76f37150f19fb1.svg\" alt=\"$\\mathbf{Y}$\" data-tex=\"inline\"><\/math>:<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/post_images\/8bf\/d3c\/f8e\/8bfd3cf8e667de3932636cc7bcac462a.png\" alt=\"Simple VQC scheme\"><\/p>\n<p>  <\/p>\n<p>\u0420\u0430\u0437\u0431\u0435\u0440\u0435\u043c \u044d\u0442\u043e\u0442 \u043c\u043e\u043c\u0435\u043d\u0442 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435. \u041c\u044b \u0445\u043e\u0442\u0438\u043c \u0437\u0430\u043a\u043e\u0434\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0432\u0445\u043e\u0434\u043d\u043e\u0439 \u0432\u0435\u043a\u0442\u043e\u0440 \u0434\u0430\u043d\u043d\u044b\u0445 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/d21\/b28\/d4c\/d21b28d4c63ebec4752c55fecef80b52.svg\" alt=\"$\\vec{X}$\" data-tex=\"inline\"><\/math> \u0432 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/8fe\/2d1\/95d\/8fe2d195de16ae766f518a330c4db8b1.svg\" alt=\"$\\left | \\Psi \\right &gt;$\" data-tex=\"inline\"><\/math>, \u043f\u043e \u0441\u0443\u0442\u0438 \u0441\u0432\u043e\u0435\u0439, \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u044e \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0430 \u00ab\u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0438\u0445\u00bb \u0432\u0445\u043e\u0434\u043d\u044b\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0435. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043c\u044b \u0431\u0435\u0440\u0435\u043c <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/1e8\/0c3\/b30\/1e80c3b3087c0a57b68ad11261a9ec2b.svg\" alt=\"$N$\" data-tex=\"inline\"><\/math> \u043a\u0443\u0431\u0438\u0442\u043e\u0432, \u043a\u0430\u0436\u0434\u044b\u0439 \u0438\u0437 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0438\u0441\u0445\u043e\u0434\u043d\u043e \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0432 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/35c\/aba\/a2b\/35cabaa2b95d22377b8a3abb8484b436.svg\" alt=\"$\\left | 0 \\right &gt;$\" data-tex=\"inline\"><\/math>. \u0421\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e\u0433\u043e \u043a\u0443\u0431\u0438\u0442\u0430 \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u043a\u0430\u043a \u0442\u043e\u0447\u043a\u0443 \u043d\u0430 \u043f\u043e\u0432\u0435\u0440\u0445\u043d\u043e\u0441\u0442\u0438 \u0441\u0444\u0435\u0440\u044b \u0411\u043b\u043e\u0445\u0430:<\/p>\n<p>  <\/p>\n<p>\u2003\u2003\u2003\u2003\u2003\u2003\u2003\u2003\u2003\u2003\u2003\u2003\u2003<img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/post_images\/23a\/71d\/7ba\/23a71d7ba67dd6c18e9184dd85a6d429.png\" alt=\"\u0421\u0444\u0435\u0440\u0430 \u0411\u043b\u043e\u0445\u0430\"><\/p>\n<p>  <\/p>\n<p>\u041c\u044b \u043c\u043e\u0436\u0435\u043c \u00ab\u0432\u0440\u0430\u0449\u0430\u0442\u044c\u00bb \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/8fe\/2d1\/95d\/8fe2d195de16ae766f518a330c4db8b1.svg\" alt=\"$\\left | \\Psi \\right &gt;$\" data-tex=\"inline\"><\/math> \u043d\u0430\u0448\u0435\u0433\u043e \u043a\u0443\u0431\u0438\u0442\u0430, \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u044f \u0441\u043f\u0435\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0435 \u043e\u0434\u043d\u043e\u043a\u0443\u0431\u0438\u0442\u043d\u044b\u0435 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0438, \u0442\u0430\u043a \u043d\u0430\u0437\u044b\u0432\u0430\u0435\u043c\u044b\u0435 \u0433\u0435\u0439\u0442\u044b <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/53b\/c83\/ad3\/53bc83ad3a575487b44b4e78f186c7c4.svg\" alt=\"$Rx$\" data-tex=\"inline\"><\/math>, <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/66b\/d8d\/df0\/66bd8ddf02d4605afe4ba48e8bf2299a.svg\" alt=\"$Ry$\" data-tex=\"inline\"><\/math>, <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/5f1\/947\/3f5\/5f19473f5777312499e93c43f1b71e7a.svg\" alt=\"$Rz$\" data-tex=\"inline\"><\/math>, \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u043f\u043e\u0432\u043e\u0440\u043e\u0442\u0430\u043c \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0440\u0430\u0437\u043d\u044b\u0445 \u043e\u0441\u0435\u0439 \u0441\u0444\u0435\u0440\u044b \u0411\u043b\u043e\u0445\u0430. \u041c\u044b \u0431\u0443\u0434\u0435\u043c \u043f\u043e\u0432\u043e\u0440\u0430\u0447\u0438\u0432\u0430\u0442\u044c \u043a\u0430\u0436\u0434\u044b\u0439 \u043a\u0443\u0431\u0438\u0442, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043f\u043e \u043e\u0441\u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/0a0\/e0d\/784\/0a0e0d784e2055ff8c9c5631d8abdb6b.svg\" alt=\"$\\mathbf{Z}$\" data-tex=\"inline\"><\/math> \u043d\u0430 \u0443\u0433\u043e\u043b, \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u043c\u044b\u0439 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0439 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u0439 \u0432\u0445\u043e\u0434\u043d\u043e\u0433\u043e \u0432\u0435\u043a\u0442\u043e\u0440\u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/d21\/b28\/d4c\/d21b28d4c63ebec4752c55fecef80b52.svg\" alt=\"$\\vec{X}$\" data-tex=\"inline\"><\/math>. <\/p>\n<p>  <\/p>\n<p>\u041f\u043e\u043b\u0443\u0447\u0438\u0432 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0439 \u0432\u0445\u043e\u0434\u043d\u043e\u0439 \u0432\u0435\u043a\u0442\u043e\u0440, \u043c\u044b \u0445\u043e\u0442\u0438\u043c \u0442\u0435\u043f\u0435\u0440\u044c \u043f\u0440\u0438\u043c\u0435\u043d\u0438\u0442\u044c \u043a \u043d\u0435\u043c\u0443 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u043e\u0435 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0435. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u00ab\u0432\u0440\u0430\u0449\u0430\u0442\u044c\u00bb \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u043a\u0443\u0431\u0438\u0442\u044b \u0443\u0436\u0435 \u043f\u043e \u0434\u0440\u0443\u0433\u043e\u0439 \u043e\u0441\u0438, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043f\u043e <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/31a\/a7d\/07e\/31aa7d07e27cfae0ac76f37150f19fb1.svg\" alt=\"$\\mathbf{Y}$\" data-tex=\"inline\"><\/math> \u043d\u0430 \u0443\u0433\u043b\u044b, \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u043c\u044b\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430\u043c\u0438 \u0441\u0445\u0435\u043c\u044b <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/ff2\/c64\/99d\/ff2c6499d038a61a41d7ce75cd78788f.svg\" alt=\"$\\theta$\" data-tex=\"inline\"><\/math>. <\/p>\n<p>  <\/p>\n<p>\u042d\u0442\u043e \u043d\u0430\u0438\u0431\u043e\u043b\u0435\u0435 \u043f\u0440\u043e\u0441\u0442\u043e\u0439 \u043f\u0440\u0438\u043c\u0435\u0440 <strong>VQC<\/strong>, \u0438, \u043a\u0430\u043a \u043c\u044b \u0443\u0432\u0438\u0434\u0438\u043c \u0434\u0430\u043b\u044c\u0448\u0435, \u0435\u0441\u0442\u044c \u0431\u043e\u043b\u0435\u0435 \u0441\u043b\u043e\u0436\u043d\u044b\u0435 \u043c\u043e\u0434\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438, \u043d\u043e \u0441\u0443\u0442\u044c \u0443 \u0432\u0441\u0435\u0445 \u043f\u0440\u0438\u0431\u043b\u0438\u0437\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043e\u0434\u043d\u0430.<\/p>\n<p>  <\/p>\n<p>\u0412 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0435 \u0434\u043b\u044f \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0445 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u0439 <em>Cirq<\/em> \u043e\u0442 \u043a\u043e\u043c\u043f\u0430\u043d\u0438\u0438 Google, \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0430\u043a\u0442\u0438\u0432\u043d\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f, \u044d\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u0442\u044c, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0442\u0430\u043a:<\/p>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">\u041a\u043e\u0434 \u043d\u0430 Cirq \u0434\u043b\u044f \u043f\u0440\u043e\u0441\u0442\u0435\u0439\u0448\u0435\u0439 VQC<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"python\">import cirq import sympy  qubits = cirq.LineQubit.range(10) x = sympy.symbols(&quot;x0:10&quot;) thetas = sympy.symbols(&quot;t0:10&quot;) circuit = cirq.Circuit()  for i in range(10):     circuit.append(cirq.rx(x[i])(qubits[i]))     circuit.append(cirq.ry(thetas[i])(qubits[i]))<\/code><\/pre>\n<p>  <\/p>\n<ul>\n<li><code>cirq.LineQubit<\/code> \u2014 \u044d\u0442\u043e \u043a\u0443\u0431\u0438\u0442 \u043d\u0430 \u043e\u0434\u043d\u043e\u043c\u0435\u0440\u043d\u043e\u0439 \u0446\u0435\u043f\u043e\u0447\u043a\u0435, \u0430 \u043c\u0435\u0442\u043e\u0434 <code>range<\/code> \u0441\u043e\u0437\u0434\u0430\u0435\u0442 \u043d\u0430\u043c \u0441\u0440\u0430\u0437\u0443 \u043d\u0443\u0436\u043d\u043e\u0435 \u0447\u0438\u0441\u043b\u043e \u043a\u0443\u0431\u0438\u0442\u043e\u0432;<\/li>\n<li>\u0412 <em>Cirq<\/em> \u0432\u0441\u0435 \u043a\u0443\u0431\u0438\u0442\u044b \u0438\u0437\u043d\u0430\u0447\u0430\u043b\u044c\u043d\u043e \u043d\u0430\u0445\u043e\u0434\u044f\u0442\u0441\u044f \u0432 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/35c\/aba\/a2b\/35cabaa2b95d22377b8a3abb8484b436.svg\" alt=\"$\\left | 0 \\right &gt;$\" data-tex=\"inline\"><\/math>, \u0442\u0430\u043a \u0447\u0442\u043e \u043d\u0430\u043c \u043d\u0435 \u043d\u0443\u0436\u043d\u043e \u0441\u043f\u0435\u0446\u0438\u0430\u043b\u044c\u043d\u043e \u0438\u0445 \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u0442\u044c;<\/li>\n<li><code>cirq.Circuit<\/code> \u2014 \u044d\u0442\u043e \u043a\u0430\u043a \u0440\u0430\u0437 \u043d\u0430\u0448\u0430 \u0441\u0445\u0435\u043c\u0430, \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u043d\u044b\u0439 \u043d\u0430\u0431\u043e\u0440 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0445 \u0433\u0435\u0439\u0442\u043e\u0432 (\u0438\u043b\u0438 \u043f\u043e \u0434\u0440\u0443\u0433\u043e\u043c\u0443 \u0432\u0435\u043d\u0442\u0438\u043b\u0435\u0439) \u2014 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0445 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0439 \u043d\u0430\u0434 \u043a\u0443\u0431\u0438\u0442\u0430\u043c\u0438;<\/li>\n<li><code>cirq.rx<\/code>, <code>cirq.ry<\/code> \u2014 \u044d\u0442\u043e \u043d\u0430\u0448\u0438 \u00ab\u0432\u0440\u0430\u0449\u0435\u043d\u0438\u044f \u0444\u0430\u0437\u044b\u00bb \u043d\u0430 \u043d\u0443\u0436\u043d\u044b\u0439 \u0443\u0433\u043e\u043b \u0432 \u0440\u0430\u0434\u0438\u0430\u043d\u0430\u0445.<\/li>\n<\/ul>\n<p>  <\/p>\n<p>\u0422\u0443\u0442 \u043c\u044b \u0442\u0430\u043a\u0436\u0435 \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0438\u0441\u044c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u043e\u0439 \u0441\u0438\u043c\u0432\u043e\u043b\u044c\u043d\u043e\u0439 \u0430\u043b\u0433\u0435\u0431\u0440\u044b <a href=\"https:\/\/www.sympy.org\/en\/index.html\"><em>SymPy<\/em><\/a>, \u043f\u0440\u043e\u0441\u0442\u043e <em>Cirq<\/em> \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0438\u0437\u043e\u0432\u044b\u0432\u0430\u0442\u044c \u0441\u0445\u0435\u043c\u044b \u043b\u0438\u0448\u044c \u0447\u0435\u0440\u0435\u0437 \u043d\u0435\u0435.<\/p>\n<\/div><\/div>\n<p>  <\/p>\n<p>\u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c, \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u0443\u044e \u044f\u0447\u0435\u0439\u043a\u0443 \u2014 <code>circuit<\/code>, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0438\u0437\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0438\u043c\u0438 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430\u043c\u0438 \u0438 \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0435\u0442 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u043a \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u043e\u043c\u0443 \u0432\u0445\u043e\u0434\u043d\u043e\u043c\u0443 \u0432\u0435\u043a\u0442\u043e\u0440\u0443. \u0418\u043c\u0435\u043d\u043d\u043e \u043d\u0430 \u0442\u0430\u043a\u0438\u0445 \u00ab\u0431\u043b\u043e\u043a\u0430\u0445\u00bb \u0438 \u0441\u0442\u0440\u043e\u044f\u0442\u0441\u044f \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u044b \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u043e-\u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u044f. \u041c\u044b \u0431\u0443\u0434\u0435\u043c \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0442\u044c \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u043a \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0438\u043c \u0434\u0430\u043d\u043d\u044b\u043c \u043d\u0430 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u043e\u043c \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0435 (\u0438\u043b\u0438 \u0441\u0438\u043c\u0443\u043b\u044f\u0442\u043e\u0440\u0435), \u0438\u0437\u043c\u0435\u0440\u044f\u0442\u044c \u0432\u044b\u0445\u043e\u0434 \u043d\u0430\u0448\u0435\u0439 <strong>VQC<\/strong> \u0438 \u0434\u0430\u043b\u0435\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u0433\u0440\u0430\u0434\u0438\u0435\u043d\u0442\u043d\u044b\u0435 \u043c\u0435\u0442\u043e\u0434\u044b \u0434\u043b\u044f \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 <strong>VQC<\/strong>.<\/p>\n<p>  <\/p>\n<h2 id=\"variational-quantum-eigensolver\">Variational Quantum Eigensolver<\/h2>\n<p>  <\/p>\n<p>\u041e\u0441\u043d\u043e\u0432\u043e\u0439 \u043c\u043d\u043e\u0433\u0438\u0445 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u043e\u0432 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u043e\u0433\u043e \u043c\u0430\u0448\u0438\u043d\u043d\u043e\u0433\u043e \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u044f \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f <strong>H<\/strong>arrow-<strong>H<\/strong>asssidim-<strong>L<\/strong>oloyd <a href=\"https:\/\/journals.aps.org\/prl\/abstract\/10.1103\/PhysRevLett.103.150502\">\u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c<\/a> (\u0435\u0441\u0442\u044c \u043f\u0440\u0435\u043f\u0440\u0438\u043d\u0442 \u0432 <a href=\"https:\/\/arxiv.org\/pdf\/0811.3171\">arXiv<\/a>) \u0434\u043b\u044f \u043f\u043e\u0438\u0441\u043a\u0430 \u0440\u0435\u0448\u0435\u043d\u0438\u044f \u0441\u0438\u0441\u0442\u0435\u043c \u043b\u0438\u043d\u0435\u0439\u043d\u044b\u0445 \u0443\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u0439. \u0418\u043c\u0435\u043d\u043d\u043e \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 \u044d\u0442\u043e\u0433\u043e \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u0430 \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0439 SVM \u2014 \u043d\u0430\u0438\u0431\u043e\u043b\u0435\u0435 \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b\u0439 \u0438 \u043c\u043d\u043e\u0433\u043e\u043e\u0431\u0435\u0449\u0430\u044e\u0449\u0438\u0439 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c <strong>QML<\/strong>. \u041e\u0434\u043d\u0430\u043a\u043e <strong>HHL<\/strong> \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0441\u043b\u043e\u0436\u043d\u044b\u0439 \u0438 \u043d\u0430\u0447\u0438\u043d\u0430\u0442\u044c \u0440\u0430\u0441\u0441\u043a\u0430\u0437 \u0441 \u043d\u0435\u0433\u043e \u0431\u044b\u043b\u043e \u0431\u044b \u0441\u0442\u0440\u0430\u043d\u043d\u043e. \u0412\u043c\u0435\u0441\u0442\u043e \u044d\u0442\u043e\u0433\u043e, \u0434\u0430\u043b\u0435\u0435, \u043c\u044b \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043a\u0430\u043a \u0443\u0441\u0442\u0440\u043e\u0435\u043d \u0434\u0440\u0443\u0433\u043e\u0439 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c \u2014 Variational Quantum Eigensolver, \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c \u043f\u043e\u0438\u0441\u043a\u0430 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u0445 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0445 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u044d\u0440\u043c\u0438\u0442\u043e\u0432\u044b\u0445 \u043c\u0430\u0442\u0440\u0438\u0446, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043b\u0435\u0436\u0438\u0442 \u0432 \u043e\u0441\u043d\u043e\u0432\u0435 <strong>HHL<\/strong>.<\/p>\n<p>  <\/p>\n<p>\u041f\u043e\u0447\u0435\u043c\u0443 \u0438\u043c\u0435\u043d\u043d\u043e \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0445 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439? \u041e\u0442\u0432\u0435\u0442 \u043f\u0440\u043e\u0441\u0442:<\/p>\n<p>  <\/p>\n<ul>\n<li>\u043f\u043e\u0438\u0441\u043a \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u0445 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0445 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u044d\u0440\u043c\u0438\u0442\u043e\u0432\u044b\u0445 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u043e\u0432 \u2014 \u0432\u0430\u0436\u043d\u0430\u044f \u0437\u0430\u0434\u0430\u0447\u0430 \u0444\u0438\u0437\u0438\u043a\u0438, \u0438\u043c\u0435\u043d\u043d\u043e \u0434\u043b\u044f \u043d\u0435\u0435 \u0420. \u0424\u0435\u0439\u043d\u043c\u0430\u043d <a href=\"https:\/\/catonmat.net\/ftp\/simulating-physics-with-computers-richard-feynman.pdf\">\u0432\u043f\u0435\u0440\u0432\u044b\u0435 \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0438\u043b<\/a> \u043c\u043e\u0434\u0435\u043b\u044c \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u043e\u0433\u043e \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0430;<\/li>\n<li>Variational Quantum Eigensolver \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043a\u043b\u044e\u0447\u0435\u0432\u043e\u0439 \u0447\u0430\u0441\u0442\u044c\u044e <strong>HHL<\/strong>-\u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u0430, \u0438\u0442\u0435\u0440\u0430\u0446\u0438\u044f <strong>HHL<\/strong> \u0441\u0432\u043e\u0434\u0438\u0442\u0441\u044f \u043a \u0437\u0430\u0434\u0430\u0447\u0435 \u043e \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0445 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f\u0445;<\/li>\n<li>\u0421\u0430\u043c \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u043f\u0440\u043e\u0441\u0442 \u043a\u0430\u043a \u0434\u043b\u044f \u043f\u043e\u043d\u0438\u043c\u0430\u043d\u0438\u044f, \u0442\u0430\u043a \u0438 \u0434\u043b\u044f \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438.<\/li>\n<\/ul>\n<p>  <\/p>\n<p>\u041e\u043f\u0438\u0448\u0435\u043c \u0437\u0430\u0434\u0430\u0447\u0443 \u0444\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u043e.<\/p>\n<p>  <\/p>\n<p><em>\u0414\u0430\u043d\u0430 \u044d\u0440\u043c\u0438\u0442\u043e\u0432\u0430 \u043c\u0430\u0442\u0440\u0438\u0446\u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/e38\/663\/cf0\/e38663cf03c7b378fa6539e05f5a8139.svg\" alt=\"$\\hat{\\mathbf{H}}$\" data-tex=\"inline\"><\/math>, \u0438\u043b\u0438, \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u0441\u043b\u043e\u0432\u0430\u043c\u0438, \u0441\u0430\u043c\u043e\u0441\u043e\u043f\u0440\u044f\u0436\u0435\u043d\u043d\u044b\u0439 \u044d\u0440\u043c\u0438\u0442\u0438\u0432 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440. \u0422\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u043d\u0430\u0439\u0442\u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/8c4\/98c\/0c2\/8c498c0c2d0c2faf194e8d463768929a.svg\" alt=\"$\\lambda_0$\" data-tex=\"inline\"><\/math>, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u043c \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u043c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435\u043c \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/e38\/663\/cf0\/e38663cf03c7b378fa6539e05f5a8139.svg\" alt=\"$\\hat{\\mathbf{H}}$\" data-tex=\"inline\"><\/math>.<\/em><\/p>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u0440\u0435\u0448\u0435\u043d\u0438\u044f \u044d\u0442\u043e\u0439 \u0437\u0430\u0434\u0430\u0447\u0438 \u043c\u044b \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0441\u044f \u0442\u0430\u043a \u043d\u0430\u0437\u044b\u0432\u0430\u0435\u043c\u043e\u0439 \u00ab\u0412\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u0442\u0435\u043e\u0440\u0435\u043c\u043e\u0439\u00bb (<a href=\"https:\/\/en.wikipedia.org\/wiki\/Variational_method_(quantum_mechanics)\">Variational theorem<\/a>), \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0434\u043b\u044f \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/e38\/663\/cf0\/e38663cf03c7b378fa6539e05f5a8139.svg\" alt=\"$\\hat{\\mathbf{H}}$\" data-tex=\"inline\"><\/math> \u0434\u0430\u0435\u0442 \u043d\u0430\u043c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435:<\/p>\n<p>  <\/p>\n<p><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/ff1\/0ec\/f17\/ff10ecf1718e01e6775917862f5e3847.svg\" alt=\"$\\left &lt; \\hat{\\mathbf{H}} \\right &gt;_{\\left | \\Psi \\right &gt;} = \\left &lt; \\Psi \\right | \\hat{\\mathbf{H}} \\left | \\Psi \\right &gt; \\geq \\mathbf{E}_0$\" data-tex=\"display\"><\/math><\/p>\n<p>  <\/p>\n<p>\u0433\u0434\u0435 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/180\/3b6\/e14\/1803b6e14b2a36481df6be4ff09fa68f.svg\" alt=\"$\\mathbf{E}_0$\" data-tex=\"inline\"><\/math> \u044d\u0442\u043e \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0435 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430. \u041f\u043e \u0441\u0443\u0442\u0438 \u0442\u0443\u0442 \u0441\u043a\u0430\u0437\u0430\u043d\u043e, \u0447\u0442\u043e \u043e\u0436\u0438\u0434\u0430\u0435\u043c\u044b\u0439 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0438\u0437\u043c\u0435\u0440\u0435\u043d\u0438\u044f \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/e38\/663\/cf0\/e38663cf03c7b378fa6539e05f5a8139.svg\" alt=\"$\\hat{\\mathbf{H}}$\" data-tex=\"inline\"><\/math> \u0432 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/8fe\/2d1\/95d\/8fe2d195de16ae766f518a330c4db8b1.svg\" alt=\"$\\left | \\Psi \\right &gt;$\" data-tex=\"inline\"><\/math> \u0432\u0441\u0435\u0433\u0434\u0430 \u0431\u043e\u043b\u044c\u0448\u0435 \u0438\u043b\u0438 \u0440\u0430\u0432\u0435\u043d \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u043c\u0443 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u043c\u0443 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044e \u044d\u0442\u043e\u0433\u043e \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430. \u041d\u0430 \u044d\u0442\u043e\u043c \u0438 \u0441\u0442\u0440\u043e\u0438\u0442\u0441\u044f \u043d\u0430\u0448 \u043f\u0440\u043e\u0446\u0435\u0441\u0441:<\/p>\n<p>  <\/p>\n<ol>\n<li>\u0413\u043e\u0442\u043e\u0432\u0438\u043c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/6ac\/f4c\/343\/6acf4c343b77a3fc89ed6c9ec3a2cc5e.svg\" alt=\"$\\left | \\Psi(\\theta_k) \\right &gt;$\" data-tex=\"inline\"><\/math>, \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u043e\u0435 \u0432\u0435\u043a\u0442\u043e\u0440\u043e\u043c \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/4c3\/7c5\/4d1\/4c37c54d11016ec30e5f3c8c0a6a5d62.svg\" alt=\"$\\theta_k$\" data-tex=\"inline\"><\/math><\/li>\n<li>\u0418\u0437\u043c\u0435\u0440\u044f\u0435\u043c \u043e\u0436\u0438\u0434\u0430\u0435\u043c\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/fad\/3ca\/04f\/fad3ca04f54ea3e6a20ec9a03d4cfc82.svg\" alt=\"$\\lambda_k$\" data-tex=\"inline\"><\/math> \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/e38\/663\/cf0\/e38663cf03c7b378fa6539e05f5a8139.svg\" alt=\"$\\hat{\\mathbf{H}}$\" data-tex=\"inline\"><\/math> \u0432 \u044d\u0442\u043e\u043c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/6ac\/f4c\/343\/6acf4c343b77a3fc89ed6c9ec3a2cc5e.svg\" alt=\"$\\left | \\Psi(\\theta_k) \\right &gt;$\" data-tex=\"inline\"><\/math><\/li>\n<li>\u041e\u0446\u0435\u043d\u0438\u0432\u0430\u0435\u043c \u0433\u0440\u0430\u0434\u0438\u0435\u043d\u0442 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/6dc\/283\/b7a\/6dc283b7a404f31d78dc364767741a7d.svg\" alt=\"$g_k = \\frac{\\partial\\lambda}{\\partial\\theta}$\" data-tex=\"inline\"><\/math>, \u043e\u0436\u0438\u0434\u0430\u0435\u043c\u043e\u0433\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u043f\u043e \u0432\u0435\u0441\u0430\u043c <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/ff2\/c64\/99d\/ff2c6499d038a61a41d7ce75cd78788f.svg\" alt=\"$\\theta$\" data-tex=\"inline\"><\/math><\/li>\n<li>\u041e\u0431\u043d\u043e\u0432\u043b\u044f\u0435\u043c \u0432\u0435\u043a\u0442\u043e\u0440 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/ff2\/c64\/99d\/ff2c6499d038a61a41d7ce75cd78788f.svg\" alt=\"$\\theta$\" data-tex=\"inline\"><\/math>: <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/95d\/907\/043\/95d907043d4cdba4bc7f36ef43b3a04a.svg\" alt=\"$\\theta_{k + 1} = \\theta_k - \\gamma \\cdot g_k$\" data-tex=\"inline\"><\/math><\/li>\n<\/ol>\n<p>  <\/p>\n<p>\u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c, \u043d\u0430\u0448 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0432\u0435\u043a\u0442\u043e\u0440 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/6ac\/f4c\/343\/6acf4c343b77a3fc89ed6c9ec3a2cc5e.svg\" alt=\"$\\left | \\Psi(\\theta_k) \\right &gt;$\" data-tex=\"inline\"><\/math> \u043a\u0430\u0436\u0434\u044b\u0439 \u0440\u0430\u0437 \u0431\u0443\u0434\u0435\u0442 \u0432\u0441\u0435 \u0431\u043b\u0438\u0436\u0435 \u043a \u043f\u0435\u0440\u0432\u043e\u043c\u0443 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u043c\u0443 \u0432\u0435\u043a\u0442\u043e\u0440\u0443 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430, \u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/fad\/3ca\/04f\/fad3ca04f54ea3e6a20ec9a03d4cfc82.svg\" alt=\"$\\lambda_k$\" data-tex=\"inline\"><\/math> \u0431\u0443\u0434\u0435\u0442 (\u0441 \u043f\u043e\u0433\u0440\u0435\u0448\u043d\u043e\u0441\u0442\u044c\u044e \u043d\u0430 \u043e\u0446\u0435\u043d\u043a\u0443 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u044f) \u043f\u0440\u0438\u0431\u043b\u0438\u0436\u0430\u0442\u044c\u0441\u044f \u043a \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u043c\u0443 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u043c\u0443 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044e <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/83c\/5e0\/72d\/83c5e072d418b4c1255b735c5f1131ca.svg\" alt=\"$\\mathbf{E_0}$\" data-tex=\"inline\"><\/math>.<\/p>\n<p>  <\/p>\n<p>\u041d\u0430\u0434\u0435\u044e\u0441\u044c, \u0431\u043e\u043b\u044c\u0448\u0435 \u043f\u043e\u043d\u0438\u043c\u0430\u043d\u0438\u044f \u0441\u0442\u0430\u043d\u0435\u0442, \u043a\u043e\u0433\u0434\u0430 \u043c\u044b \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c, \u043a\u0430\u043a \u044d\u0442\u043e \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u0432 \u043a\u043e\u0434\u0435.<\/p>\n<p>  <\/p>\n<h2 id=\"realizaciya-na-tensorflow-quantum\">\u0420\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043d\u0430 <em>Tensorflow Quantum<\/em><\/h2>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u043d\u0430\u0447\u0430\u043b\u0430 \u043a\u0440\u0430\u0442\u043a\u0438\u0435 \u043e\u0431\u043e\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0438\u043c\u043f\u043e\u0440\u0442\u043e\u0432:<\/p>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">\u041a\u043e\u0434 \u0438\u043c\u043f\u043e\u0440\u0442\u043e\u0432<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"python\">import tensorflow as tf import tensorflow-quantum as tfq<\/code><\/pre>\n<\/div><\/div>\n<p>  <\/p>\n<p><em>Tensorflow Quantum<\/em> \u2014 \u0441\u043f\u0435\u0446\u0438\u0430\u043b\u044c\u043d\u0430\u044f \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0441\u0445\u0435\u043c\u044b <em>Cirq<\/em> \u043a\u0430\u043a \u0442\u0435\u043d\u0437\u043e\u0440\u044b <em>Tensorflow<\/em>, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0441\u043f\u0435\u0446\u0438\u0430\u043b\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u044b <code>tf.keras.Layers<\/code> \u0434\u043b\u044f \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u043e-\u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u044f. \u0411\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u0430 \u0441\u043e \u0441\u0442\u0438\u043b\u0435\u043c \u0438 \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u0441\u043b\u043e\u044f\u043c\u0438 <code>tf<\/code> \u0438 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0437\u0430\u0434\u0435\u0439\u0441\u0442\u0432\u043e\u0432\u0430\u0442\u044c \u0441\u0438\u0441\u0442\u0435\u043c\u0443 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0434\u0438\u0444\u0444\u0438\u0440\u0435\u043d\u0446\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f <em>Tensorflow<\/em>. \u041e\u0434\u043d\u0438\u043c \u0438\u0437 \u0442\u0430\u043a\u0438\u0445 <code>tfq.layers<\/code> \u043c\u044b \u0438 \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0441\u044f \u2014 \u044d\u0442\u043e <code>tfq.layers.SampledExpectation<\/code>. <\/p>\n<p>  <\/p>\n<p>\u042d\u0442\u043e\u0442 \u0441\u043b\u043e\u0439, \u0432 \u0442\u043e\u043c \u0447\u0438\u0441\u043b\u0435, \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u043e\u0446\u0435\u043d\u0438\u0432\u0430\u0442\u044c \u043e\u0436\u0438\u0434\u0430\u0435\u043c\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 \u0432 \u043a\u0430\u043a\u043e\u043c-\u0442\u043e \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0438, \u0430 \u043f\u043e\u0442\u043e\u043c \u0435\u0449\u0435 \u0438 \u0433\u0440\u0430\u0434\u0438\u0435\u043d\u0442 \u043f\u043e \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430\u043c \u0441\u0445\u0435\u043c\u044b, \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u0432\u0448\u0435\u0439 \u044d\u0442\u043e \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435. \u0421\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u0430 \u0443 \u043d\u0435\u0433\u043e \u0442\u0430\u043a\u0430\u044f:<\/p>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">\u0421\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u0430 \u0438 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u0441\u043b\u043e\u044f tfq.layers.SampledExpectation<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"python\">layer = tfq.layers.SampledExpectation() res = layer(     circuit,     symbol_names,     symbol_values,     operators,     repetitions, )<\/code><\/pre>\n<p>  <\/p>\n<ul>\n<li><code>cicuit<\/code> \u2014 \u0441\u0445\u0435\u043c\u0430 (<code>cirq.Circuit<\/code>), \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0438\u0437\u0438\u0440\u0443\u044e\u0449\u0430\u044f \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/8fe\/2d1\/95d\/8fe2d195de16ae766f518a330c4db8b1.svg\" alt=\"$\\left | \\Psi \\right &gt;$\" data-tex=\"inline\"><\/math><\/li>\n<li><code>symbol_names<\/code> \u2014 \u0441\u0438\u043c\u0432\u043e\u043b\u044b <code>sympy<\/code>, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0438\u0437\u0438\u0440\u0443\u044e\u0442 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435<\/li>\n<li><code>symbol_values<\/code> \u2014 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0441\u0438\u043c\u0432\u043e\u043b\u043e\u0432-\u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 (\u043e\u0431\u044b\u0447\u043d\u043e <code>tf.Variable<\/code>)<\/li>\n<li><code>operators<\/code> \u2014 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u044b (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, <code>cirq.PauliSum<\/code>)<\/li>\n<li><code>repetitions<\/code> \u2014 \u0447\u0438\u0441\u043b\u043e \u0438\u0437\u043c\u0435\u0440\u0435\u043d\u0438\u0439, \u043f\u043e \u043a\u043e\u0442\u043e\u0440\u044b\u043c \u043e\u0446\u0435\u043d\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430<\/li>\n<\/ul>\n<p>  <\/p>\n<p>\u042d\u0442\u043e\u0442 \u0441\u043b\u043e\u0439 \u044f\u0432\u043d\u043e \u0440\u0435\u0430\u043b\u0438\u0437\u0443\u0435\u0442 \u043d\u0430\u043c \u0434\u043b\u044f \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/5bc\/55c\/b5d\/5bc55cb5db50ed9906fc5ab2988fed42.svg\" alt=\"$\\hat{\\mathbf{Op}}$\" data-tex=\"inline\"><\/math> \u043e\u0446\u0435\u043d\u043a\u0443 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 \u0432 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u043c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0438 \u043f\u043e \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u043e\u043c\u0443 \u0447\u0438\u0441\u043b\u0443 \u0438\u0437\u043c\u0435\u0440\u0435\u043d\u0438\u0439:<\/p>\n<p>  <\/p>\n<p><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/695\/a7c\/56c\/695a7c56cc6ad25743f6a162ddb617c0.svg\" alt=\"$\\left &lt; \\Psi(\\theta) \\right | \\hat{\\mathbf{Op}} \\left | \\Psi(\\theta) \\right &gt;$\" data-tex=\"display\"><\/math><\/p>\n<p>  <\/p>\n<p>\u0410 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u0432 \u0444\u043e\u0440\u043c\u0443\u043b\u0435 \u0441\u0432\u044f\u0437\u0430\u043d\u044b \u0441 \u0441\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u043e\u0439 \u043c\u0435\u0442\u043e\u0434\u0430 <code>call<\/code> \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:<\/p>\n<p>  <\/p>\n<div class=\"scrollable-table\">\n<table>\n<thead>\n<tr>\n<th>\u0424\u043e\u0440\u043c\u0443\u043b\u0430<\/th>\n<th>\u0421\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u0430 <code>tfq.layers.SampledExpectation.call<\/code><\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/ff2\/c64\/99d\/ff2c6499d038a61a41d7ce75cd78788f.svg\" alt=\"$\\theta$\" data-tex=\"inline\"><\/math><\/td>\n<td><code>symbol_values<\/code> \u2014 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432<\/td>\n<\/tr>\n<tr>\n<td><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/780\/de2\/a37\/780de2a379b6597afcad4a132591aa90.svg\" alt=\"$\\Psi$\" data-tex=\"inline\"><\/math><\/td>\n<td><code>circuit<\/code> \u2014 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u0430\u044f \u0441\u0445\u0435\u043c\u0430 \u00ab\u0433\u043e\u0442\u043e\u0432\u0438\u0442\u00bb \u043d\u0430\u043c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435<\/td>\n<\/tr>\n<tr>\n<td><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/88f\/28e\/ab8\/88f28eab822774a3a30822872bd6d321.svg\" alt=\"$\\Psi(\\theta)$\" data-tex=\"inline\"><\/math><\/td>\n<td><code>symbol_names<\/code> \u2014 \u0441\u0432\u044f\u0437\u044c \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u0441\u0445\u0435\u043c\u044b \u0441 <code>symbol_values<\/code><\/td>\n<\/tr>\n<tr>\n<td><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/5bc\/55c\/b5d\/5bc55cb5db50ed9906fc5ab2988fed42.svg\" alt=\"$\\hat{\\mathbf{Op}}$\" data-tex=\"inline\"><\/math><\/td>\n<td><code>operators<\/code> \u2014 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 <code>cirq.PauliSum<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<p>  <\/p>\n<p>\u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 <code>repetition<\/code> \u043d\u0435 \u0438\u043c\u0435\u0435\u0442 \u043f\u0440\u044f\u043c\u043e\u0439 \u0441\u0432\u044f\u0437\u0438 \u0441 \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u043c \u0444\u043e\u0440\u043c\u0430\u043b\u0438\u0437\u043c\u043e\u043c, \u043d\u043e \u0438\u043c\u0435\u043d\u043d\u043e \u043e\u043d \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 \u043d\u0430\u043c \u043d\u0430\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0445\u043e\u0440\u043e\u0448\u043e \u043c\u044b \u043e\u0446\u0435\u043d\u0438\u0432\u0430\u0435\u043c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430.<\/p>\n<\/div><\/div>\n<p>  <\/p>\n<p>\u041d\u043e \u043f\u0435\u0440\u0435\u0434 \u043d\u0430\u0447\u0430\u043b\u043e\u043c \u0432\u0441\u0435\u0433\u043e \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u044f \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0440\u0435\u0448\u0438\u0442\u044c, \u043a\u0430\u043a \u0438\u043c\u0435\u043d\u043d\u043e \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0438\u0437\u043e\u0432\u0430\u0442\u044c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435. \u0412 \u0432\u044b\u0448\u0435\u043e\u043f\u0438\u0441\u0430\u043d\u043d\u044b\u0445 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u0445 \u043d\u0430\u043c \u043d\u0430\u0434\u043e \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/fee\/566\/74f\/fee56674f6187c3e9108bd56b28067c1.svg\" alt=\"$\\left | \\Psi(\\theta) \\right &gt;$\" data-tex=\"inline\"><\/math>, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430 <code>circuit<\/code> \u0432 <code>tfq.layers.SampledExpectation<\/code>. \u0412 \u0434\u0430\u043d\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0441\u044f \u0431\u043e\u043b\u0435\u0435 \u0441\u043b\u043e\u0436\u043d\u043e\u0439 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0438\u0437\u0430\u0446\u0438\u0435\u0439, \u0433\u0434\u0435 \u043d\u0430 \u043a\u0430\u0436\u0434\u044b\u0439 \u0441\u043f\u0438\u043d \u0443 \u043d\u0430\u0441 \u0431\u0443\u0434\u0435\u0442 \u0442\u0440\u0438 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430: <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/15d\/0b4\/42e\/15d0b442e024ac1f9bb5761a2af4551c.svg\" alt=\"$\\theta_x, \\theta_y, \\theta_z$\" data-tex=\"inline\"><\/math>, \u0430 \u043d\u0435 \u043e\u0434\u0438\u043d:<\/p>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">\u041a\u043e\u0434 VQC \u0434\u043b\u044f Eigensolver-\u0430<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"python\">qubits = cirq.GridQubit.rect(dim, 1) params_x = sympy.symbols(f&quot;x0:{dim}&quot;) params_y = sympy.symbols(f&quot;y0:{dim}&quot;) params_z = sympy.symbols(f&quot;z0:{dim}&quot;) cirquit = cirq.Circuit()  for i in range(dim):     cirquit.append(cirq.rx(params_x[i])(qubits[i]))     cirquit.append(cirq.ry(params_y[i])(qubits[i]))     cirquit.append(cirq.rz(params_z[i])(qubits[i]))<\/code><\/pre>\n<\/div><\/div>\n<p>  <\/p>\n<p>\u0412\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043d\u0430\u0448\u0430 \u0441\u0445\u0435\u043c\u0430 \u0442\u0430\u043a:<br \/>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/post_images\/229\/9fa\/45c\/2299fa45c9751b41b4397c60864c636e.png\" alt=\"\u041d\u0430\u0448\u0430 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f VQC\"><\/p>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u043f\u0440\u0438\u043c\u0435\u0440\u0430, \u043d\u0430\u0439\u0434\u0435\u043c \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0435 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 <a href=\"https:\/\/en.wikipedia.org\/wiki\/Transverse-field_Ising_model\"><em>Transverse-field Ising<\/em><\/a>, \u0442\u0430\u043a \u043d\u0430\u0437\u044b\u0432\u0430\u0435\u043c\u043e\u0439 \u00ab\u043a\u0432\u0430\u043d\u0442\u043e\u0432\u043e\u0439 \u043c\u043e\u0434\u0435\u043b\u0438 \u0418\u0437\u0438\u043d\u0433\u0430\u00bb. \u042d\u0442\u043e\u0442 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 \u0441\u0442\u0440\u043e\u0438\u0442\u0441\u044f \u043f\u0440\u0438\u043c\u0435\u043d\u0435\u043d\u0438\u0435\u043c <a href=\"https:\/\/en.wikipedia.org\/wiki\/Pauli_matrices\">\u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u043e\u0432 \u041f\u0430\u0443\u043b\u0438<\/a> (\u0432 \u043d\u0430\u0448\u0435\u043c \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0435 \u044d\u0442\u043e \u0431\u0443\u0434\u0443\u0442 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/df8\/23d\/be3\/df823dbe3ad7d52652cb6612e8f05b89.svg\" alt=\"$\\sigma^z$\" data-tex=\"inline\"><\/math> \u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/8c9\/f10\/f9f\/8c9f10f9f65a59de54c297e35d973f94.svg\" alt=\"$\\sigma^x$\" data-tex=\"inline\"><\/math>) \u0438 \u0438\u043c\u0435\u0435\u0442 \u0434\u0432\u0430 \u00ab\u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0438\u0445\u00bb \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/055\/b1d\/5cc\/055b1d5cc86a88500b04db2430ec77d7.svg\" alt=\"$J, h$\" data-tex=\"inline\"><\/math>. \u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/055\/b1d\/5cc\/055b1d5cc86a88500b04db2430ec77d7.svg\" alt=\"$J, h$\" data-tex=\"inline\"><\/math> \u043d\u0430 \u0441\u0430\u043c\u043e\u043c \u0434\u0435\u043b\u0435 \u0438\u043c\u0435\u044e\u0442 \u0444\u0438\u0437\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u0441\u043c\u044b\u0441\u043b, \u0430 \u0441\u0430\u043c \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 \u0447\u0430\u0441\u0442\u043e \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u044e\u0442 \u0434\u043b\u044f \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u044f \u0413\u0430\u043c\u0438\u043b\u044c\u0442\u043e\u043d\u0438\u0430\u043d\u043e\u0432 \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0445 \u0444\u0438\u0437\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u0441\u0438\u0441\u0442\u0435\u043c, \u0442\u043e \u0435\u0441\u0442\u044c \u044d\u0442\u043e \u043d\u0435 \u043f\u0440\u043e\u0441\u0442\u043e \u0430\u0431\u0441\u0442\u0440\u0430\u043a\u0442\u043d\u0430\u044f \u0437\u0430\u0434\u0430\u0447\u0430. \u041d\u043e \u0441\u0435\u0439\u0447\u0430\u0441 \u0430\u0441\u043f\u0435\u043a\u0442\u044b \u0444\u0438\u0437\u0438\u043a\u0438 \u043d\u0430\u0441 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u0443\u044e\u0442 \u0432 \u043c\u0435\u043d\u044c\u0448\u0435\u0439 \u0441\u0442\u0435\u043f\u0435\u043d\u0438. \u041d\u0430 \u0441\u0430\u043c\u043e\u043c \u0434\u0435\u043b\u0435 \u043b\u044e\u0431\u043e\u0439 \u044d\u0440\u043c\u0438\u0442\u043e\u0432 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 \u043c\u043e\u0436\u043d\u043e \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c \u0432 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u0445 \u043c\u0430\u0442\u0440\u0438\u0446 \u041f\u0430\u0443\u043b\u0438, \u0442\u0430\u043a \u0447\u0442\u043e \u0432\u044b\u0431\u0440\u0430\u0432 \u0418\u0437\u0438\u043d\u0433\u0430 \u043c\u044b \u043d\u0435 \u0442\u0435\u0440\u044f\u0435\u043c \u043e\u0431\u0449\u043d\u043e\u0441\u0442\u0438 \u0440\u0430\u0441\u0441\u0443\u0436\u0434\u0435\u043d\u0438\u0439.<\/p>\n<p>  <\/p>\n<p><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/24d\/89f\/3d7\/24d89f3d79b17e2a86b583bbbe0fca76.svg\" alt=\"$TFI = -J \\cdot \\sum_{i=1}^{n - 1} \\sigma^z_i \\cdot \\sigma^z_{i + 1} + h \\cdot \\sum_{i=1}^n \\sigma^x_i$\" data-tex=\"display\"><\/math><\/p>\n<p>  <\/p>\n<p>\u042d\u0442\u043e \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 \u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0441\u0442\u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/6b2\/736\/96b\/6b273696bb3714734e8e989c3cea452f.svg\" alt=\"$2^N \\times 2^N$\" data-tex=\"inline\"><\/math>, \u0433\u0434\u0435 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/1e8\/0c3\/b30\/1e80c3b3087c0a57b68ad11261a9ec2b.svg\" alt=\"$N$\" data-tex=\"inline\"><\/math> \u044d\u0442\u043e \u0447\u0438\u0441\u043b\u043e \u043a\u0443\u0431\u0438\u0442\u043e\u0432, \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u043e\u043d \u0434\u0435\u0439\u0441\u0442\u0432\u0443\u0435\u0442. \u0422\u0430\u043a \u043a\u0430\u043a \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0435 \u0441\u0438\u043c\u0443\u043b\u044f\u0442\u043e\u0440\u044b \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u00ab\u043f\u0440\u043e\u0436\u043e\u0440\u043b\u0438\u0432\u044b\u00bb, \u0430 \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u043c \u043a\u0443\u0431\u0438\u0442\u0430\u043c \u0432 <em>Google Cloud Platform<\/em> \u0441\u0442\u043e\u0438\u0442 \u0434\u0435\u043d\u0435\u0433, \u0442\u043e \u043d\u0435 \u0431\u0443\u0434\u0435\u043c \u0431\u0440\u0430\u0442\u044c \u0431\u043e\u043b\u044c\u0448\u0443\u044e \u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0441\u0442\u044c <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/1e8\/0c3\/b30\/1e80c3b3087c0a57b68ad11261a9ec2b.svg\" alt=\"$N$\" data-tex=\"inline\"><\/math>. \u0421\u0435\u0439\u0447\u0430\u0441 \u043d\u0430\u043c \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u043e \u043f\u0440\u043e\u0441\u0442\u043e \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c, \u043a\u0430\u043a \u043e\u043d\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442, \u043e \u043a\u0430\u043a\u043e\u043c-\u0442\u043e \u043f\u0440\u0435\u0432\u043e\u0441\u0445\u043e\u0434\u0441\u0442\u0432\u0435 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0445 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u043e\u0432 \u043d\u0430 \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0445 \u0437\u0430\u0434\u0430\u0447\u0430\u0445 \u0440\u0435\u0447\u0438 \u043d\u0435 \u0438\u0434\u0435\u0442. \u0417\u0430\u043f\u0438\u0448\u0435\u043c \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e \u044d\u0442\u043e\u0433\u043e \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 \u0432 \u043a\u043e\u0434\u0435 <em>Cirq<\/em>.<\/p>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">TFI \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 (\u043c\u0430\u0442\u0440\u0438\u0446\u0430) \u0432 \u043a\u043e\u0434\u0435 Cirq<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"python\">def get_ising_operator(     qubits: List[cirq.GridQubit], j: float, h: float ) -&gt; cirq.PauliSum:     op = h * cirq.X(qubits[-1])      for i, _ in enumerate(qubits[:-1]):         op -= j * cirq.Z(qubits[i]) * cirq.Z(qubits[i + 1])         op += h * cirq.X(qubits[i])      return op<\/code><\/pre>\n<\/div><\/div>\n<p>  <\/p>\n<p>\u0425\u043e\u0442\u0435\u043b\u043e\u0441\u044c \u0431\u044b \u0435\u0449\u0435 \u0440\u0430\u0437 \u043e\u0431\u0440\u0430\u0442\u0438\u0442\u044c \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u043d\u0430 \u0442\u043e\u0442 \u0444\u0430\u043a\u0442, \u0447\u0442\u043e \u0434\u043b\u044f <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/1e8\/0c3\/b30\/1e80c3b3087c0a57b68ad11261a9ec2b.svg\" alt=\"$N$\" data-tex=\"inline\"><\/math> \u043a\u0443\u0431\u0438\u0442\u043e\u0432 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 TFI \u044d\u0442\u043e \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u0440\u0430\u0437\u043c\u0435\u0440\u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/6b2\/736\/96b\/6b273696bb3714734e8e989c3cea452f.svg\" alt=\"$2^N \\times 2^N$\" data-tex=\"inline\"><\/math> (\u0430 \u043d\u0435 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/f16\/b12\/32d\/f16b1232d87721b5d4725dcf648ebbe2.svg\" alt=\"$N \\times N$\" data-tex=\"inline\"><\/math>, \u043a\u0430\u043a \u043c\u043e\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u0431\u044b \u043f\u043e\u0434\u0443\u043c\u0430\u0442\u044c!) \u0427\u0442\u043e\u0431\u044b \u0443\u0431\u0435\u0434\u0438\u0442\u0441\u044f \u0432 \u044d\u0442\u043e\u043c, \u043d\u0438\u0436\u0435, \u043f\u043e\u0434 \u0441\u043f\u043e\u0439\u043b\u0435\u0440\u043e\u043c, \u0431\u0443\u0434\u0435\u0442 \u043a\u043e\u0434 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f \u0442\u0430\u043a\u043e\u0433\u043e \u0436\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 \u043d\u0430 \u0447\u0438\u0441\u0442\u043e\u043c <em>NumPy<\/em> \u0432 \u0432\u0438\u0434\u0435 \u0440\u0430\u0437\u0440\u0435\u0436\u0435\u043d\u043d\u043e\u0439 \u043a\u043e\u043c\u043f\u043b\u0435\u043a\u0441\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b:<\/p>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">\u041a\u043e\u0434 TFI \u043d\u0430 \u0447\u0438\u0441\u0442\u043e\u043c NumPy \u0438 \u0435\u0449\u0435 \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u0444\u043e\u0440\u043c\u0443\u043b<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<p>\u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 \u041f\u0430\u0443\u043b\u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/df8\/23d\/be3\/df823dbe3ad7d52652cb6612e8f05b89.svg\" alt=\"$\\sigma^z$\" data-tex=\"inline\"><\/math>. \u0421\u043e\u0433\u043b\u0430\u0441\u043d\u043e \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044e, \u044d\u0442\u043e \u043c\u0430\u0442\u0440\u0438\u0446\u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/303\/35c\/97c\/30335c97ce60ce47f6b21cd4c3053ec6.svg\" alt=\"$2 \\times 2$\" data-tex=\"inline\"><\/math>:<\/p>\n<p>  <\/p>\n<p><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/adc\/7da\/e9d\/adc7dae9d28a261aaae332e6c07aaf34.svg\" alt=\"$\\sigma^z = \\begin{matrix}1 &amp; 0 \\\\ 0 &amp; -1\\end{matrix}$\" data-tex=\"display\"><\/math><\/p>\n<p>  <\/p>\n<p>\u041d\u043e, \u043a\u0430\u043a \u043c\u043e\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u0437\u0430\u043c\u0435\u0442\u0438\u0442\u044c, \u0443 \u043d\u0430\u0441 \u0441\u0438\u0441\u0442\u0435\u043c\u0430 \u0438\u0437 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/1e8\/0c3\/b30\/1e80c3b3087c0a57b68ad11261a9ec2b.svg\" alt=\"$N$\" data-tex=\"inline\"><\/math> \u043a\u0443\u0431\u0438\u0442, \u0430 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0434\u0435\u0439\u0441\u0442\u0432\u0443\u0435\u0442 \u043d\u0430 \u0442\u0430\u043a\u0443\u044e \u0441\u0438\u0441\u0442\u0435\u043c\u0443, \u044d\u0442\u043e \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 \u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0441\u0442\u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/6b2\/736\/96b\/6b273696bb3714734e8e989c3cea452f.svg\" alt=\"$2^N \\times 2^N$\" data-tex=\"inline\"><\/math>. \u0427\u0442\u043e\u0431\u044b \u043f\u043e\u043d\u044f\u0442\u044c, \u043a\u0430\u043a \u043c\u044b \u043e\u0442 \u043c\u0430\u0442\u0440\u0438\u0446\u044b <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/303\/35c\/97c\/30335c97ce60ce47f6b21cd4c3053ec6.svg\" alt=\"$2 \\times 2$\" data-tex=\"inline\"><\/math> \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u043a \u043c\u0430\u0442\u0440\u0438\u0446\u0435 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/6b2\/736\/96b\/6b273696bb3714734e8e989c3cea452f.svg\" alt=\"$2^N \\times 2^N$\" data-tex=\"inline\"><\/math>, \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/0a9\/0e5\/58c\/0a90e558c9af8360818d6b9ad2e7fdd2.svg\" alt=\"$\\sigma^z_k$\" data-tex=\"inline\"><\/math>, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0434\u0435\u0439\u0441\u0442\u0432\u0443\u0435\u0442 \u043d\u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/16d\/a50\/7b2\/16da507b2fc389688ef0659939dcc647.svg\" alt=\"$k$\" data-tex=\"inline\"><\/math>-\u0439 \u043a\u0443\u0431\u0438\u0442 \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u0435. \u042d\u0442\u043e \u044d\u043a\u0432\u0438\u0432\u0430\u043b\u0435\u043d\u0442\u043d\u043e \u0442\u043e\u043c\u0443, \u0447\u0442\u043e \u043c\u044b \u0434\u0435\u0439\u0441\u0442\u0432\u0443\u0435\u043c \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u043e\u043c <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/df8\/23d\/be3\/df823dbe3ad7d52652cb6612e8f05b89.svg\" alt=\"$\\sigma^z$\" data-tex=\"inline\"><\/math> \u043d\u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/16d\/a50\/7b2\/16da507b2fc389688ef0659939dcc647.svg\" alt=\"$k$\" data-tex=\"inline\"><\/math>-\u0439 \u043a\u0443\u0431\u0438\u0442, \u0430 \u043d\u0430 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435 \u043c\u044b \u0434\u0435\u0439\u0441\u0442\u0432\u0443\u0435\u043c \u0435\u0434\u0438\u043d\u0438\u0447\u043d\u044b\u043c\u0438 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430\u043c\u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/2cc\/094\/be1\/2cc094be1a835907cfd2d31b930ae185.svg\" alt=\"$\\mathbf{1}$\" data-tex=\"inline\"><\/math>. \u0417\u0430\u043f\u0438\u0448\u0435\u043c \u044d\u0442\u043e \u044f\u0432\u043d\u043e, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f \u043f\u0440\u043e\u0438\u0437\u0432\u0435\u0434\u0435\u043d\u0438\u0435 \u041a\u0440\u043e\u043d\u0435\u043a\u0435\u0440\u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/d49\/671\/14a\/d4967114ad8f993ade0096e146c71447.svg\" alt=\"$\\otimes$\" data-tex=\"inline\"><\/math>:<\/p>\n<p>  <\/p>\n<p><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/58d\/6c0\/6d8\/58d6c06d82453d8a6a038eca2a9f17c6.svg\" alt=\"$\\sigma^z_k = \\mathbf{1}\\otimes\\mathbf{1}\\otimes ... \\otimes \\sigma^z \\otimes ... \\otimes \\mathbf{1} \\otimes \\mathbf{1}$\" data-tex=\"display\"><\/math><\/p>\n<p>  <\/p>\n<p>\u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0432 \u0441\u0445\u043e\u0436\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u0434\u0440\u0443\u0433\u0438\u0435 \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u041f\u0430\u0443\u043b\u0438, \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c \u043d\u0430\u0448 TFI \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 \u043f\u0440\u043e\u0441\u0442\u043e \u0447\u0435\u0440\u0435\u0437 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0438 \u043f\u0440\u0438\u0432\u044b\u0447\u043d\u043e\u0439 \u043b\u0438\u043d\u0435\u0439\u043d\u043e\u0439 \u0430\u043b\u0433\u0435\u0431\u0440\u044b:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">import numpy as np from scipy import sparse  def sigmaz_k(k, N) -&gt; sparse.csr_matrix:     res = 1     for i in range(N):         if i == k:             res = sparse.kron(                 res,                 sparse.csr_matrix(                     np.array([[1, 0], [0, -1]], dtype=np.complex)                 )             )         else:             res = sparse.kron(res, sparse.eye(2, dtype=np.complex))      return res  def sigmax_k(k, N) -&gt; sparse.csr_matrix:     res = 1     for i in range(N):         if i == k:             res = sparse.kron(                 res,                 sparse.csr_matrix(                     np.array([[0, 1], [1, 0]], dtype=np.complex)                 )             )         else:             res = sparse.kron(res, sparse.eye(2, dtype=np.complex))      return res  def tfi_op(N, j, h) -&gt; sparse.csr_matrix:     res = sparse.csr_matrix((2 ** N, 2 ** N), dtype=np.complex)      for i in range(N - 1):         res += -j * sigmaz_k(i, N) * sigmaz_k(i + 1, N)         res += h * sigmax_k(i, N)      res += h * sigmax_k(N - 1, N)      return res<\/code><\/pre>\n<p>  <\/p>\n<p>\u042d\u0442\u043e \u043a\u0430\u043a \u0440\u0430\u0437 \u0438 \u0431\u0443\u0434\u0435\u0442 \u043d\u0430\u0448\u0430 \u043c\u0430\u0442\u0440\u0438\u0446\u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/6b2\/736\/96b\/6b273696bb3714734e8e989c3cea452f.svg\" alt=\"$2^N \\times 2^N$\" data-tex=\"inline\"><\/math>. \u0412 \u043b\u043e\u0431 \u043f\u0435\u0440\u0435\u043c\u043d\u043e\u0436\u0430\u0442\u044c \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u043d\u0435 \u0441\u0430\u043c\u044b\u0439 \u044d\u0444\u0444\u0435\u043a\u0442\u0438\u0432\u043d\u044b\u0439 \u043c\u0435\u0442\u043e\u0434, \u043c\u043e\u044f \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043d\u0430\u0438\u0432\u043d\u0430\u044f, \u043d\u043e \u0438\u0434\u0435\u0439\u043d\u043e \u044d\u0442\u043e \u0442\u043e \u0436\u0435 \u0441\u0430\u043c\u043e\u0435, \u0447\u0442\u043e \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u0432 <em>Cirq<\/em>.<\/p>\n<\/div><\/div>\n<p>  <\/p>\n<p>\u041a\u0430\u043a \u044f \u0443\u0436\u0435 \u043f\u0438\u0441\u0430\u043b, \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0435 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u044d\u0442\u043e\u0433\u043e \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 \u043c\u044b \u043b\u0435\u0433\u043a\u043e \u043d\u0430\u0439\u0434\u0435\u043c \u00ab\u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0438\u043c\u0438\u00bb \u043c\u0435\u0442\u043e\u0434\u0430\u043c\u0438 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c <a href=\"https:\/\/en.wikipedia.org\/wiki\/Arnoldi_iteration\">\u0410\u0440\u043d\u043e\u043b\u044c\u0434\u0438<\/a>) \u0432 \u043f\u0430\u0440\u0443 \u0441\u0442\u0440\u043e\u0447\u0435\u043a \u043a\u043e\u0434\u0430, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f \u0433\u043e\u0442\u043e\u0432\u044b\u0435 \u0440\u0443\u0442\u0438\u043d\u044b:<\/p>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">\u041a\u043e\u0434 \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0440\u0435\u0448\u0435\u043d\u0438\u044f \u043d\u0430\u0448\u0435\u0439 \u0437\u0430\u0434\u0430\u0447\u0438<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<p>\u0414\u043b\u044f \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u043e\u0433\u043e \u0432\u044b\u0448\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 <em>Cirq<\/em> <code>op<\/code> \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u044f\u0432\u043d\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0435\u0433\u043e \u043c\u0430\u0442\u0440\u0438\u0446\u0443, \u0432\u044b\u0437\u0432\u0430\u0432 \u043c\u0435\u0442\u043e\u0434 <code>op.matrix()<\/code>. \u041d\u0443 \u0438 \u0440\u0443\u0442\u0438\u043d\u044b \u0438\u0437 <code>scipy.sparse.linalg<\/code>.<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">from scipy import sparse from scipy.sparse import linalg  exact_sol = linalg.eigs(     sparse.csc_matrix(op.matrix()), k=1, which=&quot;SR&quot;, return_eigenvectors=False )[0] print(f&quot;Exact solution: {np.real(exact_sol):.4f}&quot;)<\/code><\/pre>\n<p>  <\/p>\n<p>\u041c\u044b \u0442\u0443\u0442 \u0431\u0435\u0440\u0435\u043c \u0440\u0435\u0430\u043b\u044c\u043d\u0443\u044e \u0447\u0430\u0441\u0442\u044c, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0438\u0437 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u043e\u0439 \u0444\u0438\u0437\u0438\u043a\u0438 \u043c\u044b \u0442\u043e\u0447\u043d\u043e \u0437\u043d\u0430\u0435\u043c, \u0447\u0442\u043e \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0445 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u043e\u0432 \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0435, \u0442\u0430\u043a \u043a\u0430\u043a \u043e\u043d\u0438 \u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u0435\u0449\u0435 \u0438 \u043f\u043e\u0442\u0435\u043d\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u043c\u0438 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430\u043c\u0438 \u0438\u0437\u043c\u0435\u0440\u0435\u043d\u0438\u0439. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432 \u0444\u0438\u0437\u0438\u043a\u0435, \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 TFI \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u0435\u0442 \u044d\u043d\u0435\u0440\u0433\u0438\u0438 \u0432 \u044d\u0412, \u0442\u043e \u0435\u0441\u0442\u044c \u0440\u0435\u0430\u043b\u044c\u043d\u043e\u0439 \u0444\u0438\u0437\u0438\u0447\u0435\u0441\u043a\u043e\u0439 \u0432\u0435\u043b\u0438\u0447\u0438\u043d\u0435.<\/p>\n<\/div><\/div>\n<p>  <\/p>\n<p>\u042d\u0442\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043d\u0430\u043c \u043f\u043e\u0442\u043e\u043c \u043f\u0440\u0438\u0433\u043e\u0434\u0438\u0442\u0441\u044f \u0434\u043b\u044f \u043e\u0446\u0435\u043d\u043a\u0438 \u0442\u043e\u0433\u043e, \u043a\u0443\u0434\u0430 \u0438 \u043a\u0430\u043a \u0441\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u043d\u0430\u0448 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0439 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c.<\/p>\n<p>  <\/p>\n<p>\u041d\u0443 \u0438 \u043d\u0430\u043a\u043e\u043d\u0435\u0446 \u0441\u0430\u043c\u043e\u0435 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u043e\u0435, \u043a\u043e\u0434 \u0434\u043b\u044f \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u044f \u043d\u0430\u0448\u0435\u0439 <strong>VQC<\/strong> \u043d\u0430 <em>Tensorflow Quantum<\/em>.<\/p>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">\u041a\u043e\u0434 \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u044f<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"python\"># \u041e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 op = get_ising_operator(qubits, j, h)  # \u041c\u043e\u0434\u0435\u043b\u044c model = tfq.layers.SampledExpectation()  # \u0412\u0435\u043a\u0442\u043e\u0440 \u043e\u0431\u0443\u0447\u0430\u0435\u043c\u044b\u0445 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 thetas = tf.Variable(np.random.random((1, 3 * dim)), dtype=tf.float32)  log_writer = tf.summary.create_file_writer(&quot;train&quot;)  for epoch in tqdm(range(epochs)):     with tf.GradientTape() as gt:         out = model(             cirquit,             symbol_names=params_x + params_y + params_z,             symbol_values=thetas,             operators=op,             repetitions=5000,         )      grad = gt.gradient(out, thetas)     thetas.assign_sub(lr * grad)      with log_writer.as_default():         tf.summary.scalar(&quot;Eigen Val&quot;, out[0, 0], step=epoch)         tf.summary.histogram(&quot;Gradients&quot;, grad, step=epoch)<\/code><\/pre>\n<p>  <\/p>\n<p><code>lr<\/code> \u0442\u0443\u0442 \u044d\u0442\u043e \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440, \u043e\u0442\u0432\u0435\u0449\u0430\u044e\u0449\u0438\u0439 \u0437\u0430 \u0441\u043a\u043e\u0440\u043e\u0441\u0442\u044c \u0433\u0440\u0430\u0434\u0438\u0435\u043d\u0442\u043d\u043e\u0433\u043e \u0441\u043f\u0443\u0441\u043a\u0430 \u0438 \u044f\u0432\u043b\u044f\u044e\u0449\u0438\u0439\u0441\u044f \u0433\u0438\u043f\u0435\u0440\u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u043c.<\/p>\n<\/div><\/div>\n<p>  <\/p>\n<p>\u042d\u0442\u043e \u043f\u0440\u043e\u0441\u0442\u0435\u0439\u0448\u0438\u0439 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0439 \u0446\u0438\u043a\u043b \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u044f \u0432 <em>Tensorflow<\/em>, \u0430 <code>model<\/code> \u2014 \u044d\u0442\u043e \u043e\u0431\u044a\u0435\u043a\u0442 \u043a\u043b\u0430\u0441\u0441\u0430 <code>tf.keras.layers.Layer<\/code>, \u0434\u043b\u044f \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0442\u044c \u0432\u0441\u0435 \u043d\u0430\u0448\u0438 \u043f\u0440\u0438\u0432\u044b\u0447\u043d\u044b\u0435 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0442\u043e\u0440\u044b, \u043b\u043e\u0433\u0433\u0435\u0440\u044b \u0438 \u043f\u0440\u0438\u0435\u043c\u044b \u0438\u0437 \u00ab\u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e\u00bb \u0433\u043b\u0443\u0431\u043e\u043a\u043e\u0433\u043e \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u044f. \u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b <strong>VQC<\/strong> \u0445\u0440\u0430\u043d\u044f\u0442\u0441\u044f \u0432 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439 \u0442\u0438\u043f\u0430 <code>tf.Variable<\/code> \u0438 \u043e\u0431\u043d\u043e\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u043f\u043e \u043f\u0440\u043e\u0441\u0442\u043e\u043c\u0443 \u043f\u0440\u0430\u0432\u0438\u043b\u0443 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/95d\/907\/043\/95d907043d4cdba4bc7f36ef43b3a04a.svg\" alt=\"$\\theta_{k+1} = \\theta_k - \\gamma \\cdot g_k$\" data-tex=\"inline\"><\/math>, \u044d\u0442\u043e \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u0430\u044f \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u0433\u0440\u0430\u0434\u0438\u0435\u043d\u0442\u043d\u043e\u0433\u043e \u0441\u043f\u0443\u0441\u043a\u0430 \u0441\u043e \u0441\u043a\u043e\u0440\u043e\u0441\u0442\u044c\u044e <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/fbc\/f2a\/da4\/fbcf2ada4d2c9c0d4c2e64f59ffe82c0.svg\" alt=\"$\\gamma$\" data-tex=\"inline\"><\/math>. \u041a\u0430\u0436\u0434\u044b\u0439 \u0440\u0430\u0437 \u043c\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c 5000 \u0438\u0437\u043c\u0435\u0440\u0435\u043d\u0438\u0439 \u0434\u043b\u044f \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u043e \u0442\u043e\u0447\u043d\u043e\u0439 \u043e\u0446\u0435\u043d\u043a\u0438 \u043e\u0436\u0438\u0434\u0430\u0435\u043c\u043e\u0433\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u043d\u0430\u0448\u0435\u0433\u043e \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/5bc\/55c\/b5d\/5bc55cb5db50ed9906fc5ab2988fed42.svg\" alt=\"$\\hat{\\mathbf{Op}}$\" data-tex=\"inline\"><\/math> \u0432 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0438\u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/6ac\/f4c\/343\/6acf4c343b77a3fc89ed6c9ec3a2cc5e.svg\" alt=\"$\\left | \\Psi(\\theta_k) \\right &gt;$\" data-tex=\"inline\"><\/math>. \u0412\u0441\u0435 \u044d\u0442\u043e \u0432 \u0442\u0435\u0447\u0435\u043d\u0438\u0435 350 \u044d\u043f\u043e\u0445. \u041d\u0430 \u043c\u043e\u0435\u043c \u043d\u043e\u0443\u0442\u0431\u0443\u043a\u0435 \u0434\u043b\u044f <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/160\/0c4\/4a1\/1600c44a107a2e49daf2d08c826ace51.svg\" alt=\"$N = 5$\" data-tex=\"inline\"><\/math>, <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/033\/887\/800\/0338878003092fa472272f739acb67dd.svg\" alt=\"$j = 1.0$\" data-tex=\"inline\"><\/math> \u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/17e\/4af\/aa6\/17e4afaa68cf4857ed132286fe192cfa.svg\" alt=\"$h = 0.5$\" data-tex=\"inline\"><\/math> \u043f\u0440\u043e\u0446\u0435\u0441\u0441 \u0437\u0430\u043d\u044f\u043b \u043f\u043e\u0440\u044f\u0434\u043a\u0430 40 \u0441\u0435\u043a\u0443\u043d\u0434.<\/p>\n<p>  <\/p>\n<p>\u0412\u0438\u0437\u0443\u0430\u043b\u0438\u0437\u0438\u0440\u0443\u0435\u043c \u0433\u0440\u0430\u0444\u0438\u043a\u0438 \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u044f (<code>scipy<\/code> \u0434\u0430\u043b \u0442\u043e\u0447\u043d\u043e\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u0435 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/238\/261\/4b4\/2382614b4ab9b983941d5aaf71cca019.svg\" alt=\"$\\simeq -0.47$\" data-tex=\"inline\"><\/math>): <code>tensoboard --logdir train\/<\/code><\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/post_images\/11e\/49c\/6e1\/11e49c6e12587c23a6724430ceda7cad.png\" alt=\"\u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u043f\u043e \u044d\u043f\u043e\u0445\u0430\u043c \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u044f\"><br \/>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/post_images\/7cf\/74e\/ba5\/7cf74eba5cff8605c8a693624be35713.png\" alt=\"\u0413\u0438\u0441\u0442\u043e\u0433\u0440\u0430\u043c\u043c\u0430 \u0433\u0440\u0430\u0434\u0438\u0435\u043d\u0442\u043e\u0432 \u043f\u043e \u044d\u043f\u043e\u0445\u0430\u043c \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u044f\"><\/p>\n<p>  <\/p>\n<p>\u042d\u0442\u043e \u0443\u0436\u0435 \u00ab\u043f\u0440\u0438\u0432\u044b\u0447\u043d\u044b\u0435\u00bb \u0432\u0441\u0435\u043c \u0441\u043f\u0435\u0446\u0438\u0430\u043b\u0438\u0441\u0442\u0430\u043c \u043f\u043e \u043c\u0430\u0448\u0438\u043d\u043d\u043e\u043c\u0443 \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u044e \u043a\u0430\u0440\u0442\u0438\u043d\u043a\u0438 <em>Tensorboard<\/em>. \u041c\u043e\u0436\u043d\u043e \u0432\u0438\u0434\u0435\u0442\u044c, \u043a\u0430\u043a \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0445\u043e\u0440\u043e\u0448\u043e \u0441\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u043a \u0442\u043e\u0447\u043d\u043e\u043c\u0443, \u0430 \u0433\u0440\u0430\u0434\u0438\u0435\u043d\u0442\u044b \u0438\u0434\u0443\u0442 \u043a \u043d\u0443\u043b\u044e.<\/p>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">\u0417\u0430\u043c\u0435\u0447\u0430\u043d\u0438\u0435 \u043f\u0440\u043e \u0442\u043e\u0447\u043d\u043e\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u0435<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<p>\u0412\u043d\u0438\u043c\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u0447\u0438\u0442\u0430\u0442\u0435\u043b\u044c \u043c\u043e\u0433 \u0437\u0430\u043c\u0435\u0442\u0438\u0442\u044c, \u0447\u0442\u043e \u0440\u0435\u0448\u0435\u043d\u0438\u0435 <strong>VQC<\/strong> \u043e\u043a\u0430\u0437\u0430\u043b\u043e\u0441\u044c \u00ab\u043d\u0438\u0436\u0435\u00bb \u0440\u0435\u0448\u0435\u043d\u0438\u044f \u043f\u0440\u044f\u043c\u043e\u0439 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438. \u042f \u0434\u0443\u043c\u0430\u044e \u043f\u0440\u0438\u0447\u0438\u043d \u0442\u0443\u0442 \u0434\u0432\u0435:<\/p>\n<p>  <\/p>\n<ol>\n<li><code>tfq.layers.SampledExpectation<\/code>, \u0441\u043a\u043e\u0440\u0435\u0435 \u0432\u0441\u0435\u0433\u043e, \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442 \u00ab\u0438\u0437\u043c\u0435\u0440\u0435\u043d\u0438\u044f\u00bb <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/66b\/235\/e64\/66b235e647fb0e8904ac12d212142bb8.svg\" alt=\"$\\left &lt; \\Psi(\\theta) \\right | $\" data-tex=\"inline\"><\/math> \u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/3e4\/3e9\/e1b\/3e43e9e1b04a6b5de769209ab3ebcb9e.svg\" alt=\"$ \\hat{\\mathbf{Op}} \\left | \\Psi(\\theta) \\right &gt; $\" data-tex=\"inline\"><\/math>, \u043f\u043e\u0441\u043b\u0435 \u0447\u0435\u0433\u043e \u0432\u044b\u0447\u0438\u0441\u043b\u044f\u0435\u0442 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u0435 \u043f\u0440\u044f\u043c\u044b\u043c \u043f\u0435\u0440\u0435\u043c\u043d\u043e\u0436\u0435\u043d\u0438\u0435\u043c \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u043d\u044b\u0445 \u0432\u043e\u043b\u043d\u043e\u0432\u044b\u0445 \u0444\u0443\u043d\u043a\u0446\u0438\u0439. \u042f \u0434\u0443\u043c\u0430\u044e, \u043e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u043f\u043e\u0433\u0440\u0435\u0448\u043d\u043e\u0441\u0442\u044c \u0436\u0438\u0432\u0435\u0442 \u0438\u043c\u0435\u043d\u043d\u043e \u0432 \u0432\u0435\u0440\u043e\u044f\u0442\u043d\u043e\u0441\u0442\u043d\u043e\u043c \u0445\u0430\u0440\u0430\u043a\u0442\u0435\u0440\u0435 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0445 \u0438\u0437\u043c\u0435\u0440\u0435\u043d\u0438\u0439 \u0438 \u0438\u0445 \u0441\u0438\u043c\u0443\u043b\u044f\u0446\u0438\u0439, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u043e\u0431\u044b\u0447\u043d\u043e \u043c\u044b \u0438\u0437\u043c\u0435\u0440\u044f\u0435\u043c \u0432\u0441\u0435 \u043f\u043e \u043e\u0441\u0438 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/0a0\/e0d\/784\/0a0e0d784e2055ff8c9c5631d8abdb6b.svg\" alt=\"$\\mathbf{Z}$\" data-tex=\"inline\"><\/math>, \u0430 \u00ab\u0444\u0430\u0437\u0443\u00bb \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u043c, \u0440\u0435\u0448\u0430\u044f \u0437\u0430\u0434\u0430\u0447\u0443 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u043e\u0439 \u0442\u043e\u043c\u043e\u0433\u0440\u0430\u0444\u0438\u0438. \u041d\u0443, \u043f\u043e \u043a\u0440\u0430\u0439\u043d\u0435\u0439 \u043c\u0435\u0440\u0435, \u044f \u0431\u044b \u0434\u0435\u043b\u0430\u043b \u0442\u0430\u043a\u043e\u0439 \u00ab\u0441\u043b\u043e\u0439\u00bb \u0438\u043c\u0435\u043d\u043d\u043e \u0442\u0430\u043a, \u0445\u043e\u0442\u044f \u043d\u0435 \u0431\u0435\u0440\u0443\u0441\u044c \u0443\u0442\u0432\u0435\u0440\u0436\u0434\u0430\u0442\u044c, \u0447\u0442\u043e \u0438\u043c\u0435\u043d\u043d\u043e \u00ab\u043f\u043e\u0434 \u043a\u0430\u043f\u043e\u0442\u043e\u043c\u00bb \u0443 <em>Tensorflow Quantum<\/em>.<\/li>\n<li>\u0418\u0442\u0435\u0440\u0430\u0442\u0438\u0432\u043d\u044b\u0435 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u044b \u0434\u0430\u044e\u0442 \u043d\u0430\u043c \u043e\u0442\u0432\u0435\u0442 \u0441 \u043c\u043d\u0438\u043c\u043e\u0439 \u0447\u0430\u0441\u0442\u044c\u044e \u043e\u0442\u043b\u0438\u0447\u043d\u043e\u0439 \u043e\u0442 \u043d\u0443\u043b\u044f, \u0447\u0442\u043e \u0433\u043e\u0432\u043e\u0440\u0438\u0442 \u043e \u0442\u043e\u043c, \u0447\u0442\u043e \u043e\u043d\u0438 \u0442\u043e\u0436\u0435 \u043d\u0435 \u0434\u043e \u043a\u043e\u043d\u0446\u0430 \u0442\u043e\u0447\u043d\u044b (\u043d\u0430 \u0442\u043e \u043e\u043d\u0438 \u0438 \u0438\u0442\u0435\u0440\u0430\u0442\u0438\u0432\u043d\u044b\u0435), \u0442\u0430\u043a \u043a\u0430\u043a \u0438\u0437 \u0444\u0438\u0437\u0438\u043a\u0438 \u043c\u044b \u0437\u043d\u0430\u0435\u043c, \u0447\u0442\u043e \u043d\u0430\u0431\u043b\u044e\u0434\u0430\u0435\u043c\u044b\u0435 \u2014 \u044d\u0442\u043e \u0432\u0441\u0435 \u0436\u0435 \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0435 \u0447\u0438\u0441\u043b\u0430. \u0412 \u0441\u0432\u043e\u044e \u043e\u0447\u0435\u0440\u0435\u0434\u044c, \u044d\u0442\u043e \u0442\u043e\u0436\u0435 \u043c\u043e\u0436\u0435\u0442 \u0434\u0430\u0432\u0430\u0442\u044c \u043d\u0435\u043a\u0438\u0439 \u00ab\u0441\u0434\u0432\u0438\u0433\u00bb, \u0442\u0430\u043a \u043a\u0430\u043a \u0432 \u0441\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u0435 \u0432\u044b\u0437\u043e\u0432\u0430 <code>scipy.linalg.eigs<\/code> \u043c\u044b \u044f\u0432\u043d\u043e \u043f\u0440\u043e\u0441\u0438\u043b\u0438 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c \u043d\u0430\u0439\u0442\u0438 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0435 \u0447\u0438\u0441\u043b\u0430 \u0441 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0439 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0439 \u0447\u0430\u0441\u0442\u044c\u044e (<code>which=&quot;SR&quot;<\/code>), \u0430, \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e, \u043d\u0430\u0434\u043e \u0431\u044b\u043b\u043e \u043f\u0440\u043e\u0441\u0438\u0442\u044c \u0447\u0442\u043e-\u0442\u043e \u0434\u0440\u0443\u0433\u043e\u0435.<\/li>\n<\/ol>\n<p>  <\/p>\n<p>\u0414\u0443\u043c\u0430\u044e, \u0447\u0442\u043e \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0444\u0430\u043a\u0442\u043e\u0440 \u2014 \u044d\u0442\u043e \u0432\u0441\u0435 \u0436\u0435 \u043f\u0435\u0440\u0432\u044b\u0439 \u043f\u0443\u043d\u043a\u0442, \u043d\u043e \u043d\u0435 \u0431\u0435\u0440\u0443\u0441\u044c \u0443\u0442\u0432\u0435\u0440\u0436\u0434\u0430\u0442\u044c \u0442\u043e\u0447\u043d\u043e. \u0412\u043e\u0437\u043c\u043e\u0436\u043d\u043e, \u043a\u0442\u043e-\u0442\u043e \u0432 \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u044f\u0445 \u043f\u043e\u0434\u0441\u043a\u0430\u0436\u0435\u0442 \u0432\u0435\u0440\u0441\u0438\u044e \u043b\u0443\u0447\u0448\u0435.<\/p>\n<\/div><\/div>\n<p>  <\/p>\n<h2 id=\"esche-para-slov-o-potenciale-takogo-eigensolver-a\">\u0415\u0449\u0435 \u043f\u0430\u0440\u0430 \u0441\u043b\u043e\u0432 \u043e \u043f\u043e\u0442\u0435\u043d\u0446\u0438\u0430\u043b\u0435 \u0442\u0430\u043a\u043e\u0433\u043e Eigensolver-\u0430<\/h2>\n<p>  <\/p>\n<p>\u041d\u0435\u0441\u043c\u043e\u0442\u0440\u044f \u043d\u0430 \u00ab\u0438\u0433\u0440\u0443\u0448\u0435\u0447\u043d\u043e\u0441\u0442\u044c\u00bb \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u0441 5-\u044e \u043a\u0443\u0431\u0438\u0442\u0430\u043c\u0438, \u044f \u0431\u044b \u0445\u043e\u0442\u0435\u043b \u0435\u0449\u0435 \u0440\u0430\u0437 \u043d\u0430\u043f\u043e\u043c\u043d\u0438\u0442\u044c, \u0447\u0442\u043e \u043c\u044b \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u043c \u0441 \u043c\u0430\u0442\u0440\u0438\u0446\u0435\u0439 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/6b2\/736\/96b\/6b273696bb3714734e8e989c3cea452f.svg\" alt=\"$2^N \\times 2^N$\" data-tex=\"inline\"><\/math>. \u0411\u043e\u043b\u0435\u0435 \u0442\u043e\u0433\u043e, \u0432 \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u0438 \u0441 \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0438\u043c\u0438 \u043c\u0435\u0442\u043e\u0434\u0430\u043c\u0438 \u0433\u043b\u0443\u0431\u043e\u043a\u043e\u0433\u043e \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u044f, \u0441\u0430\u043c\u0430 \u0438\u0434\u0435\u044f \u043e \u0442\u043e\u043c, \u0447\u0442\u043e \u043c\u044b \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0438\u0437\u0443\u0435\u043c \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0435 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/104\/345\/88d\/10434588d4e739e3fe341f7120810393.svg\" alt=\"$\\mathbf{C}^{2^N} \\to \\mathbf{C}^{2^N}$\" data-tex=\"inline\"><\/math> \u043f\u0440\u0438 \u043f\u043e\u043c\u043e\u0449\u0438 \u0432\u0441\u0435\u0433\u043e \u043b\u0438\u0448\u044c <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/11b\/bac\/909\/11bbac909816a3563f0b61feec7a26f4.svg\" alt=\"$O(N)$\" data-tex=\"inline\"><\/math> \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 (\u0432 \u043d\u0430\u0448\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0440\u043e\u0432\u043d\u043e <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/837\/b96\/280\/837b9628099dc57684e336d40e8d0730.svg\" alt=\"$3N$\" data-tex=\"inline\"><\/math>) \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043e\u0447\u0435\u043d\u044c \u043f\u0435\u0440\u0441\u043f\u0435\u043a\u0442\u0438\u0432\u043d\u043e. \u0414\u043b\u044f \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044f \u2014 \u0432 \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u043e\u043c \u0433\u043b\u0443\u0431\u043e\u043a\u043e\u043c \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u0438 \u0442\u0430\u043a\u043e\u0435 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u043a\u043e\u0434\u0438\u0440\u043e\u0432\u0430\u043b\u043e\u0441\u044c \u0431\u044b \u043a\u0432\u0430\u0434\u0440\u0430\u0442\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u0435\u0439 \u0432\u0435\u0441\u043e\u0432 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/6d6\/2c8\/ec2\/6d62c8ec2dc537586342608c8949dc3a.svg\" alt=\"$W \\in \\mathbf{C}^{2^{N + 1}}$\" data-tex=\"inline\"><\/math>, \u0442\u043e \u0435\u0441\u0442\u044c \u044d\u043a\u0441\u043f\u043e\u043d\u0435\u043d\u0446\u0438\u0430\u043b\u044c\u043d\u043e \u0431\u043e\u043b\u044c\u0448\u0438\u043c \u0447\u0438\u0441\u043b\u043e\u043c \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u0432 \u0440\u044f\u0434\u0435 \u0440\u0430\u0431\u043e\u0442 \u0431\u044b\u043b\u043e \u043f\u043e\u043a\u0430\u0437\u0430\u043d\u043e, \u0447\u0442\u043e \u0432 \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u0438 \u0441 \u043e\u0431\u044b\u0447\u043d\u044b\u043c\u0438 \u043f\u043e\u043b\u043d\u043e\u0441\u0432\u044f\u0437\u043d\u044b\u043c\u0438 \u0441\u043b\u043e\u044f\u043c\u0438 \u043d\u0435\u0439\u0440\u043e\u043d\u043d\u044b\u0445 \u0441\u0435\u0442\u0435\u0439 <strong>VQC<\/strong> \u0434\u0430\u0436\u0435 \u0431\u043e\u043b\u0435\u0435 \u00ab\u0432\u044b\u0440\u0430\u0437\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u00bb \u043f\u0440\u0438 \u0441\u0442\u043e\u043b\u044c \u043c\u0435\u043d\u044c\u0448\u0435\u043c \u0447\u0438\u0441\u043b\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432! \u0418\u043c\u0435\u043d\u043d\u043e \u044d\u0442\u0438\u043c, \u043a\u0430\u043a \u043c\u043d\u0435 \u043a\u0430\u0436\u0435\u0442\u0441\u044f, \u043e\u0431\u0443\u0441\u043b\u043e\u0432\u043b\u0435\u043d \u0442\u0430\u043a\u043e\u0439 \u0436\u0438\u0432\u043e\u0439 \u0438\u043d\u0442\u0435\u0440\u0435\u0441 \u043a \u044d\u0442\u043e\u0439 \u043e\u0431\u043b\u0430\u0441\u0442\u0438: \u0435\u0441\u043b\u0438 \u0431\u044b \u0438\u043c\u0435\u043b\u0438 \u0431\u044b \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0439 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0439 \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440, <strong>QML<\/strong> \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 \u0442\u0430\u043a\u0438\u0445 <strong>VQC<\/strong>, \u0432\u0435\u0440\u043e\u044f\u0442\u043d\u043e, \u0431\u044b\u043b\u0438 \u0431\u044b \u0433\u043e\u0440\u0430\u0437\u0434\u043e \u043a\u0440\u0443\u0447\u0435 \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u043d\u0435\u0439\u0440\u043e\u043d\u043d\u044b\u0445 \u0441\u0435\u0442\u0435\u0439 \u0432\u043e \u043c\u043d\u043e\u0433\u0438\u0445 \u0437\u0430\u0434\u0430\u0447\u0430\u0445.<\/p>\n<p>  <\/p>\n<h2 id=\"zaklyuchenie\">\u0417\u0430\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435<\/h2>\n<p>  <\/p>\n<p>\u041d\u0435\u0441\u043e\u043c\u043d\u0435\u043d\u043d\u043e, \u0441\u0435\u0439\u0447\u0430\u0441 \u043d\u0435 \u0438\u0434\u0435\u0442 \u0440\u0435\u0447\u0438 \u043e \u043a\u0430\u043a\u043e\u043c-\u0442\u043e \u0440\u0435\u0430\u043b\u044c\u043d\u043e\u043c \u043f\u0440\u0438\u043c\u0435\u043d\u0435\u043d\u0438\u0438 <strong>QML<\/strong>. \u0414\u043b\u044f \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044f\u00a0\u2014 \u043d\u0430\u0448\u0430 <strong>VQC<\/strong> \u043e\u0431\u0443\u0447\u0430\u043b\u0430\u0441\u044c \u043e\u043a\u043e\u043b\u043e 45 \u0441\u0435\u043a\u0443\u043d\u0434 \u043d\u0430 \u043c\u043e\u0435\u043c \u043d\u043e\u0443\u0442\u0431\u0443\u043a\u0435, \u0430 <code>scipy.sparse.eigs<\/code> \u043f\u043e\u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043b\u0438\u0441\u044c \u0434\u043e\u043b\u0438 \u0441\u0435\u043a\u0443\u043d\u0434, \u0447\u0442\u043e\u0431\u044b \u043d\u0430\u0439\u0442\u0438 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0435 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435. \u041a \u0442\u043e\u043c\u0443 \u0436\u0435, \u0434\u0430\u0436\u0435 \u043d\u0430 \u0441\u0438\u043c\u0443\u043b\u044f\u0442\u043e\u0440\u0435, \u0433\u0434\u0435 \u043d\u0435\u0442 \u0448\u0443\u043c\u0430, \u043e\u0446\u0435\u043d\u043a\u0430 <code>tfq.layers.SampledExpectation<\/code> \u044f\u0432\u043d\u043e \u00ab\u0445\u0440\u043e\u043c\u0430\u0435\u0442\u00bb, \u0447\u0442\u043e \u0443\u0436 \u0433\u043e\u0432\u043e\u0440\u0438\u0442\u044c \u043e \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0445 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0445 \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0430\u0445. \u041d\u043e \u0441\u0435\u0439\u0447\u0430\u0441 \u043e\u0447\u0435\u043d\u044c \u043c\u043d\u043e\u0433\u0438\u0435 \u0447\u0430\u0441\u0442\u043d\u044b\u0435 \u043a\u043e\u043c\u043f\u0430\u043d\u0438\u0438, \u0442\u0430\u043a\u0438\u0435 \u043a\u0430\u043a Google, IBM, Microsoft \u0438 \u0434\u0440\u0443\u0433\u0438\u0435, \u0430 \u0442\u0430\u043a\u0436\u0435 \u043f\u0440\u0430\u0432\u0438\u0442\u0435\u043b\u044c\u0441\u0442\u0432\u0430 \u0438 \u0438\u043d\u0441\u0442\u0438\u0442\u0443\u0442\u044b \u0442\u0440\u0430\u0442\u044f\u0442 \u043e\u0433\u0440\u043e\u043c\u043d\u044b\u0435 \u0440\u0435\u0441\u0443\u0440\u0441\u044b \u043d\u0430 \u0438\u0441\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u0438\u044f \u0432 \u0434\u0430\u043d\u043d\u043e\u043c \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0438. \u041a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0435 \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u044b \u0443\u0436\u0435 \u0441\u0435\u0433\u043e\u0434\u043d\u044f \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b \u0434\u043b\u044f \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0432 \u043e\u0431\u043b\u0430\u0447\u043d\u044b\u0445 \u0441\u0435\u0440\u0432\u0435\u0440\u0430\u0445 <a href=\"https:\/\/quantum-computing.ibm.com\/login\">IBM<\/a> \u0438 <a href=\"https:\/\/aws.amazon.com\/ru\/braket\/\">AWS<\/a>. \u041c\u043d\u043e\u0433\u0438\u0435 \u0443\u0447\u0435\u043d\u044b\u0435 \u0432\u044b\u0441\u043a\u0430\u0437\u044b\u0432\u0430\u044e\u0442 \u0443\u0432\u0435\u0440\u0435\u043d\u043d\u043e\u0441\u0442\u044c \u0432 \u0441\u043a\u043e\u0440\u043e\u043c \u0434\u043e\u0441\u0442\u0438\u0436\u0435\u043d\u0438\u0438 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u043e\u0433\u043e \u043f\u0440\u0435\u0432\u043e\u0441\u0445\u043e\u0434\u0441\u0442\u0432\u0430 \u043d\u0430 \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u0437\u0430\u0434\u0430\u0447\u0430\u0445 (\u043d\u0430\u043f\u043e\u043c\u043d\u044e, \u043f\u0440\u0435\u0432\u043e\u0441\u0445\u043e\u0434\u0441\u0442\u0432\u043e \u043d\u0430 \u0441\u043f\u0435\u0446\u0438\u0430\u043b\u044c\u043d\u043e \u0432\u044b\u0431\u0440\u0430\u043d\u043d\u043e\u0439 \u00ab\u0443\u0434\u043e\u0431\u043d\u043e\u0439\u00bb \u0434\u043b\u044f \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u043e\u0433\u043e \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0430 \u0437\u0430\u0434\u0430\u0447\u0435 \u0431\u044b\u043b\u043e <a href=\"https:\/\/www.nature.com\/articles\/s41586-019-1666-5\">\u0434\u043e\u0441\u0442\u0438\u0433\u043d\u0443\u0442\u043e Google<\/a> \u0432 \u043f\u0440\u043e\u0448\u043b\u043e\u043c \u0433\u043e\u0434\u0443). \u0412\u0441\u0435 \u044d\u0442\u043e, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0442\u0430\u0438\u043d\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0441\u0442\u044c \u0438 \u043a\u0440\u0430\u0441\u043e\u0442\u0430 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u043e\u0433\u043e \u043c\u0438\u0440\u0430, \u0434\u0435\u043b\u0430\u0435\u0442 \u044d\u0442\u0443 \u043e\u0431\u043b\u0430\u0441\u0442\u044c \u0442\u0430\u043a\u043e\u0439 \u043f\u0440\u0438\u0432\u043b\u0435\u043a\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0439. \u041d\u0430\u0434\u0435\u044e\u0441\u044c, \u044d\u0442\u0430 \u0441\u0442\u0430\u0442\u044c\u044f \u043f\u043e\u043c\u043e\u0436\u0435\u0442 \u0438 \u0432\u0430\u043c \u043f\u043e\u0433\u0440\u0443\u0437\u0438\u0442\u044c\u0441\u044f \u0432 \u0434\u0438\u0432\u043d\u044b\u0439 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0439 \u043c\u0438\u0440!<\/p>\n<p>  <\/p>\n<p>\u0412\u0435\u0441\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u044b\u0439 \u043a\u043e\u0434 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0432 \u043c\u043e\u0435\u043c <a href=\"https:\/\/github.com\/SemyonSinchenko\/VariationalEigenSolver\">GitHub<\/a>.<\/p>\n<\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/company\/raiffeisenbank\/blog\/523932\/\"> https:\/\/habr.com\/ru\/company\/raiffeisenbank\/blog\/523932\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\" data-io-article-url=\"https:\/\/habr.com\/ru\/company\/raiffeisenbank\/blog\/523932\/\">\n<p>\u041d\u0430 \u0425\u0430\u0431\u0440\u0435 \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u043d\u0435\u0442 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043f\u0440\u043e \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u043e\u0435 \u043c\u0430\u0448\u0438\u043d\u043d\u043e\u0435 \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u0435 (<strong>Q<\/strong>uantum <strong>M<\/strong>achine <strong>L<\/strong>earning), \u0438 \u0432 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u044f \u043f\u043e\u0441\u0442\u0430\u0440\u0430\u044e\u0441\u044c \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435 \u0440\u0430\u0441\u043a\u0440\u044b\u0442\u044c \u0442\u0435\u043c\u0443. \u0421\u0440\u0430\u0437\u0443 \u0441\u043a\u0430\u0436\u0443, \u0447\u0442\u043e \u043f\u0440\u043e\u043c\u044b\u0448\u043b\u0435\u043d\u043d\u044b\u0445 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0445 \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u043e\u0432 \u0441\u0435\u0433\u043e\u0434\u043d\u044f \u043d\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442, \u0432\u0441\u0435 \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0438 \u0432 \u044d\u0442\u043e\u0439 \u043e\u0431\u043b\u0430\u0441\u0442\u0438 \u043d\u043e\u0441\u044f\u0442 \u0442\u0435\u043e\u0440\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u0445\u0430\u0440\u0430\u043a\u0442\u0435\u0440, \u0430 \u0437\u0430\u0434\u0430\u0447\u0443, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0440\u0430\u0437\u0431\u0438\u0440\u0430\u0442\u044c \u0432 \u0441\u0442\u0430\u0442\u044c\u0435 \u043c\u043e\u0436\u043d\u043e \u0440\u0435\u0448\u0438\u0442\u044c \u00ab\u043f\u043e \u043a\u043b\u0430\u0441\u0441\u0438\u043a\u0435\u00bb \u0437\u0430 \u0434\u043e\u043b\u0438 \u0441\u0435\u043a\u0443\u043d\u0434. \u041d\u043e \u0432\u0435\u0434\u044c \u0435\u0449\u0435 30 \u043b\u0435\u0442 \u043d\u0430\u0437\u0430\u0434 \u0431\u044b\u043b\u0430 \u0442\u0430\u043a \u043d\u0430\u0437\u044b\u0432\u0430\u0435\u043c\u0430\u044f <a href=\"https:\/\/en.wikipedia.org\/wiki\/AI_winter\">\u00ab\u0437\u0438\u043c\u0430 \u0438\u0441\u043a\u0443\u0441\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0433\u043e \u0438\u043d\u0442\u0435\u043b\u043b\u0435\u043a\u0442\u0430\u00bb<\/a>, \u0430 \u0441\u0435\u0433\u043e\u0434\u043d\u044f \u043d\u0435\u0439\u0440\u043e\u043d\u043d\u044b\u0435 \u0441\u0435\u0442\u0438 \u0431\u0443\u043a\u0432\u0430\u043b\u044c\u043d\u043e \u043e\u043a\u0440\u0443\u0436\u0430\u044e\u0442 \u043d\u0430\u0441. \u041a\u0442\u043e \u0437\u043d\u0430\u0435\u0442, \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0432\u0441\u043a\u043e\u0440\u0435 \u0438 \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0435 \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u044b \u0441\u0442\u0430\u043d\u0443\u0442 \u043d\u0435\u043e\u0442\u044a\u0435\u043c\u043b\u0435\u043c\u043e\u0439 \u0447\u0430\u0441\u0442\u044c\u044e \u043d\u0430\u0448\u0435\u0439 \u0436\u0438\u0437\u043d\u0438? \u041a \u0442\u043e\u043c\u0443 \u0436\u0435 \u043e\u0431\u043b\u0430\u0441\u0442\u044c \u043a\u0432\u0430\u043d\u0442\u043e\u0432\u044b\u0445 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u0439, \u0430 \u0442\u0435\u043c \u0431\u043e\u043b\u0435\u0435 \u043e\u0431\u043b\u0430\u0441\u0442\u044c <strong>QML<\/strong>, \u043e\u0431\u043b\u0430\u0434\u0430\u0435\u0442 \u043e\u0441\u043e\u0431\u043e\u0439 \u043f\u0440\u0438\u0442\u044f\u0433\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c\u044e \u0438 \u0442\u0430\u0438\u043d\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0441\u0442\u044c\u044e \u0438, \u043a\u0430\u043a \u043c\u0438\u043d\u0438\u043c\u0443\u043c, \u0441\u0442\u043e\u0438\u0442 \u0431\u044b\u0442\u044c \u0437\u0430\u043c\u0435\u0447\u0435\u043d\u043d\u043e\u0439.<\/p>\n<p>  <\/p>\n<p><a href=\"https:\/\/habr.com\/ru\/company\/raiffeisenbank\/blog\/523932\/\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/rd\/kz\/wt\/rdkzwt7op3gw_boistlpqrjfl3u.jpeg\" alt=\"Head image\"><\/a><\/p>\n<p>  <\/p>\n<p>\u0412 \u0441\u0442\u0430\u0442\u044c\u0435 \u044f \u043f\u043e\u0441\u0442\u0430\u0440\u0430\u043b\u0441\u044f \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u0430\u0442\u044c \u043e <strong>QML<\/strong> \u0432 \u0446\u0435\u043b\u043e\u043c, \u0430 \u0442\u0430\u043a\u0436\u0435 \u043e\u0431 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c \u0441\u0442\u0440\u043e\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u043c \u0431\u043b\u043e\u043a\u0435 <strong>QML<\/strong> \u2014 <strong>V<\/strong>ariational <strong>Q<\/strong>uantum <strong>C<\/strong>ircuit. \u0411\u043e\u043b\u044c\u0448\u0443\u044e \u0447\u0430\u0441\u0442\u044c \u0441\u0442\u0430\u0442\u044c\u0438 \u044f \u043f\u043e\u0441\u0442\u0430\u0440\u0430\u043b\u0441\u044f \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0439, c \u043f\u0440\u0438\u043c\u0435\u0440\u0430\u043c\u0438 \u043a\u043e\u0434\u0430 \u043d\u0430 <a href=\"https:\/\/github.com\/quantumlib\/Cirq\"><em>Cirq<\/em><\/a>, \u0430 \u0432 \u043a\u043e\u043d\u0446\u0435 \u2014 \u0434\u043e\u0431\u0430\u0432\u0438\u043b \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e \u043e\u0434\u043d\u043e\u0433\u043e \u0438\u0437 \u0431\u0430\u0437\u043e\u0432\u044b\u0445 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u043e\u0432 <strong>QML<\/strong> \u043d\u0430 <a href=\"https:\/\/www.tensorflow.org\/quantum\"><em>Tensorflow Quantum<\/em><\/a>.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-311681","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/311681","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=311681"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/311681\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=311681"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=311681"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=311681"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}