{"id":322363,"date":"2021-04-29T21:00:35","date_gmt":"2021-04-29T21:00:35","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=322363"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=322363","title":{"rendered":"\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430"},"content":{"rendered":"\n<div class=\"post__text post__text_v2\" id=\"post-content-body\">\n<h2>\u0421\u043e\u0434\u0435\u0440\u0436\u0430\u043d\u0438\u0435<\/h2>\n<p><a href=\"#MainPoint\" rel=\"noopener noreferrer nofollow\">\u041e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0441\u043c\u044b\u0441\u043b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430<\/a><br \/>1. <a href=\"#Terms\" rel=\"noopener noreferrer nofollow\">\u0422\u0435\u0440\u043c\u0438\u043d\u044b \u0438 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f<\/a><br \/>2. <a href=\"#PointClass\" rel=\"noopener noreferrer nofollow\">\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u0438 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c<\/a><br \/>    2.1. <a href=\"#PointClassTheory\" rel=\"noopener noreferrer nofollow\">\u0422\u0435\u043e\u0440\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u0441\u0432\u0435\u0434\u0435\u043d\u0438\u044f<\/a><br \/>    2.2. <a href=\"#PointClassAlgorithm\" rel=\"noopener noreferrer nofollow\">\u0410\u043b\u0433\u043e\u0440\u0438\u0442\u043c \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u0438 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c<\/a><br \/>    2.3. <a href=\"#PointClassExample\" rel=\"noopener noreferrer nofollow\">\u041f\u0440\u0438\u043c\u0435\u0440 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u0438 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c<\/a><br \/>3. <a href=\"#ClassClass\" rel=\"noopener noreferrer nofollow\">\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438<\/a><br \/>    3.1. <a href=\"#ClassClassTheory\" rel=\"noopener noreferrer nofollow\">\u0422\u0435\u043e\u0440\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u0441\u0432\u0435\u0434\u0435\u043d\u0438\u044f<\/a><br \/>    3.2. <a href=\"#ClassClassAlgorithm\" rel=\"noopener noreferrer nofollow\">\u0410\u043b\u0433\u043e\u0440\u0438\u0442\u043c \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438<\/a><br \/>    3.3. <a href=\"#ClassClassExample\" rel=\"noopener noreferrer nofollow\">\u041f\u0440\u0438\u043c\u0435\u0440 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438<\/a><br \/>4. <a href=\"#KNN\" rel=\"noopener noreferrer nofollow\">\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u0438 \u043c\u0435\u0442\u043e\u0434 k-\u0431\u043b\u0438\u0436\u0430\u0439\u0448\u0438\u0445 \u0441\u043e\u0441\u0435\u0434\u0435\u0439<\/a><br \/>5. <a href=\"#Weighted\" rel=\"noopener noreferrer nofollow\">\u0412\u0437\u0432\u0435\u0448\u0435\u043d\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430<\/a><br \/>6. <a href=\"#Conclusion\" rel=\"noopener noreferrer nofollow\">\u0417\u0430\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435<\/a><\/p>\n<p>\u0415\u0441\u043b\u0438 \u0435\u0441\u0442\u044c \u0437\u0430\u043c\u0435\u0447\u0430\u043d\u0438\u044f \u0438\u043b\u0438 \u043e\u0448\u0438\u0431\u043a\u0438, \u043f\u0438\u0448\u0438\u0442\u0435 \u043d\u0430 \u043f\u043e\u0447\u0442\u0443 <a href=\"mailto:quwarm@gmail.com\" rel=\"noopener noreferrer nofollow\">quwarm@gmail.com<\/a> \u0438\u043b\u0438 \u0432 \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u044f\u0445.<\/p>\n<hr>\n<p><a class=\"anchor\" name=\"MainPoint\" id=\"MainPoint\"><\/a><\/p>\n<h2>\u041e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0441\u043c\u044b\u0441\u043b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430<\/h2>\n<p>\u041d\u0430 \u0440\u0438\u0441\u0443\u043d\u043a\u0435 1 \u0434\u0432\u0430 \u043d\u0430\u0431\u043b\u044e\u0434\u0435\u043d\u0438\u044f \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u044b \u0432 \u0432\u0438\u0434\u0435 \u043a\u0440\u0430\u0441\u043d\u044b\u0445 \u0442\u043e\u0447\u0435\u043a.<br \/>\u0426\u0435\u043d\u0442\u0440 \u043a\u043b\u0430\u0441\u0441\u0430 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d \u0432 \u0432\u0438\u0434\u0435 \u0441\u0438\u043d\u0435\u0439 \u0442\u043e\u0447\u043a\u0438.<\/p>\n<figure class=\"bordered\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/050\/89e\/663\/05089e663213887584ea2ffbad8c6153.png\" alt=\"\u0420\u0438\u0441\u0443\u043d\u043e\u043a 1. \u0414\u0432\u0443\u043c\u0435\u0440\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u0441 \u044d\u043b\u043b\u0438\u043f\u0441\u0430\u043c\u0438 \u043f\u0440\u043e\u0433\u043d\u043e\u0437\u0430\" title=\"\u0420\u0438\u0441\u0443\u043d\u043e\u043a 1. \u0414\u0432\u0443\u043c\u0435\u0440\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u0441 \u044d\u043b\u043b\u0438\u043f\u0441\u0430\u043c\u0438 \u043f\u0440\u043e\u0433\u043d\u043e\u0437\u0430\" width=\"377\" height=\"360\"><figcaption>\u0420\u0438\u0441\u0443\u043d\u043e\u043a 1. \u0414\u0432\u0443\u043c\u0435\u0440\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u0441 \u044d\u043b\u043b\u0438\u043f\u0441\u0430\u043c\u0438 \u043f\u0440\u043e\u0433\u043d\u043e\u0437\u0430<\/figcaption><\/figure>\n<p><strong>\u0412\u043e\u043f\u0440\u043e\u0441 \u2014 \u043a\u0430\u043a\u043e\u0435 \u043d\u0430\u0431\u043b\u044e\u0434\u0435\u043d\u0438\u0435 \u0431\u043b\u0438\u0436\u0435 \u043a \u0446\u0435\u043d\u0442\u0440\u0443 \u043a\u043b\u0430\u0441\u0441\u0430?<br \/><\/strong>\u041e\u0442\u0432\u0435\u0442 \u0437\u0430\u0432\u0438\u0441\u0438\u0442 \u043e\u0442 \u0442\u043e\u0433\u043e, \u043a\u0430\u043a \u0438\u0437\u043c\u0435\u0440\u044f\u0435\u0442\u0441\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435.<\/p>\n<p>\u0415\u0441\u043b\u0438 \u0438\u0437\u043c\u0435\u0440\u044f\u0442\u044c \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043f\u043e <a href=\"https:\/\/en.wikipedia.org\/wiki\/Euclidean_distance\" rel=\"noopener noreferrer nofollow\">\u043c\u0435\u0442\u0440\u0438\u043a\u0435 \u0415\u0432\u043a\u043b\u0438\u0434\u0430<\/a>, \u0442\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u043c, \u0447\u0442\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043e\u0442 \u0446\u0435\u043d\u0442\u0440\u0430 \u043a\u043b\u0430\u0441\u0441\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"(0, 0)\" alt=\"(0, 0)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/f85\/4df\/0ef\/f854df0ef36ceba64d8c5b3950ba0fbc.svg\"> \u0434\u043e \u0442\u043e\u0447\u043a\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(-4, 4)\" alt=\"(-4, 4)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/199\/2ca\/a7b\/1992caa7be11330dcae8a9f73f139677.svg\"> \u0440\u0430\u0432\u043d\u043e <img decoding=\"async\" class=\"formula inline\" source=\"\\sqrt {32}\" alt=\"\\sqrt {32}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/94b\/574\/4ae\/94b5744ae24101658f5837dffe5a43d6.svg\">, \u0434\u043e \u0442\u043e\u0447\u043a\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(5, 5)\" alt=\"(5, 5)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a84\/315\/16f\/a8431516f65f06f00f40a92f30e60008.svg\"> \u0440\u0430\u0432\u043d\u043e <img decoding=\"async\" class=\"formula inline\" source=\"\\sqrt {50}\" alt=\"\\sqrt {50}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/3c7\/4cb\/42a\/3c74cb42a8a604e8fc7dcc690eed5e4f.svg\">, \u0442. \u0435. \u0442\u043e\u0447\u043a\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"(-4, 4) \" alt=\"(-4, 4) \" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/dd0\/bb4\/92c\/dd0bb492cb5f3d92ea4171af5b87e50c.svg\"> \u0431\u043b\u0438\u0436\u0435 \u043a \u0446\u0435\u043d\u0442\u0440\u0443 \u043a\u043b\u0430\u0441\u0441\u0430.<\/p>\n<p>\u041e\u0434\u043d\u0430\u043a\u043e \u0434\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f \u0434\u0438\u0441\u043f\u0435\u0440\u0441\u0438\u044f \u0432 \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"Y\" alt=\"Y\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/efe\/5c7\/f19\/efe5c7f19c5342d2256f96c29a8ce85f.svg\"> \u043c\u0435\u043d\u044c\u0448\u0435, \u0447\u0435\u043c \u0434\u0438\u0441\u043f\u0435\u0440\u0441\u0438\u044f \u0432 \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"X\" alt=\"X\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/23b\/32f\/10a\/23b32f10a62f432ce78539190302ffb8.svg\">, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0432 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0441\u043c\u044b\u0441\u043b\u0435 \u0442\u043e\u0447\u043a\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"(-4, 4)\" alt=\"(-4, 4)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/0bc\/a53\/d32\/0bca53d329a6c145d4a67b03ceebe0c3.svg\"> \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u00ab\u043d\u0430 \u0431\u043e\u043b\u044c\u0448\u0435\u043c \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u043c \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u0438\u00bb \u043e\u0442 \u0446\u0435\u043d\u0442\u0440\u0430 \u043a\u043b\u0430\u0441\u0441\u0430, \u0447\u0435\u043c <img decoding=\"async\" class=\"formula inline\" source=\"(5, 5)\" alt=\"(5, 5)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a84\/315\/16f\/a8431516f65f06f00f40a92f30e60008.svg\">.<\/p>\n<p><a href=\"https:\/\/blogs.sas.com\/content\/iml\/2014\/07\/21\/add-prediction-ellipse.html\" rel=\"noopener noreferrer nofollow\">\u042d\u043b\u043b\u0438\u043f\u0441\u044b \u043f\u0440\u043e\u0433\u043d\u043e\u0437\u0430<\/a>, \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u043d\u044b\u0435 \u043d\u0430 \u0440\u0438\u0441\u0443\u043d\u043a\u0435, <em>\u043f\u043e\u0434\u0441\u043a\u0430\u0437\u044b\u0432\u0430\u044e\u0442<\/em>, \u0447\u0442\u043e \u0442\u043e\u0447\u043a\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"(5, 5)\" alt=\"(5, 5)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a84\/315\/16f\/a8431516f65f06f00f40a92f30e60008.svg\"> \u0431\u043b\u0438\u0436\u0435 \u043f\u043e \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044e, \u0447\u0435\u043c \u0442\u043e\u0447\u043a\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"(-4, 4)\" alt=\"(-4, 4)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/0bc\/a53\/d32\/0bca53d329a6c145d4a67b03ceebe0c3.svg\">. \u0418\u0437\u043c\u0435\u0440\u0438\u0432 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043f\u043e \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0443, \u043f\u043e\u043b\u0443\u0447\u0438\u043c, \u0447\u0442\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043e\u0442 \u0446\u0435\u043d\u0442\u0440\u0430 \u043a\u043b\u0430\u0441\u0441\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"(0, 0)\" alt=\"(0, 0)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/51b\/627\/899\/51b627899f4f92488a9cca609834feb3.svg\"> \u0434\u043e \u0442\u043e\u0447\u043a\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(-4, 4)\" alt=\"(-4, 4)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/0bc\/a53\/d32\/0bca53d329a6c145d4a67b03ceebe0c3.svg\"> \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0440\u0430\u0432\u043d\u043e <img decoding=\"async\" class=\"formula inline\" source=\"0.15686\" alt=\"0.15686\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/f02\/3e8\/af5\/f023e8af5960dc390017b248b2b8da24.svg\">, \u0434\u043e \u0442\u043e\u0447\u043a\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(5, 5)\" alt=\"(5, 5)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a84\/315\/16f\/a8431516f65f06f00f40a92f30e60008.svg\"> \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0440\u0430\u0432\u043d\u043e <img decoding=\"async\" class=\"formula inline\" source=\"0.07519\" alt=\"0.07519\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/c77\/c0f\/1e0\/c77c0f1e0bee7b5e78df588e90549783.svg\">, \u0442. \u0435. \u0442\u043e\u0447\u043a\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"(5, 5)\" alt=\"(5, 5)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a84\/315\/16f\/a8431516f65f06f00f40a92f30e60008.svg\"> \u0431\u043b\u0438\u0436\u0435 \u043a \u0446\u0435\u043d\u0442\u0440\u0443 \u043a\u043b\u0430\u0441\u0441\u0430. <strong>\u0412 \u044d\u0442\u043e\u043c \u0438 \u0437\u0430\u043a\u043b\u044e\u0447\u0430\u0435\u0442\u0441\u044f \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0441\u043c\u044b\u0441\u043b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u2014 \u0443\u0447\u0438\u0442\u044b\u0432\u0430\u043d\u0438\u0435 \u0434\u0438\u0441\u043f\u0435\u0440\u0441\u0438\u0439 \u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439.<\/strong><\/p>\n<p>\u041a\u0440\u043e\u043c\u0435 \u0442\u043e\u0433\u043e, \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043f\u0440\u0435\u0434\u043f\u043e\u043b\u0430\u0433\u0430\u0435\u0442, \u0447\u0442\u043e \u0442\u043e\u0447\u043a\u0438 \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432\u0430 \u0441\u0444\u0435\u0440\u0438\u0447\u0435\u0441\u043a\u0438 \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u044b \u0432\u043e\u043a\u0440\u0443\u0433 \u0446\u0435\u043d\u0442\u0440\u0430 \u043c\u0430\u0441\u0441.<\/p>\n<hr>\n<p><a class=\"anchor\" name=\"Terms\" id=\"Terms\"><\/a><\/p>\n<h2>1. \u0422\u0435\u0440\u043c\u0438\u043d\u044b \u0438 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f<\/h2>\n<p><strong>\u041c\u0435\u0442\u0440\u0438\u043a\u0430<\/strong> \u2014 \u0444\u0443\u043d\u043a\u0446\u0438\u044f, \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u044e\u0449\u0430\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u043b\u044e\u0431\u044b\u043c\u0438 \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u0432 \u043c\u0435\u0442\u0440\u0438\u0447\u0435\u0441\u043a\u043e\u043c \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"\\mathbb {R}^n\" alt=\"\\mathbb {R}^n\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/baf\/9a8\/915\/baf9a891575cc8e8422faf0fe0c2df9d.svg\">, \u0433\u0434\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"n\" alt=\"n\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/6ae\/56b\/4cd\/6ae56b4cd22322c05eaf737c3ec3bf00.svg\"> \u2014 \u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0441\u0442\u044c \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0430.<\/p>\n<p><strong>\u041a\u043b\u0430\u0441\u0441<\/strong> <img decoding=\"async\" class=\"formula inline\" source=\"C\" alt=\"C\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/1f6\/8c7\/dc0\/1f68c7dc0f1a4cafcacc16de87cadb24.svg\"> \u2014 \u043a\u043e\u043d\u0435\u0447\u043d\u043e\u0435 \u043d\u0435\u0443\u043f\u043e\u0440\u044f\u0434\u043e\u0447\u0435\u043d\u043d\u043e\u0435 \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432\u043e \u0441\u0445\u043e\u0436\u0438\u0445 \u043f\u043e \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u043c \u043a\u0440\u0438\u0442\u0435\u0440\u0438\u044f\u043c \u043e\u043f\u0442\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u0438 \u0442\u043e\u0447\u0435\u043a: <img decoding=\"async\" class=\"formula inline\" source=\"C=\\{ X_1,\\ldots,X_m \\}\" alt=\"C=\\{ X_1,\\ldots,X_m \\}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/796\/5cf\/bb9\/7965cfbb96b429ae992d943720bcb08f.svg\">, \u0433\u0434\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"m\" alt=\"m\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/b8b\/c51\/db6\/b8bc51db6b706a9b1f0c21506e6c093d.svg\"> \u2014 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0442\u043e\u0447\u0435\u043a \u0432 \u043a\u043b\u0430\u0441\u0441\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"C\" alt=\"C\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/dd5\/99e\/d0c\/dd599ed0c47fcee6a34315f957e227de.svg\">.<\/p>\n<p><strong>\u0422\u043e\u0447\u043a\u0430<\/strong> <img decoding=\"async\" class=\"formula inline\" source=\"X\" alt=\"X\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/8d2\/555\/2c2\/8d25552c2426da0e2254c67420160446.svg\">\u2014 \u043a\u043e\u043d\u0435\u0447\u043d\u043e\u0435 \u0443\u043f\u043e\u0440\u044f\u0434\u043e\u0447\u0435\u043d\u043d\u043e\u0435 \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432\u043e <img decoding=\"async\" class=\"formula inline\" source=\"n\" alt=\"n\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/737\/4d2\/6f1\/7374d26f15d98572caded9adf20a4ce5.svg\"> \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432: <img decoding=\"async\" class=\"formula inline\" source=\"X=(x_1,\\ldots,x_n)\" alt=\"X=(x_1,\\ldots,x_n)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/1f7\/d04\/ab1\/1f7d04ab1c25eff7e6e532235450f0cf.svg\">.<\/p>\n<p>\u0411\u0443\u0434\u0435\u043c \u043e\u0431\u043e\u0437\u043d\u0430\u0447\u0430\u0442\u044c \u0431\u0443\u043a\u0432\u043e\u0439 <img decoding=\"async\" class=\"formula inline\" source=\"n\" alt=\"n\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/b5e\/4a5\/43b\/b5e4a543be2760003d00052766b86758.svg\"> \u0447\u0438\u0441\u043b\u043e \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432, \u0430 \u0431\u0443\u043a\u0432\u043e\u0439 <img decoding=\"async\" class=\"formula inline\" source=\"i\" alt=\"i\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/f80\/044\/253\/f80044253552c18397c2c3726a5bc3fd.svg\"> \u2014 <img decoding=\"async\" class=\"formula inline\" source=\"i\" alt=\"i\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/5fa\/01f\/aa1\/5fa01faa1c7ae40c51138642a6b447b6.svg\"> \u043f\u0440\u0438\u0437\u043d\u0430\u043a.<\/p>\n<details class=\"spoiler\">\n<summary>\u041f\u0440\u0438\u043c\u0435\u0447\u0430\u043d\u0438\u044f<\/summary>\n<div class=\"spoiler__content\">\n<p><strong>\u041f\u043e\u0434 \u0441\u043b\u043e\u0432\u043e\u043c \u00ab\u0442\u043e\u0447\u043a\u0430\u00bb \u043f\u043e\u0434\u0440\u0430\u0437\u0443\u043c\u0435\u0432\u0430\u0435\u0442\u0441\u044f \u0442\u043e\u0447\u043a\u0430 \u043a\u043e\u043e\u0440\u0434\u0438\u043d\u0430\u0442\u043d\u043e\u0433\u043e <img decoding=\"async\" class=\"formula inline\" source=\"n\" alt=\"n\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/da1\/247\/0f7\/da12470f71d4476c78d9bed41b9a49d6.svg\">-\u043c\u0435\u0440\u043d\u043e\u0433\u043e \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0430 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432.<\/strong> \u041f\u0440\u0438\u0447\u0435\u043c \u0437\u0430\u043c\u0435\u0447\u0435\u043d\u043d\u044b\u0435 \u0441\u0445\u043e\u0434\u0441\u0442\u0432\u0430 \u0438 \u0440\u0430\u0437\u043b\u0438\u0447\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u043d\u0430\u0445\u043e\u0434\u044f\u0442\u0441\u044f \u0432 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0438 \u0441 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f\u043c\u0438 \u043c\u0435\u0436\u0434\u0443 \u043d\u0438\u043c\u0438.<\/p>\n<p><strong>\u041a\u043b\u0430\u0441\u0441\u044b \u0438 \u0442\u043e\u0447\u043a\u0438 \u0432 \u0441\u0442\u0430\u0442\u044c\u0435 \u043e\u0431\u043e\u0437\u043d\u0430\u0447\u0430\u044e\u0442\u0441\u044f \u043a\u0430\u043a \u0432\u0435\u043a\u0442\u043e\u0440-\u0441\u0442\u0440\u043e\u043a\u0438.<\/strong> \u0412 \u043b\u0438\u0442\u0435\u0440\u0430\u0442\u0443\u0440\u0435 \u0438 \u0418\u043d\u0442\u0435\u0440\u043d\u0435\u0442\u0435 \u043e\u043d\u0438 \u0438\u043d\u043e\u0433\u0434\u0430 \u043e\u0431\u043e\u0437\u043d\u0430\u0447\u0430\u044e\u0442\u0441\u044f \u043a\u0430\u043a \u0432\u0435\u043a\u0442\u043e\u0440-\u0441\u0442\u043e\u043b\u0431\u0446\u044b \u2014 \u0442\u043e\u0433\u0434\u0430 \u0432 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0447\u0430\u0441\u0442\u044f\u0445 \u0444\u043e\u0440\u043c\u0443\u043b \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u044f \u0442\u0440\u0430\u043d\u0441\u043f\u043e\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f <img decoding=\"async\" class=\"formula inline\" source=\"{\\square}^T\" alt=\"{\\square}^T\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/258\/98a\/b78\/25898ab7829f496cefe7eda75e5f5f65.svg\">\u0443\u0431\u0438\u0440\u0430\u0435\u0442\u0441\u044f, \u0430 \u0432 \u0434\u0440\u0443\u0433\u0438\u0445 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442\u0441\u044f.<\/p>\n<p><strong>\u0412 \u043f\u0440\u0438\u043c\u0435\u0440\u0430\u0445:<\/strong> <img decoding=\"async\" class=\"formula inline\" source=\"i\" alt=\"i\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/15c\/df0\/6c8\/15cdf06c84fe9cd8df7696ed3504d621.svg\"> \u043f\u0440\u0438\u0437\u043d\u0430\u043a \u0442\u043e\u0447\u043a\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"X\" alt=\"X\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/059\/1d5\/28a\/0591d528a4948be6989c9bd99bde4206.svg\"> \u0438\u0437 <img decoding=\"async\" class=\"formula inline\" source=\"k\" alt=\"k\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/040\/2ea\/5cf\/0402ea5cf9755825763ddc6e7d501b6d.svg\"> \u043a\u043b\u0430\u0441\u0441\u0430 \u043e\u0431\u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442\u0441\u044f \u043a\u0430\u043a <img decoding=\"async\" class=\"formula inline\" source=\"X_{(k)i}\" alt=\"X_{(k)i}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/917\/69b\/c01\/91769bc010c18a86e625a43c66104551.svg\">.<\/p>\n<p><strong>\u041f\u043e\u0434\u0440\u0430\u0437\u0443\u043c\u0435\u0432\u0430\u0435\u0442\u0441\u044f, \u0447\u0442\u043e \u043e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u044b\u0445 \u0442\u043e\u0447\u0435\u043a \u0432 \u043a\u043b\u0430\u0441\u0441\u0435 (-\u0430\u0445) \u043d\u0435\u0442.<\/strong><\/p>\n<\/div>\n<\/details>\n<p><a class=\"anchor\" name=\"PointClass\" id=\"PointClass\"><\/a><\/p>\n<h2>2. \u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u0438 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c<\/h2>\n<p>\u042d\u0442\u043e\u0442 \u043f\u0443\u043d\u043a\u0442 \u0432\u043a\u043b\u044e\u0447\u0430\u0435\u0442 \u0432\u043d\u0443\u0442\u0440\u0438\u043a\u043b\u0430\u0441\u0441\u043e\u0432\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 (\u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u0438\u0437 \u043e\u0434\u043d\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430) \u0438 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 (\u043d\u0435 \u043f\u0440\u0438\u043d\u0430\u0434\u043b\u0435\u0436\u0430\u0449\u0435\u0439 \u043d\u0438 \u043e\u0434\u043d\u043e\u043c\u0443 \u0438\u0437 \u043a\u043b\u0430\u0441\u0441\u043e\u0432) \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c.<\/p>\n<p><a class=\"anchor\" name=\"PointClassTheory\" id=\"PointClassTheory\"><\/a><\/p>\n<h3>2.1 \u0422\u0435\u043e\u0440\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u0441\u0432\u0435\u0434\u0435\u043d\u0438\u044f<\/h3>\n<p><strong>\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438<\/strong> \u2014 \u043c\u0435\u0440\u0430 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u044b\u043c\u0438 \u0442\u043e\u0447\u043a\u0430\u043c\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"U\" alt=\"U\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/8cc\/808\/d4d\/8cc808d4d54765394b1a6445c4e9fd87.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"V\" alt=\"V\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/315\/59f\/020\/31559f020ad7e1565ef840d8b9467636.svg\"> , \u043e\u0434\u043d\u0430 \u0438\u0437 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043c\u043e\u0436\u0435\u0442 (\u0438\u043b\u0438 <abbr title=\"\u0434\u043b\u044f \u0440\u0430\u0441\u0447\u0435\u0442\u0430 \u0432\u043d\u0443\u0442\u0440\u0438\u043a\u043b\u0430\u0441\u0441\u043e\u0432\u043e\u0433\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f\">\u043e\u0431\u0435 \u043c\u043e\u0433\u0443\u0442<\/abbr>) \u043f\u0440\u0438\u043d\u0430\u0434\u043b\u0435\u0436\u0430\u0442\u044c \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u043c\u0443 \u043a\u043b\u0430\u0441\u0441\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"C\" alt=\"C\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/57d\/234\/cb8\/57d234cb8d027f53703cedb94703994c.svg\"> \u0441 \u043c\u0430\u0442\u0440\u0438\u0446\u0435\u0439 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 <img decoding=\"async\" class=\"formula inline\" source=\"COV\" alt=\"COV\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/802\/db5\/ac5\/802db5ac5da2d125203506ae9ce827e8.svg\">:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_M(U, V, COV^{-1}) = \\sqrt {(U - V) \\cdot COV^{-1} \\cdot (U - V)^T}\" alt=\"d_M(U, V, COV^{-1}) = \\sqrt {(U - V) \\cdot COV^{-1} \\cdot (U - V)^T}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/c0e\/086\/521\/c0e086521e93abaf6ae5a51b71898c81.svg\" width=\"383\" height=\"35\"><\/p>\n<p>\u0421\u0438\u043c\u0432\u043e\u043b <img decoding=\"async\" class=\"formula inline\" source=\"T\" alt=\"T\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/924\/c4e\/a60\/924c4ea601b491cf2ae8f36bd387767c.svg\"> \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u044e \u0442\u0440\u0430\u043d\u0441\u043f\u043e\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u0430 \u043f\u043e\u0434 <img decoding=\"async\" class=\"formula inline\" source=\"COV^{-1}\" alt=\"COV^{-1}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/ff7\/b1b\/24c\/ff7b1b24c6be58710676d51302812fb7.svg\"> \u043f\u043e\u0434\u0440\u0430\u0437\u0443\u043c\u0435\u0432\u0430\u0435\u0442\u0441\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430, \u043e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439.<\/p>\n<p>\u0415\u0441\u043b\u0438 \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0435\u0434\u0438\u043d\u0438\u0447\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u0435\u0439, \u0442\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u0441\u044f \u0440\u0430\u0432\u043d\u044b\u043c \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044e \u0415\u0432\u043a\u043b\u0438\u0434\u0430.<br \/>\u0418\u043d\u0430\u0447\u0435 \u0433\u043e\u0432\u043e\u0440\u044f, \u0435\u0441\u043b\u0438 \u043a\u043b\u0430\u0441\u0441 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0441\u043e\u0431\u043e\u0439 \u0443\u043f\u043e\u0440\u044f\u0434\u043e\u0447\u0435\u043d\u043d\u043e\u0435 \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432\u043e \u043d\u043e\u0440\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 (\u0434\u0438\u0441\u043f\u0435\u0440\u0441\u0438\u0438 \u0440\u0430\u0432\u043d\u044b 1) \u043d\u0435\u0437\u0430\u0432\u0438\u0441\u0438\u043c\u044b\u0445 (\u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0438 \u0440\u0430\u0432\u043d\u044b 0) \u0442\u043e\u0447\u0435\u043a, \u0442\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u0440\u0430\u0432\u043d\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044e \u0415\u0432\u043a\u043b\u0438\u0434\u0430.<\/p>\n<p><strong>\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 <\/strong><a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%91%D0%B5%D0%B7%D1%80%D0%B0%D0%B7%D0%BC%D0%B5%D1%80%D0%BD%D0%B0%D1%8F_%D0%B2%D0%B5%D0%BB%D0%B8%D1%87%D0%B8%D0%BD%D0%B0\" rel=\"noopener noreferrer nofollow\"><strong>\u0431\u0435\u0437\u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e<\/strong><\/a><strong> \u0438 <\/strong><a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%9C%D0%B0%D1%81%D1%88%D1%82%D0%B0%D0%B1%D0%BD%D0%B0%D1%8F_%D0%B8%D0%BD%D0%B2%D0%B0%D1%80%D0%B8%D0%B0%D0%BD%D1%82%D0%BD%D0%BE%D1%81%D1%82%D1%8C\" rel=\"noopener noreferrer nofollow\"><strong>\u043c\u0430\u0441\u0448\u0442\u0430\u0431\u043d\u043e-\u0438\u043d\u0432\u0430\u0440\u0438\u0430\u043d\u0442\u043d\u043e<\/strong><\/a><strong>.<\/strong><\/p>\n<p><strong>\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043c\u0435\u0442\u0440\u0438\u043a\u043e\u0439<\/strong> (\u0434\u043e\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u044c\u0441\u0442\u0432\u043e<a href=\"http:\/\/www.isa.ru\/aidt\/images\/documents\/2012-01\/81_89.pdf\" rel=\"noopener noreferrer nofollow\"> <\/a><a href=\"http:\/\/www.rusnauka.com\/24_PNR_2014\/Matemathics\/4_175946.doc.htm\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a> [<a href=\"https:\/\/web.archive.org\/web\/20190907235613\/http:\/\/www.rusnauka.com\/24_PNR_2014\/Matemathics\/4_175946.doc.htm\" rel=\"noopener noreferrer nofollow\">internet archive<\/a>] \u0438 <a href=\"http:\/\/www.isa.ru\/aidt\/images\/documents\/2012-01\/81_89.pdf\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a>), \u0442. \u0435. <img decoding=\"async\" class=\"formula inline\" source=\"d_M\" alt=\"d_M\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/d76\/fb8\/81e\/d76fb881e89871a6cb940d7cffef52f2.svg\"> \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"U\" alt=\"U\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/5a9\/c8b\/10c\/5a9c8b10ce57b3d99becad1dc52bc4e6.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"V\" alt=\"V\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/b2d\/d6f\/b17\/b2dd6fb173eb801d40c159ba67b55455.svg\"> \u0441 \u043c\u0430\u0442\u0440\u0438\u0446\u0435\u0439 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 <img decoding=\"async\" class=\"formula inline\" source=\"COV\" alt=\"COV\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/b7b\/d17\/62d\/b7bd1762d91fa82d4a52de0af8a8741f.svg\"> \u0432 \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0435 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u0443\u0434\u043e\u0432\u043b\u0435\u0442\u0432\u043e\u0440\u044f\u0435\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u0430\u043a\u0441\u0438\u043e\u043c\u0430\u043c:<br \/><strong>1. <\/strong>\u0410\u043a\u0441\u0438\u043e\u043c\u0430 \u0442\u043e\u0436\u0434\u0435\u0441\u0442\u0432\u0430: <img decoding=\"async\" class=\"formula inline\" source=\"d_M(U,V,COV^{-1})=0 \\iff U=V\" alt=\"d_M(U,V,COV^{-1})=0 \\iff U=V\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e14\/ae2\/d87\/e14ae2d87464b19430a799bfafa356a1.svg\">;<br \/><strong>2. <\/strong>\u0410\u043a\u0441\u0438\u043e\u043c\u0430 \u0441\u0438\u043c\u043c\u0435\u0442\u0440\u0438\u0438: <img decoding=\"async\" class=\"formula inline\" source=\"d_M(U,V,COV^{-1})=d_M(V,U,COV^{-1})\" alt=\"d_M(U,V,COV^{-1})=d_M(V,U,COV^{-1})\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/ec7\/6fd\/f58\/ec76fdf5812e4fe4d160c1dd7beba133.svg\">;<br \/><strong>3. <\/strong>\u0410\u043a\u0441\u0438\u043e\u043c\u0430 \u0442\u0440\u0435\u0443\u0433\u043e\u043b\u044c\u043d\u0438\u043a\u0430: <img decoding=\"async\" class=\"formula inline\" source=\"d_M(U,W,COV^{-1}) \\le d_M(U,V,COV^{-1})+d_M(V,W,COV^{-1})\" alt=\"d_M(U,W,COV^{-1}) \\le d_M(U,V,COV^{-1})+d_M(V,W,COV^{-1})\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/dd2\/aab\/b1f\/dd2aabb1fa37b257ff1328292f5fe600.svg\">.<br \/>\u0418\u0437 \u044d\u0442\u0438\u0445 \u0430\u043a\u0441\u0438\u043e\u043c <a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%9C%D0%B5%D1%82%D1%80%D0%B8%D1%87%D0%B5%D1%81%D0%BA%D0%BE%D0%B5_%D0%BF%D1%80%D0%BE%D1%81%D1%82%D1%80%D0%B0%D0%BD%D1%81%D1%82%D0%B2%D0%BE#%D0%97%D0%B0%D0%BC%D0%B5%D1%87%D0%B0%D0%BD%D0%B8%D1%8F\" rel=\"noopener noreferrer nofollow\">\u0441\u043b\u0435\u0434\u0443\u0435\u0442<\/a> \u043d\u0435\u043e\u0442\u0440\u0438\u0446\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f: <img decoding=\"async\" class=\"formula inline\" source=\"d_M(U,V,COV^{-1}) \\ge 0\" alt=\"d_M(U,V,COV^{-1}) \\ge 0\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/855\/9ff\/6af\/8559ff6afd1e7fc2f2a3e9db1f5b63d1.svg\">.<\/p>\n<p>\u0418\u0437 \u0430\u043a\u0441\u0438\u043e\u043c \u0441\u043b\u0435\u0434\u0443\u0435\u0442, \u0447\u0442\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043f\u043e\u0434 \u043a\u043e\u0440\u043d\u0435\u043c \u043d\u0435 \u043c\u0435\u043d\u044c\u0448\u0435 0, \u043e\u0434\u043d\u0430\u043a\u043e <strong>\u043f\u0440\u0438 \u0440\u0430\u0441\u0447\u0435\u0442\u0430\u0445 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u043d\u0435\u0442\u043e\u0447\u043d\u044b\u0445 \u0432\u0435\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0445 \u0447\u0438\u0441\u0435\u043b \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u0442\u0441\u044f \u043f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0438\u0432\u0430\u0442\u044c \u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430 \u0441\u043b\u0435\u0432\u0430 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435\u043c 0<\/strong> (<code>max(0.0, value)<\/code>) \u0432\u043e \u0438\u0437\u0431\u0435\u0436\u0430\u043d\u0438\u0435 <a href=\"https:\/\/ru.wikipedia.org\/wiki\/NaN\" rel=\"noopener noreferrer nofollow\">NaN<\/a>, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u043f\u043e\u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043f\u043e\u0441\u043b\u0435 \u0432\u0437\u044f\u0442\u0438\u044f \u043a\u043e\u0440\u043d\u044f (\u0444\u0443\u043d\u043a\u0446\u0438\u044f <code>sqrt<\/code> \u0438\u043b\u0438 \u0432\u043e\u0437\u0432\u0435\u0434\u0435\u043d\u0438\u0435 \u0432 \u0441\u0442\u0435\u043f\u0435\u043d\u044c <code>0.5<\/code>) \u0431\u043b\u0438\u0437\u043a\u043e\u0433\u043e \u043a 0 \u0441\u043b\u0435\u0432\u0430 \u0447\u0438\u0441\u043b\u0430 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, <img decoding=\"async\" class=\"formula inline\" source=\"\\mathrm {-1e^{-17}} \\approx0\" alt=\"\\mathrm {-1e^{-17}} \\approx0\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/971\/a73\/2c0\/971a732c0b1e5c49b499233fb2c3ffb7.svg\">). \u042d\u0442\u043e\u0442 \u043d\u044e\u0430\u043d\u0441 \u0447\u0430\u0441\u0442\u043e \u043d\u0435 \u0437\u0430\u043c\u0435\u0447\u0430\u0435\u0442\u0441\u044f.<\/p>\n<p><strong>\u0427\u0442\u043e\u0431\u044b \u043d\u0430\u0439\u0442\u0438 \u0432\u043d\u0443\u0442\u0440\u0438\u043a\u043b\u0430\u0441\u0441\u043e\u0432\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430<\/strong>, \u043d\u0443\u0436\u043d\u043e \u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u044c \u0432\u044b\u0448\u0435\u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u043e\u0439 \u0444\u043e\u0440\u043c\u0443\u043b\u0435 \u2014 \u0432\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u043c\u0430\u0442\u0440\u0438\u0446\u0443 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 \u043a\u043b\u0430\u0441\u0441\u0430 \u0438 \u0437\u0430\u0442\u0435\u043c \u0441\u0430\u043c\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u0432 \u043d\u0435\u043c.<\/p>\n<p><strong>\u0427\u0442\u043e\u0431\u044b \u043d\u0430\u0439\u0442\u0438 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 (\u043d\u0435 \u043f\u0440\u0438\u043d\u0430\u0434\u043b\u0435\u0436\u0430\u0449\u0435\u0439 \u043d\u0438 \u043e\u0434\u043d\u043e\u043c\u0443 \u0438\u0437 \u043a\u043b\u0430\u0441\u0441\u043e\u0432) \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c<\/strong>, \u043d\u0443\u0436\u043d\u043e \u0442\u0430\u043a\u0436\u0435 \u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u044c \u0432\u044b\u0448\u0435\u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u043e\u0439 \u0444\u043e\u0440\u043c\u0443\u043b\u0435 \u2014 \u0432\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u043c\u0430\u0442\u0440\u0438\u0446\u0443 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 \u043a\u043b\u0430\u0441\u0441\u0430 \u0438 \u0437\u0430\u0442\u0435\u043c \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 (\u043d\u0435 \u043f\u0440\u0438\u043d\u0430\u0434\u043b\u0435\u0436\u0430\u0449\u0435\u0439 \u043d\u0438 \u043e\u0434\u043d\u043e\u043c\u0443 \u0438\u0437 \u043a\u043b\u0430\u0441\u0441\u043e\u0432) \u0438 <u>\u0446\u0435\u043d\u0442\u0440\u043e\u0438\u0434\u043e\u043c<\/u> \u043a\u043b\u0430\u0441\u0441\u0430 (\u0442. \u043d. \u00ab\u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0434\u043e \u0446\u0435\u043d\u0442\u0440\u043e\u0438\u0434\u0430\u00bb).<\/p>\n<p><strong>\u0414\u043b\u044f \u0440\u0435\u0448\u0435\u043d\u0438\u044f \u0437\u0430\u0434\u0430\u0447\u0438 \u043a\u043b\u0430\u0441\u0441\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u0442\u0435\u0441\u0442\u043e\u0432\u043e\u0439 \u0442\u043e\u0447\u043a\u0438<\/strong>, \u043d\u0443\u0436\u043d\u043e \u043d\u0430\u0439\u0442\u0438 \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 <u>\u0432\u0441\u0435\u0445<\/u> \u043a\u043b\u0430\u0441\u0441\u043e\u0432. \u0417\u0430\u0442\u0435\u043c \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043f\u043e\u0434\u0441\u0447\u0435\u0442\u0430 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0439 \u043e\u0442 \u0437\u0430\u0434\u0430\u043d\u043d\u043e\u0439 \u0442\u043e\u0447\u043a\u0438 \u0434\u043e \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u043a\u043b\u0430\u0441\u0441, \u0434\u043e \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e.<br \/>\u041d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u0435\u0442\u043e\u0434\u044b (\u0442\u0430\u043a\u0438\u0435, \u043a\u0430\u043a \u043c\u0435\u0442\u043e\u0434 <img decoding=\"async\" class=\"formula inline\" source=\"k\" alt=\"k\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/47b\/8a8\/8cd\/47b8a88cdeacefd8ae8db15068ed7d63.svg\">-\u0431\u043b\u0438\u0436\u0430\u0439\u0448\u0438\u0445 \u0441\u043e\u0441\u0435\u0434\u0435\u0439, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u0443\u0434\u0435\u0442 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d \u0432 \u043f. 4) \u043f\u043e\u0434\u0440\u0430\u0437\u0443\u043c\u0435\u0432\u0430\u044e\u0442 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0439 \u043d\u0435 \u0434\u043e \u0446\u0435\u043d\u0442\u0440\u043e\u0438\u0434\u043e\u0432 \u043a\u043b\u0430\u0441\u0441\u043e\u0432, \u0430 \u0434\u043e \u0432\u0441\u0435\u0445 \u0442\u043e\u0447\u0435\u043a \u0432\u0441\u0435\u0445 \u043a\u043b\u0430\u0441\u0441\u043e\u0432.<\/p>\n<p>\u041f\u0435\u0440\u0435\u0434 \u0442\u0435\u043c, \u043a\u0430\u043a \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u044c \u043c\u0430\u0442\u0440\u0438\u0446\u0443 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0432\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u044f<strong>*<\/strong> \u0442\u043e\u0447\u0435\u043a \u043a\u043b\u0430\u0441\u0441\u0430 \u043f\u043e \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0430\u043c.<\/p>\n<details class=\"spoiler\">\n<summary>*<\/summary>\n<div class=\"spoiler__content\">\n<p>\u041d\u0430 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0435 \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u0435 \u043e\u0431\u044b\u0447\u043d\u043e \u043e\u0446\u0435\u043d\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u043a\u0430\u043a \u0441\u0440\u0435\u0434\u043d\u0435\u0435 \u0430\u0440\u0438\u0444\u043c\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"\\mu_i = \\frac {1} {|C|} \\sum_{X \\in C} {X_i}\" alt=\"\\mu_i = \\frac {1} {|C|} \\sum_{X \\in C} {X_i}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/d7f\/085\/c44\/d7f085c44e2cfa25b00bb3356bf497b9.svg\" width=\"119\" height=\"46\"><\/p>\n<p>\u0433\u0434\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"\\mu_i\" alt=\"\\mu_i\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/c7d\/fbc\/58c\/c7dfbc58c788451e9d55a2fbae02e6a4.svg\"> \u2014 \u0441\u0440\u0435\u0434\u043d\u0435\u0435 \u0430\u0440\u0438\u0444\u043c\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0442\u043e\u0447\u0435\u043a \u043a\u043b\u0430\u0441\u0441\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"C\" alt=\"C\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/c4b\/22c\/8d6\/c4b22c8d63b2c83faf0aed17eff48b07.svg\"> \u043f\u043e <img decoding=\"async\" class=\"formula inline\" source=\"i\" alt=\"i\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a78\/5eb\/d43\/a785ebd43e73b4aed30332a2db6013a2.svg\"> \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0443, <img decoding=\"async\" class=\"formula inline\" source=\"|C|\" alt=\"|C|\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/44d\/e92\/137\/44de92137799ebdc4acf6569ea323242.svg\">\u2014 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0442\u043e\u0447\u0435\u043a \u0432 \u043a\u043b\u0430\u0441\u0441\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"C\" alt=\"C\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/3bc\/672\/19b\/3bc67219b76cdb01d4cbb5a5384fa018.svg\">, <img decoding=\"async\" class=\"formula inline\" source=\"X_i\" alt=\"X_i\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/943\/de3\/f10\/943de3f109ea7cc7a4d98db187be45ca.svg\"> \u2014 <img decoding=\"async\" class=\"formula inline\" source=\"i\" alt=\"i\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/ff7\/ec6\/9a3\/ff7ec69a3b82fa6b6700208e23447907.svg\"> \u043f\u0440\u0438\u0437\u043d\u0430\u043a \u0442\u043e\u0447\u043a\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"X\" alt=\"X\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/f0a\/1b5\/00b\/f0a1b500b2e6780b58711ec047d4231a.svg\">.<\/p>\n<p>\u0426\u0435\u043d\u0442\u0440\u043e\u0438\u0434 <img decoding=\"async\" class=\"formula inline\" source=\"\\mu\" alt=\"\\mu\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/6a3\/94b\/79f\/6a394b79f9c7e917c2b22667d3647785.svg\"> \u043a\u043b\u0430\u0441\u0441\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"C\" alt=\"C\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a5d\/b51\/2a6\/a5db512a6e0f0d71680601b53450e85b.svg\">:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"\\mu = ( \\mu_1, \\ldots, \\mu_n ) = \\left ( \\frac {1} {|C|} \\sum_{X \\in C} {X_i} \\middle| i=1 \\ldots n \\right )\" alt=\"\\mu = ( \\mu_1, \\ldots, \\mu_n ) = \\left ( \\frac {1} {|C|} \\sum_{X \\in C} {X_i} \\middle| i=1 \\ldots n \\right )\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/91d\/120\/017\/91d1200176cdf23ae638a73ed7c295db.svg\" width=\"327\" height=\"54\"><\/div>\n<\/details>\n<p><a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%9A%D0%BE%D0%B2%D0%B0%D1%80%D0%B8%D0%B0%D1%86%D0%B8%D1%8F\" rel=\"noopener noreferrer nofollow\"><strong>\u041a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u044f<\/strong><\/a> \u2014 \u044d\u0442\u043e \u0447\u0438\u0441\u043b\u0435\u043d\u043d\u043e\u0435 \u0432\u044b\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u0430 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u043d\u0442\u043d\u043e\u0441\u0442\u0438 \u0434\u0432\u0443\u0445 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u0442\u043e\u0447\u0435\u043a.<br \/>\u0421\u0432\u043e\u0439\u0441\u0442\u0432\u043e \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u043d\u0442\u043d\u043e\u0441\u0442\u0438 \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442, \u0447\u0442\u043e \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0438 \u0438\u043c\u0435\u044e\u0442 \u0442\u0435\u043d\u0434\u0435\u043d\u0446\u0438\u044e \u0438\u0437\u043c\u0435\u043d\u044f\u0442\u044c\u0441\u044f \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u043e (\u043a\u043e\u0432\u0430\u0440\u0438\u0430\u043d\u0442\u043d\u043e).<\/p>\n<p><a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%9A%D0%BE%D0%B2%D0%B0%D1%80%D0%B8%D0%B0%D1%86%D0%B8%D0%BE%D0%BD%D0%BD%D0%B0%D1%8F_%D0%BC%D0%B0%D1%82%D1%80%D0%B8%D1%86%D0%B0\" rel=\"noopener noreferrer nofollow\"><strong>\u041a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430<\/strong><\/a> \u0441\u043e\u0441\u0442\u043e\u0438\u0442 \u0438\u0437 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 \u043c\u0435\u0436\u0434\u0443 \u0432\u0441\u0435\u043c\u0438 \u043f\u0430\u0440\u0430\u043c\u0438 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432. \u0415\u0441\u043b\u0438 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u0440\u0430\u0432\u043d\u043e <img decoding=\"async\" class=\"formula inline\" source=\"n\" alt=\"n\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/85c\/137\/204\/85c1372048e88bad4d4346b98395aa06.svg\">, \u0442\u043e \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u2014 \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0441\u0442\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"n \\times n\" alt=\"n \\times n\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/8d8\/224\/c05\/8d8224c05544e6e9ae6313496249a688.svg\">, \u0438\u043c\u0435\u044e\u0449\u0430\u044f \u0432\u0438\u0434:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"COV= \\begin{pmatrix} cov_{1,1} &amp; cov_{1,2} &amp; \\cdots &amp; cov_{1,n} \\\\ cov_{2,1} &amp; cov_{2,2} &amp; \\cdots &amp; cov_{2,n} \\\\ \\vdots &amp; \\vdots &amp; \\ddots &amp; \\vdots \\\\ cov_{n,1} &amp; cov_{n,2} &amp; \\cdots &amp; cov_{n,n} \\end{pmatrix}\" alt=\"COV= \\begin{pmatrix} cov_{1,1} &amp; cov_{1,2} &amp; \\cdots &amp; cov_{1,n} \\\\ cov_{2,1} &amp; cov_{2,2} &amp; \\cdots &amp; cov_{2,n} \\\\ \\vdots &amp; \\vdots &amp; \\ddots &amp; \\vdots \\\\ cov_{n,1} &amp; cov_{n,2} &amp; \\cdots &amp; cov_{n,n} \\end{pmatrix}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/5f6\/d4d\/a7a\/5f6d4da7a45486b4288a9efbe592edd8.svg\" width=\"295\" height=\"107\"><\/p>\n<p><strong>\u042d\u043b\u0435\u043c\u0435\u043d\u0442\u044b \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b<\/strong> \u2014 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0438 \u2014 \u0434\u043b\u044f \u043d\u0430\u0431\u043e\u0440\u0430 \u0442\u043e\u0447\u0435\u043a \u0432\u044b\u0447\u0438\u0441\u043b\u044f\u044e\u0442\u0441\u044f \u043f\u043e \u0444\u043e\u0440\u043c\u0443\u043b\u0435 (\u043d\u0435\u0441\u043c\u0435\u0449\u0435\u043d\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u044f, \u0430\u043d\u0433\u043b. \u00absample covariance\u00bb):<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"cov_{a,b} = \\frac {1} {|C|-1} \\sum_{X \\in C} {(X_a - \\mu_a) \\cdot (X_b - \\mu_b)} \\tag {SC}\" alt=\"cov_{a,b} = \\frac {1} {|C|-1} \\sum_{X \\in C} {(X_a - \\mu_a) \\cdot (X_b - \\mu_b)} \\tag {SC}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/686\/2fd\/67c\/6862fd67cae741cafd8c9529862d234e.svg\" width=\"734\" height=\"47\"><\/p>\n<p>\u0433\u0434\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"\\mu_a\" alt=\"\\mu_a\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/74d\/b07\/ba4\/74db07ba44ed1a2d19d7dcba291cd08a.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"\\mu_b\" alt=\"\\mu_b\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/8bd\/33a\/fa1\/8bd33afa149081e2b99ce5b98e72af6c.svg\"> \u2014 \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u044f \u043f\u043e <img decoding=\"async\" class=\"formula inline\" source=\"a\" alt=\"a\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/483\/5c2\/b29\/4835c2b29aa2efc11e1e5ae70c7940a7.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"b\" alt=\"b\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/eef\/a03\/9a3\/eefa039a3e3deae3d48514495d28d218.svg\"> \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0430\u043c \u0442\u043e\u0447\u0435\u043a \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e.<\/p>\n<p>\u0424\u043e\u0440\u043c\u0443\u043b\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"\\mathrm {(SC)}\" alt=\"\\mathrm {(SC)}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/bc2\/1a7\/dcd\/bc21a7dcd85e0b0f20f4ed30bbb7ab56.svg\"> \u043d\u0443\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u0432 \u0442\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435, \u0435\u0441\u043b\u0438 \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u044f \u0433\u0435\u043d\u0435\u0440\u0430\u043b\u044c\u043d\u043e\u0439 \u0441\u043e\u0432\u043e\u043a\u0443\u043f\u043d\u043e\u0441\u0442\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"\\operatorname E_a\" alt=\"\\operatorname E_a\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/488\/560\/26e\/48856026e1e6a9e00122812814ccc72e.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"\\operatorname E_b\" alt=\"\\operatorname E_b\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/02f\/e80\/ed1\/02fe80ed1a2a80c986530d2da0647941.svg\"> <em>\u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u0435\u043c\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430<\/em> \u043d\u0435\u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b. \u0415\u0441\u043b\u0438 \u0436\u0435 \u043e\u043d\u0438 \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b, \u0442\u043e \u0444\u043e\u0440\u043c\u0443\u043b\u0430 \u0438\u043c\u0435\u0435\u0442 \u0432\u0438\u0434 (\u0441\u043c\u0435\u0449\u0435\u043d\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u044f, \u0430\u043d\u0433\u043b. \u00abpopulation covariance\u00bb):<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"cov_{a,b} = \\frac {1} {|C|} \\sum_{X \\in C} {(X_a - \\operatorname E_a) \\cdot (X_b - \\operatorname E_b)} \\tag {PC}\" alt=\"cov_{a,b} = \\frac {1} {|C|} \\sum_{X \\in C} {(X_a - \\operatorname E_a) \\cdot (X_b - \\operatorname E_b)} \\tag {PC}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/86d\/4ef\/dbf\/86d4efdbf830ce1937196dadaf5ba744.svg\" width=\"734\" height=\"47\"><\/p>\n<p><strong>\u041a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u044f \u043e\u0431\u043b\u0430\u0434\u0430\u0435\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c\u0438 \u0432\u0430\u0436\u043d\u044b\u043c\u0438 \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u0430\u043c\u0438:<\/strong><\/p>\n<ol>\n<li>\n<p>\u0415\u0441\u043b\u0438 \u043f\u0440\u0438 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0435 \u043e\u0442 \u043e\u0434\u043d\u043e\u0439 \u0442\u043e\u0447\u043a\u0438 \u043a \u0434\u0440\u0443\u0433\u043e\u0439 <img decoding=\"async\" class=\"formula inline\" source=\"a\" alt=\"a\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/462\/b9c\/f85\/462b9cf85a750c50f20f732aa9a20362.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"b\" alt=\"b\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/07d\/7bc\/2a3\/07d7bc2a3dda9e719ee6068ce4646429.svg\"> \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0438 \u0443\u0432\u0435\u043b\u0438\u0447\u0438\u0432\u0430\u044e\u0442\u0441\u044f (\u0443\u043c\u0435\u043d\u044c\u0448\u0430\u044e\u0442\u0441\u044f) \u0432\u043c\u0435\u0441\u0442\u0435, \u0442\u043e <img decoding=\"async\" class=\"formula inline\" source=\"cov_{a,b}&gt;0\" alt=\"cov_{a,b}&gt;0\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/faf\/07a\/9e9\/faf07a9e95c345f811620c58ea69f13b.svg\">;<\/p>\n<\/li>\n<li>\n<p>\u0415\u0441\u043b\u0438 \u043f\u0440\u0438 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0435 \u043e\u0442 \u043e\u0434\u043d\u043e\u0439 \u0442\u043e\u0447\u043a\u0438 \u043a \u0434\u0440\u0443\u0433\u043e\u0439 <img decoding=\"async\" class=\"formula inline\" source=\"a\" alt=\"a\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/462\/b9c\/f85\/462b9cf85a750c50f20f732aa9a20362.svg\"> \u043f\u0440\u0438\u0437\u043d\u0430\u043a \u0443\u0432\u0435\u043b\u0438\u0447\u0438\u0432\u0430\u0435\u0442\u0441\u044f, \u0430 <img decoding=\"async\" class=\"formula inline\" source=\"b\" alt=\"b\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/07d\/7bc\/2a3\/07d7bc2a3dda9e719ee6068ce4646429.svg\"> \u0443\u043c\u0435\u043d\u044c\u0448\u0430\u0435\u0442\u0441\u044f (\u0438\u043b\u0438 \u043d\u0430\u043e\u0431\u043e\u0440\u043e\u0442), \u0442\u043e <img decoding=\"async\" class=\"formula inline\" source=\"cov_{a,b}&lt;0\" alt=\"cov_{a,b}&lt;0\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/690\/71d\/1f4\/69071d1f4c99f8846b89f3abe097efa2.svg\">;<\/p>\n<\/li>\n<li>\n<p>\u0415\u0441\u043b\u0438 \u043f\u0440\u0438 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0435 \u043e\u0442 \u043e\u0434\u043d\u043e\u0439 \u0442\u043e\u0447\u043a\u0438 \u043a \u0434\u0440\u0443\u0433\u043e\u0439 <img decoding=\"async\" class=\"formula inline\" source=\"a\" alt=\"a\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/462\/b9c\/f85\/462b9cf85a750c50f20f732aa9a20362.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"b\" alt=\"b\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/07d\/7bc\/2a3\/07d7bc2a3dda9e719ee6068ce4646429.svg\"> \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0438 \u0438\u0437\u043c\u0435\u043d\u044f\u044e\u0442\u0441\u044f \u043d\u0435\u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e, \u0442\u043e <img decoding=\"async\" class=\"formula inline\" source=\"cov_{a,b}=0\" alt=\"cov_{a,b}=0\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/21d\/720\/bda\/21d720bda741bff795dfb3fabf332be0.svg\">(\u043e\u0431\u0440\u0430\u0442\u043d\u043e\u0435 \u0443\u0442\u0432\u0435\u0440\u0436\u0434\u0435\u043d\u0438\u0435 \u0432 \u043e\u0431\u0449\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043d\u0435\u0432\u0435\u0440\u043d\u043e<strong>*<\/strong>).<\/p>\n<\/li>\n<li>\n<p>\u041a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u044f \u0441\u0438\u043c\u043c\u0435\u0442\u0440\u0438\u0447\u043d\u0430: <img decoding=\"async\" class=\"formula inline\" source=\"cov_{a,b} = cov_{b,a}\" alt=\"cov_{a,b} = cov_{b,a}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/b4d\/89d\/dfd\/b4d89ddfd17336b65276c44d02ced321.svg\">.<\/p>\n<\/li>\n<li>\n<p>\u041d\u0435\u0440\u0430\u0432\u0435\u043d\u0441\u0442\u0432\u043e \u041a\u043e\u0448\u0438 \u2014 \u0411\u0443\u043d\u044f\u043a\u043e\u0432\u0441\u043a\u043e\u0433\u043e: <img decoding=\"async\" class=\"formula inline\" source=\"\\left|{cov_{a,b}}\\right| \\leq \\sigma_a \\sigma_b\" alt=\"\\left|{cov_{a,b}}\\right| \\leq \\sigma_a \\sigma_b\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/197\/bda\/b26\/197bdab26e071e11b11c6142d2eb0ffc.svg\">.<\/p>\n<\/li>\n<\/ol>\n<details class=\"spoiler\">\n<summary>*<\/summary>\n<div class=\"spoiler__content\">\n<p>\u041f\u0443\u0441\u0442\u044c <img decoding=\"async\" class=\"formula inline\" source=\"X\" alt=\"X\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/79d\/00d\/07d\/79d00d07d60f758d900074e289e382a4.svg\"> \u2014 \u0440\u0430\u0432\u043d\u043e\u043c\u0435\u0440\u043d\u043e \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u0430\u044f \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u0430\u044f \u0432\u0435\u043b\u0438\u0447\u0438\u043d\u0430 \u0432 <img decoding=\"async\" class=\"formula inline\" source=\"[-1, 1]\" alt=\"[-1, 1]\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/331\/bd2\/f4c\/331bd2f4cacbe89ca4c786c31ac44f74.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"Y=X^2\" alt=\"Y=X^2\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/76c\/0ab\/7e1\/76c0ab7e1bcea1704a67b4b70b1ca3d0.svg\">.<br \/><img decoding=\"async\" class=\"formula inline\" source=\"X\" alt=\"X\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/79d\/00d\/07d\/79d00d07d60f758d900074e289e382a4.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"Y\" alt=\"Y\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/551\/90e\/74e\/55190e74eb3fd06f36ccc6ec6401b15f.svg\"> \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u044b, \u043d\u043e:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"\\operatorname {cov}(X, Y) = \\operatorname {cov}(X, X^2) = M[X \\cdot X^2] - M[X] \\cdot M[X^2] = \\\\ = M[X^3] - M[X] \\cdot M[X^2] =0-0 \\cdot M[X^2] = 0\" alt=\"\\operatorname {cov}(X, Y) = \\operatorname {cov}(X, X^2) = M[X \\cdot X^2] - M[X] \\cdot M[X^2] = \\\\ = M[X^3] - M[X] \\cdot M[X^2] =0-0 \\cdot M[X^2] = 0\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/6e1\/a76\/06a\/6e1a7606ad962cd54bd97ed9a1a3f542.svg\" width=\"652\" height=\"48\"><\/p>\n<p>\u0433\u0434\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"M\" alt=\"M\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/491\/0d3\/30a\/4910d330a4b0b78661ba3dfc79dc9b70.svg\"> \u2014 \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u0435.<\/p>\n<\/div>\n<\/details>\n<p>\u041f\u0435\u0440\u0432\u044b\u0435 \u0442\u0440\u0438 \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u0430 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0438 \u043f\u0440\u043e\u0438\u043b\u043b\u044e\u0441\u0442\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u044b \u043d\u0430 \u0440\u0438\u0441\u0443\u043d\u043a\u0435 2.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/69b\/fd7\/06a\/69bfd706a317c346accfffb14f6fc5b0.png\" alt=\"\u0420\u0438\u0441\u0443\u043d\u043e\u043a 2. \u0417\u043d\u0430\u043a \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0438 \u0434\u0432\u0443\u0445 \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u044b\u0445 \u0432\u0435\u043b\u0438\u0447\u0438\u043d X \u0438 Y\" title=\"\u0420\u0438\u0441\u0443\u043d\u043e\u043a 2. \u0417\u043d\u0430\u043a \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0438 \u0434\u0432\u0443\u0445 \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u044b\u0445 \u0432\u0435\u043b\u0438\u0447\u0438\u043d X \u0438 Y\" width=\"960\" height=\"300\"><figcaption>\u0420\u0438\u0441\u0443\u043d\u043e\u043a 2. \u0417\u043d\u0430\u043a \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0438 \u0434\u0432\u0443\u0445 \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u044b\u0445 \u0432\u0435\u043b\u0438\u0447\u0438\u043d X \u0438 Y<\/figcaption><\/figure>\n<p>\u0422\u0430\u043a \u043a\u0430\u043a \u0434\u043b\u044f \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u043d\u0430\u0439\u0442\u0438 \u043e\u0431\u0440\u0430\u0442\u043d\u0443\u044e \u043a <img decoding=\"async\" class=\"formula inline\" source=\"COV\" alt=\"COV\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e6d\/1b8\/4ef\/e6d1b84ef60357c33c631ceb5502efc8.svg\"> \u043c\u0430\u0442\u0440\u0438\u0446\u0443, \u0430 \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043e\u0431\u0440\u0430\u0442\u0438\u043c\u0430 \u0442\u043e\u0433\u0434\u0430 \u0438 \u0442\u043e\u043b\u044c\u043a\u043e \u0442\u043e\u0433\u0434\u0430, \u043a\u043e\u0433\u0434\u0430 \u043e\u043d\u0430 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043a\u0432\u0430\u0434\u0440\u0430\u0442\u043d\u043e\u0439 \u0438 \u043d\u0435\u0432\u044b\u0440\u043e\u0436\u0434\u0435\u043d\u043d\u043e\u0439 (\u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u0435\u043b\u044c \u043d\u0435 \u0440\u0430\u0432\u0435\u043d \u043d\u0443\u043b\u044e), \u0442\u043e <u>\u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0438 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e, \u0447\u0442\u043e\u0431\u044b \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u0435\u043b\u044c \u043c\u0430\u0442\u0440\u0438\u0446\u044b<\/u> <img decoding=\"async\" class=\"formula inline\" source=\"COV\" alt=\"COV\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e6d\/1b8\/4ef\/e6d1b84ef60357c33c631ceb5502efc8.svg\"> <u>\u043d\u0435 \u0440\u0430\u0432\u043d\u044f\u043b\u0441\u044f \u043d\u0443\u043b\u044e<\/u>. <strong>\u041e\u0434\u043d\u0430\u043a\u043e \u0442\u0430\u043a\u043e\u0435 \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u0435 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0441\u0435\u0440\u044c\u0435\u0437\u043d\u044b\u043c \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u0435\u043c.<\/strong><\/p>\n<p><strong>\u0418\u0437\u0432\u0435\u0441\u0442\u043d\u043e, \u0447\u0442\u043e \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043d\u0435\u043e\u0431\u0440\u0430\u0442\u0438\u043c\u0430 \u0432 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0445 <u>\u0447\u0430\u0441\u0442\u043d\u044b\u0445<\/u> \u0441\u043b\u0443\u0447\u0430\u044f\u0445:<\/strong><br \/><strong>1. <\/strong>\u0415\u0441\u043b\u0438 \u043f\u043e \u043a\u0430\u043a\u043e\u043c\u0443-\u043b\u0438\u0431\u043e \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"i\" alt=\"i\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/c77\/229\/560\/c77229560d56941d774cc170173861c2.svg\"> \u0432\u0441\u0435 \u0442\u043e\u0447\u043a\u0438 \u043a\u043b\u0430\u0441\u0441\u0430 \u0438\u043c\u0435\u044e\u0442 \u043e\u0434\u043d\u043e \u0438 \u0442\u043e \u0436\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0438, \u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e, \u0441\u0440\u0435\u0434\u043d\u0435\u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u0435 \u043f\u043e \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"i\" alt=\"i\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/ff4\/c96\/22d\/ff4c9622da61ae7256a4b04164893c38.svg\"> \u0440\u0430\u0432\u043d\u043e \u043d\u0443\u043b\u044e.<br \/>\u041f\u0440\u0438\u043c\u0435\u0440: <img decoding=\"async\" class=\"formula inline\" source=\"\\{ (1, 1), (2, 1), (3, 1) \\}\" alt=\"\\{ (1, 1), (2, 1), (3, 1) \\}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/b28\/f10\/8bf\/b28f108bfa1222970f6cda3257acd511.svg\">.<br \/><strong>2. <\/strong>\u0415\u0441\u043b\u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0438 \u0432\u0441\u0435\u0445 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u044b (<img decoding=\"async\" class=\"formula inline\" source=\"\\forall a \\forall b \\space cov_{a,b}=\\sigma_a \\sigma_b\" alt=\"\\forall a \\forall b \\space cov_{a,b}=\\sigma_a \\sigma_b\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/662\/b65\/e38\/662b65e381ef4aae74184926f8e22b85.svg\">, \u00abperfect covariance\u00bb). \u041f\u0440\u0438\u043c\u0435\u0440\u044b:<br \/><img decoding=\"async\" class=\"formula inline\" source=\"\\{(1, 1), (2, 2), (3, 3)\\}\" alt=\"\\{(1, 1), (2, 2), (3, 3)\\}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/cf2\/849\/260\/cf28492600f113f6c3dc3f355713edcc.svg\"> \u2014 \u0438\u0434\u0435\u0430\u043b\u044c\u043d\u0430\u044f \u043f\u043e\u043b\u043e\u0436\u0438\u0442\u0435\u043b\u044c\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u044f;<br \/><img decoding=\"async\" class=\"formula inline\" source=\"\\{(1, 3), (2, 2), (3, 1)\\}\" alt=\"\\{(1, 3), (2, 2), (3, 1)\\}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/ac4\/89c\/897\/ac489c8976293d682d1579e970c83255.svg\"> \u2014 \u0438\u0434\u0435\u0430\u043b\u044c\u043d\u0430\u044f \u043e\u0442\u0440\u0438\u0446\u0430\u0442\u0435\u043b\u044c\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u044f.<br \/><strong>3. <\/strong>\u0415\u0441\u043b\u0438 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0442\u043e\u0447\u0435\u043a \u0432 \u043a\u043b\u0430\u0441\u0441\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"|C|\" alt=\"|C|\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e86\/365\/0e7\/e863650e7696724a00ad1ef81df54d04.svg\"> \u043c\u0435\u043d\u044c\u0448\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u0430 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 <img decoding=\"async\" class=\"formula inline\" source=\"n\" alt=\"n\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/ffe\/db2\/96a\/ffedb296aaebe9147b78cf7f30009412.svg\"> \u043f\u043b\u044e\u0441 <img decoding=\"async\" class=\"formula inline\" source=\"1\" alt=\"1\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/94f\/a69\/e7e\/94fa69e7e8fdecc9d485c3ab1c2269d2.svg\">:<br \/><img decoding=\"async\" class=\"formula inline\" source=\"|C|&lt;n+1\" alt=\"|C|&lt;n+1\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/b33\/177\/7db\/b331777db17e864e068656a32490b2a1.svg\"><br \/>\u0415\u0441\u0442\u044c \u0438 \u0434\u0440\u0443\u0433\u0438\u0435 \u0441\u043b\u0443\u0447\u0430\u0438.<\/p>\n<p><strong>\u0427\u0442\u043e \u0434\u0435\u043b\u0430\u0442\u044c, \u0435\u0441\u043b\u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043d\u0435\u043e\u0431\u0440\u0430\u0442\u0438\u043c\u0430?<\/strong><br \/>\u0415\u0434\u0438\u043d\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u043e\u0433\u043e \u043f\u043e\u0434\u0445\u043e\u0434\u0430 \u043d\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442.<br \/>\u041e\u0434\u043d\u0430\u043a\u043e \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 \u0446\u0435\u043b\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c \u0438\u0441\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u0438\u0439, \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u043d\u0430\u044f \u043d\u0430 <a href=\"https:\/\/en.wikipedia.org\/wiki\/Regularization_(mathematics)\" rel=\"noopener noreferrer nofollow\">\u0440\u0435\u0433\u0443\u043b\u044f\u0440\u0438\u0437\u0430\u0446\u0438\u044e<\/a> \u044d\u0442\u043e\u0439 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b.<br \/>\u0422\u0440\u0438 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u044b\u0435 \u0432\u044b\u0448\u0435 \u0438 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0434\u0440\u0443\u0433\u0438\u0435 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b \u043c\u043e\u0433\u0443\u0442 \u0431\u044b\u0442\u044c \u0440\u0435\u0448\u0435\u043d\u044b \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c\u0438 \u0441\u043f\u043e\u0441\u043e\u0431\u0430\u043c\u0438:<\/p>\n<details class=\"spoiler\">\n<summary>1. \u0414\u0432\u0430 \u0441\u043f\u043e\u0441\u043e\u0431\u0430 \u0434\u043b\u044f \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u0441\u043b\u0443\u0447\u0430\u044f<\/summary>\n<div class=\"spoiler__content\">\n<ol>\n<li>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0431\u043e\u043b\u044c\u0448\u0435 \u0442\u043e\u0447\u0435\u043a \u0432 \u043a\u043b\u0430\u0441\u0441, \u0447\u0442\u043e\u0431\u044b \u0441\u0440\u0435\u0434\u043d\u0435\u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u0435 (<em>\u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0447\u043d\u043e \u2014 \u0434\u0438\u0441\u043f\u0435\u0440\u0441\u0438\u044f<\/em>) \u043f\u043e \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"i\" alt=\"i\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/531\/6d5\/0b4\/5316d50b4dae3d8f9deef1230a029abe.svg\"> \u043d\u0435 \u0440\u0430\u0432\u043d\u044f\u043b\u043e\u0441\u044c \u043d\u0443\u043b\u044e.<\/p>\n<\/li>\n<li>\n<p>\u0423\u0431\u0440\u0430\u0442\u044c \u043f\u0440\u0438\u0437\u043d\u0430\u043a <img decoding=\"async\" class=\"formula inline\" source=\"i\" alt=\"i\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/3d7\/85a\/7dd\/3d785a7dd9c7134dd385a8455111072a.svg\"> \u0438\u0437 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u0438\u044f.<\/p>\n<\/li>\n<\/ol>\n<\/div>\n<\/details>\n<details class=\"spoiler\">\n<summary>2. \u041c\u0435\u0442\u0440\u0438\u043a\u0430 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430<\/summary>\n<div class=\"spoiler__content\">\n<p>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043c\u043e\u0434\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044e \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0434\u043b\u044f \u0432\u0442\u043e\u0440\u043e\u0433\u043e \u0441\u043b\u0443\u0447\u0430\u044f), \u2014 \u043c\u0435\u0442\u0440\u0438\u043a\u0443 \u0415\u0432\u043a\u043b\u0438\u0434\u0430-\u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 (<a href=\"http:\/\/www.isa.ru\/aidt\/images\/documents\/2012-01\/81_89.pdf\" rel=\"noopener noreferrer nofollow\">\u0438\u0437 \u0441\u0442\u0430\u0442\u044c\u0438<\/a>):<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_{E-M}(U, V, (COV+E)^{-1}) = \\sqrt {(U - V) \\cdot {(COV+E)}^{-1} \\cdot (U - V)^T}\" alt=\"d_{E-M}(U, V, (COV+E)^{-1}) = \\sqrt {(U - V) \\cdot {(COV+E)}^{-1} \\cdot (U - V)^T}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/cd3\/f85\/3ed\/cd3f853ed3634ed408b07720a4dfd4e9.svg\" width=\"493\" height=\"34\"><\/p>\n<p>\u0433\u0434\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"E\" alt=\"E\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e91\/cf2\/7a5\/e91cf27a5d8b9ce208f5f5941e3f6973.svg\"> \u2014 \u0435\u0434\u0438\u043d\u0438\u0447\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u0442\u043e\u0433\u043e \u0436\u0435 \u0440\u0430\u0437\u043c\u0435\u0440\u0430, \u0447\u0442\u043e \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"COV\" alt=\"COV\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/b79\/cdf\/f4e\/b79cdff4e0dd0c19f74bc724704dc8da.svg\">.<\/p>\n<p>\u042d\u0442\u0430 \u043c\u0435\u0442\u0440\u0438\u043a\u0430 \u0443\u0441\u0442\u0440\u0430\u043d\u044f\u0435\u0442 \u043d\u0435\u0434\u043e\u0441\u0442\u0430\u0442\u043e\u043a \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430, \u043f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u044b \u0435\u0451 \u0433\u043b\u0430\u0432\u043d\u043e\u0439 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u0438 \u0432\u0441\u0435\u0433\u0434\u0430 \u0431\u043e\u043b\u044c\u0448\u0435 \u043d\u0443\u043b\u044f.<\/p>\n<\/div>\n<\/details>\n<details class=\"spoiler\">\n<summary>3. \u041f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u044b\u0439 \u043f\u043e\u0434\u0445\u043e\u0434<\/summary>\n<div class=\"spoiler__content\">\n<p>\u041f\u043e\u043c\u0438\u043c\u043e \u043e\u0431\u0440\u0430\u0442\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 <a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%9F%D1%81%D0%B5%D0%B2%D0%B4%D0%BE%D0%BE%D0%B1%D1%80%D0%B0%D1%82%D0%BD%D0%B0%D1%8F_%D0%BC%D0%B0%D1%82%D1%80%D0%B8%D1%86%D0%B0\" rel=\"noopener noreferrer nofollow\">\u043f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430<\/a>.<br \/>\u041e\u043f\u0435\u0440\u0430\u0446\u0438\u044f <img decoding=\"async\" class=\"formula inline\" source=\"{\\square}^{+}\" alt=\"{\\square}^{+}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/4a9\/291\/c06\/4a9291c0693589ecfbd40d5dd10d9162.svg\"> \u2014 \u043f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u043e\u0435 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u043c\u0430\u0442\u0440\u0438\u0446\u044b (<a href=\"https:\/\/en.wikipedia.org\/wiki\/Moore%E2%80%93Penrose_inverse\" rel=\"noopener noreferrer nofollow\">\u043e\u0431\u0440\u0430\u0442\u043d\u043e\u0435 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u041c\u0443\u0440\u0430 \u2014 \u041f\u0435\u043d\u0440\u043e\u0443\u0437\u0430<\/a>).<br \/>\u0424\u0443\u043d\u043a\u0446\u0438\u0438 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u043f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b:<br \/>\u2014 <a href=\"https:\/\/www.rdocumentation.org\/packages\/MASS\/versions\/7.3-53\/topics\/ginv\" rel=\"noopener noreferrer nofollow\">ginv<\/a> \u0432 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0435 MASS (R);<br \/>\u2014 <a href=\"https:\/\/pyprog.pro\/linear_algebra_functions\/linalg_pinv.html\" rel=\"noopener noreferrer nofollow\">pinv<\/a> \u0432 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0435 numpy (Python);<br \/>\u2014 <a href=\"https:\/\/www.mathworks.com\/help\/matlab\/ref\/pinv.html\" rel=\"noopener noreferrer nofollow\">pinv<\/a> \u0432 MATLAB;<br \/>\u2014 <a href=\"https:\/\/octave.sourceforge.io\/octave\/function\/pinv.html\" rel=\"noopener noreferrer nofollow\">pinv<\/a> \u0432 Octave.<\/p>\n<p>\u041f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430, \u043e\u0431\u043e\u0437\u043d\u0430\u0447\u0430\u0435\u043c\u0430\u044f <img decoding=\"async\" class=\"formula inline\" source=\"A^{+}\" alt=\"A^{+}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/7f2\/65b\/221\/7f265b2214596d7e8a6baeba91cfd0a4.svg\">, (\u0432 \u043e\u0442\u0440\u044b\u0432\u0435 \u043e\u0442 \u0442\u0435\u043c\u044b \u0441\u0442\u0430\u0442\u044c\u0438) <a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%9C%D0%B5%D1%82%D0%BE%D0%B4_%D0%BD%D0%B0%D0%B8%D0%BC%D0%B5%D0%BD%D1%8C%D1%88%D0%B8%D1%85_%D0%BA%D0%B2%D0%B0%D0%B4%D1%80%D0%B0%D1%82%D0%BE%D0%B2#%D0%9F%D1%80%D0%B8%D0%BC%D0%B5%D1%80_%E2%80%94_%D1%81%D0%B8%D1%81%D1%82%D0%B5%D0%BC%D0%B0_%D0%BB%D0%B8%D0%BD%D0%B5%D0%B9%D0%BD%D1%8B%D1%85_%D1%83%D1%80%D0%B0%D0%B2%D0%BD%D0%B5%D0%BD%D0%B8%D0%B9\" rel=\"noopener noreferrer nofollow\">\u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442\u0441\u044f \u043a\u0430\u043a<\/a> \u043c\u0430\u0442\u0440\u0438\u0446\u0430, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u00ab\u0440\u0435\u0448\u0430\u0435\u0442\u00bb \u0437\u0430\u0434\u0430\u0447\u0443 \u043d\u0430\u0438\u043c\u0435\u043d\u044c\u0448\u0438\u0445 \u043a\u0432\u0430\u0434\u0440\u0430\u0442\u043e\u0432: <img decoding=\"async\" class=\"formula inline\" source=\"Ax=b \\implies x=A^{+}b\" alt=\"Ax=b \\implies x=A^{+}b\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/d34\/363\/0f6\/d343630f6f23b2b74ff56a7e66926744.svg\">, \u0433\u0434\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"A\" alt=\"A\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/b9d\/712\/305\/b9d712305b7cfd1c93cc2f377f491a85.svg\"> \u2014 \u043f\u0440\u044f\u043c\u043e\u0443\u0433\u043e\u043b\u044c\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0447\u0438\u0441\u043b\u043e \u0441\u0442\u0440\u043e\u043a (\u0443\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u0439) \u0431\u043e\u043b\u044c\u0448\u0435 \u0447\u0438\u0441\u043b\u0430 \u0441\u0442\u043e\u043b\u0431\u0446\u043e\u0432 (\u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445); \u0442\u0430\u043a\u0430\u044f \u0441\u0438\u0441\u0442\u0435\u043c\u0430 \u0443\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u0439 \u0432 \u043e\u0431\u0449\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043d\u0435 \u0438\u043c\u0435\u0435\u0442 \u0440\u0435\u0448\u0435\u043d\u0438\u044f, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u044d\u0442\u0443 \u0441\u0438\u0441\u0442\u0435\u043c\u0443 \u043c\u043e\u0436\u043d\u043e \u00ab\u0440\u0435\u0448\u0438\u0442\u044c\u00bb \u0442\u043e\u043b\u044c\u043a\u043e \u0432 \u0441\u043c\u044b\u0441\u043b\u0435 \u0432\u044b\u0431\u043e\u0440\u0430 \u0442\u0430\u043a\u043e\u0433\u043e \u0432\u0435\u043a\u0442\u043e\u0440\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"x\" alt=\"x\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/fa5\/088\/56c\/fa508856ce744e4e9e927005ce5d7a42.svg\">, \u0447\u0442\u043e\u0431\u044b \u043c\u0438\u043d\u0438\u043c\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u00ab\u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435\u00bb \u043c\u0435\u0436\u0434\u0443 \u0432\u0435\u043a\u0442\u043e\u0440\u0430\u043c\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"Ax\" alt=\"Ax\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/115\/b4a\/2da\/115b4a2da12fe1499600f15b1dbd7897.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"b\" alt=\"b\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/ad7\/fc0\/0f1\/ad7fc00f1ae80412d2d7c30b5ba28285.svg\">.<br \/>\u041f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043d\u0430\u0439\u0434\u0435\u043d\u0430 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e <a href=\"http:\/\/www.machinelearning.ru\/wiki\/index.php?title=%D0%A1%D0%B8%D0%BD%D0%B3%D1%83%D0%BB%D1%8F%D1%80%D0%BD%D0%BE%D0%B5_%D1%80%D0%B0%D0%B7%D0%BB%D0%BE%D0%B6%D0%B5%D0%BD%D0%B8%D0%B5\" rel=\"noopener noreferrer nofollow\">\u0441\u0438\u043d\u0433\u0443\u043b\u044f\u0440\u043d\u043e\u0433\u043e \u0440\u0430\u0437\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u044b<\/a>. \u041f\u0440\u0438\u0447\u0435\u043c \u0434\u043b\u044f \u043b\u044e\u0431\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u043d\u0430\u0434 \u0432\u0435\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u043c\u0438 \u0447\u0438\u0441\u043b\u0430\u043c\u0438 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 \u043f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u0438 \u043f\u0440\u0438\u0442\u043e\u043c \u0442\u043e\u043b\u044c\u043a\u043e \u043e\u0434\u043d\u0430.<br \/>\u0422\u0430\u043a\u0436\u0435 \u0432\u0430\u0436\u043d\u043e \u043e\u0442\u043c\u0435\u0442\u0438\u0442\u044c \u0442\u043e\u0442 \u0444\u0430\u043a\u0442, \u0447\u0442\u043e \u0435\u0441\u043b\u0438 \u043e\u0431\u0440\u0430\u0442\u043d\u0443\u044e \u043c\u0430\u0442\u0440\u0438\u0446\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"A^{-1}\" alt=\"A^{-1}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e31\/6f8\/387\/e316f8387775bbd967c0ce085851376b.svg\"> \u043c\u043e\u0436\u043d\u043e \u043d\u0430\u0439\u0442\u0438 (\u0438\u043d\u0430\u0447\u0435 \u0433\u043e\u0432\u043e\u0440\u044f, \u0438\u0441\u0445\u043e\u0434\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"A\" alt=\"A\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/aba\/d79\/f5b\/abad79f5b89068246c183ba489959ed9.svg\"> \u2014 \u043a\u0432\u0430\u0434\u0440\u0430\u0442\u043d\u0430\u044f \u0438 \u043d\u0435\u0432\u044b\u0440\u043e\u0436\u0434\u0435\u043d\u043d\u0430\u044f), \u0442\u043e \u043f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u0431\u0443\u0434\u0435\u0442 \u0441 <img decoding=\"async\" class=\"formula inline\" source=\"A^{-1}\" alt=\"A^{-1}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/42a\/5b3\/844\/42a5b384409b8fa9f93a5bd05e06b328.svg\"> \u0441\u043e\u0432\u043f\u0430\u0434\u0430\u0442\u044c: <img decoding=\"async\" class=\"formula inline\" source=\"\\mathrm {det}(A_{n \\times n}) \\ne 0 \\iff A^{+}=A^{-1}\" alt=\"\\mathrm {det}(A_{n \\times n}) \\ne 0 \\iff A^{+}=A^{-1}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/1ec\/d54\/0ae\/1ecd540ae770a94a65c10d5e0dc91cf1.svg\">.<\/p>\n<p>\u0424\u043e\u0440\u043c\u0443\u043b\u0430 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_M^+ (U, V, COV^{+}) = \\sqrt {(U - V) \\cdot COV^{+} \\cdot (U - V)^T}\" alt=\"d_M^+ (U, V, COV^{+}) = \\sqrt {(U - V) \\cdot COV^{+} \\cdot (U - V)^T}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/2f5\/6ce\/da3\/2f56ceda302f0ed663c138cfbc51754f.svg\" width=\"371\" height=\"35\"><\/p>\n<p>\u041f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u044b\u0439 \u043f\u043e\u0434\u0445\u043e\u0434 \u0438\u043d\u043e\u0433\u0434\u0430 \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u044e\u0442 \u0432 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0438 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430, \u043d\u043e: \u00ab\u041c\u044b \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u0437\u043d\u0430\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043c\u0435\u043d\u044c\u0448\u0443\u044e \u0442\u043e\u0447\u043d\u043e\u0441\u0442\u044c \u043a\u043b\u0430\u0441\u0441\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u043f\u0440\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u043f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u044b\u0445 \u043c\u0430\u0442\u0440\u0438\u0446. \u0414\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e, \u043f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u044b\u0439 \u043f\u043e\u0434\u0445\u043e\u0434 \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u0435\u0442 \u0432\u0434\u0432\u043e\u0435 \u0431\u043e\u043b\u044c\u0448\u0435 \u043e\u0448\u0438\u0431\u043e\u043a, \u0447\u0435\u043c \u043c\u0435\u0442\u043e\u0434 \u0443\u0441\u0430\u0434\u043a\u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u0438\u043b\u0438 \u043c\u0435\u0442\u043e\u0434 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b\u00bb (<a href=\"https:\/\/arxiv.org\/pdf\/1010.1526.pdf\" rel=\"noopener noreferrer nofollow\">\u0438\u0437 \u0441\u0442\u0430\u0442\u044c\u0438<\/a>).<\/p>\n<p>\u041a\u0440\u043e\u043c\u0435 \u0442\u043e\u0433\u043e, \u0434\u0430\u043b\u0435\u0435 \u0431\u0443\u0434\u0435\u0442 \u043f\u0440\u043e\u0434\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0438\u0440\u043e\u0432\u0430\u043d \u0441\u043b\u0443\u0447\u0430\u0439, \u043a\u043e\u0433\u0434\u0430 <strong>\u043f\u0440\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u043f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u043e\u0433\u043e \u043f\u043e\u0434\u0445\u043e\u0434\u0430 \u043d\u0430\u0440\u0443\u0448\u0430\u0435\u0442\u0441\u044f \u0430\u043a\u0441\u0438\u043e\u043c\u0430 \u0442\u043e\u0436\u0434\u0435\u0441\u0442\u0432\u0430<\/strong> (\u0438\u0437-\u0437\u0430 \u0447\u0435\u0433\u043e \u044d\u0442\u043e\u0442 \u043f\u043e\u0434\u0445\u043e\u0434 \u043d\u0430\u0437\u044b\u0432\u0430\u044e\u0442 <em>\u043f\u0441\u0435\u0432\u0434\u043e\u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435\u043c \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430<\/em> \u0438\u043b\u0438 <em>\u043f\u0441\u0435\u0432\u0434\u043e\u043c\u0435\u0442\u0440\u0438\u043a\u043e\u0439<\/em>).<\/p>\n<\/div>\n<\/details>\n<details class=\"spoiler\">\n<summary>4. \u041c\u0435\u0442\u043e\u0434 \u0443\u0441\u0430\u0434\u043a\u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b<\/summary>\n<div class=\"spoiler__content\">\n<p>\u041c\u0435\u0442\u043e\u0434 \u0443\u0441\u0430\u0434\u043a\u0438 (shrinkage) \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u2014 \u044d\u0442\u043e \u043c\u0435\u0442\u043e\u0434 \u043e\u0446\u0435\u043d\u043a\u0438 \u0437\u0430\u0434\u0430\u0447 \u0441 \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u0438\u043c \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e\u043c \u0442\u043e\u0447\u0435\u043a \u0438 \u0431\u043e\u043b\u044c\u0448\u0438\u043c \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e\u043c \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 (\u0442. \u0435. \u0434\u043b\u044f \u0442\u0440\u0435\u0442\u044c\u0435\u0433\u043e \u0441\u043b\u0443\u0447\u0430\u044f).<br \/>\u0421\u043c\u044b\u0441\u043b \u044d\u0442\u043e\u0433\u043e \u043c\u0435\u0442\u043e\u0434\u0430 \u0432 \u0437\u0430\u043c\u0435\u043d\u0435 \u043c\u0430\u0442\u0440\u0438\u0446\u044b <img decoding=\"async\" class=\"formula inline\" source=\"COV\" alt=\"COV\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/4fb\/188\/380\/4fb188380da8ea612847fca48692d3f7.svg\"> \u043d\u0430 \u043c\u0430\u0442\u0440\u0438\u0446\u0443<img decoding=\"async\" class=\"formula inline\" source=\"COV_{(*)} = \\left ((1 - \\lambda) COV + \\lambda T \\right)\" alt=\"COV_{(*)} = \\left ((1 - \\lambda) COV + \\lambda T \\right)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/003\/8b2\/d11\/0038b2d11202fcc9960a49009022512a.svg\">, \u0433\u0434\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"T\" alt=\"T\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/49e\/ea9\/da9\/49eea9da9560455fc078971f3c362694.svg\"> \u2014 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u0430\u044f <em>\u043f\u043e\u0434\u0445\u043e\u0434\u044f\u0449\u0430\u044f<\/em> \u043f\u043e\u043b\u043e\u0436\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430, <img decoding=\"async\" class=\"formula inline\" source=\"\\lambda \\in (0,1]\" alt=\"\\lambda \\in (0,1]\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/0ab\/d1f\/697\/0abd1f697011118bc819a3b3e7d6a9d8.svg\"> \u2014 \u043a\u043e\u044d\u0444\u0444\u0438\u0446\u0438\u0435\u043d\u0442 \u0443\u0441\u0430\u0434\u043a\u0438, \u043f\u0440\u0438\u0447\u0435\u043c \u043d\u0430\u0438\u043c\u0435\u043d\u044c\u0448\u0435\u0435 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043c\u0430\u0442\u0440\u0438\u0446\u044b <img decoding=\"async\" class=\"formula inline\" source=\"COV_{(*)}\" alt=\"COV_{(*)}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/5a4\/23a\/8b7\/5a423a8b790316839a6d2ee58da012e0.svg\"> \u0434\u043e\u043b\u0436\u043d\u043e \u0431\u044b\u0442\u044c \u043d\u0435 \u043c\u0435\u043d\u044c\u0448\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"\\lambda\" alt=\"\\lambda\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/354\/17e\/0ac\/35417e0acd7d6e4a973c576f58b11efb.svg\">, \u0443\u043c\u043d\u043e\u0436\u0435\u043d\u043d\u043e\u0439 \u043d\u0430 \u043d\u0430\u0438\u043c\u0435\u043d\u044c\u0448\u0435\u0435 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"T\" alt=\"T\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/788\/b04\/0bf\/788b040bffea2199bca017014241663b.svg\">.<br \/>\u0412 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0438 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_{M{(*)}}(U, V, COV^{-1}_{(*)}) = \\sqrt {(U - V) \\cdot COV^{-1}_{(*)} \\cdot (U - V)^T}\" alt=\"d_{M{(*)}}(U, V, COV^{-1}_{(*)}) = \\sqrt {(U - V) \\cdot COV^{-1}_{(*)} \\cdot (U - V)^T}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/59e\/5a6\/64a\/59e5a664af4a2cad4a8111a961ae9903.svg\" width=\"399\" height=\"34\"><\/p>\n<p><a href=\"https:\/\/perso.ens-lyon.fr\/patrick.flandrin\/LedoitWolf_JMA2004.pdf\" rel=\"noopener noreferrer nofollow\">\u041f\u0440\u0435\u0434\u043b\u043e\u0436\u0435\u043d\u0438\u0435 Olivier Ledoit \u0438 Michael Wolf<\/a> \u2014 <img decoding=\"async\" class=\"formula inline\" source=\"((1 - \\lambda) COV + \\lambda \\mu E)\" alt=\"((1 - \\lambda) COV + \\lambda \\mu E)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/244\/536\/058\/244536058b9ec9626d9363b807bec309.svg\">, \u0433\u0434\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"\\mu=\\mathbb{trace}(COV)\/n\" alt=\"\\mu=\\mathbb{trace}(COV)\/n\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/877\/007\/c44\/877007c44072586bd2a845085e1c82e6.svg\"> \u2014 \u0441\u0443\u043c\u043c\u0430 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u044c\u043d\u044b\u0445 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u0432 \u043c\u0430\u0442\u0440\u0438\u0446\u044b <img decoding=\"async\" class=\"formula inline\" source=\"COV\" alt=\"COV\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/635\/e89\/797\/635e89797b1ac6d9682c695aebfcb184.svg\">, \u0434\u0435\u043b\u0435\u043d\u043d\u0430\u044f \u043d\u0430 \u0447\u0438\u0441\u043b\u043e \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432, <img decoding=\"async\" class=\"formula inline\" source=\"E\" alt=\"E\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/7ed\/6bb\/2df\/7ed6bb2dfa88ffd46f64f6159f43b791.svg\"> \u2014 \u0435\u0434\u0438\u043d\u0438\u0447\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430, \u0430 <img decoding=\"async\" class=\"formula inline\" source=\"\\lambda\" alt=\"\\lambda\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a55\/096\/db9\/a55096db93edd5a149442eeef7323cbb.svg\"> \u0432\u044b\u0447\u0438\u0441\u043b\u044f\u0435\u0442\u0441\u044f \u0432 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0438 \u0441 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u044b\u043c \u0430\u0432\u0442\u043e\u0440\u0430\u043c\u0438 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u043e\u043c.<br \/>\u0420\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u0430, \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0435\u043d\u043d\u043e\u0433\u043e \u0430\u0432\u0442\u043e\u0440\u0430\u043c\u0438, \u043d\u0430 Python \u0438\u043c\u0435\u0435\u0442\u0441\u044f \u0432 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0435 <a href=\"https:\/\/github.com\/scikit-learn\/scikit-learn\" rel=\"noopener noreferrer nofollow\">scikit-learn<\/a> (<a href=\"https:\/\/github.com\/scikit-learn\/scikit-learn\/blob\/95119c13a\/sklearn\/covariance\/_shrunk_covariance.py#L319\" rel=\"noopener noreferrer nofollow\">sklearn.covariance.LedoitWolf<\/a>, <a href=\"https:\/\/github.com\/scikit-learn\/scikit-learn\/blob\/95119c13af77c76e150b753485c662b7c52a41a2\/sklearn\/covariance\/_shrunk_covariance.py#L257\" rel=\"noopener noreferrer nofollow\">sklearn.covariance.ledoit_wolf<\/a>, <a href=\"https:\/\/github.com\/scikit-learn\/scikit-learn\/blob\/95119c13af77c76e150b753485c662b7c52a41a2\/sklearn\/covariance\/_shrunk_covariance.py#L162\" rel=\"noopener noreferrer nofollow\">sklearn.covariance.ledoit_wolf_shrinkage<\/a>).<\/p>\n<p>\u041d\u0430 <a href=\"https:\/\/arxiv.org\/pdf\/1010.1526.pdf\" rel=\"noopener noreferrer nofollow\">\u0441\u0442\u0440. 8<\/a> \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u043e, \u0447\u0442\u043e \u00ab\u0432 \u043e\u0442\u043b\u0438\u0447\u0438\u0435 \u043e\u0442 \u043f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u043e\u0433\u043e \u043f\u043e\u0434\u0445\u043e\u0434\u0430, \u043c\u0435\u0442\u043e\u0434 \u0443\u0441\u0430\u0434\u043a\u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u0435\u0442 \u043e\u0431\u043e\u0431\u0449\u0435\u043d\u043d\u0443\u044e \u043c\u0435\u0440\u0443 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043c\u0435\u0442\u0440\u0438\u043a\u043e\u0439\u00bb (\u0430\u0434\u0430\u043f\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u043f\u0435\u0440\u0435\u0432\u043e\u0434). \u042d\u0442\u043e \u0443\u0442\u0432\u0435\u0440\u0436\u0434\u0435\u043d\u0438\u0435 \u043c\u043e\u0436\u0435\u0442 \u0432\u0432\u0435\u0441\u0442\u0438 \u0432 \u0437\u0430\u0431\u043b\u0443\u0436\u0434\u0435\u043d\u0438\u0435 \u0432 \u043e\u0442\u0440\u044b\u0432\u0435 \u043e\u0442 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u0430 \u2014 <u>\u0442\u0440\u0438 \u043f\u0435\u0440\u0435\u0447\u0438\u0441\u043b\u0435\u043d\u043d\u044b\u0445 \u0432\u044b\u0448\u0435 \u0443\u0441\u043b\u043e\u0432\u0438\u044f<\/u> (\u043f\u0440\u043e <img decoding=\"async\" class=\"formula inline\" source=\"T\" alt=\"T\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/3a4\/091\/d60\/3a4091d605f16454a09acf619ff53ad9.svg\">, \u043f\u0440\u043e <img decoding=\"async\" class=\"formula inline\" source=\"\\lambda\" alt=\"\\lambda\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/6d4\/1d9\/816\/6d41d981607c2f7aa23a34ceebf49188.svg\">, \u043f\u0440\u043e \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f) <u>\u043e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u044b<\/u>, \u0438\u043d\u0430\u0447\u0435 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043d\u0435\u0432\u0435\u0440\u043d\u044b\u043c.<br \/>\u0421\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u043f\u0440\u0438\u043c\u0435\u0440 \u0434\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0438\u0440\u0443\u0435\u0442 \u043d\u0435\u0441\u043e\u0431\u043b\u044e\u0434\u0435\u043d\u0438\u0435 \u0443\u0441\u043b\u043e\u0432\u0438\u044f <img decoding=\"async\" class=\"formula inline\" source=\"\\lambda \\in (0,1]\" alt=\"\\lambda \\in (0,1]\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/677\/f1a\/b80\/677f1ab801df6f009b746642a8073050.svg\">.<\/p>\n<p>\u041f\u0443\u0441\u0442\u044c <img decoding=\"async\" class=\"formula inline\" source=\"C=\\{ (1, 1), (2, 2) \\}\" alt=\"C=\\{ (1, 1), (2, 2) \\}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/719\/b06\/5fb\/719b065fb082ec75aaf3a1058a037e00.svg\">, \u0442\u043e\u0433\u0434\u0430 \u0432 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0438 \u0441 \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0435\u043d\u0438\u0435\u043c \u0432 <a href=\"https:\/\/arxiv.org\/pdf\/1010.1526.pdf\" rel=\"noopener noreferrer nofollow\">\u044d\u0442\u043e\u0439<\/a> \u0438 <a href=\"https:\/\/www.strimmerlab.org\/publications\/journals\/shrinkcov2005.pdf\" rel=\"noopener noreferrer nofollow\">\u044d\u0442\u043e\u0439<\/a> \u0441\u0442\u0430\u0442\u044c\u044f\u0445 (<a href=\"https:\/\/gist.github.com\/Quwarm\/b3624e17fe9a200b24bf32831156ae7a\" rel=\"noopener noreferrer nofollow\">\u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043d\u0430 Python<\/a>):<br \/>\u2014 <img decoding=\"async\" class=\"formula inline\" source=\"\\lambda=0\" alt=\"\\lambda=0\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/110\/b8c\/0ae\/110b8c0ae7263e4bcaada6c7ff65e55c.svg\">;<br \/>\u2014 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043e\u0442 \u0442\u043e\u0447\u043a\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(1,1)\" alt=\"(1,1)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/458\/bee\/c78\/458beec78e05f0cfb5317242162d737e.svg\"> \u0434\u043e \u0442\u043e\u0447\u043a\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(1.5,1.5)\" alt=\"(1.5,1.5)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/88b\/217\/587\/88b217587b13a2cb4f10c81693a3f2f1.svg\">: <img decoding=\"async\" class=\"formula inline\" source=\"\\approx 0.7071\" alt=\"\\approx 0.7071\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/224\/620\/3d8\/2246203d8b91a4dc36eebcb4458f492b.svg\">;<br \/>\u2014 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043e\u0442 \u0442\u043e\u0447\u043a\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(2,2)\" alt=\"(2,2)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/b0a\/652\/bfa\/b0a652bfac6d6f560c3e9fd642017c3f.svg\"> \u0434\u043e \u0442\u043e\u0447\u043a\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(1.5,1.5)\" alt=\"(1.5,1.5)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/88b\/217\/587\/88b217587b13a2cb4f10c81693a3f2f1.svg\">: <img decoding=\"async\" class=\"formula inline\" source=\"\\approx 0.7071\" alt=\"\\approx 0.7071\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/64e\/5a8\/a22\/64e5a8a22a9495f790b2b146a2b000cc.svg\">;<br \/>\u2014 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043e\u0442 \u0442\u043e\u0447\u043a\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(1,1)\" alt=\"(1,1)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/458\/bee\/c78\/458beec78e05f0cfb5317242162d737e.svg\"> \u0434\u043e \u0442\u043e\u0447\u043a\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(1.51,1.5)\" alt=\"(1.51,1.5)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/800\/fb7\/597\/800fb7597cc0524a2ac6d140fe8e3bdb.svg\">: <img decoding=\"async\" class=\"formula inline\" source=\"\\approx 671088.64 \\ldots {63} \\ldots\" alt=\"\\approx 671088.64 \\ldots {63} \\ldots\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/2c2\/ff0\/20c\/2c2ff020c4ec82a99d90b75be9f22dcd.svg\">;<br \/>\u2014 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043e\u0442 \u0442\u043e\u0447\u043a\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(2,2)\" alt=\"(2,2)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a4b\/1fd\/1b7\/a4b1fd1b70ab27cb9e5ed26a9a8d7945.svg\"> \u0434\u043e \u0442\u043e\u0447\u043a\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(1.51,1.5)\" alt=\"(1.51,1.5)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/def\/764\/025\/def7640258500a2422de87aea5dc6748.svg\">: <img decoding=\"async\" class=\"formula inline\" source=\"\\approx 671088.64 \\ldots 04 \\ldots\" alt=\"\\approx 671088.64 \\ldots 04 \\ldots\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a88\/ddf\/2c5\/a88ddf2c5e44788ca25b0eb6d46c1c14.svg\">.<br \/>\u0412 \u0434\u0430\u043d\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0435\u043d\u0438\u0435:<br \/><img decoding=\"async\" class=\"formula inline\" source=\"T=\\mathrm {diag}(COV) \\implies COV_{(*)}= ((1 - \\lambda) COV + \\lambda \\mathrm {diag}(COV))\" alt=\"T=\\mathrm {diag}(COV) \\implies COV_{(*)}= ((1 - \\lambda) COV + \\lambda \\mathrm {diag}(COV))\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/aa2\/ffc\/f54\/aa2ffcf5455a83d506af762302f6a12b.svg\"><br \/>\u0433\u0434\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"\\mathrm {diag}(COV)\" alt=\"\\mathrm {diag}(COV)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a7c\/92b\/64b\/a7c92b64ba8fbdf808cb94170d794df8.svg\"> \u2014 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u044c\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u0441\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f\u043c\u0438 \u043d\u0430 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"COV\" alt=\"COV\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/32d\/d81\/72b\/32dd8172b9d59f5d4241a70dfe0da3f6.svg\">.<\/p>\n<p>\u0422\u0430\u043a\u0436\u0435 \u0435\u0441\u0442\u044c <a href=\"https:\/\/scikit-learn.org\/stable\/modules\/covariance.html#shrunk-covariance\" rel=\"noopener noreferrer nofollow\">Shrunk Covariance<\/a> (<a href=\"https:\/\/github.com\/scikit-learn\/scikit-learn\/blob\/95119c13a\/sklearn\/covariance\/_shrunk_covariance.py#L63\" rel=\"noopener noreferrer nofollow\">sklearn.covariance.ShrunkCovariance<\/a>, <a href=\"https:\/\/github.com\/scikit-learn\/scikit-learn\/blob\/95119c13a\/sklearn\/covariance\/_shrunk_covariance.py#L26\" rel=\"noopener noreferrer nofollow\">sklearn.covariance.shrunk_covariance<\/a>). \u041e\u0434\u043d\u0430\u043a\u043e \u043e\u043d \u043d\u0435 \u043d\u0430\u0445\u043e\u0434\u0438\u0442 <img decoding=\"async\" class=\"formula inline\" source=\"\\lambda\" alt=\"\\lambda\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/c57\/5ec\/a34\/c575eca34b3bd4a4e78c63d963fc4605.svg\">, \u0430 \u043f\u0440\u0435\u0434\u043b\u0430\u0433\u0430\u0435\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u0438\u0439 \u0432\u044b\u0431\u043e\u0440 (\u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e <img decoding=\"async\" class=\"formula inline\" source=\"\\lambda_{SC}=0.1\" alt=\"\\lambda_{SC}=0.1\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/cbd\/4ac\/44a\/cbd4ac44aa0994b194885ef388f7dfea.svg\">).<br \/>\u041c\u0430\u0442\u0440\u0438\u0446\u0430 (\u043a\u0430\u043a \u0438 \u0432 \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0435\u043d\u0438\u0438 Ledoit \u2014 Wolf): <img decoding=\"async\" class=\"formula inline\" source=\"((1 - \\lambda) COV + \\lambda \\mu E)\" alt=\"((1 - \\lambda) COV + \\lambda \\mu E)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/3a7\/d4d\/85c\/3a7d4d85cf805551104642fb14a70726.svg\">.<\/p>\n<p>\u041e\u0431\u0449\u0443\u044e \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u043e\u0431 \u0443\u0441\u0430\u0434\u043a\u0435 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0447\u0438\u0442\u0430\u0442\u044c \u0432 <a href=\"https:\/\/en.wikipedia.org\/wiki\/Estimation_of_covariance_matrices#Shrinkage_estimation\" rel=\"noopener noreferrer nofollow\">\u0432\u0438\u043a\u0438\u043f\u0435\u0434\u0438\u0438<\/a>.<\/p>\n<p>\u041f\u0440\u0438\u0447\u0435\u043c \u0441\u0442\u043e\u0438\u0442 \u043e\u0431\u0440\u0430\u0442\u0438\u0442\u044c \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u043d\u0430 \u0442\u043e, \u0447\u0442\u043e LedoitWolf \u0438 ShrunkCovariance (\u0438 <a href=\"https:\/\/scikit-learn.org\/stable\/modules\/covariance.html\" rel=\"noopener noreferrer nofollow\">\u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0434\u0440\u0443\u0433\u0438\u0435 \u043c\u0435\u0442\u043e\u0434\u044b<\/a>) \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442 <a href=\"https:\/\/github.com\/scikit-learn\/scikit-learn\/blob\/95119c13af77c76e150b753485c662b7c52a41a2\/sklearn\/covariance\/_empirical_covariance.py#L52\" rel=\"noopener noreferrer nofollow\">empirical_covariance<\/a>, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0432\u044b\u0447\u0438\u0441\u043b\u044f\u0435\u0442 \u0441\u043c\u0435\u0449\u0435\u043d\u043d\u0443\u044e \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u044e (\u0430\u043d\u0433\u043b. \u00abpopulation covariance\u00bb, \u0444\u043e\u0440\u043c\u0443\u043b\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"\\mathrm {(PC)}\" alt=\"\\mathrm {(PC)}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/531\/ffe\/26c\/531ffe26c96b16e5f00104c61faf50c4.svg\">).<\/p>\n<\/div>\n<\/details>\n<details class=\"spoiler\">\n<summary>5. \u041d\u043e\u0440\u043c\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0415\u0432\u043a\u043b\u0438\u0434\u0430<\/summary>\n<div class=\"spoiler__content\">\n<p>\u0415\u0441\u043b\u0438 \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u044c\u043d\u0430\u044f (\u043d\u043e \u043d\u0435\u043e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u0435\u0434\u0438\u043d\u0438\u0447\u043d\u0430\u044f), \u0442\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u0432\u0448\u0430\u044f\u0441\u044f \u043c\u0435\u0440\u0430 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043d\u043e\u0441\u0438\u0442 \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u0435 \u00ab\u043d\u043e\u0440\u043c\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0415\u0432\u043a\u043b\u0438\u0434\u0430\u00bb:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_{std}(U, V, \\sigma) = \\sqrt {\\sum_{i=1}^n {\\left (\\frac {U_i - V_i} {\\sigma_i} \\right)^2}}\" alt=\"d_{std}(U, V, \\sigma) = \\sqrt {\\sum_{i=1}^n {\\left (\\frac {U_i - V_i} {\\sigma_i} \\right)^2}}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/9fe\/0aa\/6b2\/9fe0aa6b266172a417d337437e2ffe71.svg\" width=\"250\" height=\"56\"><\/p>\n<p>\u0433\u0434\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"\\sigma_i\" alt=\"\\sigma_i\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/244\/817\/37f\/24481737f8b14515bb7ead142c679be9.svg\"> \u2014 \u0441\u0440\u0435\u0434\u043d\u0435\u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u0435 \u0442\u043e\u0447\u0435\u043a \u043a\u043b\u0430\u0441\u0441\u0430 (\u043a \u043a\u043e\u0442\u043e\u0440\u043e\u043c\u0443 \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0441\u044f \u0442\u043e\u0447\u043a\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"U\" alt=\"U\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/eaa\/b19\/274\/eaab19274670eea07d6b666882400f08.svg\"> \u0438\/\u0438\u043b\u0438 \u0442\u043e\u0447\u043a\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"V\" alt=\"V\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/470\/7e0\/2d8\/4707e02d8ae3568e3f9d417bf2e53935.svg\">) \u043f\u043e <img decoding=\"async\" class=\"formula inline\" source=\"i\" alt=\"i\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/732\/ca5\/e9a\/732ca5e9a4db1f895505b677dd24c829.svg\"> \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0443 (\u0438\u0441\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u043d\u043e\u0435 \u0421\u041a\u041e, \u00abcorrected sample standard deviation\u00bb):<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"\\sigma_i = \\sqrt {\\frac {1} {|C|-1} \\sum_{X \\in C} {(X_i - \\mu_i)^2}} \\tag {CSSD}\" alt=\"\\sigma_i = \\sqrt {\\frac {1} {|C|-1} \\sum_{X \\in C} {(X_i - \\mu_i)^2}} \\tag {CSSD}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/192\/7fc\/27a\/1927fc27ac9e7f8f9af0579f1b555d5c.svg\" width=\"652\" height=\"54\"><\/p>\n<p>\u0433\u0434\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"\\mu_i\" alt=\"\\mu_i\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/8bf\/656\/c87\/8bf656c876c4a2f8a40e6cc64686d8d0.svg\"> \u2014 \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u0435 \u0442\u043e\u0447\u0435\u043a \u043a\u043b\u0430\u0441\u0441\u0430 \u043a \u043a\u043e\u0442\u043e\u0440\u043e\u043c\u0443 \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0441\u044f \u0442\u043e\u0447\u043a\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"U\" alt=\"U\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/b5f\/361\/9b8\/b5f3619b83cd523969e457d0c706ae7c.svg\"> \u0438\/\u0438\u043b\u0438 \u0442\u043e\u0447\u043a\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"V\" alt=\"V\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/dcb\/dc4\/298\/dcbdc4298eceba1392154876f328a133.svg\">) \u043f\u043e <img decoding=\"async\" class=\"formula inline\" source=\"i\" alt=\"i\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/3b4\/572\/a03\/3b4572a03adc493455704d2de6d1a3d1.svg\"> \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0443.<br \/>\u0412 \u0441\u043b\u0443\u0447\u0430\u0435 \u0441\u0440\u0435\u0434\u043d\u0435\u0433\u043e \u0430\u0440\u0438\u0444\u043c\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"\\mu_i = \\frac {1} {|C|} \\sum_{X \\in C} {X_i}\" alt=\"\\mu_i = \\frac {1} {|C|} \\sum_{X \\in C} {X_i}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/ad0\/704\/017\/ad0704017ddcd936bf0262a40607a400.svg\" width=\"119\" height=\"46\"><\/p>\n<p>\u0424\u043e\u0440\u043c\u0443\u043b\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"\\mathrm {(CSSD)}\" alt=\"\\mathrm {(CSSD)}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/71d\/5f0\/954\/71d5f095491d8954e9f154abea9aadb7.svg\"> \u043d\u0443\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u0432 \u0442\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435, \u0435\u0441\u043b\u0438 \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u044f \u0433\u0435\u043d\u0435\u0440\u0430\u043b\u044c\u043d\u043e\u0439 \u0441\u043e\u0432\u043e\u043a\u0443\u043f\u043d\u043e\u0441\u0442\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"\\operatorname E_i\" alt=\"\\operatorname E_i\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/0e1\/773\/6bf\/0e17736bf3e32fa3e0176cc19a11eb98.svg\"> <em>\u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u0435\u043c\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430<\/em> \u043d\u0435\u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b. \u0415\u0441\u043b\u0438 \u0436\u0435 \u043e\u043d\u0438 \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b, \u0442\u043e \u0444\u043e\u0440\u043c\u0443\u043b\u0430 \u0438\u043c\u0435\u0435\u0442 \u0432\u0438\u0434 (\u043d\u0435\u0438\u0441\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u043d\u043e\u0435 \u0421\u041a\u041e, \u0430\u043d\u0433\u043b. \u00abuncorrected sample standard deviation\u00bb):<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"\\sigma_i = \\sqrt {\\frac {1} {|C|} \\sum_{X \\in C} {(X_i - \\operatorname E_i)^2}} \\tag {USSD}\" alt=\"\\sigma_i = \\sqrt {\\frac {1} {|C|} \\sum_{X \\in C} {(X_i - \\operatorname E_i)^2}} \\tag {USSD}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/28d\/9e9\/1a0\/28d9e91a004bd86ee9dade3c97da8341.svg\" width=\"652\" height=\"54\"><\/p>\n<p>\u042d\u0442\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043d\u0435 \u0443\u0447\u0438\u0442\u044b\u0432\u0430\u0435\u0442 \u043a\u0430\u043a\u0443\u044e-\u043b\u0438\u0431\u043e \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c \u043c\u0435\u0436\u0434\u0443 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0430\u043c\u0438 \u0438 \u0442\u0440\u0435\u0431\u0443\u0435\u0442 \u043d\u0435 \u0440\u0430\u0432\u043d\u044b\u0435 \u043d\u0443\u043b\u044e \u0441\u0440\u0435\u0434\u043d\u0435\u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u044f.<\/p>\n<\/div>\n<\/details>\n<details class=\"spoiler\">\n<summary>6. \u041c\u0435\u0442\u043e\u0434 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b<\/summary>\n<div class=\"spoiler__content\">\n<p>\u0418\u0437 <a href=\"https:\/\/arxiv.org\/pdf\/1010.1526.pdf\" rel=\"noopener noreferrer nofollow\">\u0441\u0442\u0430\u0442\u044c\u0438<\/a>:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_{diag}(U, V, \\sigma) = d_{std}(U, V, \\sigma) \\cdot \\sqrt[n] {\\prod^n_{i=1} \\sigma^2_i}\" alt=\"d_{diag}(U, V, \\sigma) = d_{std}(U, V, \\sigma) \\cdot \\sqrt[n] {\\prod^n_{i=1} \\sigma^2_i}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/9f1\/2f6\/a8b\/9f12f6a8b9f7d94aca95f61099fe4caf.svg\" width=\"280\" height=\"54\"><\/p>\n<p>\u0418\u043b\u0438 \u0431\u043e\u043b\u0435\u0435 \u043f\u043e\u043b\u043d\u043e:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_{diag}(U, V, \\sigma) = \\sqrt {\\sum_{i=1}^n {\\left (\\frac {U_i - V_i} {\\sigma_i} \\right)^2}} \\cdot \\sqrt[n] {\\prod^n_{i=1} \\sigma^2_i}\" alt=\"d_{diag}(U, V, \\sigma) = \\sqrt {\\sum_{i=1}^n {\\left (\\frac {U_i - V_i} {\\sigma_i} \\right)^2}} \\cdot \\sqrt[n] {\\prod^n_{i=1} \\sigma^2_i}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/048\/442\/66c\/04844266cf94ad4170dc5d76331edb41.svg\" width=\"327\" height=\"58\"><\/p>\n<p>\u042d\u0442\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043d\u0435 \u0443\u0447\u0438\u0442\u044b\u0432\u0430\u0435\u0442 \u043a\u0430\u043a\u0443\u044e-\u043b\u0438\u0431\u043e \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c \u043c\u0435\u0436\u0434\u0443 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0430\u043c\u0438 \u0438 \u0442\u0440\u0435\u0431\u0443\u0435\u0442 \u043d\u0435 \u0440\u0430\u0432\u043d\u044b\u0435 \u043d\u0443\u043b\u044e \u0441\u0440\u0435\u0434\u043d\u0435\u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u044f.<\/p>\n<\/div>\n<\/details>\n<p>\u0415\u0441\u0442\u044c \u0438 \u0434\u0440\u0443\u0433\u0438\u0435 \u0441\u043f\u043e\u0441\u043e\u0431\u044b, \u043d\u043e \u043e\u043d\u0438 \u0432\u044b\u0445\u043e\u0434\u044f\u0442 \u0437\u0430 \u0440\u0430\u043c\u043a\u0438 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0438.<\/p>\n<p>\u0412\u043e \u0432\u0441\u044f\u043a\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435, \u043a\u0430\u043a \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0430, \u043d\u0443\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0432 10 \u0440\u0430\u0437 \u0431\u043e\u043b\u044c\u0448\u0435 \u0442\u043e\u0447\u0435\u043a, \u0447\u0435\u043c \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432. \u0412\u0435\u0434\u044c \u0437\u0430\u0434\u0430\u0447\u0430 \u043d\u0435 \u0442\u043e\u043b\u044c\u043a\u043e \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e\u0431\u044b \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u044f \u0431\u044b\u043b\u0430 \u0445\u043e\u0440\u043e\u0448\u043e \u043e\u0431\u0443\u0441\u043b\u043e\u0432\u043b\u0435\u043d\u0430, \u043d\u043e \u0442\u0430\u043a\u0436\u0435 \u0438 \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e\u0431\u044b \u043e\u043d\u0430 \u0431\u044b\u043b\u0430 \u0442\u043e\u0447\u043d\u043e\u0439.<\/p>\n<p><a class=\"anchor\" name=\"PointClassAlgorithm\" id=\"PointClassAlgorithm\"><\/a><\/p>\n<h3>2.2 \u0410\u043b\u0433\u043e\u0440\u0438\u0442\u043c \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u0438 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c<\/h3>\n<p><strong>\u0428\u0430\u0433 1.<\/strong> \u0412\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u044f \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u0442\u043e\u0447\u0435\u043a <em>\u043a\u043b\u0430\u0441\u0441\u0430<\/em>.<\/p>\n<p><strong>\u0428\u0430\u0433 2.<\/strong> \u0412\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u0441\u0440\u0435\u0434\u043d\u0435\u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u044f \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u0442\u043e\u0447\u0435\u043a <em>\u043a\u043b\u0430\u0441\u0441\u0430<\/em>.<\/p>\n<p><strong>\u0428\u0430\u0433 3.<\/strong> \u0412\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0438 \u043c\u0435\u0436\u0434\u0443 \u0432\u0441\u0435\u043c\u0438 \u043f\u0430\u0440\u0430\u043c\u0438 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u0442\u043e\u0447\u0435\u043a <em>\u043a\u043b\u0430\u0441\u0441\u0430<\/em> \u0438 \u0441\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0443\u044e \u043c\u0430\u0442\u0440\u0438\u0446\u0443.<\/p>\n<p><strong>\u0428\u0430\u0433 4.<\/strong> \u0415\u0441\u043b\u0438 \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043e\u0431\u0440\u0430\u0442\u0438\u043c\u0430, \u0442\u043e \u0432\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043f\u043e \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0443. \u0415\u0441\u043b\u0438 \u043d\u0435\u0442, \u0442\u043e \u043f\u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u0442\u044c \u043e\u0434\u0438\u043d \u0438\u0437 \u0432\u044b\u0448\u0435\u043f\u0435\u0440\u0435\u0447\u0438\u0441\u043b\u0435\u043d\u043d\u044b\u0445 \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u0432 \u0440\u0435\u0448\u0435\u043d\u0438\u044f.<\/p>\n<p><a class=\"anchor\" name=\"PointClassExample\" id=\"PointClassExample\"><\/a><\/p>\n<h3>2.3 \u041f\u0440\u0438\u043c\u0435\u0440 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u0438 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c<\/h3>\n<p>\u041f\u0443\u0441\u0442\u044c \u0438\u043c\u0435\u0435\u0442\u0441\u044f \u0442\u0435\u0441\u0442\u043e\u0432\u0430\u044f \u0442\u043e\u0447\u043a\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"(4, 2)\" alt=\"(4, 2)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/024\/54e\/55f\/02454e55fe5c1d5e3b105d0b19108429.svg\"> \u0438 \u0434\u0432\u0430 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0445 \u043a\u043b\u0430\u0441\u0441\u0430 (\u0440\u0438\u0441. 3):<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"C_{(1)} = \\{ ( 1 , 1 ) , ( 2 , 2 ) , ( 3 , 3 ) , ( 4 , 4 ) , ( 5 , 5 ) \\} \\\\ C_{(2)} = \\{ ( 3 , 1 ) , ( 4 , 0 ) , ( 6 , 0 ) , ( 6 , 2 ) , ( 5 , 3 ) \\}\" alt=\"C_{(1)} = \\{ ( 1 , 1 ) , ( 2 , 2 ) , ( 3 , 3 ) , ( 4 , 4 ) , ( 5 , 5 ) \\} \\\\ C_{(2)} = \\{ ( 3 , 1 ) , ( 4 , 0 ) , ( 6 , 0 ) , ( 6 , 2 ) , ( 5 , 3 ) \\}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/c60\/04e\/281\/c6004e281b8443ef3b5ea0aacf73e587.svg\" width=\"734\" height=\"48\"><\/p>\n<figure class=\"\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e8f\/ccf\/dbc\/e8fccfdbc99b29fe5c9912f3fe97e4ca.png\" alt=\"\u0420\u0438\u0441\u0443\u043d\u043e\u043a 3. \u0418\u0441\u0445\u043e\u0434\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u043f\u0440\u0438\u043c\u0435\u0440\u0430\" title=\"\u0420\u0438\u0441\u0443\u043d\u043e\u043a 3. \u0418\u0441\u0445\u043e\u0434\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u043f\u0440\u0438\u043c\u0435\u0440\u0430\" width=\"400\" height=\"400\"><figcaption>\u0420\u0438\u0441\u0443\u043d\u043e\u043a 3. \u0418\u0441\u0445\u043e\u0434\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u043f\u0440\u0438\u043c\u0435\u0440\u0430<\/figcaption><\/figure>\n<p><strong>\u0428\u0430\u0433 1.<\/strong> \u0412\u044b\u0447\u0438\u0441\u043b\u0438\u043c \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u044f \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u0442\u043e\u0447\u0435\u043a <em>\u043a\u043b\u0430\u0441\u0441\u043e\u0432<\/em>.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"\\mu_{(1)} = \\left (\\frac {1 + 2 + 3 + 4 + 5} {5}, \\frac {1 + 2 + 3 + 4 + 5} {5} \\right) = (3, 3) \\\\ \\mu_{(2)} = \\left (\\frac {3 + 4 + 6 + 6 + 5} {5}, \\frac {1 + 0 + 0 + 2 + 3} {5} \\right) = (4.8, 1.2)\" alt=\"\\mu_{(1)} = \\left (\\frac {1 + 2 + 3 + 4 + 5} {5}, \\frac {1 + 2 + 3 + 4 + 5} {5} \\right) = (3, 3) \\\\ \\mu_{(2)} = \\left (\\frac {3 + 4 + 6 + 6 + 5} {5}, \\frac {1 + 0 + 0 + 2 + 3} {5} \\right) = (4.8, 1.2)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/6f3\/eaf\/84c\/6f3eaf84c0883430e2d16691f6f8cb2a.svg\" width=\"734\" height=\"91\"><\/p>\n<p><strong>\u0428\u0430\u0433 2.<\/strong> \u0412\u044b\u0447\u0438\u0441\u043b\u0438\u043c \u0441\u0440\u0435\u0434\u043d\u0435\u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u044f \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u0442\u043e\u0447\u0435\u043a <em>\u043a\u043b\u0430\u0441\u0441\u043e\u0432<\/em>.<\/p>\n<p>\u041f\u043e \u043f\u0435\u0440\u0432\u043e\u043c\u0443 \u0438 \u0432\u0442\u043e\u0440\u043e\u043c\u0443 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0430\u043c \u0442\u043e\u0447\u0435\u043a \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"\\sigma_{(1)1} = \\sqrt {\\frac {(1-3)^2+(2-3)^2+(3-3)^2+(4-3)^2+(5-3)^2} {5 - 1}} = \\sqrt {2.5} \\\\ \\sigma_{(1)2} = \\sqrt {\\frac {(1-3)^2+(2-3)^2+(3-3)^2+(4-3)^2+(5-3)^2} {5 - 1}} = \\sqrt {2.5}\" alt=\"\\sigma_{(1)1} = \\sqrt {\\frac {(1-3)^2+(2-3)^2+(3-3)^2+(4-3)^2+(5-3)^2} {5 - 1}} = \\sqrt {2.5} \\\\ \\sigma_{(1)2} = \\sqrt {\\frac {(1-3)^2+(2-3)^2+(3-3)^2+(4-3)^2+(5-3)^2} {5 - 1}} = \\sqrt {2.5}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/1c2\/10b\/2c1\/1c210b2c1d12068657080858be71a69b.svg\" width=\"734\" height=\"114\"><\/p>\n<p>\u041f\u043e \u043f\u0435\u0440\u0432\u043e\u043c\u0443 \u0438 \u0432\u0442\u043e\u0440\u043e\u043c\u0443 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0430\u043c \u0442\u043e\u0447\u0435\u043a \u0432\u0442\u043e\u0440\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"\\sigma_{(2)1} = \\sqrt {\\frac {(3-4.8)^2+(4-4.8)^2+(6-4.8)^2+(6-4.8)^2+(5-4.8)^2} {5 - 1}} = \\sqrt {1.7} \\\\ \\sigma_{(2)2} = \\sqrt {\\frac {(1-1.2)^2+(0-1.2)^2+(0-1.2)^2+(2-1.2)^2+(3-1.2)^2} {5 - 1}} = \\sqrt {1.7}\" alt=\"\\sigma_{(2)1} = \\sqrt {\\frac {(3-4.8)^2+(4-4.8)^2+(6-4.8)^2+(6-4.8)^2+(5-4.8)^2} {5 - 1}} = \\sqrt {1.7} \\\\ \\sigma_{(2)2} = \\sqrt {\\frac {(1-1.2)^2+(0-1.2)^2+(0-1.2)^2+(2-1.2)^2+(3-1.2)^2} {5 - 1}} = \\sqrt {1.7}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/d6d\/099\/5bd\/d6d0995bd0fe23352f5c2eb6c09b290c.svg\" width=\"734\" height=\"114\"><\/p>\n<p><strong>\u0428\u0430\u0433 3.<\/strong> \u0412\u044b\u0447\u0438\u0441\u043b\u0438\u043c \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0438 \u043c\u0435\u0436\u0434\u0443 \u0432\u0441\u0435\u043c\u0438 \u043f\u0430\u0440\u0430\u043c\u0438 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u0442\u043e\u0447\u0435\u043a <em>\u043a\u043b\u0430\u0441\u0441\u043e\u0432<\/em> \u0438 \u0441\u043e\u0441\u0442\u0430\u0432\u0438\u043c \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0435 \u043c\u0430\u0442\u0440\u0438\u0446\u044b.<\/p>\n<p><strong>\u0414\u043b\u044f \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430.<\/strong><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"cov_{(1)1,1} = \\sigma^2_{(1)1} = 2.5 \\quad cov_{(1)1,2} = cov_{(1)2,1} \\quad cov_{(1)2,2} = \\sigma^2_{(1)2} = 2.5 \\\\ cov_{(1)1,2} = \\frac {1} {5-1} \\sum_{X \\in C_{(1)}} {(X_1 - \\mu_1) \\cdot (X_2 - \\mu_2)} = \\\\  \\frac {1} {4} \\left ( (1 - 3) (1 - 3) + (2 - 3) (2 - 3) + (3 - 3) (3 - 3) + \\\\ + (4 - 3) (4 - 3) + (5 - 3) (5 - 3) \\right) = \\frac {10} {4} = 2.5\" alt=\"cov_{(1)1,1} = \\sigma^2_{(1)1} = 2.5 \\quad cov_{(1)1,2} = cov_{(1)2,1} \\quad cov_{(1)2,2} = \\sigma^2_{(1)2} = 2.5 \\\\ cov_{(1)1,2} = \\frac {1} {5-1} \\sum_{X \\in C_{(1)}} {(X_1 - \\mu_1) \\cdot (X_2 - \\mu_2)} = \\\\  \\frac {1} {4} \\left ( (1 - 3) (1 - 3) + (2 - 3) (2 - 3) + (3 - 3) (3 - 3) + \\\\ + (4 - 3) (4 - 3) + (5 - 3) (5 - 3) \\right) = \\frac {10} {4} = 2.5\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/d77\/199\/b95\/d77199b952e72178ddd14a9ecac71f21.svg\" width=\"734\" height=\"163\"><\/p>\n<p>\u041f\u043e\u043b\u0443\u0447\u0438\u043c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0443\u044e \u043c\u0430\u0442\u0440\u0438\u0446\u0443 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"COV_{(1)} = \\begin{pmatrix} cov_{(1)1,1} &amp; cov_{(1)1,2} \\\\ cov_{(1)2,1} &amp; cov_{(1)2,2} \\end{pmatrix} = \\begin{pmatrix} 2.5 &amp; 2.5 \\\\ 2.5 &amp; 2.5 \\end{pmatrix}\" alt=\"COV_{(1)} = \\begin{pmatrix} cov_{(1)1,1} &amp; cov_{(1)1,2} \\\\ cov_{(1)2,1} &amp; cov_{(1)2,2} \\end{pmatrix} = \\begin{pmatrix} 2.5 &amp; 2.5 \\\\ 2.5 &amp; 2.5 \\end{pmatrix}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/72a\/48d\/f8a\/72a48df8a1eb428795bfffa4c0213615.svg\" width=\"348\" height=\"54\"><\/p>\n<p>\u0412\u044b\u0447\u0438\u0441\u043b\u0438\u043c \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u0435\u043b\u044c \u044d\u0442\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b: <img decoding=\"async\" class=\"formula inline\" source=\"2.5 \\cdot 2.5 - 2.5 \\cdot 2.5 = 0\" alt=\"2.5 \\cdot 2.5 - 2.5 \\cdot 2.5 = 0\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/9c5\/37b\/f28\/9c537bf28f773ecb102ca4201bbd88c5.svg\">. \u0421\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e, \u043c\u0430\u0442\u0440\u0438\u0446\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"COV_{(1)}\" alt=\"COV_{(1)}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a51\/866\/edc\/a51866edca302fd8c76a18a30939caa3.svg\"> <u>\u043d\u0435\u043e\u0431\u0440\u0430\u0442\u0438\u043c\u0430<\/u>.<\/p>\n<p><strong>\u0414\u043b\u044f \u0432\u0442\u043e\u0440\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430.<\/strong><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"cov_{(2)1,1} = \\sigma^2_{(2)1} = 1.7 \\quad cov_{(2)1,2} = cov_{(2)2,1} \\quad cov_{(2)2,2} = \\sigma^2_{(2)2} = 1.7 \\\\ cov_{(2)1,2} = \\frac {1} {5-1} \\sum_{X \\in C_{(2)}} {(X_1 - \\mu_1) \\cdot (X_2 - \\mu_2)} = \\\\ = \\frac {1} {4} \\left ( (3 - 4.8) (1 - 1.2) + (4 - 4.8) (0 - 1.2) + (6 - 4.8) (0 - 1.2) + \\\\ + (6 - 4.8) (2 - 1.2) + (5 - 4.8) (3 - 1.2) \\right) = \\frac {1.2} {4} = 0.3\" alt=\"cov_{(2)1,1} = \\sigma^2_{(2)1} = 1.7 \\quad cov_{(2)1,2} = cov_{(2)2,1} \\quad cov_{(2)2,2} = \\sigma^2_{(2)2} = 1.7 \\\\ cov_{(2)1,2} = \\frac {1} {5-1} \\sum_{X \\in C_{(2)}} {(X_1 - \\mu_1) \\cdot (X_2 - \\mu_2)} = \\\\ = \\frac {1} {4} \\left ( (3 - 4.8) (1 - 1.2) + (4 - 4.8) (0 - 1.2) + (6 - 4.8) (0 - 1.2) + \\\\ + (6 - 4.8) (2 - 1.2) + (5 - 4.8) (3 - 1.2) \\right) = \\frac {1.2} {4} = 0.3\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/053\/dfe\/507\/053dfe50738346b949ec8f172ba865e8.svg\" width=\"734\" height=\"163\"><\/p>\n<p>\u041f\u043e\u043b\u0443\u0447\u0438\u043c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0443\u044e \u043c\u0430\u0442\u0440\u0438\u0446\u0443 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"COV_{(2)} = \\begin{pmatrix} cov_{(2)1,1} &amp; cov_{(2)1,2} \\\\ cov_{(2)2,1} &amp; cov_{(2)2,2} \\end{pmatrix} = \\begin{pmatrix} 1.7 &amp; 0.3 \\\\ 0.3 &amp; 1.7 \\end{pmatrix}\" alt=\"COV_{(2)} = \\begin{pmatrix} cov_{(2)1,1} &amp; cov_{(2)1,2} \\\\ cov_{(2)2,1} &amp; cov_{(2)2,2} \\end{pmatrix} = \\begin{pmatrix} 1.7 &amp; 0.3 \\\\ 0.3 &amp; 1.7 \\end{pmatrix}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/7bb\/9ec\/1cb\/7bb9ec1cbc5ab2e7efaa9b51314468b1.svg\" width=\"348\" height=\"54\"><\/p>\n<p>\u0412\u044b\u0447\u0438\u0441\u043b\u0438\u043c \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u0435\u043b\u044c \u044d\u0442\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b: <img decoding=\"async\" class=\"formula inline\" source=\"1.7*1.7-0.3*0.3=2.8 \\neq 0\" alt=\"1.7*1.7-0.3*0.3=2.8 \\neq 0\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/f5a\/2e1\/99e\/f5a2e199e26a8d03865bcfc9f3edcdf7.svg\">. \u0421\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e, \u043c\u0430\u0442\u0440\u0438\u0446\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"COV_{(2)}\" alt=\"COV_{(2)}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/8ad\/489\/b85\/8ad489b8510404ab23e7b6a5c83ecc65.svg\"> <u>\u043e\u0431\u0440\u0430\u0442\u0438\u043c\u0430<\/u>.<\/p>\n<details class=\"spoiler\">\n<summary>\u041a\u043e\u0434 \u043d\u0430 Python 3.6 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 numpy 1.19.5<\/summary>\n<div class=\"spoiler__content\">\n<pre><code class=\"python\">import numpy as np  classes = [     np.array([[1, 1], [2, 2], [3, 3], [4, 4], [5, 5]]),     np.array([[3, 1], [4, 0], [6, 0], [6, 2], [5, 3]]) ]  centroids = [class_.mean(axis=0) for class_ in classes] standard_deviations = [class_.std(axis=0, ddof=1) for class_ in classes] covariance_matrices = np.array([np.cov(class_, rowvar=False, ddof=1) for class_ in classes]) det_covariance_matrices = [np.linalg.det(cov) for cov in covariance_matrices]  print(\"Centroids:\", *centroids) print(\"Standard deviations:\", *standard_deviations) print(\"Covariance matrices:\", *covariance_matrices.tolist()) print(\"Determinants of covariance matrices:\", det_covariance_matrices) <\/code><\/pre>\n<p>\u0412\u044b\u0432\u043e\u0434:<\/p>\n<pre><code class=\"xml\">Centroids: [3. 3.] [4.8 1.2] Standard deviations: [1.58113883 1.58113883] [1.30384048 1.30384048] Covariance matrices: [[2.5, 2.5], [2.5, 2.5]] [[1.7, 0.3], [0.3, 1.7]] Determinants of covariance matrices: [0.0, 2.8]<\/code><\/pre>\n<\/div>\n<\/details>\n<p><strong>\u0428\u0430\u0433 4.<\/strong> \u0415\u0441\u043b\u0438 \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043e\u0431\u0440\u0430\u0442\u0438\u043c\u0430, \u0442\u043e \u0432\u044b\u0447\u0438\u0441\u043b\u0438\u043c \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043f\u043e \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0443 \u0438 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043f\u043e \u0415\u0432\u043a\u043b\u0438\u0434\u0443 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0443. \u0415\u0441\u043b\u0438 \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043d\u0435\u043e\u0431\u0440\u0430\u0442\u0438\u043c\u0430, \u0442\u043e \u043f\u043e\u043f\u0440\u043e\u0431\u0443\u0435\u043c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u0432 \u0440\u0435\u0448\u0435\u043d\u0438\u044f \u044d\u0442\u043e\u0439 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b.<\/p>\n<p>\u0420\u0430\u0437\u043b\u0438\u0447\u0430\u044e\u0442 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435, \u0438\u0437\u043c\u0435\u0440\u044f\u0435\u043c\u043e\u0435 \u043f\u043e \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0443 \u0431\u043b\u0438\u0436\u0430\u0439\u0448\u0435\u0433\u043e \u0441\u043e\u0441\u0435\u0434\u0430, \u0434\u0430\u043b\u044c\u043d\u0435\u0433\u043e \u0441\u043e\u0441\u0435\u0434\u0430 \u0438 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435, \u0438\u0437\u043c\u0435\u0440\u044f\u0435\u043c\u043e\u0435 \u043f\u043e \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0443 \u0446\u0435\u043d\u0442\u0440\u043e\u0438\u0434\u0430.<br \/>\u0418\u0437\u043c\u0435\u0440\u0438\u043c \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0442\u0435\u0441\u0442\u043e\u0432\u043e\u0439 \u0442\u043e\u0447\u043a\u043e\u0439 <img decoding=\"async\" class=\"formula inline\" source=\"(4,2)\" alt=\"(4,2)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/862\/d5e\/773\/862d5e7736f4e4387eb236b39238bdf6.svg\"> \u0438 \u0432\u0441\u0435\u043c\u0438 \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u0432, \u0432\u043a\u043b\u044e\u0447\u0430\u044f \u0442\u043e\u0447\u043a\u0443 \u0446\u0435\u043d\u0442\u0440\u043e\u0438\u0434\u0430.<\/p>\n<p><strong><u>\u041f\u0435\u0440\u0432\u044b\u0439 \u043a\u043b\u0430\u0441\u0441<\/u>.<\/strong> \u041a\u0430\u043a \u0443\u0436\u0435 \u0431\u044b\u043b\u043e \u0441\u043a\u0430\u0437\u0430\u043d\u043e \u0440\u0430\u043d\u0435\u0435 \u2014 \u0434\u043b\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 <u>\u043d\u0435\u043b\u044c\u0437\u044f<\/u> \u043d\u0430\u0439\u0442\u0438 \u043e\u0431\u0440\u0430\u0442\u043d\u0443\u044e \u043c\u0430\u0442\u0440\u0438\u0446\u0443, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u0442\u0435\u0441\u0442\u043e\u0432\u043e\u0439 \u0442\u043e\u0447\u043a\u043e\u0439 \u0438 \u043f\u0435\u0440\u0432\u044b\u043c \u043a\u043b\u0430\u0441\u0441\u043e\u043c \u0431\u0443\u0434\u0435\u043c \u0432\u044b\u0447\u0438\u0441\u043b\u044f\u0442\u044c \u043f\u043e 5 \u0444\u043e\u0440\u043c\u0443\u043b\u0430\u043c: <em>(1) \u043c\u0435\u0442\u0440\u0438\u043a\u0430 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430, (2) \u043c\u0435\u0442\u043e\u0434 \u0443\u0441\u0430\u0434\u043a\u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b (LedoitWolf), (3) \u043f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u044b\u0439 \u043f\u043e\u0434\u0445\u043e\u0434, (4) \u043d\u043e\u0440\u043c\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0415\u0432\u043a\u043b\u0438\u0434\u0430, (5) \u043c\u0435\u0442\u043e\u0434 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b<\/em> \u2014 \u0438 \u0432\u044b\u0431\u0435\u0440\u0435\u043c \u0441\u0440\u0435\u0434\u0438 \u043d\u0438\u0445 \u043d\u0430\u0438\u0431\u043e\u043b\u0435\u0435 \u043f\u0440\u0430\u0432\u0434\u043e\u043f\u043e\u0434\u043e\u0431\u043d\u0443\u044e:<\/p>\n<p><strong>1.<\/strong> \u041c\u0435\u0442\u0440\u0438\u043a\u0430 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_{E-M}\\left((4,2), (1,1), \\begin{pmatrix} 0.5833 &amp; -0.4167 \\\\ -0.4167 &amp; 0.5833 \\end{pmatrix} \\right) = 1.8257 \\\\ d_{E-M}\\left((4,2), (2,2), \\begin{pmatrix} 0.5833 &amp; -0.4167 \\\\ -0.4167 &amp; 0.5833 \\end{pmatrix} \\right) = 1.5275 \\\\ d_{E-M}\\left((4,2), (3,3), \\begin{pmatrix} 0.5833 &amp; -0.4167 \\\\ -0.4167 &amp; 0.5833 \\end{pmatrix} \\right) = 1.4142 \\\\ d_{E-M}\\left((4,2), (4,4), \\begin{pmatrix} 0.5833 &amp; -0.4167 \\\\ -0.4167 &amp; 0.5833 \\end{pmatrix} \\right) = 1.5275 \\\\ d_{E-M}\\left((4,2), (5,5), \\begin{pmatrix} 0.5833 &amp; -0.4167 \\\\ -0.4167 &amp; 0.5833 \\end{pmatrix} \\right) = 1.8257\" alt=\"d_{E-M}\\left((4,2), (1,1), \\begin{pmatrix} 0.5833 &amp; -0.4167 \\\\ -0.4167 &amp; 0.5833 \\end{pmatrix} \\right) = 1.8257 \\\\ d_{E-M}\\left((4,2), (2,2), \\begin{pmatrix} 0.5833 &amp; -0.4167 \\\\ -0.4167 &amp; 0.5833 \\end{pmatrix} \\right) = 1.5275 \\\\ d_{E-M}\\left((4,2), (3,3), \\begin{pmatrix} 0.5833 &amp; -0.4167 \\\\ -0.4167 &amp; 0.5833 \\end{pmatrix} \\right) = 1.4142 \\\\ d_{E-M}\\left((4,2), (4,4), \\begin{pmatrix} 0.5833 &amp; -0.4167 \\\\ -0.4167 &amp; 0.5833 \\end{pmatrix} \\right) = 1.5275 \\\\ d_{E-M}\\left((4,2), (5,5), \\begin{pmatrix} 0.5833 &amp; -0.4167 \\\\ -0.4167 &amp; 0.5833 \\end{pmatrix} \\right) = 1.8257\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e2a\/189\/9d7\/e2a1899d7291015163d6adde55876d36.svg\" width=\"734\" height=\"234\"><\/p>\n<details class=\"spoiler\">\n<summary>\u041a\u043e\u0434 \u043d\u0430 Python 3.6 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 numpy 1.19.5<\/summary>\n<div class=\"spoiler__content\">\n<pre><code class=\"python\">import numpy as np   def mahalanobis(point_from, point_to, inverse_covariance_matrix):     delta = point_from - point_to     return max(np.float64(0), np.dot(np.dot(delta, inverse_covariance_matrix), delta)) ** 0.5   test_point = np.array([4., 2.]) class_ = np.array([[1., 1.], [2., 2.], [3., 3.], [4., 4.], [5., 5.]]) covariance_matrix = np.cov(class_, rowvar=False, ddof=1) inverse_covariance_matrix = np.linalg.inv(covariance_matrix + np.identity(covariance_matrix.shape[0])) print(\"\u041e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430:\\n\", inverse_covariance_matrix, sep='')  for point_to in [class_.mean(axis=0), *class_]:     print(\"d_E-M (\", test_point, \", \", point_to, \", (COV+E)^(-1)) = \",           mahalanobis(test_point, point_to, inverse_covariance_matrix), sep='') <\/code><\/pre>\n<p>\u0412\u044b\u0432\u043e\u0434:<\/p>\n<pre><code class=\"xml\">\u041e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430: [[ 0.58333333 -0.41666667]  [-0.41666667  0.58333333]] d_E-M ([4. 2.], [3. 3.], (COV+E)^(-1)) = 1.414213562373095 d_E-M ([4. 2.], [1. 1.], (COV+E)^(-1)) = 1.8257418583505538 d_E-M ([4. 2.], [2. 2.], (COV+E)^(-1)) = 1.5275252316519465 d_E-M ([4. 2.], [3. 3.], (COV+E)^(-1)) = 1.414213562373095 d_E-M ([4. 2.], [4. 4.], (COV+E)^(-1)) = 1.5275252316519465 d_E-M ([4. 2.], [5. 5.], (COV+E)^(-1)) = 1.8257418583505536<\/code><\/pre>\n<p>\u041f\u0435\u0440\u0432\u0430\u044f \u0442\u043e\u0447\u043a\u0430 \u2014 \u0442\u043e\u0447\u043a\u0430 \u0446\u0435\u043d\u0442\u0440\u043e\u0438\u0434\u0430, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0441\u043e\u0432\u043f\u0430\u0434\u0430\u0435\u0442 \u0441 \u043e\u0434\u043d\u043e\u0439 \u0438\u0437 \u0442\u043e\u0447\u0435\u043a \u043a\u043b\u0430\u0441\u0441\u0430.<\/p>\n<\/div>\n<\/details>\n<p><strong>2.<\/strong> \u041c\u0435\u0442\u043e\u0434 \u0443\u0441\u0430\u0434\u043a\u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b (<a href=\"https:\/\/scikit-learn.org\/stable\/modules\/covariance.html#ledoit-wolf-shrinkage\" rel=\"noopener noreferrer nofollow\">LedoitWolf<\/a>).<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_{M{(*)}}\\left((4,2), (1,1), \\begin{pmatrix} 1.0382 &amp; -0.7475 \\\\ -0.7475 &amp; 1.0382 \\end{pmatrix} \\right) = 2.4284 \\\\ d_{M{(*)}}\\left((4,2), (2,2), \\begin{pmatrix} 1.0382 &amp; -0.7475 \\\\ -0.7475 &amp; 1.0382 \\end{pmatrix} \\right) = 2.0378 \\\\ d_{M{(*)}}\\left((4,2), (3,3), \\begin{pmatrix} 1.0382 &amp; -0.7475 \\\\ -0.7475 &amp; 1.0382 \\end{pmatrix} \\right) = 1.8898 \\\\ d_{M{(*)}}\\left((4,2), (4,4), \\begin{pmatrix} 1.0382 &amp; -0.7475 \\\\ -0.7475 &amp; 1.0382 \\end{pmatrix} \\right) = 2.0378 \\\\ d_{M{(*)}}\\left((4,2), (5,5), \\begin{pmatrix} 1.0382 &amp; -0.7475 \\\\ -0.7475 &amp; 1.0382 \\end{pmatrix} \\right) = 2.4284\" alt=\"d_{M{(*)}}\\left((4,2), (1,1), \\begin{pmatrix} 1.0382 &amp; -0.7475 \\\\ -0.7475 &amp; 1.0382 \\end{pmatrix} \\right) = 2.4284 \\\\ d_{M{(*)}}\\left((4,2), (2,2), \\begin{pmatrix} 1.0382 &amp; -0.7475 \\\\ -0.7475 &amp; 1.0382 \\end{pmatrix} \\right) = 2.0378 \\\\ d_{M{(*)}}\\left((4,2), (3,3), \\begin{pmatrix} 1.0382 &amp; -0.7475 \\\\ -0.7475 &amp; 1.0382 \\end{pmatrix} \\right) = 1.8898 \\\\ d_{M{(*)}}\\left((4,2), (4,4), \\begin{pmatrix} 1.0382 &amp; -0.7475 \\\\ -0.7475 &amp; 1.0382 \\end{pmatrix} \\right) = 2.0378 \\\\ d_{M{(*)}}\\left((4,2), (5,5), \\begin{pmatrix} 1.0382 &amp; -0.7475 \\\\ -0.7475 &amp; 1.0382 \\end{pmatrix} \\right) = 2.4284\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/8b3\/21d\/082\/8b321d08207d9541c022f71f569132d3.svg\" width=\"734\" height=\"234\"><\/p>\n<details class=\"spoiler\">\n<summary>\u041a\u043e\u0434 \u043d\u0430 Python 3.6 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a numpy 1.19.5 \u0438 scikit-learn 0.24.1<\/summary>\n<div class=\"spoiler__content\">\n<pre><code class=\"python\">import numpy as np from sklearn.covariance import LedoitWolf   def mahalanobis(point_from, point_to, inverse_covariance_matrix):     delta = point_from - point_to     return max(np.float64(0), np.dot(np.dot(delta, inverse_covariance_matrix), delta)) ** 0.5   def approx(number, *, sign, epsilon=1e-4):     return number + np.sign(sign) * epsilon   test_point = np.array([4., 2.]) class_ = np.array([[1., 1.], [2., 2.], [3., 3.], [4., 4.], [5., 5.]]) lw = LedoitWolf().fit(class_) lw_covariance_matrix = lw.covariance_ lw_lambda = lw.shrinkage_ covariance_matrix = np.cov(class_, rowvar=False, ddof=0) mu = np.sum(np.trace(covariance_matrix)) \/ class_.shape[0] T = mu * np.identity(class_.shape[1]) print(\"T:\", *T) print(\"COV(*):\", *lw_covariance_matrix) print(\"Lambda:\", lw_lambda)  # \u041f\u0435\u0440\u0432\u043e\u0435 \u0443\u0441\u043b\u043e\u0432\u0438\u0435 - T \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043f\u043e\u043b\u043e\u0436\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u0435\u0439 # (\u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e\u0435 \u0443\u0441\u043b\u043e\u0432\u0438\u0435: \u0432\u0441\u0435 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u044b T \u043f\u043e\u043b\u043e\u0436\u0438\u0442\u0435\u043b\u044c\u043d\u044b) # ddof=0, \u0442. \u043a. LedoitWolf \u0432\u044b\u0437\u044b\u0432\u0430\u0435\u0442 empirical_covariance (\u0438\u0441\u043f. \u0441\u043c\u0435\u0449\u0435\u043d\u043d\u0443\u044e \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u044e) first_condition = (np.linalg.eig(T)[0] &gt; approx(0., sign=+1)).all() print(\"All(\", np.linalg.eig(T)[0], \") &gt; 0 ? -&gt; \", first_condition, sep='')  # \u0412\u0442\u043e\u0440\u043e\u0435 \u0443\u0441\u043b\u043e\u0432\u0438\u0435 - \u043b\u044f\u043c\u0431\u0434\u0430 \u0432 \u043f\u043e\u043b\u0443\u0438\u043d\u0442\u0435\u0440\u0432\u0430\u043b\u0435 (0, 1] second_condition = approx(0., sign=+1) &lt; lw_lambda &lt;= 1 print(\"Lambda =\", lw_lambda, \"in (0, 1] ? -&gt;\", second_condition)  # \u0422\u0440\u0435\u0442\u044c\u0435 \u0443\u0441\u043b\u043e\u0432\u0438\u0435 - \u043d\u0430\u0438\u043c\u0435\u043d\u044c\u0448\u0435\u0435 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043c\u0430\u0442\u0440\u0438\u0446\u044b COV(*) # \u0434\u043e\u043b\u0436\u043d\u043e \u0431\u044b\u0442\u044c \u043d\u0435 \u043c\u0435\u043d\u044c\u0448\u0435 lambda, \u0443\u043c\u043d\u043e\u0436\u0435\u043d\u043d\u043e\u0439 \u043d\u0430 \u043d\u0430\u0438\u043c\u0435\u043d\u044c\u0448\u0435\u0435 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 T cov_eig = min(np.linalg.eig(lw_covariance_matrix)[0]) lambda_t_eig = lw_lambda * min(np.linalg.eig(T)[0]) third_condition = cov_eig &gt;= lambda_t_eig print(cov_eig, \"&gt;=\", lambda_t_eig, \"? -&gt;\", third_condition) conditions = [first_condition, second_condition, third_condition]  if all(conditions):     print(\"\u0412\u0441\u0435 \u0442\u0440\u0438 \u0443\u0441\u043b\u043e\u0432\u0438\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u044b\")     # \u041e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430     inverse_lw_covariance_matrix = np.linalg.inv(lw_covariance_matrix)     print(\"\u041e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430:\\n\", inverse_lw_covariance_matrix, sep='')     for point_to in [class_.mean(axis=0), *class_]:         print(\"d_M(*) (\", test_point, \", \", point_to, \", COV(*)) = \",               mahalanobis(test_point, point_to, inverse_lw_covariance_matrix), sep='') else:     print(\"\u041d\u0435\u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u043d\u044b\u0435 \u0443\u0441\u043b\u043e\u0432\u0438\u044f (1-3): \", [i for i, x in enumerate(conditions, 1) if not x]) <\/code><\/pre>\n<p>\u0412\u044b\u0432\u043e\u0434:<\/p>\n<pre><code class=\"xml\">T: [0.8 0. ] [0.  0.8] COV(*): [2.   1.44] [1.44 2.  ] Lambda: 0.27999999999999997 All([0.8 0.8]) &gt; 0 ? -&gt; True Lambda = 0.27999999999999997 in (0, 1] ? -&gt; True 0.56 &gt;= 0.22399999999999998 ? -&gt; True \u0412\u0441\u0435 \u0442\u0440\u0438 \u0443\u0441\u043b\u043e\u0432\u0438\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u044b \u041e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430: [[ 1.03820598 -0.74750831]  [-0.74750831  1.03820598]] d_M(*) ([4. 2.], [3. 3.], COV(*)) = 1.889822365046136 d_M(*) ([4. 2.], [1. 1.], COV(*)) = 2.4283759936997833 d_M(*) ([4. 2.], [2. 2.], COV(*)) = 2.037847864848056 d_M(*) ([4. 2.], [3. 3.], COV(*)) = 1.889822365046136 d_M(*) ([4. 2.], [4. 4.], COV(*)) = 2.037847864848056 d_M(*) ([4. 2.], [5. 5.], COV(*)) = 2.4283759936997833<\/code><\/pre>\n<p>\u041f\u0435\u0440\u0432\u0430\u044f \u0442\u043e\u0447\u043a\u0430 \u2014 \u0442\u043e\u0447\u043a\u0430 \u0446\u0435\u043d\u0442\u0440\u043e\u0438\u0434\u0430, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0441\u043e\u0432\u043f\u0430\u0434\u0430\u0435\u0442 \u0441 \u043e\u0434\u043d\u043e\u0439 \u0438\u0437 \u0442\u043e\u0447\u0435\u043a \u043a\u043b\u0430\u0441\u0441\u0430.<\/p>\n<\/div>\n<\/details>\n<p><strong>3. <\/strong>\u041f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u044b\u0439 \u043f\u043e\u0434\u0445\u043e\u0434.<\/p>\n<p>\u0420\u0430\u043d\u0435\u0435 \u0443\u0436\u0435 \u0431\u044b\u043b\u043e \u0441\u043a\u0430\u0437\u0430\u043d\u043e \u043f\u0440\u043e \u043f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u044b\u0435 \u043c\u0430\u0442\u0440\u0438\u0446\u044b. \u0418\u0445 \u043d\u0435\u0434\u043e\u0441\u0442\u0430\u0442\u043e\u043a \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0434\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u0432 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u0435.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_{M^+}\\left((4,2), (1,1), \\begin{pmatrix} 0.1 &amp; 0.1 \\\\ 0.1 &amp; 0.1 \\end{pmatrix} \\right) = 1.2649 \\\\ d_{M^+}\\left((4,2), (2,2), \\begin{pmatrix} 0.1 &amp; 0.1 \\\\ 0.1 &amp; 0.1 \\end{pmatrix} \\right) = 0.6324 \\\\ d_{M^+}\\left((4,2), (3,3), \\begin{pmatrix} 0.1 &amp; 0.1 \\\\ 0.1 &amp; 0.1 \\end{pmatrix} \\right) = 0.0000 \\\\ d_{M^+}\\left((4,2), (4,4), \\begin{pmatrix} 0.1 &amp; 0.1 \\\\ 0.1 &amp; 0.1 \\end{pmatrix} \\right) = 0.6324 \\\\ d_{M^+}\\left((4,2), (5,5), \\begin{pmatrix} 0.1 &amp; 0.1 \\\\ 0.1 &amp; 0.1 \\end{pmatrix} \\right) = 1.2649\" alt=\"d_{M^+}\\left((4,2), (1,1), \\begin{pmatrix} 0.1 &amp; 0.1 \\\\ 0.1 &amp; 0.1 \\end{pmatrix} \\right) = 1.2649 \\\\ d_{M^+}\\left((4,2), (2,2), \\begin{pmatrix} 0.1 &amp; 0.1 \\\\ 0.1 &amp; 0.1 \\end{pmatrix} \\right) = 0.6324 \\\\ d_{M^+}\\left((4,2), (3,3), \\begin{pmatrix} 0.1 &amp; 0.1 \\\\ 0.1 &amp; 0.1 \\end{pmatrix} \\right) = 0.0000 \\\\ d_{M^+}\\left((4,2), (4,4), \\begin{pmatrix} 0.1 &amp; 0.1 \\\\ 0.1 &amp; 0.1 \\end{pmatrix} \\right) = 0.6324 \\\\ d_{M^+}\\left((4,2), (5,5), \\begin{pmatrix} 0.1 &amp; 0.1 \\\\ 0.1 &amp; 0.1 \\end{pmatrix} \\right) = 1.2649\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a59\/539\/b5b\/a59539b5be43591dfcd6811ef1e011dc.svg\" width=\"734\" height=\"234\"><\/p>\n<p>\u041a\u0430\u043a \u0432\u0438\u0434\u0438\u043c, \u043d\u0430\u0440\u0443\u0448\u0435\u043d\u0430 \u0430\u043a\u0441\u0438\u043e\u043c\u0430 \u0442\u043e\u0436\u0434\u0435\u0441\u0442\u0432\u0430 \u2014 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u043c\u0438 \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u0440\u0430\u0432\u043d\u043e \u043d\u0443\u043b\u044e.<\/p>\n<details class=\"spoiler\">\n<summary>\u041a\u043e\u0434 \u043d\u0430 Python 3.6 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 numpy 1.19.5<\/summary>\n<div class=\"spoiler__content\">\n<pre><code class=\"python\">import numpy as np   def mahalanobis(point_from, point_to, inverse_covariance_matrix):     delta = point_from - point_to     return max(np.float64(0), np.dot(np.dot(delta, inverse_covariance_matrix), delta)) ** 0.5   test_point = np.array([4., 2.]) class_ = np.array([[1., 1.], [2., 2.], [3., 3.], [4., 4.], [5., 5.]]) covariance_matrix = np.cov(class_, rowvar=False, ddof=1) # \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0441\u0438\u043d\u0433\u0443\u043b\u044f\u0440\u043d\u043e\u0435 \u0440\u0430\u0437\u043b\u043e\u0436\u0435\u043d\u0438\u0435 (Singular Value Decomposition, SVD) # \u0434\u043b\u044f \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u043f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b pseudo_inverse_covariance_matrix = np.linalg.pinv(covariance_matrix) print(\"\u041f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430:\\n\", pseudo_inverse_covariance_matrix, sep='')  for point_to in [class_.mean(axis=0), *class_]:     print(\"d_M+ (\", test_point, \", \", point_to, \", COV+) = \",           mahalanobis(test_point, point_to, pseudo_inverse_covariance_matrix), sep='') <\/code><\/pre>\n<p>\u0412\u044b\u0432\u043e\u0434:<\/p>\n<pre><code class=\"xml\">\u041f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430: [[0.1 0.1]  [0.1 0.1]] d_M+ ([4. 2.], [3. 3.], COV+) = 0.0 d_M+ ([4. 2.], [1. 1.], COV+) = 1.2649110640673513 d_M+ ([4. 2.], [2. 2.], COV+) = 0.6324555320336757 d_M+ ([4. 2.], [3. 3.], COV+) = 0.0 d_M+ ([4. 2.], [4. 4.], COV+) = 0.6324555320336757 d_M+ ([4. 2.], [5. 5.], COV+) = 1.2649110640673513<\/code><\/pre>\n<p>\u041f\u0435\u0440\u0432\u0430\u044f \u0442\u043e\u0447\u043a\u0430 \u2014 \u0442\u043e\u0447\u043a\u0430 \u0446\u0435\u043d\u0442\u0440\u043e\u0438\u0434\u0430, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0441\u043e\u0432\u043f\u0430\u0434\u0430\u0435\u0442 \u0441 \u043e\u0434\u043d\u043e\u0439 \u0438\u0437 \u0442\u043e\u0447\u0435\u043a \u043a\u043b\u0430\u0441\u0441\u0430.<\/p>\n<\/div>\n<\/details>\n<p><strong>4. <\/strong>\u041d\u043e\u0440\u043c\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0415\u0432\u043a\u043b\u0438\u0434\u0430.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_{std}((4,2), (1,1), (\\sqrt {2.5}, \\sqrt {2.5})) = 2.0000 \\\\ d_{std}((4,2), (2,2), (\\sqrt {2.5}, \\sqrt {2.5})) \\approx 1.2649 \\\\ d_{std}((4,2), (3,3), (\\sqrt {2.5}, \\sqrt {2.5})) \\approx 0.8944 \\\\ d_{std}((4,2), (4,4), (\\sqrt {2.5}, \\sqrt {2.5})) \\approx 1.2649 \\\\ d_{std}((4,2), (5,5), (\\sqrt {2.5}, \\sqrt {2.5})) = 2.0000\" alt=\"d_{std}((4,2), (1,1), (\\sqrt {2.5}, \\sqrt {2.5})) = 2.0000 \\\\ d_{std}((4,2), (2,2), (\\sqrt {2.5}, \\sqrt {2.5})) \\approx 1.2649 \\\\ d_{std}((4,2), (3,3), (\\sqrt {2.5}, \\sqrt {2.5})) \\approx 0.8944 \\\\ d_{std}((4,2), (4,4), (\\sqrt {2.5}, \\sqrt {2.5})) \\approx 1.2649 \\\\ d_{std}((4,2), (5,5), (\\sqrt {2.5}, \\sqrt {2.5})) = 2.0000\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/7f4\/3e2\/5ea\/7f43e25eaf79aa1b439e83b014498c77.svg\" width=\"734\" height=\"126\"><\/p>\n<details class=\"spoiler\">\n<summary>\u041a\u043e\u0434 \u043d\u0430 Python 3.6 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 numpy 1.19.5<\/summary>\n<div class=\"spoiler__content\">\n<pre><code class=\"python\">import numpy as np   def euclid_std(point_from, point_to, standard_deviations):     return sum(((point_from - point_to) \/ standard_deviations) ** 2) ** 0.5   def approx(number, *, sign, epsilon=1e-4):     return number + np.sign(sign) * epsilon   test_point = np.array([4., 2.]) class_ = np.array([[1., 1.], [2., 2.], [3., 3.], [4., 4.], [5., 5.]]) standard_deviations = class_.std(axis=0, ddof=1)  # \u0415\u0441\u043b\u0438 \u043d\u0435 \u0431\u043b\u0438\u0437\u043a\u043e \u0438 \u043d\u0435 \u0440\u0430\u0432\u043d\u043e 0 std_le_0 = standard_deviations &lt;= approx(0., sign=+1, epsilon=1e-6) print(\"\u0421\u0440\u0435\u0434\u043d\u0435\u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u044f:\\n\", standard_deviations, sep='')  if std_le_0.any():     print(\"\u0421\u041a\u041e \u043f\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0430\u043c \u0440\u0430\u0432\u043d\u043e 0: \", np.where(std_le_0)[0]) else:     for point_to in [class_.mean(axis=0), *class_]:         print(\"d_std (\", test_point, \", \", point_to, \", sigma) = \",               euclid_std(test_point, point_to, standard_deviations), sep='') <\/code><\/pre>\n<p>\u0412\u044b\u0432\u043e\u0434:<\/p>\n<pre><code class=\"xml\">\u0421\u0440\u0435\u0434\u043d\u0435\u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u044f: [1.58113883 1.58113883] d_std ([4. 2.], [3. 3.], sigma) = 0.8944271909999159 d_std ([4. 2.], [1. 1.], sigma) = 1.9999999999999998 d_std ([4. 2.], [2. 2.], sigma) = 1.2649110640673518 d_std ([4. 2.], [3. 3.], sigma) = 0.8944271909999159 d_std ([4. 2.], [4. 4.], sigma) = 1.2649110640673518 d_std ([4. 2.], [5. 5.], sigma) = 1.9999999999999998<\/code><\/pre>\n<p>\u041f\u0435\u0440\u0432\u0430\u044f \u0442\u043e\u0447\u043a\u0430 \u2014 \u0442\u043e\u0447\u043a\u0430 \u0446\u0435\u043d\u0442\u0440\u043e\u0438\u0434\u0430, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0441\u043e\u0432\u043f\u0430\u0434\u0430\u0435\u0442 \u0441 \u043e\u0434\u043d\u043e\u0439 \u0438\u0437 \u0442\u043e\u0447\u0435\u043a \u043a\u043b\u0430\u0441\u0441\u0430.<\/p>\n<\/div>\n<\/details>\n<p><strong>5.<\/strong> \u041c\u0435\u0442\u043e\u0434 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_{diag}((4,2), (1,1), (\\sqrt {2.5}, \\sqrt {2.5})) = 5.0000 \\\\ d_{diag}((4,2), (2,2), (\\sqrt {2.5}, \\sqrt {2.5})) \\approx 3.1623 \\\\ d_{diag}((4,2), (3,3), (\\sqrt {2.5}, \\sqrt {2.5})) \\approx 2.2360 \\\\ d_{diag}((4,2), (4,4), (\\sqrt {2.5}, \\sqrt {2.5})) \\approx 3.1623 \\\\ d_{diag}((4,2), (5,5), (\\sqrt {2.5}, \\sqrt {2.5})) = 5.0000\" alt=\"d_{diag}((4,2), (1,1), (\\sqrt {2.5}, \\sqrt {2.5})) = 5.0000 \\\\ d_{diag}((4,2), (2,2), (\\sqrt {2.5}, \\sqrt {2.5})) \\approx 3.1623 \\\\ d_{diag}((4,2), (3,3), (\\sqrt {2.5}, \\sqrt {2.5})) \\approx 2.2360 \\\\ d_{diag}((4,2), (4,4), (\\sqrt {2.5}, \\sqrt {2.5})) \\approx 3.1623 \\\\ d_{diag}((4,2), (5,5), (\\sqrt {2.5}, \\sqrt {2.5})) = 5.0000\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/677\/2eb\/434\/6772eb4348240c4c8df7c00c7f6b8209.svg\" width=\"734\" height=\"129\"><\/p>\n<details class=\"spoiler\">\n<summary>\u041a\u043e\u0434 \u043d\u0430 Python 3.6 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 numpy 1.19.5<\/summary>\n<div class=\"spoiler__content\">\n<pre><code class=\"python\">import numpy as np   def euclid_std(point_from, point_to, standard_deviations):     return sum(((point_from - point_to) \/ standard_deviations) ** 2) ** 0.5   def euclid_diag(point_from, point_to, standard_deviations):     return euclid_std(point_from, point_to, standard_deviations) \\            * (np.prod(standard_deviations ** 2)) ** (1. \/ point_from.shape[0])   def approx(number, *, sign, epsilon=1e-4):     return number + np.sign(sign) * epsilon   test_point = np.array([4., 2.]) class_ = np.array([[1., 1.], [2., 2.], [3., 3.], [4., 4.], [5., 5.]]) standard_deviations = class_.std(axis=0, ddof=1)  # \u0415\u0441\u043b\u0438 \u043d\u0435 \u0431\u043b\u0438\u0437\u043a\u043e \u0438 \u043d\u0435 \u0440\u0430\u0432\u043d\u043e 0 std_le_0 = standard_deviations &lt;= approx(0., sign=+1, epsilon=1e-6) print(\"\u0421\u0440\u0435\u0434\u043d\u0435\u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u044f:\\n\", standard_deviations, sep='')  if std_le_0.any():     print(\"\u0421\u041a\u041e \u043f\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0430\u043c \u0440\u0430\u0432\u043d\u043e 0: \", np.where(std_le_0)[0]) else:     for point_to in [class_.mean(axis=0), *class_]:         print(\"d_diag (\", test_point, \", \", point_to, \", sigma) = \",               euclid_diag(test_point, point_to, standard_deviations), sep='') <\/code><\/pre>\n<p>\u0412\u044b\u0432\u043e\u0434:<\/p>\n<pre><code class=\"xml\">\u0421\u0440\u0435\u0434\u043d\u0435\u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u044f: [1.58113883 1.58113883] d_diag ([4. 2.], [3. 3.], sigma) = 2.2360679774997902 d_diag ([4. 2.], [1. 1.], sigma) = 5.0 d_diag ([4. 2.], [2. 2.], sigma) = 3.16227766016838 d_diag ([4. 2.], [3. 3.], sigma) = 2.2360679774997902 d_diag ([4. 2.], [4. 4.], sigma) = 3.16227766016838 d_diag ([4. 2.], [5. 5.], sigma) = 5.0<\/code><\/pre>\n<p>\u041f\u0435\u0440\u0432\u0430\u044f \u0442\u043e\u0447\u043a\u0430 \u2014 \u0442\u043e\u0447\u043a\u0430 \u0446\u0435\u043d\u0442\u0440\u043e\u0438\u0434\u0430, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0441\u043e\u0432\u043f\u0430\u0434\u0430\u0435\u0442 \u0441 \u043e\u0434\u043d\u043e\u0439 \u0438\u0437 \u0442\u043e\u0447\u0435\u043a \u043a\u043b\u0430\u0441\u0441\u0430.<\/p>\n<\/div>\n<\/details>\n<p><strong><u>\u0412\u0442\u043e\u0440\u043e\u0439 \u043a\u043b\u0430\u0441\u0441<\/u>.<\/strong> \u0414\u043b\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 \u0432\u0442\u043e\u0440\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 <u>\u043c\u043e\u0436\u043d\u043e<\/u> \u043d\u0430\u0439\u0442\u0438 \u043e\u0431\u0440\u0430\u0442\u043d\u0443\u044e \u043c\u0430\u0442\u0440\u0438\u0446\u0443 (\u044d\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c <a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%9E%D0%B1%D1%80%D0%B0%D1%82%D0%BD%D0%B0%D1%8F_%D0%BC%D0%B0%D1%82%D1%80%D0%B8%D1%86%D0%B0#%D0%A1%D0%BF%D0%BE%D1%81%D0%BE%D0%B1%D1%8B_%D0%BD%D0%B0%D1%85%D0%BE%D0%B6%D0%B4%D0%B5%D0%BD%D0%B8%D1%8F_%D0%BE%D0%B1%D1%80%D0%B0%D1%82%D0%BD%D0%BE%D0%B9_%D0%BC%D0%B0%D1%82%D1%80%D0%B8%D1%86%D1%8B\" rel=\"noopener noreferrer nofollow\">\u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u043c\u0438 \u0441\u043f\u043e\u0441\u043e\u0431\u0430\u043c\u0438<\/a>). \u0412\u0440\u0443\u0447\u043d\u0443\u044e \u043b\u0435\u0433\u0447\u0435 \u0432\u0441\u0435\u0433\u043e \u0432\u044b\u0447\u0438\u0441\u043b\u044f\u0442\u044c \u043f\u0440\u0438 \u043f\u043e\u043c\u043e\u0449\u0438 \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u0430\u043b\u0433\u0435\u0431\u0440\u0430\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u0434\u043e\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0439:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"COV^{-1}_{(2)} = \\frac {1} {\\Delta_{(2)}} A^{T}_{(2)}\" alt=\"COV^{-1}_{(2)} = \\frac {1} {\\Delta_{(2)}} A^{T}_{(2)}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/3f8\/88b\/3b7\/3f888b3b7bc76ca7bf84da8c9e8b2290.svg\" width=\"146\" height=\"44\"><\/p>\n<p>\u0433\u0434\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"\\Delta_{(2)}\" alt=\"\\Delta_{(2)}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/888\/616\/b2e\/888616b2ea53a9c761dfcd09df53dfc6.svg\">\u2014 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u0435\u043b\u044c \u043c\u0430\u0442\u0440\u0438\u0446\u044b <img decoding=\"async\" class=\"formula inline\" source=\"COV_{(2)}\" alt=\"COV_{(2)}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e67\/cef\/736\/e67cef736b241f051778de4558018151.svg\">, <img decoding=\"async\" class=\"formula inline\" source=\"A^{T}_{(2)}\" alt=\"A^{T}_{(2)}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/ab2\/1f7\/eea\/ab21f7eea2e59c9e0aa544a670e7ebdc.svg\"> \u2014 \u0442\u0440\u0430\u043d\u0441\u043f\u043e\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u0430\u043b\u0433\u0435\u0431\u0440\u0430\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u0434\u043e\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0439 \u0434\u043b\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 \u0432\u0442\u043e\u0440\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"A^{T}_{(2)} = \\begin{pmatrix} A_{(2)1,1} &amp; A_{(2)2,1} \\\\ A_{(2)1,2} &amp; A_{(2)2,2} \\end{pmatrix} = \\begin{pmatrix} 1.7 &amp; -0.3 \\\\ -0.3 &amp; 1.7 \\end{pmatrix} \\\\ COV^{-1}_{(2)} = \\frac {1} {2.8} \\begin{pmatrix} 1.7 &amp; -0.3 \\\\ -0.3 &amp; 1.7 \\end{pmatrix} = \\begin{pmatrix} 0.6071 &amp; -0.1071 \\\\ -0.1071 &amp; 0.6071 \\end{pmatrix}\" alt=\"A^{T}_{(2)} = \\begin{pmatrix} A_{(2)1,1} &amp; A_{(2)2,1} \\\\ A_{(2)1,2} &amp; A_{(2)2,2} \\end{pmatrix} = \\begin{pmatrix} 1.7 &amp; -0.3 \\\\ -0.3 &amp; 1.7 \\end{pmatrix} \\\\ COV^{-1}_{(2)} = \\frac {1} {2.8} \\begin{pmatrix} 1.7 &amp; -0.3 \\\\ -0.3 &amp; 1.7 \\end{pmatrix} = \\begin{pmatrix} 0.6071 &amp; -0.1071 \\\\ -0.1071 &amp; 0.6071 \\end{pmatrix}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/10b\/2d3\/6f6\/10b2d36f6383f320d6052a1f187f54c5.svg\" width=\"734\" height=\"101\"><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_{M}((4,2), (3,1), COV^{-1}_{(2)}) = \\sqrt {((4,2)-(3,1)) \\cdot COV^{-1}_{(2)} \\cdot ((4,2)-(3,1))^T} = \\\\ \\sqrt {(4-3, 2-1) \\cdot \\begin{pmatrix} 0.6071 &amp; -0.1071 \\\\ -0.1071 &amp; 0.6071 \\end{pmatrix} \\cdot (4-3, 2-1)^T} = \\\\ \\sqrt {(0.5, 0.5) \\cdot \\begin{pmatrix} 1 \\\\ 1 \\end{pmatrix}} = 1\" alt=\"d_{M}((4,2), (3,1), COV^{-1}_{(2)}) = \\sqrt {((4,2)-(3,1)) \\cdot COV^{-1}_{(2)} \\cdot ((4,2)-(3,1))^T} = \\\\ \\sqrt {(4-3, 2-1) \\cdot \\begin{pmatrix} 0.6071 &amp; -0.1071 \\\\ -0.1071 &amp; 0.6071 \\end{pmatrix} \\cdot (4-3, 2-1)^T} = \\\\ \\sqrt {(0.5, 0.5) \\cdot \\begin{pmatrix} 1 \\\\ 1 \\end{pmatrix}} = 1\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/8d1\/891\/a6d\/8d1891a6dddc332a3923e27642fd1daf.svg\" width=\"734\" height=\"152\"><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_{M}((4,2), (4.8,1.2), COV^{-1}_{(2)}) \\approx 0.9562 \\\\ d_{M}((4,2), (3,1), COV^{-1}_{(2)}) = 1.0000 \\\\ d_{M}((4,2), (4,0), COV^{-1}_{(2)}) \\approx 1.5584 \\\\ d_{M}((4,2), (6,0), COV^{-1}_{(2)}) \\approx 2.3905 \\\\ d_{M}((4,2), (6,2), COV^{-1}_{(2)}) \\approx 1.5584 \\\\ d_{M}((4,2), (5,3), COV^{-1}_{(2)}) = 1.0000\" alt=\"d_{M}((4,2), (4.8,1.2), COV^{-1}_{(2)}) \\approx 0.9562 \\\\ d_{M}((4,2), (3,1), COV^{-1}_{(2)}) = 1.0000 \\\\ d_{M}((4,2), (4,0), COV^{-1}_{(2)}) \\approx 1.5584 \\\\ d_{M}((4,2), (6,0), COV^{-1}_{(2)}) \\approx 2.3905 \\\\ d_{M}((4,2), (6,2), COV^{-1}_{(2)}) \\approx 1.5584 \\\\ d_{M}((4,2), (5,3), COV^{-1}_{(2)}) = 1.0000\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/169\/78c\/399\/16978c399adfc5ce494e4889a71499b2.svg\" width=\"734\" height=\"182\"><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_{E-M}((4,2), (4.8,1.2), (COV_{(2)}+E)^{-1}) \\approx 0.7303 \\\\ d_{E-M}((4,2), (3,1), (COV_{(2)}+E)^{-1}) \\approx 0.8165 \\\\ d_{E-M}((4,2), (4,0), (COV_{(2)}+E)^{-1}) \\approx 1.2247 \\\\ d_{E-M}((4,2), (6,0), (COV_{(2)}+E)^{-1}) \\approx 1.8257 \\\\ d_{E-M}((4,2), (6,2), (COV_{(2)}+E)^{-1}) \\approx 1.2247 \\\\ d_{E-M}((4,2), (5,3), (COV_{(2)}+E)^{-1}) \\approx 0.8165\" alt=\"d_{E-M}((4,2), (4.8,1.2), (COV_{(2)}+E)^{-1}) \\approx 0.7303 \\\\ d_{E-M}((4,2), (3,1), (COV_{(2)}+E)^{-1}) \\approx 0.8165 \\\\ d_{E-M}((4,2), (4,0), (COV_{(2)}+E)^{-1}) \\approx 1.2247 \\\\ d_{E-M}((4,2), (6,0), (COV_{(2)}+E)^{-1}) \\approx 1.8257 \\\\ d_{E-M}((4,2), (6,2), (COV_{(2)}+E)^{-1}) \\approx 1.2247 \\\\ d_{E-M}((4,2), (5,3), (COV_{(2)}+E)^{-1}) \\approx 0.8165\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/f6c\/ad7\/9f5\/f6cad79f537b334b0d3d547a5cae1318.svg\" width=\"734\" height=\"165\"><\/p>\n<details class=\"spoiler\">\n<summary>\u041a\u043e\u0434 \u043d\u0430 Python 3.6 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 numpy 1.19.5<\/summary>\n<div class=\"spoiler__content\">\n<pre><code class=\"python\">import numpy as np   def mahalanobis(point_from, point_to, inverse_covariance_matrix):     delta = point_from - point_to     return max(np.float64(0), np.dot(np.dot(delta, inverse_covariance_matrix), delta)) ** 0.5   def approx(number, *, sign, epsilon=1e-4):     return number + np.sign(sign) * epsilon   test_point = np.array([4., 2.]) class_ = np.array([[3., 1.], [4., 0.], [6., 0.], [6., 2.], [5., 3.]]) covariance_matrix = np.cov(class_, rowvar=False, ddof=1) if abs(np.linalg.det(covariance_matrix)) &lt;= approx(0., sign=+1):     print(\"\u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u0435\u043b\u044c \u0440\u0430\u0432\u0435\u043d 0. \u041c\u0430\u0442\u0440\u0438\u0446\u0430 \u043d\u0435\u043e\u0431\u0440\u0430\u0442\u0438\u043c\u0430.\") else:     inverse_covariance_matrix = np.linalg.inv(covariance_matrix)     print(\"\u041e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 (d_M):\\n\", inverse_covariance_matrix, sep='')     for point_to in [class_.mean(axis=0), *class_]:         print(\"d_M (\", test_point, \", \", point_to, \", COV^(-1)) = \",               mahalanobis(test_point, point_to, inverse_covariance_matrix), sep='')  covariance_matrix = covariance_matrix + np.identity(class_.shape[1]) inverse_covariance_matrix = np.linalg.inv(covariance_matrix) print(\"\u041e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 (d_E-M):\\n\", inverse_covariance_matrix, sep='')  for point_to in [class_.mean(axis=0), *class_]:     print(\"d_E-M (\", test_point, \", \", point_to, \", (COV+E)^(-1)) = \",           mahalanobis(test_point, point_to, inverse_covariance_matrix), sep='') <\/code><\/pre>\n<p>\u0412\u044b\u0432\u043e\u0434:<\/p>\n<pre><code class=\"xml\">\u041e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 (d_M): [[ 0.60714286 -0.10714286]  [-0.10714286  0.60714286]] d_M ([4. 2.], [4.8 1.2], COV^(-1)) = 0.9561828874675149 d_M ([4. 2.], [3. 1.], COV^(-1)) = 1.0 d_M ([4. 2.], [4. 0.], COV^(-1)) = 1.5583874449479593 d_M ([4. 2.], [6. 0.], COV^(-1)) = 2.3904572186687876 d_M ([4. 2.], [6. 2.], COV^(-1)) = 1.5583874449479593 d_M ([4. 2.], [5. 3.], COV^(-1)) = 1.0 \u041e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 (d_E-M): [[ 0.375      -0.04166667]  [-0.04166667  0.375     ]] d_E-M ([4. 2.], [4.8 1.2], (COV+E)^(-1)) = 0.7302967433402214 d_E-M ([4. 2.], [3. 1.], (COV+E)^(-1)) = 0.8164965809277259 d_E-M ([4. 2.], [4. 0.], (COV+E)^(-1)) = 1.224744871391589 d_E-M ([4. 2.], [6. 0.], (COV+E)^(-1)) = 1.8257418583505536 d_E-M ([4. 2.], [6. 2.], (COV+E)^(-1)) = 1.224744871391589 d_E-M ([4. 2.], [5. 3.], (COV+E)^(-1)) = 0.8164965809277259<\/code><\/pre>\n<p>\u041f\u0435\u0440\u0432\u0430\u044f \u0442\u043e\u0447\u043a\u0430 \u2014 \u0442\u043e\u0447\u043a\u0430 \u0446\u0435\u043d\u0442\u0440\u043e\u0438\u0434\u0430.<\/p>\n<\/div>\n<\/details>\n<p>\u2022 <strong>\u041f\u043e \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0443 \u0431\u043b\u0438\u0436\u043d\u0435\u0433\u043e \u0441\u043e\u0441\u0435\u0434\u0430<\/strong><\/p>\n<p>\u041f\u0435\u0440\u0432\u044b\u0439 \u043a\u043b\u0430\u0441\u0441:<br \/>1. \u041c\u0435\u0442\u0440\u0438\u043a\u0430 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430: <img decoding=\"async\" class=\"formula inline\" source=\"1.4142\" alt=\"1.4142\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/bf2\/39b\/e61\/bf239be61c404359396e5d80da17b01a.svg\">;<br \/>2. \u041c\u0435\u0442\u043e\u0434 \u0443\u0441\u0430\u0434\u043a\u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b (LedoitWolf): <img decoding=\"async\" class=\"formula inline\" source=\"1.8898\" alt=\"1.8898\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/128\/d37\/aa8\/128d37aa8c5a29cf877dcef7d74ff147.svg\">;<br \/>3. \u041f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u044b\u0439 \u043f\u043e\u0434\u0445\u043e\u0434: <img decoding=\"async\" class=\"formula inline\" source=\"0.0000\" alt=\"0.0000\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/f40\/831\/cde\/f40831cdee069c5d3c5d46006b0662f6.svg\">;<br \/>4. \u041d\u043e\u0440\u043c\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0415\u0432\u043a\u043b\u0438\u0434\u0430: <img decoding=\"async\" class=\"formula inline\" source=\"0.8944\" alt=\"0.8944\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/cb7\/254\/697\/cb725469740b91caa36f84bb574c1427.svg\">;<br \/>5. \u041c\u0435\u0442\u043e\u0434 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b: <img decoding=\"async\" class=\"formula inline\" source=\"2.2360\" alt=\"2.2360\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/68c\/d47\/fdc\/68cd47fdce389afdcbfd1e2a24ddc596.svg\">.<\/p>\n<p>\u0412\u0442\u043e\u0440\u043e\u0439 \u043a\u043b\u0430\u0441\u0441 (\u043c\u0435\u0442\u0440\u0438\u043a\u0430 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430): <img decoding=\"async\" class=\"formula inline\" source=\"1.0000\" alt=\"1.0000\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/4c1\/cb9\/813\/4c1cb9813f5455896bd239b2af4f855b.svg\">.<br \/>\u0412\u0442\u043e\u0440\u043e\u0439 \u043a\u043b\u0430\u0441\u0441 (\u043c\u0435\u0442\u0440\u0438\u043a\u0430 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430): <img decoding=\"async\" class=\"formula inline\" source=\"0.8165\" alt=\"0.8165\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/5e7\/bbd\/35d\/5e7bbd35d3a5f5bc31a3383a57b5e56c.svg\">.<\/p>\n<p>\u0421\u0443\u0434\u044f \u043f\u043e \u0440\u0438\u0441\u0443\u043d\u043a\u0443 3, \u0431\u043e\u043b\u0435\u0435 \u043f\u0440\u0430\u0432\u0434\u043e\u043f\u043e\u0434\u043e\u0431\u043d\u044b (\u0434\u043b\u044f \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u0438 \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0430) <u>\u043c\u0435\u0442\u0440\u0438\u043a\u0430 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430<\/u>, <u>\u043c\u0435\u0442\u043e\u0434 \u0443\u0441\u0430\u0434\u043a\u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b<\/u> \u0438 <u>\u043c\u0435\u0442\u043e\u0434 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b<\/u>.<\/p>\n<p>\u2022 <strong>\u041f\u043e \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0443 \u0434\u0430\u043b\u044c\u043d\u0435\u0433\u043e \u0441\u043e\u0441\u0435\u0434\u0430<\/strong><\/p>\n<p>\u041f\u0435\u0440\u0432\u044b\u0439 \u043a\u043b\u0430\u0441\u0441:<br \/>1. \u041c\u0435\u0442\u0440\u0438\u043a\u0430 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430: <img decoding=\"async\" class=\"formula inline\" source=\"1.8257\" alt=\"1.8257\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/09b\/188\/b98\/09b188b98b7bf0d2be7451f0ebc289ed.svg\">;<br \/>2. \u041c\u0435\u0442\u043e\u0434 \u0443\u0441\u0430\u0434\u043a\u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b (LedoitWolf): <img decoding=\"async\" class=\"formula inline\" source=\"2.4284\" alt=\"2.4284\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/5c9\/ae1\/58f\/5c9ae158f9248c6501eaf079e54bd773.svg\">;<br \/>3. \u041f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u044b\u0439 \u043f\u043e\u0434\u0445\u043e\u0434: <img decoding=\"async\" class=\"formula inline\" source=\"1.2649\" alt=\"1.2649\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/1e9\/1da\/600\/1e91da600f49feaed890cd297ad0110b.svg\">;<br \/>4. \u041d\u043e\u0440\u043c\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0415\u0432\u043a\u043b\u0438\u0434\u0430: <img decoding=\"async\" class=\"formula inline\" source=\"2.0000\" alt=\"2.0000\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/5fb\/ccc\/f26\/5fbcccf268c1ecdd8d113990a3c498cf.svg\">;<br \/>5. \u041c\u0435\u0442\u043e\u0434 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b: <img decoding=\"async\" class=\"formula inline\" source=\"5.0000\" alt=\"5.0000\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/cdd\/30c\/318\/cdd30c318a503da4dea2b86272bd2583.svg\">.<\/p>\n<p>\u0412\u0442\u043e\u0440\u043e\u0439 \u043a\u043b\u0430\u0441\u0441 (\u043c\u0435\u0442\u0440\u0438\u043a\u0430 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430): <img decoding=\"async\" class=\"formula inline\" source=\"2.3905\" alt=\"2.3905\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/f12\/43d\/586\/f1243d586b7fd6777ef53783ccedee8d.svg\">.<br \/>\u0412\u0442\u043e\u0440\u043e\u0439 \u043a\u043b\u0430\u0441\u0441 (\u043c\u0435\u0442\u0440\u0438\u043a\u0430 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430): <img decoding=\"async\" class=\"formula inline\" source=\"1.8257\" alt=\"1.8257\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/8eb\/660\/dbc\/8eb660dbc25587f320ae0f79dff7f572.svg\">.<\/p>\n<p>\u0421\u0443\u0434\u044f \u043f\u043e \u0440\u0438\u0441\u0443\u043d\u043a\u0443 3, \u0431\u043e\u043b\u0435\u0435 \u043f\u0440\u0430\u0432\u0434\u043e\u043f\u043e\u0434\u043e\u0431\u043d\u044b (\u0434\u043b\u044f \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u0438 \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0430) <u>\u043c\u0435\u0442\u043e\u0434 \u0443\u0441\u0430\u0434\u043a\u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b<\/u> \u0438 <u>\u043c\u0435\u0442\u043e\u0434 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b<\/u>.<\/p>\n<p>\u2022 <strong>\u041f\u043e \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0443 \u0446\u0435\u043d\u0442\u0440\u043e\u0438\u0434\u0430<\/strong><\/p>\n<p>\u041f\u0435\u0440\u0432\u044b\u0439 \u043a\u043b\u0430\u0441\u0441:<br \/>1. \u041c\u0435\u0442\u0440\u0438\u043a\u0430 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430: <img decoding=\"async\" class=\"formula inline\" source=\"1.4142\" alt=\"1.4142\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/8e3\/4f1\/37a\/8e34f137aeae703362a8aa794b744688.svg\">;<br \/>2. \u041c\u0435\u0442\u043e\u0434 \u0443\u0441\u0430\u0434\u043a\u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b (LedoitWolf): <img decoding=\"async\" class=\"formula inline\" source=\"1.8898\" alt=\"1.8898\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/acf\/af5\/f17\/acfaf5f173dae08c5ae306ba6aa9b164.svg\">;<br \/>3. \u041f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u044b\u0439 \u043f\u043e\u0434\u0445\u043e\u0434: <img decoding=\"async\" class=\"formula inline\" source=\"0.0000\" alt=\"0.0000\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/033\/108\/618\/033108618c0e4348ba9dec555546306a.svg\">;<br \/>4. \u041d\u043e\u0440\u043c\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0415\u0432\u043a\u043b\u0438\u0434\u0430: <img decoding=\"async\" class=\"formula inline\" source=\"0.8944\" alt=\"0.8944\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/3ce\/971\/48e\/3ce97148e74bd16134f9f1c81b316227.svg\">;<br \/>5. \u041c\u0435\u0442\u043e\u0434 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b: <img decoding=\"async\" class=\"formula inline\" source=\"2.2360\" alt=\"2.2360\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/d46\/d2c\/336\/d46d2c336137667ba884912a2121424c.svg\">.<\/p>\n<p>\u0412\u0442\u043e\u0440\u043e\u0439 \u043a\u043b\u0430\u0441\u0441 (\u043c\u0435\u0442\u0440\u0438\u043a\u0430 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430): <img decoding=\"async\" class=\"formula inline\" source=\"0.9562\" alt=\"0.9562\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/690\/b67\/eef\/690b67eeffed210b362fcaf02aa0cbae.svg\">.<br \/>\u0412\u0442\u043e\u0440\u043e\u0439 \u043a\u043b\u0430\u0441\u0441 (\u043c\u0435\u0442\u0440\u0438\u043a\u0430 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430): <img decoding=\"async\" class=\"formula inline\" source=\"0.7303\" alt=\"0.7303\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/105\/60c\/0f2\/10560c0f2966d05b1d73a85fc89e9a9e.svg\">.<\/p>\n<p>\u0421\u0443\u0434\u044f \u043f\u043e \u0440\u0438\u0441\u0443\u043d\u043a\u0443 3, \u0431\u043e\u043b\u0435\u0435 \u043f\u0440\u0430\u0432\u0434\u043e\u043f\u043e\u0434\u043e\u0431\u043d\u044b (\u0434\u043b\u044f \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u0438 \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0430) <u>\u043c\u0435\u0442\u0440\u0438\u043a\u0430 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430,<\/u> <u>\u043c\u0435\u0442\u043e\u0434 \u0443\u0441\u0430\u0434\u043a\u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b<\/u> \u0438 <u>\u043c\u0435\u0442\u043e\u0434 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b<\/u>.<\/p>\n<p><strong>\u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442<\/strong><\/p>\n<p>\u041d\u0430\u0438\u0431\u043e\u043b\u0435\u0435 \u043f\u0440\u0430\u0432\u0434\u043e\u043f\u043e\u0434\u043e\u0431\u043d\u044b\u043c\u0438 \u043c\u0435\u0442\u043e\u0434\u0430\u043c\u0438 \u0434\u043b\u044f \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f <u>\u043c\u0435\u0442\u043e\u0434 \u0443\u0441\u0430\u0434\u043a\u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b<\/u> \u0438 <u>\u043c\u0435\u0442\u043e\u0434 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b<\/u>.<\/p>\n<p><a class=\"anchor\" name=\"ClassClass\" id=\"ClassClass\"><\/a><\/p>\n<h2>3. \u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438<\/h2>\n<p>\u042d\u0442\u043e\u0442 \u043f\u0443\u043d\u043a\u0442 \u0432\u043a\u043b\u044e\u0447\u0430\u0435\u0442 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438 \u0438 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 (\u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u044e\u0449\u0435\u0439 \u0435\u0434\u0438\u043d\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0439 \u043e\u0431\u044a\u0435\u043a\u0442 \u043a\u043b\u0430\u0441\u0441\u0430) \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c.<\/p>\n<p><strong><u>\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043a\u0432\u0430\u0437\u0438\u043c\u0435\u0442\u0440\u0438\u043a\u043e\u0439<\/u><\/strong>, \u0442. \u0435.:<strong><u><br \/><\/u><\/strong>\u2014 \u0443\u0434\u043e\u0432\u043b\u0435\u0442\u0432\u043e\u0440\u044f\u0435\u0442 \u0443\u0441\u043b\u043e\u0432\u0438\u044f\u043c <img decoding=\"async\" class=\"formula inline\" source=\"d_M(C_i, C_j, COV_0^{-1}) \\ge 0\" alt=\"d_M(C_i, C_j, COV_0^{-1}) \\ge 0\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/b68\/427\/9d9\/b684279d91f62fd1113873b8b4287f6d.svg\">,  <img decoding=\"async\" class=\"formula inline\" source=\"d_M(C_i, C_j, COV_0^{-1})=0 \\impliedby C_i=C_j\" alt=\"d_M(C_i, C_j, COV_0^{-1})=0 \\impliedby C_i=C_j\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/efd\/18c\/09b\/efd18c09b447d3c53d209a63671875b3.svg\">,  <img decoding=\"async\" class=\"formula inline\" source=\"d_M(C_i, C_j, COV_0^{-1})=d_M(C_j, C_i, COV_0^{-1})\" alt=\"d_M(C_i, C_j, COV_0^{-1})=d_M(C_j, C_i, COV_0^{-1})\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/762\/1f6\/387\/7621f6387e2be765d4504d6a33dc9710.svg\">.<br \/>\u2014 \u043d\u0435 \u0443\u0434\u043e\u0432\u043b\u0435\u0442\u0432\u043e\u0440\u044f\u0435\u0442 \u0443\u0441\u043b\u043e\u0432\u0438\u044e (\u0432 \u043e\u0431\u0449\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435) <img decoding=\"async\" class=\"formula inline\" source=\"d_M(C_i, C_j, COV_0^{-1})=0 \\implies C_i=C_j\" alt=\"d_M(C_i, C_j, COV_0^{-1})=0 \\implies C_i=C_j\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/477\/7c1\/72e\/4777c172e06e494d7af9d3f4e0ec9c86.svg\">.<br \/>\u041f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435 <a href=\"http:\/\/www.rusnauka.com\/24_PNR_2014\/Matemathics\/4_175946.doc.htm\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a>.<\/p>\n<p><a class=\"anchor\" name=\"ClassClassTheory\" id=\"ClassClassTheory\"><\/a><\/p>\n<h3>3.1 \u0422\u0435\u043e\u0440\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u0441\u0432\u0435\u0434\u0435\u043d\u0438\u044f<\/h3>\n<p><strong>\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438<\/strong> \u2014 \u043c\u0435\u0440\u0430 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"C_1\" alt=\"C_1\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/718\/7af\/35a\/7187af35aa9c181601b783002e47fe14.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"C_2\" alt=\"C_2\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/c92\/147\/742\/c9214774278e311e453fc3e6f90ac1ad.svg\">  \u0441 \u0446\u0435\u043d\u0442\u0440\u043e\u0438\u0434\u0430\u043c\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"\\overline {C_1}\" alt=\"\\overline {C_1}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/f94\/aad\/ed8\/f94aaded840131b05a1ed309cf8a2160.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"\\overline {C_2}\" alt=\"\\overline {C_2}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/3b8\/fac\/923\/3b8fac923872d3692e1a38f1da265d64.svg\"> \u0438 \u0441 \u043c\u0430\u0442\u0440\u0438\u0446\u0430\u043c\u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 <img decoding=\"async\" class=\"formula inline\" source=\"COV_1\" alt=\"COV_1\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/737\/25c\/63a\/73725c63a4b1266a893fff755815dd88.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"COV_2\" alt=\"COV_2\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/4ad\/337\/2d5\/4ad3372d596f779edee639216fad1352.svg\"> \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_M \\left(\\overline {C_1}, \\overline {C_2}, COV^{-1}_0 \\right) = \\sqrt {\\left (\\overline {C_1} - \\overline {C_2} \\right) \\cdot COV^{-1}_0 \\cdot \\left (\\overline {C_1} - \\overline {C_2} \\right)^T} \\\\ COV_0 = \\frac {1} {|C_1| + |C_2| - 2} \\left (COV_{(1)} + COV_{(2)} \\right)\" alt=\"d_M \\left(\\overline {C_1}, \\overline {C_2}, COV^{-1}_0 \\right) = \\sqrt {\\left (\\overline {C_1} - \\overline {C_2} \\right) \\cdot COV^{-1}_0 \\cdot \\left (\\overline {C_1} - \\overline {C_2} \\right)^T} \\\\ COV_0 = \\frac {1} {|C_1| + |C_2| - 2} \\left (COV_{(1)} + COV_{(2)} \\right)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/580\/1a3\/143\/5801a3143a368c7c4eba2db0cb9b9239.svg\" width=\"734\" height=\"91\"><\/p>\n<p>\u0433\u0434\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"COV_0\" alt=\"COV_0\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a12\/254\/cc3\/a12254cc3d85c84143d62e9fbc10d6d6.svg\"> \u2014 \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430, <img decoding=\"async\" class=\"formula inline\" source=\"COV^{-1}_0\" alt=\"COV^{-1}_0\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/d2c\/e6d\/25b\/d2ce6d25b1579be50380b67165a541d3.svg\"> \u2014 \u043e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430, <img decoding=\"async\" class=\"formula inline\" source=\"COV_1\" alt=\"COV_1\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/3a3\/f00\/07d\/3a3f0007de08f00edf83e34b32393efd.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"COV_2\" alt=\"COV_2\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/f97\/4fc\/976\/f974fc97671bb5a00be9a62c34661a01.svg\"> \u2014 \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 \u0434\u0432\u0443\u0445 \u043a\u043b\u0430\u0441\u0441\u043e\u0432, <img decoding=\"async\" class=\"formula inline\" source=\"|C_1|\" alt=\"|C_1|\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/650\/23c\/e61\/65023ce617ae87bd18b9906b0dc9202e.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"|C_2|\" alt=\"|C_2|\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/24e\/2a8\/d18\/24e2a8d1891586798574fc38f034de14.svg\"> \u2014 \u0447\u0438\u0441\u043b\u043e \u0442\u043e\u0447\u0435\u043a \u0432 \u043f\u0435\u0440\u0432\u043e\u043c \u0438 \u0432\u043e \u0432\u0442\u043e\u0440\u043e\u043c \u043a\u043b\u0430\u0441\u0441\u0430\u0445 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e.<\/p>\n<p>\u041f\u0440\u0438\u0447\u0435\u043c \u0432 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u043b\u0438\u0442\u0435\u0440\u0430\u0442\u0443\u0440\u0435 \u0442\u0430\u043a\u0436\u0435 \u043f\u0440\u0435\u0434\u043b\u0430\u0433\u0430\u0435\u0442\u0441\u044f \u0434\u0440\u0443\u0433\u043e\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"COV_0 = COV_{(1)} + COV_{(2)}\" alt=\"COV_0 = COV_{(1)} + COV_{(2)}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/917\/57b\/1f7\/91757b1f7c1a0595b0c4d3589f43acfa.svg\" width=\"191\" height=\"21\"><\/p>\n<p><strong>\u0412\u0430\u0436\u043d\u043e \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u0438 \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0442\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u043e\u0434\u0438\u043d \u0438\u0437 \u044d\u0442\u0438\u0445 \u0434\u0432\u0443\u0445 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u043e\u0432.<br \/><\/strong>\u041a\u0440\u043e\u043c\u0435 \u0442\u043e\u0433\u043e, \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u0432\u0441\u0435\u0433\u0434\u0430 \u043e\u0442\u043c\u0435\u0447\u0430\u0442\u044c, \u043a\u0430\u043a\u043e\u0439 \u0438\u0437 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u043e\u0432 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f.<\/p>\n<p>\u041f\u0440\u0438\u043c\u0435\u0447\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u0442\u043e, \u0447\u0442\u043e \u043f\u0440\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u0432\u0442\u043e\u0440\u043e\u0433\u043e \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430 \u0434\u043b\u044f \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u0441 \u043e\u0434\u043d\u043e\u0439 \u0442\u043e\u0447\u043a\u043e\u0439 \u0438 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0432\u0442\u043e\u0440\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442\u0441\u044f \u0444\u043e\u0440\u043c\u0443\u043b\u0430, \u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0447\u043d\u0430\u044f \u0444\u043e\u0440\u043c\u0443\u043b\u0435 \u0440\u0430\u0441\u0447\u0435\u0442\u0430 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 (\u043d\u0435 \u043f\u0440\u0438\u043d\u0430\u0434\u043b\u0435\u0436\u0430\u0449\u0435\u0439 \u043d\u0438 \u043e\u0434\u043d\u043e\u043c\u0443 \u0438\u0437 \u043a\u043b\u0430\u0441\u0441\u043e\u0432) \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c (\u043f. 2 \u00ab\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c\u00bb):<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_M \\left (X_{(1)}, \\overline C_2, COV^{-1}_0 \\right) = \\sqrt {\\left(X_{(1)} - \\overline {C_2} \\right) \\cdot COV^{-1}_0 \\cdot \\left (X_{(1)} - \\overline {C_2} \\right)^T} \\\\ COV_0 = 0 + COV_{(2)} = COV_{(2)}\" alt=\"d_M \\left (X_{(1)}, \\overline C_2, COV^{-1}_0 \\right) = \\sqrt {\\left(X_{(1)} - \\overline {C_2} \\right) \\cdot COV^{-1}_0 \\cdot \\left (X_{(1)} - \\overline {C_2} \\right)^T} \\\\ COV_0 = 0 + COV_{(2)} = COV_{(2)}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/6fe\/c1c\/b21\/6fec1cb21f9a09ba094e5aa385b7ff81.svg\" width=\"734\" height=\"69\"><\/p>\n<p>\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0415\u0432\u043a\u043b\u0438\u0434\u0430-\u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_{E-M} \\left(\\overline {C_1}, \\overline {C_2}, \\left (COV_0+E \\right)^{-1} \\right) = \\sqrt {\\left (\\overline {C_1} - \\overline {C_2} \\right) \\cdot (COV_0+E)^{-1} \\cdot \\left (\\overline {C_1} - \\overline {C_2} \\right)^T}\" alt=\"d_{E-M} \\left(\\overline {C_1}, \\overline {C_2}, \\left (COV_0+E \\right)^{-1} \\right) = \\sqrt {\\left (\\overline {C_1} - \\overline {C_2} \\right) \\cdot (COV_0+E)^{-1} \\cdot \\left (\\overline {C_1} - \\overline {C_2} \\right)^T}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/db0\/4ac\/08b\/db04ac08b6a601fcd582394259f3829f.svg\" width=\"572\" height=\"44\"><\/p>\n<p>\u0433\u0434\u0435 <img decoding=\"async\" class=\"formula inline\" source=\"E\" alt=\"E\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e91\/cf2\/7a5\/e91cf27a5d8b9ce208f5f5941e3f6973.svg\"> \u2014 \u0435\u0434\u0438\u043d\u0438\u0447\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u0442\u043e\u0433\u043e \u0436\u0435 \u0440\u0430\u0437\u043c\u0435\u0440\u0430, \u0447\u0442\u043e \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"COV_0\" alt=\"COV_0\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/64d\/f6d\/5f9\/64df6d5f90b7ac5d6ae9c59c0c3d2dde.svg\">.<\/p>\n<p><a class=\"anchor\" name=\"ClassClassAlgorithm\" id=\"ClassClassAlgorithm\"><\/a><\/p>\n<h3>3.2 \u0410\u043b\u0433\u043e\u0440\u0438\u0442\u043c \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438<\/h3>\n<p><strong>\u0428\u0430\u0433 1.<\/strong> \u0412\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u044f \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u0442\u043e\u0447\u0435\u043a <em>\u043a\u043b\u0430\u0441\u0441\u043e\u0432<\/em>.<\/p>\n<p><strong>\u0428\u0430\u0433 2.<\/strong> \u0412\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u0441\u0440\u0435\u0434\u043d\u0435\u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u043d\u044b\u0435 \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u044f \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u0442\u043e\u0447\u0435\u043a <em>\u043a\u043b\u0430\u0441\u0441\u043e\u0432<\/em>.<\/p>\n<p><strong>\u0428\u0430\u0433 3.<\/strong> \u0412\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0438 \u043c\u0435\u0436\u0434\u0443 \u0432\u0441\u0435\u043c\u0438 \u043f\u0430\u0440\u0430\u043c\u0438 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u0442\u043e\u0447\u0435\u043a <em>\u043a\u043b\u0430\u0441\u0441\u043e\u0432<\/em>, \u0441\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0435 \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u0438 \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u043d\u0443\u044e \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0443\u044e \u043c\u0430\u0442\u0440\u0438\u0446\u0443.<\/p>\n<p><strong>\u0428\u0430\u0433 4.<\/strong> \u0415\u0441\u043b\u0438 \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043e\u0431\u0440\u0430\u0442\u0438\u043c\u0430, \u0442\u043e \u0432\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043f\u043e \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0443. \u0415\u0441\u043b\u0438 \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043d\u0435\u043e\u0431\u0440\u0430\u0442\u0438\u043c\u0430, \u0442\u043e \u0432\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043f\u043e \u0444\u043e\u0440\u043c\u0443\u043b\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430.<\/p>\n<p><a class=\"anchor\" name=\"ClassClassExample\" id=\"ClassClassExample\"><\/a><\/p>\n<h3>3.3 \u041f\u0440\u0438\u043c\u0435\u0440 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438<\/h3>\n<p>\u0418\u0437 \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u043f. 2.2.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"C_{(1)} = \\{ ( 1 , 1 ) , ( 2 , 2 ) , ( 3 , 3 ) , ( 4 , 4 ) , ( 5 , 5 ) \\} \\\\ C_{(2)} = \\{ ( 3 , 1 ) , ( 4 , 0 ) , ( 6 , 0 ) , ( 6 , 2 ) , ( 5 , 3 ) \\}\" alt=\"C_{(1)} = \\{ ( 1 , 1 ) , ( 2 , 2 ) , ( 3 , 3 ) , ( 4 , 4 ) , ( 5 , 5 ) \\} \\\\ C_{(2)} = \\{ ( 3 , 1 ) , ( 4 , 0 ) , ( 6 , 0 ) , ( 6 , 2 ) , ( 5 , 3 ) \\}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/6b3\/839\/eb0\/6b3839eb047a602b991f0f22fdeef5f7.svg\" width=\"734\" height=\"48\"><\/p>\n<p>\u041d\u0430\u0439\u0434\u0435\u043c \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438.<br \/>\u041f\u0435\u0440\u0432\u044b\u0435 3 \u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0447\u043d\u044b\u0445 \u0448\u0430\u0433\u0430 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u0430 \u0431\u044b\u043b\u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u044b \u0432 \u043f. 2.2.<br \/>\u0412\u044b\u043f\u043e\u043b\u043d\u0438\u043c 4 \u0448\u0430\u0433.<\/p>\n<p><strong>\u0428\u0430\u0433 4.<\/strong> \u0415\u0441\u043b\u0438 \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043e\u0431\u0440\u0430\u0442\u0438\u043c\u0430, \u0442\u043e \u0432\u044b\u0447\u0438\u0441\u043b\u0438\u043c \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043f\u043e \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0443. \u0415\u0441\u043b\u0438 \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043d\u0435\u043e\u0431\u0440\u0430\u0442\u0438\u043c\u0430, \u0442\u043e \u0432\u044b\u0447\u0438\u0441\u043b\u0438\u043c \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043f\u043e \u0444\u043e\u0440\u043c\u0443\u043b\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430.<\/p>\n<p>\u041e\u0431\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"COV_0 = \\frac {1} {5 + 5 - 2} \\left (\\begin{pmatrix} 2.5 &amp; 2.5 \\\\ 2.5 &amp; 2.5 \\end{pmatrix} + \\begin{pmatrix} 1.7 &amp; 0.3 \\\\ 0.3 &amp; 1.7 \\end{pmatrix} \\right) = \\\\ = \\frac {1} {8} \\begin{pmatrix} 4.2 &amp; 2.8 \\\\ 2.8 &amp; 4.2 \\end{pmatrix} = \\begin{pmatrix} 0.525 &amp; 0.35 \\\\ 0.35 &amp; 0.525 \\end{pmatrix}\" alt=\"COV_0 = \\frac {1} {5 + 5 - 2} \\left (\\begin{pmatrix} 2.5 &amp; 2.5 \\\\ 2.5 &amp; 2.5 \\end{pmatrix} + \\begin{pmatrix} 1.7 &amp; 0.3 \\\\ 0.3 &amp; 1.7 \\end{pmatrix} \\right) = \\\\ = \\frac {1} {8} \\begin{pmatrix} 4.2 &amp; 2.8 \\\\ 2.8 &amp; 4.2 \\end{pmatrix} = \\begin{pmatrix} 0.525 &amp; 0.35 \\\\ 0.35 &amp; 0.525 \\end{pmatrix}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/00d\/6e5\/e5d\/00d6e5e5dd5ac537e04c5c2d0633da85.svg\" width=\"734\" height=\"91\"><\/p>\n<p>\u041e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"COV^{-1}_0 \\approx \\begin{pmatrix} 3.42857143 &amp; -2.28571429 \\\\ -2.28571429 &amp; 3.42857143 \\end{pmatrix}\" alt=\"COV^{-1}_0 \\approx \\begin{pmatrix} 3.42857143 &amp; -2.28571429 \\\\ -2.28571429 &amp; 3.42857143 \\end{pmatrix}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/b93\/e0e\/6e7\/b93e0e6e72d1b67a4175fdb15e59b747.svg\" width=\"314\" height=\"44\"><\/p>\n<p>\u2022 <strong>\u041f\u043e \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0443 \u0446\u0435\u043d\u0442\u0440\u043e\u0438\u0434\u0430<\/strong><\/p>\n<p>\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430<img decoding=\"async\" class=\"formula inline\" source=\"\\approx 6.0851\" alt=\"\\approx 6.0851\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/d9c\/8b5\/ce0\/d9c8b5ce0f5aba03eea627b23f1877ec.svg\">.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_M \\left((3, 3), (4.8, 1.2), COV^{-1}_0 \\right) = \\\\ = \\sqrt {\\left ((3, 3) - (4.8, 1.2) \\right) \\cdot COV^{-1}_0 \\cdot \\left ((3, 3) - (4.8, 1.2) \\right)^T} = \\\\ = \\sqrt {(-1.8, 1.8) \\cdot \\begin{pmatrix} 3.42857143 &amp; -2.28571429 \\\\ -2.28571429 &amp; 3.42857143 \\end{pmatrix} \\cdot (-1.8, 1.8)^T} \\approx 6.0851\" alt=\"d_M \\left((3, 3), (4.8, 1.2), COV^{-1}_0 \\right) = \\\\ = \\sqrt {\\left ((3, 3) - (4.8, 1.2) \\right) \\cdot COV^{-1}_0 \\cdot \\left ((3, 3) - (4.8, 1.2) \\right)^T} = \\\\ = \\sqrt {(-1.8, 1.8) \\cdot \\begin{pmatrix} 3.42857143 &amp; -2.28571429 \\\\ -2.28571429 &amp; 3.42857143 \\end{pmatrix} \\cdot (-1.8, 1.8)^T} \\approx 6.0851\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/880\/72c\/0fb\/88072c0fb0015729a09712506225a2c9.svg\" width=\"734\" height=\"121\"><\/p>\n<p>\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"\\approx 2.3484\" alt=\"\\approx 2.3484\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/781\/36c\/3d2\/78136c3d2da32220f20ade26f50d48d8.svg\">.<\/p>\n<p>\u0414\u043b\u044f \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"COV_0 = COV_{(1)} + COV_{(2)}\" alt=\"COV_0 = COV_{(1)} + COV_{(2)}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/eac\/041\/2f4\/eac0412f483aadda9c6a320f595d770f.svg\">:<br \/>\u2014 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"\\approx 2.1514\" alt=\"\\approx 2.1514\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/456\/d5a\/f30\/456d5af3091953a6de385821d11da064.svg\">;<br \/>\u2014 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430  <img decoding=\"async\" class=\"formula inline\" source=\"\\approx 1.6432\" alt=\"\\approx 1.6432\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/9bc\/bfe\/b4b\/9bcbfeb4b8f9e0ed38a0c2a55be2a6eb.svg\">.<\/p>\n<p>\u2022 <strong>\u041f\u043e \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0443 \u0431\u043b\u0438\u0436\u043d\u0435\u0433\u043e \u0441\u043e\u0441\u0435\u0434\u0430<\/strong><\/p>\n<p>\u041c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"\\approx 3.3806\" alt=\"\\approx 3.3806\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/d67\/4c0\/3ce\/d674c03cea1263f124bcd8e28d7e4225.svg\"> \u043c\u0435\u0436\u0434\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"(2,2)\" alt=\"(2,2)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/673\/3d2\/dc9\/6733d2dc92d3d2b0a8dcb851e377dbce.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(3,1)\" alt=\"(3,1)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/7f7\/19c\/ea8\/7f719cea81f6321425bdb0d2ff1a15d8.svg\"> \u0438 \u043c\u0435\u0436\u0434\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"(4,4)\" alt=\"(4,4)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/6e4\/e17\/3e5\/6e4e173e5336c9adcf09d05ae4da3df1.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(5,3)\" alt=\"(5,3)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/94c\/17c\/6b6\/94c17c6b657943346a0e5a7e18a7910a.svg\">.<\/p>\n<p>\u041c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"\\approx 1.3047\" alt=\"\\approx 1.3047\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/8cc\/134\/5f7\/8cc1345f76fd78f3e75061c8c7a42731.svg\"> \u043c\u0435\u0436\u0434\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"(2,2)\" alt=\"(2,2)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/673\/3d2\/dc9\/6733d2dc92d3d2b0a8dcb851e377dbce.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(3,1)\" alt=\"(3,1)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/7f7\/19c\/ea8\/7f719cea81f6321425bdb0d2ff1a15d8.svg\"> \u0438 \u043c\u0435\u0436\u0434\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"(4,4)\" alt=\"(4,4)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/6e4\/e17\/3e5\/6e4e173e5336c9adcf09d05ae4da3df1.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(5,3)\" alt=\"(5,3)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/94c\/17c\/6b6\/94c17c6b657943346a0e5a7e18a7910a.svg\">.<\/p>\n<p>\u0414\u043b\u044f \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"COV_0 = COV_{(1)} + COV_{(2)}\" alt=\"COV_0 = COV_{(1)} + COV_{(2)}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/eac\/041\/2f4\/eac0412f483aadda9c6a320f595d770f.svg\">:<br \/>\u2014 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"\\approx 1.1952\" alt=\"\\approx 1.1952\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/7d9\/e4f\/deb\/7d9e4fdebae371118fd23a71e5974056.svg\"> \u043c\u0435\u0436\u0434\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"(2,2)\" alt=\"(2,2)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/673\/3d2\/dc9\/6733d2dc92d3d2b0a8dcb851e377dbce.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(3,1)\" alt=\"(3,1)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/7f7\/19c\/ea8\/7f719cea81f6321425bdb0d2ff1a15d8.svg\"> \u0438 \u043c\u0435\u0436\u0434\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"(4,4)\" alt=\"(4,4)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/6e4\/e17\/3e5\/6e4e173e5336c9adcf09d05ae4da3df1.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(5,3)\" alt=\"(5,3)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/94c\/17c\/6b6\/94c17c6b657943346a0e5a7e18a7910a.svg\">;<br \/>\u2014 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"\\approx 0.9129\" alt=\"\\approx 0.9129\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/1e0\/1e1\/e14\/1e01e1e14d6f93b55dbeb0b4495b8e5a.svg\"> \u043c\u0435\u0436\u0434\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"(2,2)\" alt=\"(2,2)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/673\/3d2\/dc9\/6733d2dc92d3d2b0a8dcb851e377dbce.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(3,1)\" alt=\"(3,1)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/7f7\/19c\/ea8\/7f719cea81f6321425bdb0d2ff1a15d8.svg\"> \u0438 \u043c\u0435\u0436\u0434\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"(4,4)\" alt=\"(4,4)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/6e4\/e17\/3e5\/6e4e173e5336c9adcf09d05ae4da3df1.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(5,3)\" alt=\"(5,3)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/94c\/17c\/6b6\/94c17c6b657943346a0e5a7e18a7910a.svg\">.<\/p>\n<p>\u2022 <strong>\u041f\u043e \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0443 \u0434\u0430\u043b\u044c\u043d\u0435\u0433\u043e \u0441\u043e\u0441\u0435\u0434\u0430<\/strong><\/p>\n<p>\u041c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"\\approx 10.5830\" alt=\"\\approx 10.5830\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/1f9\/11b\/003\/1f911b0038a9c22a7ebccda1cc811352.svg\"> \u043c\u0435\u0436\u0434\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"(1,1)\" alt=\"(1,1)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/822\/65d\/25f\/82265d25fbf9e63530fd7eb1942b5248.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(6,0)\" alt=\"(6,0)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/d39\/682\/79a\/d3968279a15e479cae98196b5eb16a15.svg\"> \u0438 \u043c\u0435\u0436\u0434\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"(5,5)\" alt=\"(5,5)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/0df\/dde\/794\/0dfdde794b4ecb58a8d2f1f54ded61fe.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(6,0)\" alt=\"(6,0)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e4d\/348\/f47\/e4d348f470c79e673fde0482756c0f10.svg\">.<\/p>\n<p>\u041c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"\\approx 4.4256\" alt=\"\\approx 4.4256\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/44f\/c19\/da9\/44fc19da9c7af0a8636e4ee018414d4b.svg\"> \u043c\u0435\u0436\u0434\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"(1,1)\" alt=\"(1,1)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/822\/65d\/25f\/82265d25fbf9e63530fd7eb1942b5248.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(6,0)\" alt=\"(6,0)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/d39\/682\/79a\/d3968279a15e479cae98196b5eb16a15.svg\"> \u0438 \u043c\u0435\u0436\u0434\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"(5,5)\" alt=\"(5,5)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/0df\/dde\/794\/0dfdde794b4ecb58a8d2f1f54ded61fe.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(6,0)\" alt=\"(6,0)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e4d\/348\/f47\/e4d348f470c79e673fde0482756c0f10.svg\">.<\/p>\n<p>\u0414\u043b\u044f \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"COV_0 = COV_{(1)} + COV_{(2)}\" alt=\"COV_0 = COV_{(1)} + COV_{(2)}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/eac\/041\/2f4\/eac0412f483aadda9c6a320f595d770f.svg\">:<br \/>\u2014 \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"\\approx 3.7417\" alt=\"\\approx 3.7417\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/03f\/891\/4f2\/03f8914f2b6aa13d749b8175bfee1a7f.svg\"> \u043c\u0435\u0436\u0434\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"(1,1)\" alt=\"(1,1)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/822\/65d\/25f\/82265d25fbf9e63530fd7eb1942b5248.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(6,0)\" alt=\"(6,0)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/d39\/682\/79a\/d3968279a15e479cae98196b5eb16a15.svg\"> \u0438 \u043c\u0435\u0436\u0434\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"(5,5)\" alt=\"(5,5)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/0df\/dde\/794\/0dfdde794b4ecb58a8d2f1f54ded61fe.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(6,0)\" alt=\"(6,0)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e4d\/348\/f47\/e4d348f470c79e673fde0482756c0f10.svg\">;<br \/>\u2014 \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"\\approx 2.9155\" alt=\"\\approx 2.9155\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/204\/991\/037\/20499103721b030e98474e44d51e8ecf.svg\"> \u043c\u0435\u0436\u0434\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"(1,1)\" alt=\"(1,1)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/822\/65d\/25f\/82265d25fbf9e63530fd7eb1942b5248.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(6,0)\" alt=\"(6,0)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/d39\/682\/79a\/d3968279a15e479cae98196b5eb16a15.svg\"> \u0438 \u043c\u0435\u0436\u0434\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"(5,5)\" alt=\"(5,5)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/0df\/dde\/794\/0dfdde794b4ecb58a8d2f1f54ded61fe.svg\"> \u0438 <img decoding=\"async\" class=\"formula inline\" source=\"(6,0)\" alt=\"(6,0)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e4d\/348\/f47\/e4d348f470c79e673fde0482756c0f10.svg\">.<\/p>\n<p>\u041a\u043e\u0434 \u043d\u0430 Python 3.6 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 numpy 1.19.5 \u0434\u043b\u044f \u0440\u0430\u0441\u0447\u0435\u0442\u0430 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d <a href=\"https:\/\/gist.github.com\/Quwarm\/979fb9af037da142895c9e5a5d2a59cd\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a>.<\/p>\n<p><a class=\"anchor\" name=\"KNN\" id=\"KNN\"><\/a><\/p>\n<h2>4. \u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u0438 \u043c\u0435\u0442\u043e\u0434 k-\u0431\u043b\u0438\u0436\u0430\u0439\u0448\u0438\u0445 \u0441\u043e\u0441\u0435\u0434\u0435\u0439<\/h2>\n<p>\u041a\u043b\u0430\u0441\u0441\u0438\u0444\u0438\u0446\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0442\u0435\u0441\u0442\u043e\u0432\u0443\u044e \u0442\u043e\u0447\u043a\u0443 \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u0438 \u043f\u043e\u043c\u043e\u0449\u0438 <a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%9C%D0%B5%D1%82%D0%BE%D0%B4_k-%D0%B1%D0%BB%D0%B8%D0%B6%D0%B0%D0%B9%D1%88%D0%B8%D1%85_%D1%81%D0%BE%D1%81%D0%B5%D0%B4%D0%B5%D0%B9\" rel=\"noopener noreferrer nofollow\">\u043c\u0435\u0442\u043e\u0434\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"k\" alt=\"k\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/f12\/338\/104\/f1233810432a545f1c21c5044fcc9ee2.svg\">-\u0431\u043b\u0438\u0436\u0430\u0439\u0448\u0438\u0445 \u0441\u043e\u0441\u0435\u0434\u0435\u0439<\/a>. \u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u043d\u0443\u0436\u043d\u043e \u0432\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0443\u044e \u043c\u0430\u0442\u0440\u0438\u0446\u0443 \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430, \u0437\u0430\u0442\u0435\u043c \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c <img decoding=\"async\" class=\"formula inline\" source=\"k\" alt=\"k\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/2b0\/d5e\/be2\/2b0d5ebe21ad500f1a1baa53fa555f0f.svg\">-\u0431\u043b\u0438\u0436\u0430\u0439\u0448\u0438\u0445 \u0441\u043e\u0441\u0435\u0434\u0435\u0439 \u0434\u043b\u044f \u0442\u0435\u0441\u0442\u043e\u0432\u043e\u0439 \u0442\u043e\u0447\u043a\u0438 (\u0432\u044b\u0447\u0438\u0441\u043b\u0438\u0432 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043e\u0442 \u043d\u0435\u0451 \u0434\u043e \u0432\u0441\u0435\u0445 \u0442\u043e\u0447\u0435\u043a \u0432\u0441\u0435\u0445 \u043a\u043b\u0430\u0441\u0441\u043e\u0432 \u0441 \u0443\u0447\u0435\u0442\u043e\u043c \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0445 \u043c\u0430\u0442\u0440\u0438\u0446) \u0438 \u043e\u0442\u043d\u0435\u0441\u0442\u0438 \u0442\u043e\u0447\u043a\u0443 \u043a \u043a\u043b\u0430\u0441\u0441\u0443 \u0441 \u043d\u0430\u0438\u0431\u043e\u043b\u044c\u0448\u0438\u043c \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e\u043c \u0432\u0445\u043e\u0436\u0434\u0435\u043d\u0438\u0439 \u0441\u0440\u0435\u0434\u0438 <img decoding=\"async\" class=\"formula inline\" source=\"k\" alt=\"k\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/21b\/55d\/f50\/21b55df5047b7991a77b24d4ed8815e6.svg\"> \u0431\u043b\u0438\u0436\u0430\u0439\u0448\u0438\u0445 \u0441\u043e\u0441\u0435\u0434\u0435\u0439.<\/p>\n<p>\u0414\u0430\u043b\u0435\u0435 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d \u043a\u043e\u0434 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u044b \u0434\u043b\u044f \u043a\u043b\u0430\u0441\u0441\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u043c\u0435\u0442\u043e\u0434\u043e\u043c <img decoding=\"async\" class=\"formula inline\" source=\"k\" alt=\"k\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/52b\/b7f\/3a5\/52bb7f3a5b3f870ab2d22c6b85026426.svg\">-\u0431\u043b\u0438\u0436\u0430\u0439\u0448\u0438\u0445 \u0441\u043e\u0441\u0435\u0434\u0435\u0439.<br \/>\u041f\u0440\u0438\u0447\u0435\u043c:<br \/>\u2014 \u041e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430: <img decoding=\"async\" class=\"formula inline\" source=\"(COV+E)^{-1}\" alt=\"(COV+E)^{-1}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/9ae\/615\/270\/9ae615270c1710ef86623d5dc310f1d4.svg\"> (\u043c\u0435\u0442\u0440\u0438\u043a\u0430 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430);<br \/>\u2014 \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u043a\u0432\u0430\u0434\u0440\u0430\u0442 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f (\u043a\u0432\u0430\u0434\u0440\u0430\u0442\u043d\u044b\u0439 \u043a\u043e\u0440\u0435\u043d\u044c \u043d\u0435 \u0438\u043c\u0435\u0435\u0442 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0434\u043b\u044f \u043a\u043e\u043d\u0435\u0447\u043d\u043e\u0433\u043e \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430 \u043a\u043b\u0430\u0441\u0441\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438, \u0430 \u0431\u0435\u0437 \u043d\u0435\u0433\u043e \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0430 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u0431\u044b\u0441\u0442\u0440\u0435\u0435).<\/p>\n<details class=\"spoiler\">\n<summary>\u041a\u043e\u0434 \u043d\u0430 Python 3.6 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 numpy 1.19.5<\/summary>\n<div class=\"spoiler__content\">\n<pre><code class=\"python\"># \u041f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u0443\u0431\u0440\u0430\u043d\u044b \u0434\u043b\u044f \u0443\u0434\u043e\u0431\u043e\u0447\u0438\u0442\u0430\u0435\u043c\u043e\u0441\u0442\u0438  import heapq from collections import Counter from operator import itemgetter  import numpy as np   class MkNN:     def __init__(self, k, classes, inv_cov_matrices):         self.n = len(classes)         self.k = k         self.classes = classes         self.inv_cov_matrices = inv_cov_matrices      @staticmethod     def mahalanobis_sqr(point_from, point_to, inverse_covariance_matrix):         delta = point_from - point_to         return max(np.float64(0), np.dot(np.dot(delta, inverse_covariance_matrix), delta))      def _get_k_smallest(self, test_point):         generator = (             (MkNN.mahalanobis_sqr(test_point, point, inv_cov), i)             for i, (class_, inv_cov) in enumerate(zip(self.classes, self.inv_cov_matrices))             for point in class_         )         return heapq.nsmallest(self.k, generator, key=itemgetter(0))      def predict(self, test_point):         return heapq.nlargest(1, Counter((i for _, i in self._get_k_smallest(test_point))).items(),                               key=lambda t: (t[1], -t[0]))[0][0]      def predict_proba(self, test_point):         most_common = Counter((i for _, i in self._get_k_smallest(test_point)))         classes_proba = np.array([most_common.get(i, 0) for i in range(self.n)])         return classes_proba \/ classes_proba.sum()      def predict_all_max(self, test_point):         p = self.predict_proba(test_point)         return np.where(p == max(p))[0]   def main():     # \u0422\u0435\u0441\u0442\u043e\u0432\u044b\u0435 \u0442\u043e\u0447\u043a\u0438, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u043e\u0442\u043d\u0435\u0441\u0442\u0438 \u043a \u043a\u0430\u043a\u043e\u043c\u0443-\u043b\u0438\u0431\u043e \u0438\u0437 classes     test_points = np.array([[4., 2.]])     # \u041a\u043b\u0430\u0441\u0441\u044b \u0441 \u0442\u043e\u0447\u043a\u0430\u043c\u0438     classes = [         np.array([[1., 1.], [2., 2.], [3., 3.], [4., 4.], [5., 5.]]),         np.array([[3., 1.], [4., 0.], [6., 0.], [6., 2.], [5., 3.]])     ]     # \u0427\u0438\u0441\u043b\u043e \u0442\u0440\u0435\u043d\u0438\u0440\u043e\u0432\u043e\u0447\u043d\u044b\u0445 \u0442\u043e\u0447\u0435\u043a     n_train_points = sum(class_.shape[0] for class_ in classes)     # \u0421\u043f\u0438\u0441\u043e\u043a \u043c\u0430\u0442\u0440\u0438\u0446 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430     cov_matrices = [np.cov(class_, rowvar=False, ddof=1) for class_ in classes]     # \u0421\u043f\u0438\u0441\u043e\u043a \u043e\u0431\u0440\u0430\u0442\u043d\u044b\u0445 \u043c\u0430\u0442\u0440\u0438\u0446 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 -- \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 - \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430     inv_cov_matrices = [np.linalg.inv(cov + np.identity(cov.shape[0])) for cov in cov_matrices]     for test_point in test_points:         print(\"Point:\", test_point)         # k \u043e\u0442 1 \u0434\u043e \u0447\u0438\u0441\u043b\u0430 \u0442\u043e\u0447\u0435\u043a (\u043d\u0435 \u0432\u043a\u043b\u044e\u0447\u0430\u044f)         for i in range(1, n_train_points):             classifier = MkNN(i, classes, inv_cov_matrices)             print(f\"{i}nn:\",                   1 + classifier.predict(test_point),                   classifier.predict_proba(test_point),                   classifier.predict_all_max(test_point))   if __name__ == \"__main__\":     main() <\/code><\/pre>\n<\/div>\n<\/details>\n<p>\u0412\u044b\u0432\u043e\u0434 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u044b \u0432 \u0444\u043e\u0440\u043c\u0430\u0442\u0435:<br \/>&#171;<u>k<\/u>nn: [<u>\u043d\u0430\u0438\u043c\u0435\u043d\u044c\u0448\u0438\u0439 \u043d\u043e\u043c\u0435\u0440 \u043a\u043b\u0430\u0441\u0441\u0430, \u043a \u043a\u043e\u0442\u043e\u0440\u043e\u043c\u0443 \u043c\u043e\u0436\u043d\u043e \u043e\u0442\u043d\u0435\u0441\u0442\u0438 \u0442\u043e\u0447\u043a\u0443<\/u>] [<u>\u0432\u0435\u0440\u043e\u044f\u0442\u043d\u043e\u0441\u0442\u043d\u044b\u0435 \u043e\u0446\u0435\u043d\u043a\u0438 \u0434\u043b\u044f \u0442\u0435\u0441\u0442\u043e\u0432\u044b\u0445 \u0442\u043e\u0447\u0435\u043a \u0434\u043b\u044f \u0432\u0441\u0435\u0445 \u043a\u043b\u0430\u0441\u0441\u043e\u0432<\/u>] [<u>\u043d\u043e\u043c\u0435\u0440\u0430 \u043a\u043b\u0430\u0441\u0441\u043e\u0432, \u043a \u043a\u043e\u0442\u043e\u0440\u044b\u043c \u043c\u043e\u0436\u043d\u043e \u043e\u0442\u043d\u0435\u0441\u0442\u0438 \u0442\u043e\u0447\u043a\u0443<\/u>]&#187;.<\/p>\n<pre><code class=\"xml\">Point: [4. 2.] 1nn: 2 [0. 1.] [1] 2nn: 2 [0. 1.] [1] 3nn: 2 [0. 1.] [1] 4nn: 2 [0. 1.] [1] 5nn: 2 [0.2 0.8] [1] 6nn: 2 [0.33333333 0.66666667] [1] 7nn: 2 [0.42857143 0.57142857] [1] 8nn: 1 [0.5 0.5] [0 1] 9nn: 2 [0.44444444 0.55555556] [1]<\/code><\/pre>\n<p>\u0412\u0438\u0437\u0443\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043a\u043b\u0430\u0441\u0441\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u0441\u0435\u0442\u043a\u0438 \u0442\u043e\u0447\u0435\u043a \u043f\u0440\u0438 \u0440\u0430\u0437\u043d\u044b\u0445 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f\u0445 <img decoding=\"async\" class=\"formula inline\" source=\"k\" alt=\"k\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/b1f\/988\/acc\/b1f988acc37a35d4f2968dea3c594840.svg\"> \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0430 \u043d\u0430 \u0440\u0438\u0441. 4.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/58c\/7b1\/b34\/58c7b1b34797ae7953ad446202627a2c.png\" alt=\"\u0420\u0438\u0441\u0443\u043d\u043e\u043a 4. \u0412\u0438\u0437\u0443\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043a\u043b\u0430\u0441\u0441\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u0441\u0435\u0442\u043a\u0438 \u0442\u043e\u0447\u0435\u043a\" title=\"\u0420\u0438\u0441\u0443\u043d\u043e\u043a 4. \u0412\u0438\u0437\u0443\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043a\u043b\u0430\u0441\u0441\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u0441\u0435\u0442\u043a\u0438 \u0442\u043e\u0447\u0435\u043a\" width=\"800\" height=\"800\"><figcaption>\u0420\u0438\u0441\u0443\u043d\u043e\u043a 4. \u0412\u0438\u0437\u0443\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043a\u043b\u0430\u0441\u0441\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u0441\u0435\u0442\u043a\u0438 \u0442\u043e\u0447\u0435\u043a<\/figcaption><\/figure>\n<details class=\"spoiler\">\n<summary>\u041a\u043e\u0434 \u0434\u043b\u044f \u0432\u0438\u0437\u0443\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u043d\u0430 Python 3.6<\/summary>\n<div class=\"spoiler__content\">\n<pre><code class=\"python\"># ...  from operator import sub  import numpy as np  # 1.19.5 from matplotlib import colors, pyplot as plt  # 3.3.4  # \u0412\u0438\u0437\u0443\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043a\u043b\u0430\u0441\u0441\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u0441\u0435\u0442\u043a\u0438 \u0442\u043e\u0447\u0435\u043a def show_data_on_mesh(k, classes, inv_cov_matrices):     # \u0413\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u044f \u0441\u0435\u0442\u043a\u0438     min_ = np.min([np.min(class_, axis=0) for class_ in classes], axis=1) - 1     max_ = np.max([np.max(class_, axis=0) for class_ in classes], axis=1) + 1     min_c = min(min_[0], min_[1])     max_c = max(max_[0], max_[1])     h = 0.05     test_mesh = np.meshgrid(np.arange(min_c, max_c, h), np.arange(min_c, max_c, h))     test_points = np.c_[test_mesh[0].ravel(), test_mesh[1].ravel()]     # \u041a\u043b\u0430\u0441\u0441\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044f \u0442\u043e\u0447\u0435\u043a \u0441\u0435\u0442\u043a\u0438     classifier = MkNN(k, classes, inv_cov_matrices)     test_mesh_labels = [sub(*classifier.predict_proba(x)) for x in test_points]     # \u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0433\u0440\u0430\u0444\u0438\u043a\u0430     plt.figure(figsize=(6, 5), dpi=90)     class_colormap = colors.ListedColormap(['#070648', '#480607'])     plt.pcolormesh(test_mesh[0], test_mesh[1],                    np.asarray(test_mesh_labels).reshape(test_mesh[0].shape),                    cmap='coolwarm', shading='nearest')     plt.colorbar()     plt.scatter([point[0] for class_ in classes for point in class_],                 [point[1] for class_ in classes for point in class_],                 c=[-i for i, class_ in enumerate(classes) for _ in class_],                 cmap=class_colormap)     plt.axis([min_c, max_c, min_c, max_c])     plt.xlabel(\"X\")     plt.ylabel(\"Y\")     plt.title(\"k=\" + str(k))     plt.show()  # ... <\/code><\/pre>\n<p>\u041e\u0434\u0438\u043d \u0437\u0430\u043f\u0443\u0441\u043a \u2014 \u043e\u0434\u0438\u043d \u0433\u0440\u0430\u0444\u0438\u043a \u0434\u043b\u044f \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u0430 <img decoding=\"async\" class=\"formula inline\" source=\"k\" alt=\"k\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/5e8\/25c\/99f\/5e825c99fc179499d361fa60f46bbbfa.svg\">.<\/p>\n<\/div>\n<\/details>\n<p><a class=\"anchor\" name=\"Weighted\" id=\"Weighted\"><\/a><\/p>\n<h2>5. \u0412\u0437\u0432\u0435\u0448\u0435\u043d\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430<\/h2>\n<p>\u0420\u0430\u0441\u0448\u0438\u0440\u0435\u043d\u0438\u0435\u043c \u043f\u043e\u043d\u044f\u0442\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0432\u0437\u0432\u0435\u0448\u0435\u043d\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430, \u0444\u043e\u0440\u043c\u0443\u043b\u0430 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u043e\u0442\u043b\u0438\u0447\u0430\u0435\u0442\u0441\u044f \u043e\u0442 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0439 \u043d\u0430\u043b\u0438\u0447\u0438\u0435\u043c \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0433\u043e \u0441\u043e\u043c\u043d\u043e\u0436\u0438\u0442\u0435\u043b\u044f \u2014 \u0441\u0438\u043c\u043c\u0435\u0442\u0440\u0438\u0447\u0435\u0441\u043a\u043e\u0439 \u043d\u0435\u043e\u0442\u0440\u0438\u0446\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u0432\u0435\u0441\u043e\u0432\u044b\u0445 \u043a\u043e\u044d\u0444\u0444\u0438\u0446\u0438\u0435\u043d\u0442\u043e\u0432 <img decoding=\"async\" class=\"formula inline\" source=\"\\Lambda\" alt=\"\\Lambda\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/5ac\/9c0\/1ab\/5ac9c01abc4e4146a6e4c65c5a584185.svg\">, \u043d\u0435\u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u044c\u043d\u044b\u0435 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u044b \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0447\u0430\u0449\u0435 \u0432\u0441\u0435\u0433\u043e \u0440\u0430\u0432\u043d\u044b \u043d\u0443\u043b\u044e:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_{M-\\Lambda} ( U , V, COV^{-1}, \\Lambda ) = \\sqrt { ( U - V ) * \\Lambda \\cdot COV^{-1} \\cdot \\Lambda^T * ( U - V )^T }\" alt=\"d_{M-\\Lambda} ( U , V, COV^{-1}, \\Lambda ) = \\sqrt { ( U - V ) * \\Lambda \\cdot COV^{-1} \\cdot \\Lambda^T * ( U - V )^T }\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/973\/f70\/cf5\/973f70cf54e369c77930c32da69ef733.svg\" width=\"485\" height=\"35\"><\/p>\n<p>\u041f\u0440\u0438\u043c\u0435\u0440 \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u0432\u0435\u0441\u043e\u0432\u044b\u0445 \u043a\u043e\u044d\u0444\u0444\u0438\u0446\u0438\u0435\u043d\u0442\u043e\u0432 (\u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0435\u0434\u0438\u043d\u0438\u0447\u043d\u043e\u0439, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043d\u0430 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u043d\u0435 \u043f\u043e\u0432\u043b\u0438\u044f\u0435\u0442) \u0434\u043b\u044f \u0442\u043e\u0447\u0435\u043a \u0441 \u0434\u0432\u0443\u043c\u044f \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0430\u043c\u0438:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"\\Lambda = \\begin{pmatrix} 1 &amp; 0 \\\\ 0 &amp; 1 \\end{pmatrix}\" alt=\"\\Lambda = \\begin{pmatrix} 1 &amp; 0 \\\\ 0 &amp; 1 \\end{pmatrix}\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/82c\/6cd\/edb\/82c6cdedb75eb1c3c3348b631681eb3e.svg\" width=\"98\" height=\"44\"><\/p>\n<p>\u0424\u043e\u0440\u043c\u0443\u043b\u0430 \u0432\u0437\u0432\u0435\u0448\u0435\u043d\u043d\u043e\u0433\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"d_{E-M-\\Lambda} ( U , V, \\left (COV+E \\right)^{-1}, \\Lambda ) = \\sqrt { ( U - V ) * \\Lambda \\cdot \\left (COV+E \\right)^{-1} \\cdot \\Lambda^T * ( U - V )^T }\" alt=\"d_{E-M-\\Lambda} ( U , V, \\left (COV+E \\right)^{-1}, \\Lambda ) = \\sqrt { ( U - V ) * \\Lambda \\cdot \\left (COV+E \\right)^{-1} \\cdot \\Lambda^T * ( U - V )^T }\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/d4b\/bea\/802\/d4bbea80279cb2e70a1d0a0733bc147a.svg\" width=\"595\" height=\"34\"><a class=\"anchor\" name=\"Conclusion\" id=\"Conclusion\"><\/a><\/p>\n<h2>6. \u0417\u0430\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435<\/h2>\n<p>\u0412 \u0441\u0442\u0430\u0442\u044c\u0435 \u0434\u0430\u043d\u044b \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0439 \u0438 \u043c\u0435\u0442\u0440\u0438\u043a \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430, \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u044b \u0442\u0435\u043e\u0440\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u0441\u0432\u0435\u0434\u0435\u043d\u0438\u044f \u0438 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u044b \u043f\u0440\u0438\u043c\u0435\u0440\u044b \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0439 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438 (\u0442\u0430\u043a\u0436\u0435 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c) \u0438 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438, \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u0430 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0430 \u0434\u043b\u044f \u043a\u043b\u0430\u0441\u0441\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u043f\u043e \u043c\u0435\u0442\u043e\u0434\u0443 <img decoding=\"async\" class=\"formula inline\" source=\"k\" alt=\"k\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/71e\/1cd\/b4f\/71e1cdb4f8c4b149d399de5f49364369.svg\">-\u0431\u043b\u0438\u0436\u0430\u0439\u0448\u0438\u0445 \u0441\u043e\u0441\u0435\u0434\u0435\u0439 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430.<\/p>\n<p>\u0427\u0442\u043e \u0435\u0449\u0451?<br \/>1. \u0421\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 \u043f\u043e\u043b\u0438\u043d\u043e\u043c\u0438\u0430\u043b\u044c\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430, \u043e \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0447\u0438\u0442\u0430\u0442\u044c <a href=\"http:\/\/www.roboticsproceedings.org\/rss02\/p20.pdf\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a>.<br \/>2. \u041e \u043f\u0440\u0438\u043c\u0435\u043d\u0435\u043d\u0438\u0438 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u0432 \u043c\u0430\u0448\u0438\u043d\u043d\u043e\u043c \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u0438 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0447\u0438\u0442\u0430\u0442\u044c \u0432 \u043a\u043d\u0438\u0433\u0435 \u00ab<a href=\"https:\/\/ieeexplore.ieee.org\/document\/7047350\" rel=\"noopener noreferrer nofollow\">Metric Learning<\/a>\u00bb (\u0430\u0432\u0442\u043e\u0440\u044b: Aur\u00e9lien Bellet, Amaury Habrard, Marc Sebban; <a href=\"https:\/\/sci-hub.do\/10.2200\/S00626ED1V01Y201501AIM030\" rel=\"noopener noreferrer nofollow\">\u0432\u0435\u0440\u0441\u0438\u044f \u0434\u043b\u044f \u043e\u0437\u043d\u0430\u043a\u043e\u043c\u043b\u0435\u043d\u0438\u044f<\/a>).<br \/>3. \u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u043e\u0436\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0432 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0438\u0437\u0430\u0446\u0438\u0438 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, k-means: <a href=\"https:\/\/sci-hub.do\/10.1109\/icacci.2016.7732167\" rel=\"noopener noreferrer nofollow\">\u0441\u0442\u0430\u0442\u044c\u044f 1<\/a>, <a href=\"https:\/\/sci-hub.do\/10.1016\/j.spl.2013.09.026\" rel=\"noopener noreferrer nofollow\">\u0441\u0442\u0430\u0442\u044c\u044f 2<\/a>, <a href=\"https:\/\/library.ndsu.edu\/ir\/bitstream\/handle\/10365\/26766\/On%20K-Means%20Clustering%20Using%20Mahalanobis%20Distance.pdf?sequence=1\" rel=\"noopener noreferrer nofollow\">\u0441\u0442\u0430\u0442\u044c\u044f 3<\/a>).<br \/>4. \u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u043e\u0436\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0432 \u043e\u0431\u043b\u0430\u0441\u0442\u0438 \u0438\u043d\u0442\u0435\u043b\u043b\u0435\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0430\u043d\u0430\u043b\u0438\u0437\u0430 \u0442\u0435\u043a\u0441\u0442\u0430 (<a href=\"https:\/\/sci-hub.do\/10.1109\/iccrd.2011.5764268\" rel=\"noopener noreferrer nofollow\">\u0441\u0442\u0430\u0442\u044c\u044f<\/a>).<br \/>5. \u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u043e\u0436\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0434\u043b\u044f \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0435\u043d\u0438\u044f \u0432\u044b\u0431\u0440\u043e\u0441\u043e\u0432 (<a href=\"https:\/\/core.ac.uk\/download\/pdf\/233075917.pdf\" rel=\"noopener noreferrer nofollow\">\u0441\u0442\u0430\u0442\u044c\u044f 1<\/a>, <a href=\"https:\/\/sci-hub.do\/10.1016\/j.jesp.2017.09.011\" rel=\"noopener noreferrer nofollow\">\u0441\u0442\u0430\u0442\u044c\u044f 2<\/a>, <a href=\"https:\/\/sci-hub.do\/10.1007\/s00362-019-01148-1\" rel=\"noopener noreferrer nofollow\">\u0441\u0442\u0430\u0442\u044c\u044f 3<\/a>).<\/p>\n<hr>\n<p>\u0415\u0441\u043b\u0438 \u0435\u0441\u0442\u044c \u0437\u0430\u043c\u0435\u0447\u0430\u043d\u0438\u044f \u0438\u043b\u0438 \u043e\u0448\u0438\u0431\u043a\u0438, \u043f\u0438\u0448\u0438\u0442\u0435 \u043d\u0430 \u043f\u043e\u0447\u0442\u0443 <a href=\"mailto:quwarm@gmail.com\" rel=\"noopener noreferrer nofollow\">quwarm@gmail.com<\/a> \u0438\u043b\u0438 \u0432 \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u044f\u0445.<\/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\/post\/555144\/\"> https:\/\/habr.com\/ru\/post\/555144\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"\n<div class=\"post__text post__text_v2\" id=\"post-content-body\">\n<h2>\u0421\u043e\u0434\u0435\u0440\u0436\u0430\u043d\u0438\u0435<\/h2>\n<p><a href=\"#MainPoint\" rel=\"noopener noreferrer nofollow\">\u041e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0441\u043c\u044b\u0441\u043b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430<\/a><br \/>1. <a href=\"#Terms\" rel=\"noopener noreferrer nofollow\">\u0422\u0435\u0440\u043c\u0438\u043d\u044b \u0438 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f<\/a><br \/>2. <a href=\"#PointClass\" rel=\"noopener noreferrer nofollow\">\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u0438 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c<\/a><br \/>    2.1. <a href=\"#PointClassTheory\" rel=\"noopener noreferrer nofollow\">\u0422\u0435\u043e\u0440\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u0441\u0432\u0435\u0434\u0435\u043d\u0438\u044f<\/a><br \/>    2.2. <a href=\"#PointClassAlgorithm\" rel=\"noopener noreferrer nofollow\">\u0410\u043b\u0433\u043e\u0440\u0438\u0442\u043c \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u0438 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c<\/a><br \/>    2.3. <a href=\"#PointClassExample\" rel=\"noopener noreferrer nofollow\">\u041f\u0440\u0438\u043c\u0435\u0440 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u0438 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c<\/a><br \/>3. <a href=\"#ClassClass\" rel=\"noopener noreferrer nofollow\">\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438<\/a><br \/>    3.1. <a href=\"#ClassClassTheory\" rel=\"noopener noreferrer nofollow\">\u0422\u0435\u043e\u0440\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u0441\u0432\u0435\u0434\u0435\u043d\u0438\u044f<\/a><br \/>    3.2. <a href=\"#ClassClassAlgorithm\" rel=\"noopener noreferrer nofollow\">\u0410\u043b\u0433\u043e\u0440\u0438\u0442\u043c \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438<\/a><br \/>    3.3. <a href=\"#ClassClassExample\" rel=\"noopener noreferrer nofollow\">\u041f\u0440\u0438\u043c\u0435\u0440 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438<\/a><br \/>4. <a href=\"#KNN\" rel=\"noopener noreferrer nofollow\">\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u0438 \u043c\u0435\u0442\u043e\u0434 k-\u0431\u043b\u0438\u0436\u0430\u0439\u0448\u0438\u0445 \u0441\u043e\u0441\u0435\u0434\u0435\u0439<\/a><br \/>5. <a href=\"#Weighted\" rel=\"noopener noreferrer nofollow\">\u0412\u0437\u0432\u0435\u0448\u0435\u043d\u043d\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430<\/a><br \/>6. <a href=\"#Conclusion\" rel=\"noopener noreferrer nofollow\">\u0417\u0430\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435<\/a><\/p>\n<p>\u0415\u0441\u043b\u0438 \u0435\u0441\u0442\u044c \u0437\u0430\u043c\u0435\u0447\u0430\u043d\u0438\u044f \u0438\u043b\u0438 \u043e\u0448\u0438\u0431\u043a\u0438, \u043f\u0438\u0448\u0438\u0442\u0435 \u043d\u0430 \u043f\u043e\u0447\u0442\u0443 <a href=\"mailto:quwarm@gmail.com\" rel=\"noopener noreferrer nofollow\">quwarm@gmail.com<\/a> \u0438\u043b\u0438 \u0432 \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u044f\u0445.<\/p>\n<hr>\n<p><a class=\"anchor\" name=\"MainPoint\" id=\"MainPoint\"><\/a><\/p>\n<h2>\u041e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0441\u043c\u044b\u0441\u043b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430<\/h2>\n<p>\u041d\u0430 \u0440\u0438\u0441\u0443\u043d\u043a\u0435 1 \u0434\u0432\u0430 \u043d\u0430\u0431\u043b\u044e\u0434\u0435\u043d\u0438\u044f \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u044b \u0432 \u0432\u0438\u0434\u0435 \u043a\u0440\u0430\u0441\u043d\u044b\u0445 \u0442\u043e\u0447\u0435\u043a.<br \/>\u0426\u0435\u043d\u0442\u0440 \u043a\u043b\u0430\u0441\u0441\u0430 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d \u0432 \u0432\u0438\u0434\u0435 \u0441\u0438\u043d\u0435\u0439 \u0442\u043e\u0447\u043a\u0438.<\/p>\n<figure class=\"bordered\"><figcaption>\u0420\u0438\u0441\u0443\u043d\u043e\u043a 1. \u0414\u0432\u0443\u043c\u0435\u0440\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u0441 \u044d\u043b\u043b\u0438\u043f\u0441\u0430\u043c\u0438 \u043f\u0440\u043e\u0433\u043d\u043e\u0437\u0430<\/figcaption><\/figure>\n<p><strong>\u0412\u043e\u043f\u0440\u043e\u0441 \u2014 \u043a\u0430\u043a\u043e\u0435 \u043d\u0430\u0431\u043b\u044e\u0434\u0435\u043d\u0438\u0435 \u0431\u043b\u0438\u0436\u0435 \u043a \u0446\u0435\u043d\u0442\u0440\u0443 \u043a\u043b\u0430\u0441\u0441\u0430?<br \/><\/strong>\u041e\u0442\u0432\u0435\u0442 \u0437\u0430\u0432\u0438\u0441\u0438\u0442 \u043e\u0442 \u0442\u043e\u0433\u043e, \u043a\u0430\u043a \u0438\u0437\u043c\u0435\u0440\u044f\u0435\u0442\u0441\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435.<\/p>\n<p>\u0415\u0441\u043b\u0438 \u0438\u0437\u043c\u0435\u0440\u044f\u0442\u044c \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043f\u043e <a href=\"https:\/\/en.wikipedia.org\/wiki\/Euclidean_distance\" rel=\"noopener noreferrer nofollow\">\u043c\u0435\u0442\u0440\u0438\u043a\u0435 \u0415\u0432\u043a\u043b\u0438\u0434\u0430<\/a>, \u0442\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u043c, \u0447\u0442\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043e\u0442 \u0446\u0435\u043d\u0442\u0440\u0430 \u043a\u043b\u0430\u0441\u0441\u0430  \u0434\u043e \u0442\u043e\u0447\u043a\u0438  \u0440\u0430\u0432\u043d\u043e , \u0434\u043e \u0442\u043e\u0447\u043a\u0438  \u0440\u0430\u0432\u043d\u043e , \u0442. \u0435. \u0442\u043e\u0447\u043a\u0430  \u0431\u043b\u0438\u0436\u0435 \u043a \u0446\u0435\u043d\u0442\u0440\u0443 \u043a\u043b\u0430\u0441\u0441\u0430.<\/p>\n<p>\u041e\u0434\u043d\u0430\u043a\u043e \u0434\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f \u0434\u0438\u0441\u043f\u0435\u0440\u0441\u0438\u044f \u0432 \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0438  \u043c\u0435\u043d\u044c\u0448\u0435, \u0447\u0435\u043c \u0434\u0438\u0441\u043f\u0435\u0440\u0441\u0438\u044f \u0432 \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0438 , \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0432 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0441\u043c\u044b\u0441\u043b\u0435 \u0442\u043e\u0447\u043a\u0430  \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u00ab\u043d\u0430 \u0431\u043e\u043b\u044c\u0448\u0435\u043c \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u043c \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u0438\u00bb \u043e\u0442 \u0446\u0435\u043d\u0442\u0440\u0430 \u043a\u043b\u0430\u0441\u0441\u0430, \u0447\u0435\u043c .<\/p>\n<p><a href=\"https:\/\/blogs.sas.com\/content\/iml\/2014\/07\/21\/add-prediction-ellipse.html\" rel=\"noopener noreferrer nofollow\">\u042d\u043b\u043b\u0438\u043f\u0441\u044b \u043f\u0440\u043e\u0433\u043d\u043e\u0437\u0430<\/a>, \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u043d\u044b\u0435 \u043d\u0430 \u0440\u0438\u0441\u0443\u043d\u043a\u0435, <em>\u043f\u043e\u0434\u0441\u043a\u0430\u0437\u044b\u0432\u0430\u044e\u0442<\/em>, \u0447\u0442\u043e \u0442\u043e\u0447\u043a\u0430  \u0431\u043b\u0438\u0436\u0435 \u043f\u043e \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044e, \u0447\u0435\u043c \u0442\u043e\u0447\u043a\u0430 . \u0418\u0437\u043c\u0435\u0440\u0438\u0432 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043f\u043e \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0443, \u043f\u043e\u043b\u0443\u0447\u0438\u043c, \u0447\u0442\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043e\u0442 \u0446\u0435\u043d\u0442\u0440\u0430 \u043a\u043b\u0430\u0441\u0441\u0430  \u0434\u043e \u0442\u043e\u0447\u043a\u0438  \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0440\u0430\u0432\u043d\u043e , \u0434\u043e \u0442\u043e\u0447\u043a\u0438  \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0440\u0430\u0432\u043d\u043e , \u0442. \u0435. \u0442\u043e\u0447\u043a\u0430  \u0431\u043b\u0438\u0436\u0435 \u043a \u0446\u0435\u043d\u0442\u0440\u0443 \u043a\u043b\u0430\u0441\u0441\u0430. <strong>\u0412 \u044d\u0442\u043e\u043c \u0438 \u0437\u0430\u043a\u043b\u044e\u0447\u0430\u0435\u0442\u0441\u044f \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0441\u043c\u044b\u0441\u043b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u2014 \u0443\u0447\u0438\u0442\u044b\u0432\u0430\u043d\u0438\u0435 \u0434\u0438\u0441\u043f\u0435\u0440\u0441\u0438\u0439 \u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439.<\/strong><\/p>\n<p>\u041a\u0440\u043e\u043c\u0435 \u0442\u043e\u0433\u043e, \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043f\u0440\u0435\u0434\u043f\u043e\u043b\u0430\u0433\u0430\u0435\u0442, \u0447\u0442\u043e \u0442\u043e\u0447\u043a\u0438 \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432\u0430 \u0441\u0444\u0435\u0440\u0438\u0447\u0435\u0441\u043a\u0438 \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u044b \u0432\u043e\u043a\u0440\u0443\u0433 \u0446\u0435\u043d\u0442\u0440\u0430 \u043c\u0430\u0441\u0441.<\/p>\n<hr>\n<p><a class=\"anchor\" name=\"Terms\" id=\"Terms\"><\/a><\/p>\n<h2>1. \u0422\u0435\u0440\u043c\u0438\u043d\u044b \u0438 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f<\/h2>\n<p><strong>\u041c\u0435\u0442\u0440\u0438\u043a\u0430<\/strong> \u2014 \u0444\u0443\u043d\u043a\u0446\u0438\u044f, \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u044e\u0449\u0430\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u043b\u044e\u0431\u044b\u043c\u0438 \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u0432 \u043c\u0435\u0442\u0440\u0438\u0447\u0435\u0441\u043a\u043e\u043c \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0435 , \u0433\u0434\u0435  \u2014 \u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0441\u0442\u044c \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0430.<\/p>\n<p><strong>\u041a\u043b\u0430\u0441\u0441<\/strong>  \u2014 \u043a\u043e\u043d\u0435\u0447\u043d\u043e\u0435 \u043d\u0435\u0443\u043f\u043e\u0440\u044f\u0434\u043e\u0447\u0435\u043d\u043d\u043e\u0435 \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432\u043e \u0441\u0445\u043e\u0436\u0438\u0445 \u043f\u043e \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u043c \u043a\u0440\u0438\u0442\u0435\u0440\u0438\u044f\u043c \u043e\u043f\u0442\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u0438 \u0442\u043e\u0447\u0435\u043a: , \u0433\u0434\u0435  \u2014 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0442\u043e\u0447\u0435\u043a \u0432 \u043a\u043b\u0430\u0441\u0441\u0435 .<\/p>\n<p><strong>\u0422\u043e\u0447\u043a\u0430<\/strong> \u2014 \u043a\u043e\u043d\u0435\u0447\u043d\u043e\u0435 \u0443\u043f\u043e\u0440\u044f\u0434\u043e\u0447\u0435\u043d\u043d\u043e\u0435 \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432\u043e  \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432: .<\/p>\n<p>\u0411\u0443\u0434\u0435\u043c \u043e\u0431\u043e\u0437\u043d\u0430\u0447\u0430\u0442\u044c \u0431\u0443\u043a\u0432\u043e\u0439  \u0447\u0438\u0441\u043b\u043e \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432, \u0430 \u0431\u0443\u043a\u0432\u043e\u0439  \u2014  \u043f\u0440\u0438\u0437\u043d\u0430\u043a.<\/p>\n<details class=\"spoiler\">\n<summary>\u041f\u0440\u0438\u043c\u0435\u0447\u0430\u043d\u0438\u044f<\/summary>\n<div class=\"spoiler__content\">\n<p><strong>\u041f\u043e\u0434 \u0441\u043b\u043e\u0432\u043e\u043c \u00ab\u0442\u043e\u0447\u043a\u0430\u00bb \u043f\u043e\u0434\u0440\u0430\u0437\u0443\u043c\u0435\u0432\u0430\u0435\u0442\u0441\u044f \u0442\u043e\u0447\u043a\u0430 \u043a\u043e\u043e\u0440\u0434\u0438\u043d\u0430\u0442\u043d\u043e\u0433\u043e -\u043c\u0435\u0440\u043d\u043e\u0433\u043e \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0430 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432.<\/strong> \u041f\u0440\u0438\u0447\u0435\u043c \u0437\u0430\u043c\u0435\u0447\u0435\u043d\u043d\u044b\u0435 \u0441\u0445\u043e\u0434\u0441\u0442\u0432\u0430 \u0438 \u0440\u0430\u0437\u043b\u0438\u0447\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u043d\u0430\u0445\u043e\u0434\u044f\u0442\u0441\u044f \u0432 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0438 \u0441 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f\u043c\u0438 \u043c\u0435\u0436\u0434\u0443 \u043d\u0438\u043c\u0438.<\/p>\n<p><strong>\u041a\u043b\u0430\u0441\u0441\u044b \u0438 \u0442\u043e\u0447\u043a\u0438 \u0432 \u0441\u0442\u0430\u0442\u044c\u0435 \u043e\u0431\u043e\u0437\u043d\u0430\u0447\u0430\u044e\u0442\u0441\u044f \u043a\u0430\u043a \u0432\u0435\u043a\u0442\u043e\u0440-\u0441\u0442\u0440\u043e\u043a\u0438.<\/strong> \u0412 \u043b\u0438\u0442\u0435\u0440\u0430\u0442\u0443\u0440\u0435 \u0438 \u0418\u043d\u0442\u0435\u0440\u043d\u0435\u0442\u0435 \u043e\u043d\u0438 \u0438\u043d\u043e\u0433\u0434\u0430 \u043e\u0431\u043e\u0437\u043d\u0430\u0447\u0430\u044e\u0442\u0441\u044f \u043a\u0430\u043a \u0432\u0435\u043a\u0442\u043e\u0440-\u0441\u0442\u043e\u043b\u0431\u0446\u044b \u2014 \u0442\u043e\u0433\u0434\u0430 \u0432 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0447\u0430\u0441\u0442\u044f\u0445 \u0444\u043e\u0440\u043c\u0443\u043b \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u044f \u0442\u0440\u0430\u043d\u0441\u043f\u043e\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0443\u0431\u0438\u0440\u0430\u0435\u0442\u0441\u044f, \u0430 \u0432 \u0434\u0440\u0443\u0433\u0438\u0445 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442\u0441\u044f.<\/p>\n<p><strong>\u0412 \u043f\u0440\u0438\u043c\u0435\u0440\u0430\u0445:<\/strong>  \u043f\u0440\u0438\u0437\u043d\u0430\u043a \u0442\u043e\u0447\u043a\u0438  \u0438\u0437  \u043a\u043b\u0430\u0441\u0441\u0430 \u043e\u0431\u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442\u0441\u044f \u043a\u0430\u043a .<\/p>\n<p><strong>\u041f\u043e\u0434\u0440\u0430\u0437\u0443\u043c\u0435\u0432\u0430\u0435\u0442\u0441\u044f, \u0447\u0442\u043e \u043e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u044b\u0445 \u0442\u043e\u0447\u0435\u043a \u0432 \u043a\u043b\u0430\u0441\u0441\u0435 (-\u0430\u0445) \u043d\u0435\u0442.<\/strong><\/p>\n<\/div>\n<\/details>\n<p><a class=\"anchor\" name=\"PointClass\" id=\"PointClass\"><\/a><\/p>\n<h2>2. \u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u0438 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c<\/h2>\n<p>\u042d\u0442\u043e\u0442 \u043f\u0443\u043d\u043a\u0442 \u0432\u043a\u043b\u044e\u0447\u0430\u0435\u0442 \u0432\u043d\u0443\u0442\u0440\u0438\u043a\u043b\u0430\u0441\u0441\u043e\u0432\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 (\u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u0438\u0437 \u043e\u0434\u043d\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430) \u0438 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 (\u043d\u0435 \u043f\u0440\u0438\u043d\u0430\u0434\u043b\u0435\u0436\u0430\u0449\u0435\u0439 \u043d\u0438 \u043e\u0434\u043d\u043e\u043c\u0443 \u0438\u0437 \u043a\u043b\u0430\u0441\u0441\u043e\u0432) \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c.<\/p>\n<p><a class=\"anchor\" name=\"PointClassTheory\" id=\"PointClassTheory\"><\/a><\/p>\n<h3>2.1 \u0422\u0435\u043e\u0440\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u0441\u0432\u0435\u0434\u0435\u043d\u0438\u044f<\/h3>\n<p><strong>\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438<\/strong> \u2014 \u043c\u0435\u0440\u0430 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u044b\u043c\u0438 \u0442\u043e\u0447\u043a\u0430\u043c\u0438  \u0438  , \u043e\u0434\u043d\u0430 \u0438\u0437 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043c\u043e\u0436\u0435\u0442 (\u0438\u043b\u0438 <abbr title=\"\u0434\u043b\u044f \u0440\u0430\u0441\u0447\u0435\u0442\u0430 \u0432\u043d\u0443\u0442\u0440\u0438\u043a\u043b\u0430\u0441\u0441\u043e\u0432\u043e\u0433\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f\">\u0441\u0441\u043e\u0432\u043e\u0433\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f&#187;>\u043e\u0431\u0435 \u043c\u043e\u0433\u0443<\/abbr>) \u043f\u0440\u0438\u043d\u0430\u0434\u043b\u0435\u0436\u0430\u0442\u044c \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u043c\u0443 \u043a\u043b\u0430\u0441\u0441\u0443  \u0441 \u043c\u0430\u0442\u0440\u0438\u0446\u0435\u0439 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 :<\/p>\n<p>\u0421\u0438\u043c\u0432\u043e\u043b  \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u044e \u0442\u0440\u0430\u043d\u0441\u043f\u043e\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u0430 \u043f\u043e\u0434  \u043f\u043e\u0434\u0440\u0430\u0437\u0443\u043c\u0435\u0432\u0430\u0435\u0442\u0441\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430, \u043e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439.<\/p>\n<p>\u0415\u0441\u043b\u0438 \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0435\u0434\u0438\u043d\u0438\u0447\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u0435\u0439, \u0442\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u0441\u044f \u0440\u0430\u0432\u043d\u044b\u043c \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044e \u0415\u0432\u043a\u043b\u0438\u0434\u0430.<br \/>\u0418\u043d\u0430\u0447\u0435 \u0433\u043e\u0432\u043e\u0440\u044f, \u0435\u0441\u043b\u0438 \u043a\u043b\u0430\u0441\u0441 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0441\u043e\u0431\u043e\u0439 \u0443\u043f\u043e\u0440\u044f\u0434\u043e\u0447\u0435\u043d\u043d\u043e\u0435 \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432\u043e \u043d\u043e\u0440\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 (\u0434\u0438\u0441\u043f\u0435\u0440\u0441\u0438\u0438 \u0440\u0430\u0432\u043d\u044b 1) \u043d\u0435\u0437\u0430\u0432\u0438\u0441\u0438\u043c\u044b\u0445 (\u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0438 \u0440\u0430\u0432\u043d\u044b 0) \u0442\u043e\u0447\u0435\u043a, \u0442\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u0440\u0430\u0432\u043d\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044e \u0415\u0432\u043a\u043b\u0438\u0434\u0430.<\/p>\n<p><strong>\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 <\/strong><a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%91%D0%B5%D0%B7%D1%80%D0%B0%D0%B7%D0%BC%D0%B5%D1%80%D0%BD%D0%B0%D1%8F_%D0%B2%D0%B5%D0%BB%D0%B8%D1%87%D0%B8%D0%BD%D0%B0\" rel=\"noopener noreferrer nofollow\"><strong>\u0431\u0435\u0437\u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e<\/strong><\/a><strong> \u0438 <\/strong><a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%9C%D0%B0%D1%81%D1%88%D1%82%D0%B0%D0%B1%D0%BD%D0%B0%D1%8F_%D0%B8%D0%BD%D0%B2%D0%B0%D1%80%D0%B8%D0%B0%D0%BD%D1%82%D0%BD%D0%BE%D1%81%D1%82%D1%8C\" rel=\"noopener noreferrer nofollow\"><strong>\u043c\u0430\u0441\u0448\u0442\u0430\u0431\u043d\u043e-\u0438\u043d\u0432\u0430\u0440\u0438\u0430\u043d\u0442\u043d\u043e<\/strong><\/a><strong>.<\/strong><\/p>\n<p><strong>\u0420\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043c\u0435\u0442\u0440\u0438\u043a\u043e\u0439<\/strong> (\u0434\u043e\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u044c\u0441\u0442\u0432\u043e<a href=\"http:\/\/www.isa.ru\/aidt\/images\/documents\/2012-01\/81_89.pdf\" rel=\"noopener noreferrer nofollow\"> <\/a><a href=\"http:\/\/www.rusnauka.com\/24_PNR_2014\/Matemathics\/4_175946.doc.htm\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a> [<a href=\"https:\/\/web.archive.org\/web\/20190907235613\/http:\/\/www.rusnauka.com\/24_PNR_2014\/Matemathics\/4_175946.doc.htm\" rel=\"noopener noreferrer nofollow\">internet archive<\/a>] \u0438 <a href=\"http:\/\/www.isa.ru\/aidt\/images\/documents\/2012-01\/81_89.pdf\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a>), \u0442. \u0435.  \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438  \u0438  \u0441 \u043c\u0430\u0442\u0440\u0438\u0446\u0435\u0439 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439  \u0432 \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0435 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u0443\u0434\u043e\u0432\u043b\u0435\u0442\u0432\u043e\u0440\u044f\u0435\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u0430\u043a\u0441\u0438\u043e\u043c\u0430\u043c:<br \/><strong>1. <\/strong>\u0410\u043a\u0441\u0438\u043e\u043c\u0430 \u0442\u043e\u0436\u0434\u0435\u0441\u0442\u0432\u0430: ;<br \/><strong>2. <\/strong>\u0410\u043a\u0441\u0438\u043e\u043c\u0430 \u0441\u0438\u043c\u043c\u0435\u0442\u0440\u0438\u0438: ;<br \/><strong>3. <\/strong>\u0410\u043a\u0441\u0438\u043e\u043c\u0430 \u0442\u0440\u0435\u0443\u0433\u043e\u043b\u044c\u043d\u0438\u043a\u0430: .<br \/>\u0418\u0437 \u044d\u0442\u0438\u0445 \u0430\u043a\u0441\u0438\u043e\u043c <a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%9C%D0%B5%D1%82%D1%80%D0%B8%D1%87%D0%B5%D1%81%D0%BA%D0%BE%D0%B5_%D0%BF%D1%80%D0%BE%D1%81%D1%82%D1%80%D0%B0%D0%BD%D1%81%D1%82%D0%B2%D0%BE#%D0%97%D0%B0%D0%BC%D0%B5%D1%87%D0%B0%D0%BD%D0%B8%D1%8F\" rel=\"noopener noreferrer nofollow\">\u0441\u043b\u0435\u0434\u0443\u0435\u0442<\/a> \u043d\u0435\u043e\u0442\u0440\u0438\u0446\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f: .<\/p>\n<p>\u0418\u0437 \u0430\u043a\u0441\u0438\u043e\u043c \u0441\u043b\u0435\u0434\u0443\u0435\u0442, \u0447\u0442\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043f\u043e\u0434 \u043a\u043e\u0440\u043d\u0435\u043c \u043d\u0435 \u043c\u0435\u043d\u044c\u0448\u0435 0, \u043e\u0434\u043d\u0430\u043a\u043e <strong>\u043f\u0440\u0438 \u0440\u0430\u0441\u0447\u0435\u0442\u0430\u0445 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u043d\u0435\u0442\u043e\u0447\u043d\u044b\u0445 \u0432\u0435\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0445 \u0447\u0438\u0441\u0435\u043b \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u0442\u0441\u044f \u043f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0438\u0432\u0430\u0442\u044c \u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430 \u0441\u043b\u0435\u0432\u0430 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435\u043c 0<\/strong> (<code>max(0.0, value)<\/code>) \u0432\u043e \u0438\u0437\u0431\u0435\u0436\u0430\u043d\u0438\u0435 <a href=\"https:\/\/ru.wikipedia.org\/wiki\/NaN\" rel=\"noopener noreferrer nofollow\">NaN<\/a>, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u043f\u043e\u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043f\u043e\u0441\u043b\u0435 \u0432\u0437\u044f\u0442\u0438\u044f \u043a\u043e\u0440\u043d\u044f (\u0444\u0443\u043d\u043a\u0446\u0438\u044f <code>sqrt<\/code> \u0438\u043b\u0438 \u0432\u043e\u0437\u0432\u0435\u0434\u0435\u043d\u0438\u0435 \u0432 \u0441\u0442\u0435\u043f\u0435\u043d\u044c <code>0.5<\/code>) \u0431\u043b\u0438\u0437\u043a\u043e\u0433\u043e \u043a 0 \u0441\u043b\u0435\u0432\u0430 \u0447\u0438\u0441\u043b\u0430 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, ). \u042d\u0442\u043e\u0442 \u043d\u044e\u0430\u043d\u0441 \u0447\u0430\u0441\u0442\u043e \u043d\u0435 \u0437\u0430\u043c\u0435\u0447\u0430\u0435\u0442\u0441\u044f.<\/p>\n<p><strong>\u0427\u0442\u043e\u0431\u044b \u043d\u0430\u0439\u0442\u0438 \u0432\u043d\u0443\u0442\u0440\u0438\u043a\u043b\u0430\u0441\u0441\u043e\u0432\u043e\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430<\/strong>, \u043d\u0443\u0436\u043d\u043e \u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u044c \u0432\u044b\u0448\u0435\u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u043e\u0439 \u0444\u043e\u0440\u043c\u0443\u043b\u0435 \u2014 \u0432\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u043c\u0430\u0442\u0440\u0438\u0446\u0443 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 \u043a\u043b\u0430\u0441\u0441\u0430 \u0438 \u0437\u0430\u0442\u0435\u043c \u0441\u0430\u043c\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u0434\u0432\u0443\u043c\u044f \u0442\u043e\u0447\u043a\u0430\u043c\u0438 \u0432 \u043d\u0435\u043c.<\/p>\n<p><strong>\u0427\u0442\u043e\u0431\u044b \u043d\u0430\u0439\u0442\u0438 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 (\u043d\u0435 \u043f\u0440\u0438\u043d\u0430\u0434\u043b\u0435\u0436\u0430\u0449\u0435\u0439 \u043d\u0438 \u043e\u0434\u043d\u043e\u043c\u0443 \u0438\u0437 \u043a\u043b\u0430\u0441\u0441\u043e\u0432) \u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u043c<\/strong>, \u043d\u0443\u0436\u043d\u043e \u0442\u0430\u043a\u0436\u0435 \u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u044c \u0432\u044b\u0448\u0435\u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u043e\u0439 \u0444\u043e\u0440\u043c\u0443\u043b\u0435 \u2014 \u0432\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u043c\u0430\u0442\u0440\u0438\u0446\u0443 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 \u043a\u043b\u0430\u0441\u0441\u0430 \u0438 \u0437\u0430\u0442\u0435\u043c \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u043e\u0439 (\u043d\u0435 \u043f\u0440\u0438\u043d\u0430\u0434\u043b\u0435\u0436\u0430\u0449\u0435\u0439 \u043d\u0438 \u043e\u0434\u043d\u043e\u043c\u0443 \u0438\u0437 \u043a\u043b\u0430\u0441\u0441\u043e\u0432) \u0438 <u>\u0446\u0435\u043d\u0442\u0440\u043e\u0438\u0434\u043e\u043c<\/u> \u043a\u043b\u0430\u0441\u0441\u0430 (\u0442. \u043d. \u00ab\u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0434\u043e \u0446\u0435\u043d\u0442\u0440\u043e\u0438\u0434\u0430\u00bb).<\/p>\n<p><strong>\u0414\u043b\u044f \u0440\u0435\u0448\u0435\u043d\u0438\u044f \u0437\u0430\u0434\u0430\u0447\u0438 \u043a\u043b\u0430\u0441\u0441\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u0442\u0435\u0441\u0442\u043e\u0432\u043e\u0439 \u0442\u043e\u0447\u043a\u0438<\/strong>, \u043d\u0443\u0436\u043d\u043e \u043d\u0430\u0439\u0442\u0438 \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 <u>\u0432\u0441\u0435\u0445<\/u> \u043a\u043b\u0430\u0441\u0441\u043e\u0432. \u0417\u0430\u0442\u0435\u043c \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043f\u043e\u0434\u0441\u0447\u0435\u0442\u0430 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0439 \u043e\u0442 \u0437\u0430\u0434\u0430\u043d\u043d\u043e\u0439 \u0442\u043e\u0447\u043a\u0438 \u0434\u043e \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u043a\u043b\u0430\u0441\u0441, \u0434\u043e \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e.<br \/>\u041d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u0435\u0442\u043e\u0434\u044b (\u0442\u0430\u043a\u0438\u0435, \u043a\u0430\u043a \u043c\u0435\u0442\u043e\u0434 -\u0431\u043b\u0438\u0436\u0430\u0439\u0448\u0438\u0445 \u0441\u043e\u0441\u0435\u0434\u0435\u0439, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u0443\u0434\u0435\u0442 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d \u0432 \u043f. 4) \u043f\u043e\u0434\u0440\u0430\u0437\u0443\u043c\u0435\u0432\u0430\u044e\u0442 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u0435 \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0439 \u043d\u0435 \u0434\u043e \u0446\u0435\u043d\u0442\u0440\u043e\u0438\u0434\u043e\u0432 \u043a\u043b\u0430\u0441\u0441\u043e\u0432, \u0430 \u0434\u043e \u0432\u0441\u0435\u0445 \u0442\u043e\u0447\u0435\u043a \u0432\u0441\u0435\u0445 \u043a\u043b\u0430\u0441\u0441\u043e\u0432.<\/p>\n<p>\u041f\u0435\u0440\u0435\u0434 \u0442\u0435\u043c, \u043a\u0430\u043a \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u044c \u043c\u0430\u0442\u0440\u0438\u0446\u0443 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0432\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u044f<strong>*<\/strong> \u0442\u043e\u0447\u0435\u043a \u043a\u043b\u0430\u0441\u0441\u0430 \u043f\u043e \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0430\u043c.<\/p>\n<details class=\"spoiler\">\n<summary>*<\/summary>\n<div class=\"spoiler__content\">\n<p>\u041d\u0430 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0435 \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u0435 \u043e\u0431\u044b\u0447\u043d\u043e \u043e\u0446\u0435\u043d\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u043a\u0430\u043a \u0441\u0440\u0435\u0434\u043d\u0435\u0435 \u0430\u0440\u0438\u0444\u043c\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435:<\/p>\n<p>\u0433\u0434\u0435  \u2014 \u0441\u0440\u0435\u0434\u043d\u0435\u0435 \u0430\u0440\u0438\u0444\u043c\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0442\u043e\u0447\u0435\u043a \u043a\u043b\u0430\u0441\u0441\u0430  \u043f\u043e  \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0443, \u2014 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0442\u043e\u0447\u0435\u043a \u0432 \u043a\u043b\u0430\u0441\u0441\u0435 ,  \u2014  \u043f\u0440\u0438\u0437\u043d\u0430\u043a \u0442\u043e\u0447\u043a\u0438 .<\/p>\n<p>\u0426\u0435\u043d\u0442\u0440\u043e\u0438\u0434  \u043a\u043b\u0430\u0441\u0441\u0430 :<\/p>\n<\/div>\n<\/details>\n<p><a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%9A%D0%BE%D0%B2%D0%B0%D1%80%D0%B8%D0%B0%D1%86%D0%B8%D1%8F\" rel=\"noopener noreferrer nofollow\"><strong>\u041a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u044f<\/strong><\/a> \u2014 \u044d\u0442\u043e \u0447\u0438\u0441\u043b\u0435\u043d\u043d\u043e\u0435 \u0432\u044b\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u0430 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u043d\u0442\u043d\u043e\u0441\u0442\u0438 \u0434\u0432\u0443\u0445 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u0442\u043e\u0447\u0435\u043a.<br \/>\u0421\u0432\u043e\u0439\u0441\u0442\u0432\u043e \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u043d\u0442\u043d\u043e\u0441\u0442\u0438 \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442, \u0447\u0442\u043e \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0438 \u0438\u043c\u0435\u044e\u0442 \u0442\u0435\u043d\u0434\u0435\u043d\u0446\u0438\u044e \u0438\u0437\u043c\u0435\u043d\u044f\u0442\u044c\u0441\u044f \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u043e (\u043a\u043e\u0432\u0430\u0440\u0438\u0430\u043d\u0442\u043d\u043e).<\/p>\n<p><a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%9A%D0%BE%D0%B2%D0%B0%D1%80%D0%B8%D0%B0%D1%86%D0%B8%D0%BE%D0%BD%D0%BD%D0%B0%D1%8F_%D0%BC%D0%B0%D1%82%D1%80%D0%B8%D1%86%D0%B0\" rel=\"noopener noreferrer nofollow\"><strong>\u041a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430<\/strong><\/a> \u0441\u043e\u0441\u0442\u043e\u0438\u0442 \u0438\u0437 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0439 \u043c\u0435\u0436\u0434\u0443 \u0432\u0441\u0435\u043c\u0438 \u043f\u0430\u0440\u0430\u043c\u0438 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432. \u0415\u0441\u043b\u0438 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u0440\u0430\u0432\u043d\u043e , \u0442\u043e \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u2014 \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0441\u0442\u0438 , \u0438\u043c\u0435\u044e\u0449\u0430\u044f \u0432\u0438\u0434:<\/p>\n<p><strong>\u042d\u043b\u0435\u043c\u0435\u043d\u0442\u044b \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b<\/strong> \u2014 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0438 \u2014 \u0434\u043b\u044f \u043d\u0430\u0431\u043e\u0440\u0430 \u0442\u043e\u0447\u0435\u043a \u0432\u044b\u0447\u0438\u0441\u043b\u044f\u044e\u0442\u0441\u044f \u043f\u043e \u0444\u043e\u0440\u043c\u0443\u043b\u0435 (\u043d\u0435\u0441\u043c\u0435\u0449\u0435\u043d\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u044f, \u0430\u043d\u0433\u043b. \u00absample covariance\u00bb):<\/p>\n<p>\u0433\u0434\u0435  \u0438  \u2014 \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u044f \u043f\u043e  \u0438  \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0430\u043c \u0442\u043e\u0447\u0435\u043a \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e.<\/p>\n<p>\u0424\u043e\u0440\u043c\u0443\u043b\u0443  \u043d\u0443\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u0432 \u0442\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435, \u0435\u0441\u043b\u0438 \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u044f \u0433\u0435\u043d\u0435\u0440\u0430\u043b\u044c\u043d\u043e\u0439 \u0441\u043e\u0432\u043e\u043a\u0443\u043f\u043d\u043e\u0441\u0442\u0438  \u0438  <em>\u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u0435\u043c\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430<\/em> \u043d\u0435\u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b. \u0415\u0441\u043b\u0438 \u0436\u0435 \u043e\u043d\u0438 \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b, \u0442\u043e \u0444\u043e\u0440\u043c\u0443\u043b\u0430 \u0438\u043c\u0435\u0435\u0442 \u0432\u0438\u0434 (\u0441\u043c\u0435\u0449\u0435\u043d\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u044f, \u0430\u043d\u0433\u043b. \u00abpopulation covariance\u00bb):<\/p>\n<p><strong>\u041a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u044f \u043e\u0431\u043b\u0430\u0434\u0430\u0435\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c\u0438 \u0432\u0430\u0436\u043d\u044b\u043c\u0438 \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u0430\u043c\u0438:<\/strong><\/p>\n<ol>\n<li>\n<p>\u0415\u0441\u043b\u0438 \u043f\u0440\u0438 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0435 \u043e\u0442 \u043e\u0434\u043d\u043e\u0439 \u0442\u043e\u0447\u043a\u0438 \u043a \u0434\u0440\u0443\u0433\u043e\u0439  \u0438  \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0438 \u0443\u0432\u0435\u043b\u0438\u0447\u0438\u0432\u0430\u044e\u0442\u0441\u044f (\u0443\u043c\u0435\u043d\u044c\u0448\u0430\u044e\u0442\u0441\u044f) \u0432\u043c\u0435\u0441\u0442\u0435, \u0442\u043e ;<\/p>\n<\/li>\n<li>\n<p>\u0415\u0441\u043b\u0438 \u043f\u0440\u0438 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0435 \u043e\u0442 \u043e\u0434\u043d\u043e\u0439 \u0442\u043e\u0447\u043a\u0438 \u043a \u0434\u0440\u0443\u0433\u043e\u0439  \u043f\u0440\u0438\u0437\u043d\u0430\u043a \u0443\u0432\u0435\u043b\u0438\u0447\u0438\u0432\u0430\u0435\u0442\u0441\u044f, \u0430  \u0443\u043c\u0435\u043d\u044c\u0448\u0430\u0435\u0442\u0441\u044f (\u0438\u043b\u0438 \u043d\u0430\u043e\u0431\u043e\u0440\u043e\u0442), \u0442\u043e ;<\/p>\n<\/li>\n<li>\n<p>\u0415\u0441\u043b\u0438 \u043f\u0440\u0438 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0435 \u043e\u0442 \u043e\u0434\u043d\u043e\u0439 \u0442\u043e\u0447\u043a\u0438 \u043a \u0434\u0440\u0443\u0433\u043e\u0439  \u0438  \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0438 \u0438\u0437\u043c\u0435\u043d\u044f\u044e\u0442\u0441\u044f \u043d\u0435\u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e, \u0442\u043e (\u043e\u0431\u0440\u0430\u0442\u043d\u043e\u0435 \u0443\u0442\u0432\u0435\u0440\u0436\u0434\u0435\u043d\u0438\u0435 \u0432 \u043e\u0431\u0449\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043d\u0435\u0432\u0435\u0440\u043d\u043e<strong>*<\/strong>).<\/p>\n<\/li>\n<li>\n<p>\u041a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u044f \u0441\u0438\u043c\u043c\u0435\u0442\u0440\u0438\u0447\u043d\u0430: .<\/p>\n<\/li>\n<li>\n<p>\u041d\u0435\u0440\u0430\u0432\u0435\u043d\u0441\u0442\u0432\u043e \u041a\u043e\u0448\u0438 \u2014 \u0411\u0443\u043d\u044f\u043a\u043e\u0432\u0441\u043a\u043e\u0433\u043e: .<\/p>\n<\/li>\n<\/ol>\n<details class=\"spoiler\">\n<summary>*<\/summary>\n<div class=\"spoiler__content\">\n<p>\u041f\u0443\u0441\u0442\u044c  \u2014 \u0440\u0430\u0432\u043d\u043e\u043c\u0435\u0440\u043d\u043e \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u0430\u044f \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u0430\u044f \u0432\u0435\u043b\u0438\u0447\u0438\u043d\u0430 \u0432  \u0438 .<br \/> \u0438  \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u044b, \u043d\u043e:<\/p>\n<p>\u0433\u0434\u0435  \u2014 \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u0435.<\/p>\n<\/div>\n<\/details>\n<p>\u041f\u0435\u0440\u0432\u044b\u0435 \u0442\u0440\u0438 \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u0430 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0438 \u043f\u0440\u043e\u0438\u043b\u043b\u044e\u0441\u0442\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u044b \u043d\u0430 \u0440\u0438\u0441\u0443\u043d\u043a\u0435 2.<\/p>\n<figure class=\"full-width\"><figcaption>\u0420\u0438\u0441\u0443\u043d\u043e\u043a 2. \u0417\u043d\u0430\u043a \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0438 \u0434\u0432\u0443\u0445 \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u044b\u0445 \u0432\u0435\u043b\u0438\u0447\u0438\u043d X \u0438 Y<\/figcaption><\/figure>\n<p>\u0422\u0430\u043a \u043a\u0430\u043a \u0434\u043b\u044f \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u043d\u0430\u0439\u0442\u0438 \u043e\u0431\u0440\u0430\u0442\u043d\u0443\u044e \u043a  \u043c\u0430\u0442\u0440\u0438\u0446\u0443, \u0430 \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043e\u0431\u0440\u0430\u0442\u0438\u043c\u0430 \u0442\u043e\u0433\u0434\u0430 \u0438 \u0442\u043e\u043b\u044c\u043a\u043e \u0442\u043e\u0433\u0434\u0430, \u043a\u043e\u0433\u0434\u0430 \u043e\u043d\u0430 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043a\u0432\u0430\u0434\u0440\u0430\u0442\u043d\u043e\u0439 \u0438 \u043d\u0435\u0432\u044b\u0440\u043e\u0436\u0434\u0435\u043d\u043d\u043e\u0439 (\u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u0435\u043b\u044c \u043d\u0435 \u0440\u0430\u0432\u0435\u043d \u043d\u0443\u043b\u044e), \u0442\u043e <u>\u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0438 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e, \u0447\u0442\u043e\u0431\u044b \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u0435\u043b\u044c \u043c\u0430\u0442\u0440\u0438\u0446\u044b<\/u>  <u>\u043d\u0435 \u0440\u0430\u0432\u043d\u044f\u043b\u0441\u044f \u043d\u0443\u043b\u044e<\/u>. <strong>\u041e\u0434\u043d\u0430\u043a\u043e \u0442\u0430\u043a\u043e\u0435 \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u0435 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0441\u0435\u0440\u044c\u0435\u0437\u043d\u044b\u043c \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u0435\u043c.<\/strong><\/p>\n<p><strong>\u0418\u0437\u0432\u0435\u0441\u0442\u043d\u043e, \u0447\u0442\u043e \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043d\u0435\u043e\u0431\u0440\u0430\u0442\u0438\u043c\u0430 \u0432 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0445 <u>\u0447\u0430\u0441\u0442\u043d\u044b\u0445<\/u> \u0441\u043b\u0443\u0447\u0430\u044f\u0445:<\/strong><br \/><strong>1. <\/strong>\u0415\u0441\u043b\u0438 \u043f\u043e \u043a\u0430\u043a\u043e\u043c\u0443-\u043b\u0438\u0431\u043e \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0443  \u0432\u0441\u0435 \u0442\u043e\u0447\u043a\u0438 \u043a\u043b\u0430\u0441\u0441\u0430 \u0438\u043c\u0435\u044e\u0442 \u043e\u0434\u043d\u043e \u0438 \u0442\u043e \u0436\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0438, \u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e, \u0441\u0440\u0435\u0434\u043d\u0435\u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u0435 \u043f\u043e \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0443  \u0440\u0430\u0432\u043d\u043e \u043d\u0443\u043b\u044e.<br \/>\u041f\u0440\u0438\u043c\u0435\u0440: .<br \/><strong>2. <\/strong>\u0415\u0441\u043b\u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u0438 \u0432\u0441\u0435\u0445 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u044b (, \u00abperfect covariance\u00bb). \u041f\u0440\u0438\u043c\u0435\u0440\u044b:<br \/> \u2014 \u0438\u0434\u0435\u0430\u043b\u044c\u043d\u0430\u044f \u043f\u043e\u043b\u043e\u0436\u0438\u0442\u0435\u043b\u044c\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u044f;<br \/> \u2014 \u0438\u0434\u0435\u0430\u043b\u044c\u043d\u0430\u044f \u043e\u0442\u0440\u0438\u0446\u0430\u0442\u0435\u043b\u044c\u043d\u0430\u044f \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u044f.<br \/><strong>3. <\/strong>\u0415\u0441\u043b\u0438 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0442\u043e\u0447\u0435\u043a \u0432 \u043a\u043b\u0430\u0441\u0441\u0435  \u043c\u0435\u043d\u044c\u0448\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u0430 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432  \u043f\u043b\u044e\u0441 :<\/p>\n<p>\u0415\u0441\u0442\u044c \u0438 \u0434\u0440\u0443\u0433\u0438\u0435 \u0441\u043b\u0443\u0447\u0430\u0438.<\/p>\n<p><strong>\u0427\u0442\u043e \u0434\u0435\u043b\u0430\u0442\u044c, \u0435\u0441\u043b\u0438 \u043a\u043e\u0432\u0430\u0440\u0438\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043d\u0435\u043e\u0431\u0440\u0430\u0442\u0438\u043c\u0430?<\/strong><br \/>\u0415\u0434\u0438\u043d\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u043e\u0433\u043e \u043f\u043e\u0434\u0445\u043e\u0434\u0430 \u043d\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442.<br \/>\u041e\u0434\u043d\u0430\u043a\u043e \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 \u0446\u0435\u043b\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c \u0438\u0441\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u0438\u0439, \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u043d\u0430\u044f \u043d\u0430 <a href=\"https:\/\/en.wikipedia.org\/wiki\/Regularization_(mathematics)\" rel=\"noopener noreferrer nofollow\">\u0440\u0435\u0433\u0443\u043b\u044f\u0440\u0438\u0437\u0430\u0446\u0438\u044e<\/a> \u044d\u0442\u043e\u0439 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b.<br \/>\u0422\u0440\u0438 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u044b\u0435 \u0432\u044b\u0448\u0435 \u0438 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0434\u0440\u0443\u0433\u0438\u0435 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b \u043c\u043e\u0433\u0443\u0442 \u0431\u044b\u0442\u044c \u0440\u0435\u0448\u0435\u043d\u044b \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c\u0438 \u0441\u043f\u043e\u0441\u043e\u0431\u0430\u043c\u0438:<\/p>\n<details class=\"spoiler\">\n<summary>1. \u0414\u0432\u0430 \u0441\u043f\u043e\u0441\u043e\u0431\u0430 \u0434\u043b\u044f \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u0441\u043b\u0443\u0447\u0430\u044f<\/summary>\n<div class=\"spoiler__content\">\n<ol>\n<li>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0431\u043e\u043b\u044c\u0448\u0435 \u0442\u043e\u0447\u0435\u043a \u0432 \u043a\u043b\u0430\u0441\u0441, \u0447\u0442\u043e\u0431\u044b \u0441\u0440\u0435\u0434\u043d\u0435\u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u0435 (<em>\u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0447\u043d\u043e \u2014 \u0434\u0438\u0441\u043f\u0435\u0440\u0441\u0438\u044f<\/em>) \u043f\u043e \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0443  \u043d\u0435 \u0440\u0430\u0432\u043d\u044f\u043b\u043e\u0441\u044c \u043d\u0443\u043b\u044e.<\/p>\n<\/li>\n<li>\n<p>\u0423\u0431\u0440\u0430\u0442\u044c \u043f\u0440\u0438\u0437\u043d\u0430\u043a  \u0438\u0437 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u0438\u044f.<\/p>\n<\/li>\n<\/ol>\n<\/div>\n<\/details>\n<details class=\"spoiler\">\n<summary>2. \u041c\u0435\u0442\u0440\u0438\u043a\u0430 \u0415\u0432\u043a\u043b\u0438\u0434\u0430 \u2014 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430<\/summary>\n<div class=\"spoiler__content\">\n<p>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043c\u043e\u0434\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044e \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0434\u043b\u044f \u0432\u0442\u043e\u0440\u043e\u0433\u043e \u0441\u043b\u0443\u0447\u0430\u044f), \u2014 \u043c\u0435\u0442\u0440\u0438\u043a\u0443 \u0415\u0432\u043a\u043b\u0438\u0434\u0430-\u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430 (<a href=\"http:\/\/www.isa.ru\/aidt\/images\/documents\/2012-01\/81_89.pdf\" rel=\"noopener noreferrer nofollow\">\u0438\u0437 \u0441\u0442\u0430\u0442\u044c\u0438<\/a>):<\/p>\n<p>\u0433\u0434\u0435  \u2014 \u0435\u0434\u0438\u043d\u0438\u0447\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u0442\u043e\u0433\u043e \u0436\u0435 \u0440\u0430\u0437\u043c\u0435\u0440\u0430, \u0447\u0442\u043e \u0438 .<\/p>\n<p>\u042d\u0442\u0430 \u043c\u0435\u0442\u0440\u0438\u043a\u0430 \u0443\u0441\u0442\u0440\u0430\u043d\u044f\u0435\u0442 \u043d\u0435\u0434\u043e\u0441\u0442\u0430\u0442\u043e\u043a \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u041c\u0430\u0445\u0430\u043b\u0430\u043d\u043e\u0431\u0438\u0441\u0430, \u043f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u044b \u0435\u0451 \u0433\u043b\u0430\u0432\u043d\u043e\u0439 \u0434\u0438\u0430\u0433\u043e\u043d\u0430\u043b\u0438 \u0432\u0441\u0435\u0433\u0434\u0430 \u0431\u043e\u043b\u044c\u0448\u0435 \u043d\u0443\u043b\u044f.<\/p>\n<\/div>\n<\/details>\n<details class=\"spoiler\">\n<summary>3. \u041f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u044b\u0439 \u043f\u043e\u0434\u0445\u043e\u0434<\/summary>\n<div class=\"spoiler__content\">\n<p>\u041f\u043e\u043c\u0438\u043c\u043e \u043e\u0431\u0440\u0430\u0442\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 <a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%9F%D1%81%D0%B5%D0%B2%D0%B4%D0%BE%D0%BE%D0%B1%D1%80%D0%B0%D1%82%D0%BD%D0%B0%D1%8F_%D0%BC%D0%B0%D1%82%D1%80%D0%B8%D1%86%D0%B0\" rel=\"noopener noreferrer nofollow\">\u043f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430<\/a>.<br \/>\u041e\u043f\u0435\u0440\u0430\u0446\u0438\u044f  \u2014 \u043f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u043e\u0435 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u043c\u0430\u0442\u0440\u0438\u0446\u044b (<a href=\"https:\/\/en.wikipedia.org\/wiki\/Moore%E2%80%93Penrose_inverse\" rel=\"noopener noreferrer nofollow\">\u043e\u0431\u0440\u0430\u0442\u043d\u043e\u0435 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u041c\u0443\u0440\u0430 \u2014 \u041f\u0435\u043d\u0440\u043e\u0443\u0437\u0430<\/a>).<br \/>\u0424\u0443\u043d\u043a\u0446\u0438\u0438 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u043f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b:<br \/>\u2014 <a href=\"https:\/\/www.rdocumentation.org\/packages\/MASS\/versions\/7.3-53\/topics\/ginv\" rel=\"noopener noreferrer nofollow\">ginv<\/a> \u0432 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0435 MASS (R);<br \/>\u2014 <a href=\"https:\/\/pyprog.pro\/linear_algebra_functions\/linalg_pinv.html\" rel=\"noopener noreferrer nofollow\">pinv<\/a> \u0432 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0435 numpy (Python);<br \/>\u2014 <a href=\"https:\/\/www.mathworks.com\/help\/matlab\/ref\/pinv.html\" rel=\"noopener noreferrer nofollow\">pinv<\/a> \u0432 MATLAB;<br \/>\u2014 <a href=\"https:\/\/octave.sourceforge.io\/octave\/function\/pinv.html\" rel=\"noopener noreferrer nofollow\">pinv<\/a> \u0432 Octave.<\/p>\n<p>\u041f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430, \u043e\u0431\u043e\u0437\u043d\u0430\u0447\u0430\u0435\u043c\u0430\u044f , (\u0432 \u043e\u0442\u0440\u044b\u0432\u0435 \u043e\u0442 \u0442\u0435\u043c\u044b \u0441\u0442\u0430\u0442\u044c\u0438) <a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%9C%D0%B5%D1%82%D0%BE%D0%B4_%D0%BD%D0%B0%D0%B8%D0%BC%D0%B5%D0%BD%D1%8C%D1%88%D0%B8%D1%85_%D0%BA%D0%B2%D0%B0%D0%B4%D1%80%D0%B0%D1%82%D0%BE%D0%B2#%D0%9F%D1%80%D0%B8%D0%BC%D0%B5%D1%80_%E2%80%94_%D1%81%D0%B8%D1%81%D1%82%D0%B5%D0%BC%D0%B0_%D0%BB%D0%B8%D0%BD%D0%B5%D0%B9%D0%BD%D1%8B%D1%85_%D1%83%D1%80%D0%B0%D0%B2%D0%BD%D0%B5%D0%BD%D0%B8%D0%B9\" rel=\"noopener noreferrer nofollow\">\u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442\u0441\u044f \u043a\u0430\u043a<\/a> \u043c\u0430\u0442\u0440\u0438\u0446\u0430, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u00ab\u0440\u0435\u0448\u0430\u0435\u0442\u00bb \u0437\u0430\u0434\u0430\u0447\u0443 \u043d\u0430\u0438\u043c\u0435\u043d\u044c\u0448\u0438\u0445 \u043a\u0432\u0430\u0434\u0440\u0430\u0442\u043e\u0432: , \u0433\u0434\u0435  \u2014 \u043f\u0440\u044f\u043c\u043e\u0443\u0433\u043e\u043b\u044c\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0447\u0438\u0441\u043b\u043e \u0441\u0442\u0440\u043e\u043a (\u0443\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u0439) \u0431\u043e\u043b\u044c\u0448\u0435 \u0447\u0438\u0441\u043b\u0430 \u0441\u0442\u043e\u043b\u0431\u0446\u043e\u0432 (\u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445); \u0442\u0430\u043a\u0430\u044f \u0441\u0438\u0441\u0442\u0435\u043c\u0430 \u0443\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u0439 \u0432 \u043e\u0431\u0449\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043d\u0435 \u0438\u043c\u0435\u0435\u0442 \u0440\u0435\u0448\u0435\u043d\u0438\u044f, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u044d\u0442\u0443 \u0441\u0438\u0441\u0442\u0435\u043c\u0443 \u043c\u043e\u0436\u043d\u043e \u00ab\u0440\u0435\u0448\u0438\u0442\u044c\u00bb \u0442\u043e\u043b\u044c\u043a\u043e \u0432 \u0441\u043c\u044b\u0441\u043b\u0435 \u0432\u044b\u0431\u043e\u0440\u0430 \u0442\u0430\u043a\u043e\u0433\u043e \u0432\u0435\u043a\u0442\u043e\u0440\u0430 , \u0447\u0442\u043e\u0431\u044b \u043c\u0438\u043d\u0438\u043c\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u00ab\u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435\u00bb \u043c\u0435\u0436\u0434\u0443 \u0432\u0435\u043a\u0442\u043e\u0440\u0430\u043c\u0438  \u0438 .<br \/>\u041f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043d\u0430\u0439\u0434\u0435\u043d\u0430 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e <a href=\"http:\/\/www.machinelearning.ru\/wiki\/index.php?title=%D0%A1%D0%B8%D0%BD%D0%B3%D1%83%D0%BB%D1%8F%D1%80%D0%BD%D0%BE%D0%B5_%D1%80%D0%B0%D0%B7%D0%BB%D0%BE%D0%B6%D0%B5%D0%BD%D0%B8%D0%B5\" rel=\"noopener noreferrer nofollow\">\u0441\u0438\u043d\u0433\u0443\u043b\u044f\u0440\u043d\u043e\u0433\u043e \u0440\u0430\u0437\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u044b<\/a>. \u041f\u0440\u0438\u0447\u0435\u043c \u0434\u043b\u044f \u043b\u044e\u0431\u043e\u0439 \u043c\u0430\u0442\u0440\u0438\u0446\u044b \u043d\u0430\u0434 \u0432\u0435\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u043c\u0438 \u0447\u0438\u0441\u043b\u0430\u043c\u0438 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 \u043f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430 \u0438 \u043f\u0440\u0438\u0442\u043e\u043c \u0442\u043e\u043b\u044c\u043a\u043e \u043e\u0434\u043d\u0430.<br \/>\u0422\u0430\u043a\u0436\u0435 \u0432\u0430\u0436\u043d\u043e \u043e\u0442\u043c\u0435\u0442\u0438\u0442\u044c \u0442\u043e\u0442 \u0444\u0430\u043a\u0442, \u0447\u0442\u043e \u0435\u0441\u043b\u0438 \u043e\u0431\u0440\u0430\u0442\u043d\u0443\u044e \u043c\u0430\u0442\u0440\u0438\u0446\u0443  \u043c\u043e\u0436\u043d\u043e \u043d\u0430\u0439\u0442\u0438 (\u0438\u043d\u0430\u0447\u0435 \u0433\u043e\u0432\u043e\u0440\u044f, \u0438\u0441\u0445\u043e\u0434\u043d\u0430\u044f \u043c\u0430\u0442\u0440\u0438\u0446\u0430  \u2014 \u043a\u0432\u0430\u0434\u0440\u0430\u0442\u043d\u0430\u044f \u0438 \u043d\u0435\u0432\u044b\u0440\u043e\u0436\u0434\u0435\u043d\u043d\u0430\u044f), \u0442\u043e \u043f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u0430\u044f \u0431\u0443\u0434\u0435\u0442 \u0441  \u0441\u043e\u0432\u043f\u0430\u0434\u0430\u0442\u044c: .<\/p>\n<p>\u0424\u043e\u0440\u043c\u0443\u043b\u0430 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u044f:<\/p>\n<p>\u041f\u0441\u0435\u0432\u0434\u043e\u043e\u0431\u0440\u0430\u0442\u043d\u044b\u0439 \u043f\u043e\u0434\u0445\u043e\u0434 \u0438\u043d\u043e\u0433\u0434\u0430 \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u044e\u0442 \u0432<\/p>\n<p><\/br><\/p>\n<p><\/br><\/br><\/br><\/br><\/br><\/p>\n<\/div>\n<\/details>\n<p><\/br><\/br><\/p>\n<p><\/br><\/br><\/br><\/br><\/br><\/br><\/br><\/p>\n<\/details>\n<\/p>\n<p><\/br><\/br><\/br><\/p>\n<\/p>\n<\/hr>\n<\/p>\n<\/hr>\n<p><\/br><\/br><\/br><\/br><\/br><\/br><\/br><\/br><\/br><\/br><\/br><\/p>\n<\/div>\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-322363","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/322363","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=322363"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/322363\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=322363"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=322363"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=322363"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}