diff --git a/README.md b/README.md index d49a0f61..3a8db2bb 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,6 @@ +<<<<<<< HEAD # WUT_Computer_Science This repository aims to consolidate every single project I did solo during my Computer Science course on Warsaw University of Technology +======= +# elacProjectA +>>>>>>> elacProjectA/main diff --git a/project.aux b/project.aux new file mode 100644 index 00000000..dab0405b --- /dev/null +++ b/project.aux @@ -0,0 +1,32 @@ +\relax +\@writefile{toc}{\contentsline {section}{\numberline {1.1}Regular expression}{1}{}\protected@file@percent } +\@writefile{toc}{\contentsline {section}{\numberline {1.2}Examples of accepted strings}{1}{}\protected@file@percent } +\@writefile{toc}{\contentsline {section}{\numberline {1.3}Building NFA using Thompson construction algorithm}{1}{}\protected@file@percent } +\@writefile{lof}{\contentsline {figure}{\numberline {1.1}{\ignorespaces Operator 'a'}}{1}{}\protected@file@percent } +\newlabel{fig:operatorA}{{1.1}{1}} +\@writefile{lof}{\contentsline {figure}{\numberline {1.2}{\ignorespaces Operator 'b'}}{1}{}\protected@file@percent } +\newlabel{fig:operatorB}{{1.2}{1}} +\@writefile{lof}{\contentsline {figure}{\numberline {1.3}{\ignorespaces Operator '$a^*$'}}{1}{}\protected@file@percent } +\newlabel{fig:operatorAstar}{{1.3}{1}} +\@writefile{lof}{\contentsline {figure}{\numberline {1.4}{\ignorespaces Operator '$ba^*$'}}{2}{}\protected@file@percent } +\newlabel{fig:operatorbastar}{{1.4}{2}} +\@writefile{lof}{\contentsline {figure}{\numberline {1.5}{\ignorespaces Operator '$ba^*b$'}}{2}{}\protected@file@percent } +\newlabel{fig:operatorbastarb}{{1.5}{2}} +\@writefile{lof}{\contentsline {figure}{\numberline {1.6}{\ignorespaces Operator '$bb$'}}{2}{}\protected@file@percent } +\newlabel{fig:operatorbb}{{1.6}{2}} +\@writefile{lof}{\contentsline {figure}{\numberline {1.7}{\ignorespaces Operator '$bba^*$'}}{2}{}\protected@file@percent } +\newlabel{fig:operatorbbastar}{{1.7}{2}} +\@writefile{lof}{\contentsline {figure}{\numberline {1.8}{\ignorespaces Operator '$a^*+ba^*b$'}}{2}{}\protected@file@percent } +\newlabel{fig:operatorastarOrbastarb}{{1.8}{2}} +\@writefile{lof}{\contentsline {figure}{\numberline {1.9}{\ignorespaces Operator '$a^*+ba^*b + bba^*$'}}{3}{}\protected@file@percent } +\newlabel{fig:final}{{1.9}{3}} +\@writefile{lof}{\contentsline {figure}{\numberline {1.10}{\ignorespaces Operator '$a^*+ba^*b + bba^*$' - changed names of states}}{3}{}\protected@file@percent } +\newlabel{fig:finalBetter}{{1.10}{3}} +\@writefile{toc}{\contentsline {section}{\numberline {1.4}Transforming NFA into DFA using subset algorithm}{4}{}\protected@file@percent } +\@writefile{toc}{\contentsline {subsection}{\numberline {1.4.1}State table}{4}{}\protected@file@percent } +\@writefile{lof}{\contentsline {figure}{\numberline {1.11}{\ignorespaces DFA graph before minimalization}}{5}{}\protected@file@percent } +\newlabel{dfaNominimalization}{{1.11}{5}} +\@writefile{toc}{\contentsline {section}{\numberline {1.5}Constructing minimal state DFA}{5}{}\protected@file@percent } +\@writefile{lof}{\contentsline {figure}{\numberline {1.12}{\ignorespaces DFA graph after minimalization}}{6}{}\protected@file@percent } +\newlabel{dfaMinimalization}{{1.12}{6}} +\gdef \@abspage@last{7} diff --git a/project.fdb_latexmk b/project.fdb_latexmk new file mode 100644 index 00000000..236a52b6 --- /dev/null +++ b/project.fdb_latexmk @@ -0,0 +1,133 @@ +# Fdb version 3 +["pdflatex"] 1637160557 "project.tex" "project.pdf" "project" 1637160560 + "/etc/texmf/web2c/texmf.cnf" 1624878795 475 c0e671620eb5563b2130f56340a5fde8 "" + "/usr/share/texlive/texmf-dist/fonts/map/fontname/texfonts.map" 1577235249 3524 cb3e574dea2d1052e39280babc910dc8 "" + "/usr/share/texlive/texmf-dist/fonts/tfm/public/amsfonts/cmextra/cmex7.tfm" 1246382020 1004 54797486969f23fa377b128694d548df "" + "/usr/share/texlive/texmf-dist/fonts/tfm/public/amsfonts/cmextra/cmex8.tfm" 1246382020 988 bdf658c3bfc2d96d3c8b02cfc1c94c20 "" + "/usr/share/texlive/texmf-dist/fonts/tfm/public/cm/cmbx12.tfm" 1136768653 1324 c910af8c371558dc20f2d7822f66fe64 "" + "/usr/share/texlive/texmf-dist/fonts/tfm/public/cm/cmex10.tfm" 1136768653 992 662f679a0b3d2d53c1b94050fdaa3f50 "" + "/usr/share/texlive/texmf-dist/fonts/tfm/public/cm/cmmi12.tfm" 1136768653 1524 4414a8315f39513458b80dfc63bff03a "" + "/usr/share/texlive/texmf-dist/fonts/tfm/public/cm/cmmi6.tfm" 1136768653 1512 f21f83efb36853c0b70002322c1ab3ad "" + "/usr/share/texlive/texmf-dist/fonts/tfm/public/cm/cmmi8.tfm" 1136768653 1520 eccf95517727cb11801f4f1aee3a21b4 "" + "/usr/share/texlive/texmf-dist/fonts/tfm/public/cm/cmr12.tfm" 1136768653 1288 655e228510b4c2a1abe905c368440826 "" + "/usr/share/texlive/texmf-dist/fonts/tfm/public/cm/cmr17.tfm" 1136768653 1292 296a67155bdbfc32aa9c636f21e91433 "" + "/usr/share/texlive/texmf-dist/fonts/tfm/public/cm/cmr6.tfm" 1136768653 1300 b62933e007d01cfd073f79b963c01526 "" + "/usr/share/texlive/texmf-dist/fonts/tfm/public/cm/cmr8.tfm" 1136768653 1292 21c1c5bfeaebccffdb478fd231a0997d "" + "/usr/share/texlive/texmf-dist/fonts/tfm/public/cm/cmsy10.tfm" 1136768653 1124 6c73e740cf17375f03eec0ee63599741 "" + "/usr/share/texlive/texmf-dist/fonts/tfm/public/cm/cmsy6.tfm" 1136768653 1116 933a60c408fc0a863a92debe84b2d294 "" + "/usr/share/texlive/texmf-dist/fonts/tfm/public/cm/cmsy8.tfm" 1136768653 1120 8b7d695260f3cff42e636090a8002094 "" + "/usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmbx12.pfb" 1248133631 32080 340ef9bf63678554ee606688e7b5339d "" + "/usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmmi10.pfb" 1248133631 36299 5f9df58c2139e7edcf37c8fca4bd384d "" + "/usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmmi7.pfb" 1248133631 36281 c355509802a035cadc5f15869451dcee "" + "/usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmr10.pfb" 1248133631 35752 024fb6c41858982481f6968b5fc26508 "" + "/usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmr12.pfb" 1248133631 32722 d7379af29a190c3f453aba36302ff5a9 "" + "/usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmr17.pfb" 1248133631 32362 179c33bbf43f19adbb3825bb4e36e57a "" + "/usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmr7.pfb" 1248133631 32762 224316ccc9ad3ca0423a14971cfa7fc1 "" + "/usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmsy10.pfb" 1248133631 32569 5e5ddc8df908dea60932f3c484a54c0d "" + "/usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmsy7.pfb" 1248133631 32716 08e384dc442464e7285e891af9f45947 "" + "/usr/share/texlive/texmf-dist/tex/context/base/mkii/supp-pdf.mkii" 1461363279 71627 94eb9990bed73c364d7f53f960cc8c5b "" + "/usr/share/texlive/texmf-dist/tex/generic/iftex/iftex.sty" 1583617216 6501 4011d89d9621e0b0901138815ba5ff29 "" + "/usr/share/texlive/texmf-dist/tex/generic/infwarerr/infwarerr.sty" 1575499628 8356 7bbb2c2373aa810be568c29e333da8ed "" + "/usr/share/texlive/texmf-dist/tex/generic/kvdefinekeys/kvdefinekeys.sty" 1576878844 5412 d5a2436094cd7be85769db90f29250a6 "" + "/usr/share/texlive/texmf-dist/tex/generic/kvsetkeys/kvsetkeys.sty" 1576624944 13807 952b0226d4efca026f0e19dd266dcc22 "" + "/usr/share/texlive/texmf-dist/tex/generic/ltxcmds/ltxcmds.sty" 1600895880 17859 4409f8f50cd365c68e684407e5350b1b "" + "/usr/share/texlive/texmf-dist/tex/generic/pdftexcmds/pdftexcmds.sty" 1593379760 20089 80423eac55aa175305d35b49e04fe23b "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcore.code.tex" 1601326656 992 855ff26741653ab54814101ca36e153c "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcorearrows.code.tex" 1601326656 43820 1fef971b75380574ab35a0d37fd92608 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreexternal.code.tex" 1601326656 19324 f4e4c6403dd0f1605fd20ed22fa79dea "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcoregraphicstate.code.tex" 1601326656 6038 ccb406740cc3f03bbfb58ad504fe8c27 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreimage.code.tex" 1601326656 6944 e12f8f7a7364ddf66f93ba30fb3a3742 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcorelayers.code.tex" 1601326656 4883 42daaf41e27c3735286e23e48d2d7af9 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreobjects.code.tex" 1601326656 2544 8c06d2a7f0f469616ac9e13db6d2f842 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepathconstruct.code.tex" 1601326656 44195 5e390c414de027626ca5e2df888fa68d "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepathprocessing.code.tex" 1601326656 17311 2ef6b2e29e2fc6a2fc8d6d652176e257 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepathusage.code.tex" 1601326656 21302 788a79944eb22192a4929e46963a3067 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepatterns.code.tex" 1601326656 9690 01feb7cde25d4293ef36eef45123eb80 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepoints.code.tex" 1601326656 33335 dd1fa4814d4e51f18be97d88bf0da60c "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcorequick.code.tex" 1601326656 2965 4c2b1f4e0826925746439038172e5d6f "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcorerdf.code.tex" 1601326656 5196 2cc249e0ee7e03da5f5f6589257b1e5b "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcorescopes.code.tex" 1601326656 20726 d4c8db1e2e53b72721d29916314a22ea "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreshade.code.tex" 1601326656 35249 abd4adf948f960299a4b3d27c5dddf46 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcoretransformations.code.tex" 1601326656 21989 fdc867d05d228316de137a9fc5ec3bbe "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcoretransparency.code.tex" 1601326656 8893 e851de2175338fdf7c17f3e091d94618 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibraryautomata.code.tex" 1601326656 3986 90961e1e824ee04363a83e4b53cbd527 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrarypositioning.code.tex" 1601326656 3937 3f208572dd82c71103831da976d74f1a "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibraryshapes.multipart.code.tex" 1601326656 919 938802205ca20d7c36615aabc4d34be2 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrarytopaths.code.tex" 1608933718 11518 738408f795261b70ce8dd47459171309 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/frontendlayer/tikz/tikz.code.tex" 1609106292 188275 555994923a0cb0c4aff9710e303272bb "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/libraries/pgflibraryarrows.meta.code.tex" 1601326656 58801 1e750fb0692eb99aaac45698bbec96b1 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/libraries/pgflibraryplothandlers.code.tex" 1601326656 32995 ac577023e12c0e4bd8aa420b2e852d1a "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/libraries/shapes/pgflibraryshapes.multipart.code.tex" 1601326656 62281 aff261ef10ba6cbe8e3c872a38c05a61 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfint.code.tex" 1557692582 3063 8c415c68a0f3394e45cfeca0b65f6ee6 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmath.code.tex" 1601326656 521 8e224a7af69b7fee4451d1bf76b46654 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathcalc.code.tex" 1601326656 13391 84d29568c13bdce4133ab4a214711112 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathfloat.code.tex" 1601326656 104935 184ed87524e76d4957860df4ce0cd1c3 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.base.code.tex" 1601326656 10165 cec5fa73d49da442e56efc2d605ef154 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.basic.code.tex" 1601326656 28178 41c17713108e0795aac6fef3d275fbca "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.code.tex" 1601326656 9989 c55967bf45126ff9b061fa2ca0c4694f "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.comparison.code.tex" 1601326656 3865 ac538ab80c5cf82b345016e474786549 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.integerarithmetics.code.tex" 1557692582 3177 27d85c44fbfe09ff3b2cf2879e3ea434 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.misc.code.tex" 1601326656 10925 139ac69ce3e9a1892add56d0b818cf97 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.random.code.tex" 1608933718 7854 4176998eeefd8745ac6d2d4bd9c98451 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.round.code.tex" 1601326656 3379 781797a101f647bab82741a99944a229 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.trigonometric.code.tex" 1601326656 92405 f515f31275db273f97b9d8f52e1b0736 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathparser.code.tex" 1601326656 37376 11cd75aac3da1c1b152b2848f30adc14 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathutil.code.tex" 1601326656 8471 c2883569d03f69e8e1cabfef4999cfd7 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/modules/pgfmodulematrix.code.tex" 1601326656 21201 08d231a2386e2b61d64641c50dc15abd "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/modules/pgfmoduleplot.code.tex" 1601326656 16121 346f9013d34804439f7436ff6786cef7 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/modules/pgfmoduleshapes.code.tex" 1606168878 43260 c5ced91ac9ecf66ab0674d57bda14c1f "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/pgf.revision.tex" 1609106292 465 311958b39a263956b78fd69c4bc8a85c "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgf.cfg" 1601326656 926 2963ea0dcf6cc6c0a770b69ec46a477b "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgfsys-common-pdf.def" 1601326656 5546 f3f24d7898386cb7daac70bdd2c4d6dc "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgfsys-pdftex.def" 1601326656 12601 4786e597516eddd82097506db7cfa098 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgfsys.code.tex" 1601326656 60544 7aef020a49f066dc86a26e7719af2a98 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgfsysprotocol.code.tex" 1601326656 1896 b8e0ca0ac371d74c0ca05583f6313c91 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgfsyssoftpath.code.tex" 1601326656 7778 53c8b5623d80238f6a20aa1df1868e63 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgffor.code.tex" 1606168878 23997 a4bed72405fa644418bea7eac2887006 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfkeys.code.tex" 1606168878 36938 2b5b0039ae51cc081ebb25d84b8a3408 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfkeysfiltered.code.tex" 1601326656 37431 9abe862035de1b29c7a677f3205e3d9f "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfrcs.code.tex" 1601326656 4494 af17fb7efeafe423710479858e42fa7e "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfutil-common-lists.tex" 1601326656 7251 fb18c67117e09c64de82267e12cd8aa4 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfutil-common.tex" 1601326656 28579 1cdb9cf41947e1e5889d97a41f9bb448 "" + "/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfutil-latex.def" 1606168878 6860 2503857fc7e280acd60acdfa6c8c90c4 "" + "/usr/share/texlive/texmf-dist/tex/latex/amsmath/amsbsy.sty" 1523134290 2211 ca7ce284ab93c8eecdc6029dc5ccbd73 "" + "/usr/share/texlive/texmf-dist/tex/latex/amsmath/amsgen.sty" 1523134290 4161 7f6eb9092061a11f87d08ed13515b48d "" + "/usr/share/texlive/texmf-dist/tex/latex/amsmath/amsmath.sty" 1601675358 87353 2c21ff5f2e32e1bf714e600924d810db "" + "/usr/share/texlive/texmf-dist/tex/latex/amsmath/amsopn.sty" 1523134290 4116 32e6abd27229755a83a8b7f18e583890 "" + "/usr/share/texlive/texmf-dist/tex/latex/amsmath/amstext.sty" 1523134290 2432 8ff93b1137020e8f21930562a874ae66 "" + "/usr/share/texlive/texmf-dist/tex/latex/base/report.cls" 1601675358 23204 74c91ecbcc47161218f25d9d0651c0f7 "" + "/usr/share/texlive/texmf-dist/tex/latex/base/size10.clo" 1601675358 8449 a72d5d4e612221b46000c3d71724e0ef "" + "/usr/share/texlive/texmf-dist/tex/latex/epstopdf-pkg/epstopdf-base.sty" 1579991033 13886 d1306dcf79a944f6988e688c1785f9ce "" + "/usr/share/texlive/texmf-dist/tex/latex/graphics-cfg/color.cfg" 1459978653 1213 620bba36b25224fa9b7e1ccb4ecb76fd "" + "/usr/share/texlive/texmf-dist/tex/latex/graphics-cfg/graphics.cfg" 1465944070 1224 978390e9c2234eab29404bc21b268d1e "" + "/usr/share/texlive/texmf-dist/tex/latex/graphics-def/pdftex.def" 1601931164 19103 48d29b6e2a64cb717117ef65f107b404 "" + "/usr/share/texlive/texmf-dist/tex/latex/graphics/graphics.sty" 1601675358 18272 a8c6a275b34ab6717ceeb8fa04b104e2 "" + "/usr/share/texlive/texmf-dist/tex/latex/graphics/graphicx.sty" 1601675358 7919 20fdfdd783821971c55bc8ee918cbe63 "" + "/usr/share/texlive/texmf-dist/tex/latex/graphics/keyval.sty" 1580683321 2590 e3b24ff953e5b58d924f163d25380312 "" + "/usr/share/texlive/texmf-dist/tex/latex/graphics/trig.sty" 1580683321 3976 d7fa7d81d2870d509d25b17d0245e735 "" + "/usr/share/texlive/texmf-dist/tex/latex/grfext/grfext.sty" 1575499774 7133 b94bbacbee6e4fdccdc7f810b2aec370 "" + "/usr/share/texlive/texmf-dist/tex/latex/kvoptions/kvoptions.sty" 1602274869 22521 d2fceb764a442a2001d257ef11db7618 "" + "/usr/share/texlive/texmf-dist/tex/latex/l3backend/l3backend-pdftex.def" 1611959857 27097 58278863d97b10ab86e334b8da33df7a "" + "/usr/share/texlive/texmf-dist/tex/latex/latexconfig/epstopdf-sys.cfg" 1279039959 678 4792914a8f45be57bb98413425e4c7af "" + "/usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgf.sty" 1601326656 1090 bae35ef70b3168089ef166db3e66f5b2 "" + "/usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgfcore.sty" 1601326656 410 615550c46f918fcbee37641b02a862d9 "" + "/usr/share/texlive/texmf-dist/tex/latex/pgf/compatibility/pgfcomp-version-0-65.sty" 1601326656 21013 f4ff83d25bb56552493b030f27c075ae "" + "/usr/share/texlive/texmf-dist/tex/latex/pgf/compatibility/pgfcomp-version-1-18.sty" 1601326656 989 c49c8ae06d96f8b15869da7428047b1e "" + "/usr/share/texlive/texmf-dist/tex/latex/pgf/frontendlayer/tikz.sty" 1601326656 339 c2e180022e3afdb99c7d0ea5ce469b7d "" + "/usr/share/texlive/texmf-dist/tex/latex/pgf/math/pgfmath.sty" 1601326656 306 c56a323ca5bf9242f54474ced10fca71 "" + "/usr/share/texlive/texmf-dist/tex/latex/pgf/systemlayer/pgfsys.sty" 1601326656 443 8c872229db56122037e86bcda49e14f3 "" + "/usr/share/texlive/texmf-dist/tex/latex/pgf/utilities/pgffor.sty" 1601326656 348 ee405e64380c11319f0e249fed57e6c5 "" + "/usr/share/texlive/texmf-dist/tex/latex/pgf/utilities/pgfkeys.sty" 1601326656 274 5ae372b7df79135d240456a1c6f2cf9a "" + "/usr/share/texlive/texmf-dist/tex/latex/pgf/utilities/pgfrcs.sty" 1601326656 325 f9f16d12354225b7dd52a3321f085955 "" + "/usr/share/texlive/texmf-dist/tex/latex/placeins/placeins.sty" 1137110565 4087 636308456f60d2b31cbf97867db5708d "" + "/usr/share/texlive/texmf-dist/tex/latex/xcolor/xcolor.sty" 1463002160 55589 34128738f682d033422ca125f82e5d62 "" + "/usr/share/texlive/texmf-dist/web2c/texmf.cnf" 1613593815 38841 799d1dd9682a55ce442e10c99777ecc1 "" + "/usr/share/texmf/web2c/texmf.cnf" 1613593815 38841 799d1dd9682a55ce442e10c99777ecc1 "" + "/var/lib/texmf/fonts/map/pdftex/updmap/pdftex.map" 1624878842 5160710 ecf427ae8fa19139d8691f526e47bb9b "" + "/var/lib/texmf/web2c/pdftex/pdflatex.fmt" 1624878876 2570852 ef2a47e64eb64912b01ccaedc81044b8 "" + "project.aux" 1637160560 2768 ba7afbf6aa8cf2ecf75244c6b0b5947d "pdflatex" + "project.tex" 1637160557 19508 62a6208c5f9a3e39d9db16a6856da62e "" + (generated) + "project.log" + "project.aux" + "project.pdf" diff --git a/project.fls b/project.fls new file mode 100644 index 00000000..f276ffce --- /dev/null +++ b/project.fls @@ -0,0 +1,145 @@ +PWD /home/kuchy/Zlew/Studia/SEM_5/elac DONE/project/elacProjectA +INPUT /etc/texmf/web2c/texmf.cnf +INPUT /usr/share/texmf/web2c/texmf.cnf +INPUT /usr/share/texlive/texmf-dist/web2c/texmf.cnf +INPUT /var/lib/texmf/web2c/pdftex/pdflatex.fmt +INPUT project.tex +OUTPUT project.log +INPUT /usr/share/texlive/texmf-dist/tex/latex/base/report.cls +INPUT /usr/share/texlive/texmf-dist/tex/latex/base/report.cls +INPUT /usr/share/texlive/texmf-dist/tex/latex/base/report.cls +INPUT /usr/share/texlive/texmf-dist/tex/latex/base/report.cls +INPUT /usr/share/texlive/texmf-dist/tex/latex/base/report.cls +INPUT /usr/share/texlive/texmf-dist/tex/latex/base/report.cls +INPUT /usr/share/texlive/texmf-dist/tex/latex/base/report.cls +INPUT /usr/share/texlive/texmf-dist/tex/latex/base/report.cls +INPUT /usr/share/texlive/texmf-dist/tex/latex/base/report.cls +INPUT /usr/share/texlive/texmf-dist/tex/latex/base/report.cls +INPUT /usr/share/texlive/texmf-dist/tex/latex/base/report.cls +INPUT /usr/share/texlive/texmf-dist/tex/latex/base/size10.clo +INPUT /usr/share/texlive/texmf-dist/tex/latex/base/size10.clo +INPUT /usr/share/texlive/texmf-dist/tex/latex/base/size10.clo +INPUT /usr/share/texlive/texmf-dist/tex/latex/base/size10.clo +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsmath.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsmath.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsmath.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsmath.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsmath.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsmath.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsmath.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsmath.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsmath.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsmath.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsmath.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsopn.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsopn.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amstext.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amstext.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amstext.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amstext.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amstext.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amstext.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amstext.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amstext.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amstext.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amstext.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amstext.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsgen.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsgen.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsgen.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsgen.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsgen.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsgen.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsgen.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsgen.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsgen.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsgen.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsgen.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsbsy.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsbsy.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsbsy.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsbsy.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsbsy.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsbsy.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsbsy.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsbsy.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsbsy.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsbsy.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsbsy.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsgen.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsopn.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsopn.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsopn.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsopn.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsopn.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsopn.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsopn.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsopn.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsopn.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsopn.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsopn.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/amsmath/amsgen.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/frontendlayer/tikz.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/frontendlayer/tikz.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/frontendlayer/tikz.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/frontendlayer/tikz.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/frontendlayer/tikz.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/frontendlayer/tikz.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/frontendlayer/tikz.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/frontendlayer/tikz.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/frontendlayer/tikz.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/frontendlayer/tikz.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/frontendlayer/tikz.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgf.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgf.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgf.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgf.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgf.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgf.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgf.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgf.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgf.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgf.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgf.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/utilities/pgfrcs.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/utilities/pgfrcs.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/utilities/pgfrcs.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/utilities/pgfrcs.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/utilities/pgfrcs.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/utilities/pgfrcs.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/utilities/pgfrcs.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/utilities/pgfrcs.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/utilities/pgfrcs.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/utilities/pgfrcs.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/utilities/pgfrcs.sty +INPUT /usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfutil-common.tex +INPUT /usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfutil-common-lists.tex +INPUT /usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfutil-latex.def +INPUT /usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfrcs.code.tex +INPUT /usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfrcs.code.tex +INPUT /usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfrcs.code.tex +INPUT /usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfrcs.code.tex +INPUT /usr/share/texlive/texmf-dist/tex/generic/pgf/pgf.revision.tex +INPUT /usr/share/texlive/texmf-dist/tex/generic/pgf/pgf.revision.tex +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgfcore.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgfcore.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgfcore.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgfcore.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgfcore.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgfcore.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgfcore.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgfcore.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgfcore.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgfcore.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgfcore.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/graphics/graphicx.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/graphics/graphicx.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/graphics/graphicx.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/graphics/graphicx.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/graphics/graphicx.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/graphics/graphicx.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/graphics/graphicx.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/graphics/graphicx.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/graphics/graphicx.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/graphics/graphicx.sty +INPUT /usr/share/texlive/texmf-dist/tex/latex/graphics/graphicx.sty diff --git a/project.log b/project.log new file mode 100644 index 00000000..e69de29b diff --git a/project.pdf b/project.pdf new file mode 100644 index 00000000..d70f0a99 Binary files /dev/null and b/project.pdf differ diff --git a/project.synctex(busy) b/project.synctex(busy) new file mode 100644 index 00000000..e69de29b diff --git a/project.synctex.gz b/project.synctex.gz new file mode 100644 index 00000000..4018fb59 Binary files /dev/null and b/project.synctex.gz differ diff --git a/project.tex b/project.tex new file mode 100644 index 00000000..3c0d7ef2 --- /dev/null +++ b/project.tex @@ -0,0 +1,617 @@ +\documentclass{report}[pt12] +\usepackage{amsmath} +\usepackage{tikz} +\usepackage[section]{placeins} +\usetikzlibrary{automata, arrows.meta, positioning} + + + +\setcounter{chapter}{+1} + +\title{Language and Automata, Assignment 1} +\author{Krzysztof Rudnicki\\ Student number: 307585} +\date{\today} + + +\begin{document} +\maketitle + +\section{Regular expression} +We are given following regular expression: +\[ a^* + ba^*b + bba^*\] + +\section{Examples of accepted strings} +\begin{enumerate} +\item $ \varepsilon $ +\item a +\item bab +\item bba +\item bb +\end{enumerate} + +\section{Building NFA using Thompson construction algorithm} +\begin{figure}[!htb] +\centering +\begin{tikzpicture} [node distance = 2cm, on grid, auto] + +\node (q0) [state, initial, initial text = {}] {$q_0$}; +\node (q1) [state, accepting, right = of q0] {$q_1$}; + +\path [-stealth, thick] + (q0) edge node {$\varepsilon$} (q1); +\end{tikzpicture} +\caption{Operator 'a'} \label{fig:operatorA} +\end{figure} + +\begin{figure}[!htb] +\centering +\begin{tikzpicture} [node distance = 2cm, on grid, auto] + +\node (q0) [state, initial, initial text = {}] {$q_2$}; +\node (q1) [state, accepting, right = of q0] {$q_3$}; + +\path [-stealth, thick] + (q0) edge node {$\varepsilon$} (q1); +\end{tikzpicture} +\caption{Operator 'b'} \label{fig:operatorB} +\end{figure} + +\begin{figure}[!htb] +\centering +\begin{tikzpicture} [node distance = 2cm, on grid, auto] + +\node (q0) [state, initial, initial text = {}] {$q_4$}; +\node (q1) [state, right = of q0] {$q_0$}; +\node (q2) [state, right = of q1] {$q_1$}; +\node (q3) [state, accepting, right = of q2] {$q_5$}; + +\path [-stealth, thick] + (q0) edge node {$\varepsilon$} (q1); +\path [-stealth, thick] + (q0) edge [bend right] node[below left] {$\varepsilon$} (q3); +\path [-stealth, thick] + (q1) edge node {a} (q2); +\path [-stealth, thick] + (q2) [bend left] edge node {$\varepsilon$} (q1); +\path [-stealth, thick] + (q2) edge node {$\varepsilon$} (q3); +\end{tikzpicture} +\caption{Operator '$a^*$'} \label{fig:operatorAstar} +\end{figure} + +\begin{figure}[!htb] +\centering +\begin{tikzpicture} [node distance = 2cm, on grid, auto] + +\node (q6) [state, initial, initial text = {}] {$q_2$}; +\node (q0) [state, right = of q6] {$q_4$}; +\node (q1) [state, right = of q0] {$q_0$}; +\node (q2) [state, right = of q1] {$q_1$}; +\node (q3) [state, accepting, right = of q2] {$q_5$}; + +\path [-stealth, thick] + (q6) edge node {$b$} (q0); +\path [-stealth, thick] + (q0) edge node {$\varepsilon$} (q1); +\path [-stealth, thick] + (q0) edge [bend right] node[below left] {$\varepsilon$} (q3); +\path [-stealth, thick] + (q1) edge node {a} (q2); +\path [-stealth, thick] + (q2) [bend left] edge node {$\varepsilon$} (q1); +\path [-stealth, thick] + (q2) edge node {$\varepsilon$} (q3); +\end{tikzpicture} +\caption{Operator '$ba^*$'} \label{fig:operatorbastar} +\end{figure} + +\begin{figure}[!htb] +\centering +\begin{tikzpicture} [node distance = 2cm, on grid, auto] + +\node (q6) [state, initial, initial text = {}] {$q_6$}; +\node (q0) [state, right = of q6] {$q_4$}; +\node (q1) [state, right = of q0] {$q_0$}; +\node (q2) [state, right = of q1] {$q_1$}; +\node (q3) [state, right = of q2] {$q_5$}; +\node (q7) [state, accepting, right = of q3] {$q_7$}; + +\path [-stealth, thick] + (q6) edge node {$b$} (q0); +\path [-stealth, thick] + (q0) edge node {$\varepsilon$} (q1); +\path [-stealth, thick] + (q0) edge [bend right] node[below left] {$\varepsilon$} (q3); +\path [-stealth, thick] + (q1) edge node {a} (q2); +\path [-stealth, thick] + (q2) [bend left] edge node {$\varepsilon$} (q1); +\path [-stealth, thick] + (q2) edge node {$\varepsilon$} (q3); +\path [-stealth, thick] + (q3) edge node {$b$} (q7); + +\end{tikzpicture} +\caption{Operator '$ba^*b$'} \label{fig:operatorbastarb} +\end{figure} + +\begin{figure}[!htb] +\centering +\begin{tikzpicture} [node distance = 2cm, on grid, auto] + +\node (q8) [state, initial, initial text = {}] {$q_2$}; +\node (q9) [state, right = of q8] {$q_3$}; +\node (q4) [state, accepting, right = of q9] {$q_{4}$}; + +\path [-stealth, thick] + (q8) edge node {$b$} (q9); +\path [-stealth, thick] + (q9) edge node {$b$} (q4); + + +\end{tikzpicture} +\caption{Operator '$bb$'} \label{fig:operatorbb} +\end{figure} + +\begin{figure}[!htb] +\centering +\begin{tikzpicture} [node distance = 2cm, on grid, auto] + +\node (q8) [state, initial, initial text = {}] {$q_2$}; +\node (q9) [state, right = of q8] {$q_3$}; +\node (q0) [state, right = of q9] {$q_4$}; +\node (q1) [state, right = of q0] {$q_0$}; +\node (q2) [state, right = of q1] {$q_1$}; +\node (q3) [state, accepting, right = of q2] {$q_5$}; + +\path [-stealth, thick] + (q0) edge node {$\varepsilon$} (q1); +\path [-stealth, thick] + (q0) edge [bend right] node[below left] {$\varepsilon$} (q3); +\path [-stealth, thick] + (q1) edge node {a} (q2); +\path [-stealth, thick] + (q2) [bend left] edge node {$\varepsilon$} (q1); +\path [-stealth, thick] + (q2) edge node {$\varepsilon$} (q3); + +\path [-stealth, thick] + (q8) edge node {$b$} (q9); +\path [-stealth, thick] + (q9) edge node {$b$} (q4); +\end{tikzpicture} +\caption{Operator '$bba^*$'} \label{fig:operatorbbastar} +\end{figure} + +\begin{figure}[!htb] +\centering +\begin{tikzpicture} [node distance = 2cm, on grid, auto] + +\node (q10) [state, initial, initial text = {}] {$q_{10}$}; +% a* + +\node (q0) [state, above right = of q10] {$q_4$}; +\node (q1) [state, right = of q0] {$q_0$}; +\node (q2) [state, right = of q1] {$q_1$}; +\node (q3) [state, right = of q2] {$q_5$}; +% ba*b +\node (q4) [state, below right = of q10] {$q_6$}; +\node (q5) [state, right = of q4] {$q_8$}; +\node (q6) [state, right = of q5] {$q_9$}; +\node (q7) [state, right = of q6] {$q_{12}$}; +\node (q8) [state, right = of q7] {$q_{13}$}; +\node (q9) [state, right = of q8] {$q_7$}; + +\node (q11) [state, accepting, above right = of q9] {$q_{11}$}; + +\path [-stealth, thick] + (q10) edge node {$\varepsilon$} (q0); + +\path [-stealth, thick] + (q10) edge node {$\varepsilon$} (q4); + +% a* +\path [-stealth, thick] + (q0) edge node {$\varepsilon$} (q1); +\path [-stealth, thick] + (q0) edge [bend right] node[below left] {$\varepsilon$} (q3); +\path [-stealth, thick] + (q1) edge node {a} (q2); +\path [-stealth, thick] + (q2) [bend left] edge node {$\varepsilon$} (q1); +\path [-stealth, thick] + (q2) edge node {$\varepsilon$} (q3); +\path [-stealth, thick] + (q3) edge node {$\varepsilon$} (q11); + +% ba*b +\path [-stealth, thick] + (q4) edge node {$b$} (q5); +\path [-stealth, thick] + (q5) edge node {$\varepsilon$} (q6); +\path [-stealth, thick] + (q5) edge [bend right] node[below left] {$\varepsilon$} (q8); +\path [-stealth, thick] + (q6) edge node {a} (q7); +\path [-stealth, thick] + (q7) [bend left] edge node {$\varepsilon$} (q6); +\path [-stealth, thick] + (q7) edge node {$\varepsilon$} (q8); +\path [-stealth, thick] + (q8) edge node {$b$} (q9); +\path [-stealth, thick] + (q9) edge node {$\varepsilon$} (q11); +\end{tikzpicture} +\caption{Operator '$a^*+ba^*b$'} \label{fig:operatorastarOrbastarb} +\end{figure} + +\begin{figure}[!htb] +\begin{tikzpicture} [node distance = 1.5cm, on grid, auto] + +\node (q12) [state, initial, initial text = {}] {$q_{12}$}; + +\node (q10) [state, above right = of q12] {$q_{10}$}; +% a* + +\node (q0) [state, above right = of q10] {$q_4$}; +\node (q1) [state, right = of q0] {$q_0$}; +\node (q2) [state, right = of q1] {$q_1$}; +\node (q3) [state, right = of q2] {$q_5$}; +% ba*b +\node (q4) [state, below right = of q10] {$q_6$}; +\node (q5) [state, right = of q4] {$q_8$}; +\node (q6) [state, right = of q5] {$q_9$}; +\node (q7) [state, right = of q6] {$q_{12}$}; +\node (q8) [state, right = of q7] {$q_{13}$}; +\node (q9) [state, right = of q8] {$q_7$}; + +\node (q11) [state, above right = of q9] {$q_{11}$}; + +\node (q13) [state, accepting, below right = of q11] {$q_{13}$}; + +% bba* +\node (q14) [state, below right = of q12] {$q_{14}$}; +\node (q15) [state, right = of q14] {$q_{15}$}; +\node (q16) [state, right = of q15] {$q_{16}$}; +\node (q17) [state, right = of q16] {$q_{17}$}; +\node (q18) [state, right = of q17] {$q_{18}$}; +\node (q19) [state, right = of q18] {$q_{19}$}; + +\path [-stealth, thick] + (q12) edge node {$b$} (q14); + +\path [-stealth, thick] + (q14) edge node {$b$} (q15); +\path [-stealth, thick] + (q15) edge node {$b$} (q16); +\path [-stealth, thick] + (q16) edge node {$\varepsilon$} (q17); +\path [-stealth, thick] + (q16) edge [bend right] node[below left] {$\varepsilon$} (q19); +\path [-stealth, thick] + (q17) edge node {$a$} (q18); +\path [-stealth, thick] + (q18) edge node {$\varepsilon$} (q19); +\path [-stealth, thick] + (q18) [bend left] edge node {$\varepsilon$} (q17); +\path [-stealth, thick] + (q19) edge [bend right] node {$b$} (q13); + +\path [-stealth, thick] + (q12) edge node {$\varepsilon$} (q10); + +\path [-stealth, thick] + (q10) edge node {$\varepsilon$} (q0); + +\path [-stealth, thick] + (q10) edge node {$\varepsilon$} (q4); + +% a* +\path [-stealth, thick] + (q0) edge node {$\varepsilon$} (q1); +\path [-stealth, thick] + (q0) edge [bend right] node[below left] {$\varepsilon$} (q3); +\path [-stealth, thick] + (q1) edge node {a} (q2); +\path [-stealth, thick] + (q2) [bend left] edge node {$\varepsilon$} (q1); +\path [-stealth, thick] + (q2) edge node {$\varepsilon$} (q3); +\path [-stealth, thick] + (q3) edge node {$\varepsilon$} (q11); + +% ba*b +\path [-stealth, thick] + (q4) edge node {$b$} (q5); +\path [-stealth, thick] + (q5) edge node {$\varepsilon$} (q6); +\path [-stealth, thick] + (q5) edge [bend left] node[below left] {$\varepsilon$} (q8); +\path [-stealth, thick] + (q6) edge node {a} (q7); +\path [-stealth, thick] + (q7) [bend left] edge node {$\varepsilon$} (q6); +\path [-stealth, thick] + (q7) edge node {$\varepsilon$} (q8); +\path [-stealth, thick] + (q8) edge node {$b$} (q9); +\path [-stealth, thick] + (q9) edge node {$\varepsilon$} (q11); +\path [-stealth, thick] + (q11) edge node {$\varepsilon$} (q13); + +% bba* + +\end{tikzpicture} +\caption{Operator '$a^*+ba^*b + bba^*$'} \label{fig:final} +\end{figure} + +\begin{figure}[!htb] +\begin{tikzpicture} [node distance = 1.5cm, on grid, auto] + +\node (q12) [state, initial, initial text = {}] {$q_{0}$}; + +\node (q10) [state, above right = of q12] {$q_{1}$}; +% a* + +\node (q0) [state, above right = of q10] {$q_3$}; +\node (q1) [state, right = of q0] {$q_6$}; +\node (q2) [state, right = of q1] {$q_9$}; +\node (q3) [state, right = of q2] {$q_{12}$}; +% ba*b +\node (q4) [state, below right = of q10] {$q_4$}; +\node (q5) [state, right = of q4] {$q_7$}; +\node (q6) [state, right = of q5] {$q_{10}$}; +\node (q7) [state, right = of q6] {$q_{13}$}; +\node (q8) [state, right = of q7] {$q_{15}$}; +\node (q9) [state, right = of q8] {$q_{17}$}; + +\node (q11) [state, above right = of q9] {$q_{18}$}; + +\node (q13) [state, accepting, below right = of q11] {$q_{19}$}; + +% bba* +\node (q14) [state, below right = of q12] {$q_{2}$}; +\node (q15) [state, right = of q14] {$q_{5}$}; +\node (q16) [state, right = of q15] {$q_{8}$}; +\node (q17) [state, right = of q16] {$q_{11}$}; +\node (q18) [state, right = of q17] {$q_{14}$}; +\node (q19) [state, right = of q18] {$q_{16}$}; + +\path [-stealth, thick] + (q12) edge node {$b$} (q14); + +\path [-stealth, thick] + (q14) edge node {$b$} (q15); +\path [-stealth, thick] + (q15) edge node {$b$} (q16); +\path [-stealth, thick] + (q16) edge node {$\varepsilon$} (q17); +\path [-stealth, thick] + (q16) edge [bend right] node[below left] {$\varepsilon$} (q19); +\path [-stealth, thick] + (q17) edge node {$a$} (q18); +\path [-stealth, thick] + (q18) edge node {$\varepsilon$} (q19); +\path [-stealth, thick] + (q18) [bend left] edge node {$\varepsilon$} (q17); +\path [-stealth, thick] + (q19) edge [bend right] node {$b$} (q13); + +\path [-stealth, thick] + (q12) edge node {$\varepsilon$} (q10); + +\path [-stealth, thick] + (q10) edge node {$\varepsilon$} (q0); + +\path [-stealth, thick] + (q10) edge node {$\varepsilon$} (q4); + +% a* +\path [-stealth, thick] + (q0) edge node {$\varepsilon$} (q1); +\path [-stealth, thick] + (q0) edge [bend right] node[below left] {$\varepsilon$} (q3); +\path [-stealth, thick] + (q1) edge node {a} (q2); +\path [-stealth, thick] + (q2) [bend left] edge node {$\varepsilon$} (q1); +\path [-stealth, thick] + (q2) edge node {$\varepsilon$} (q3); +\path [-stealth, thick] + (q3) edge node {$\varepsilon$} (q11); + +% ba*b +\path [-stealth, thick] + (q4) edge node {$b$} (q5); +\path [-stealth, thick] + (q5) edge node {$\varepsilon$} (q6); +\path [-stealth, thick] + (q5) edge [bend left] node[below left] {$\varepsilon$} (q8); +\path [-stealth, thick] + (q6) edge node {a} (q7); +\path [-stealth, thick] + (q7) [bend left] edge node {$\varepsilon$} (q6); +\path [-stealth, thick] + (q7) edge node {$\varepsilon$} (q8); +\path [-stealth, thick] + (q8) edge node {$b$} (q9); +\path [-stealth, thick] + (q9) edge node {$\varepsilon$} (q11); +\path [-stealth, thick] + (q11) edge node {$\varepsilon$} (q13); + +% bba* + +\end{tikzpicture} +\caption{Operator '$a^*+ba^*b + bba^*$' - changed names of states} \label{fig:finalBetter} +\end{figure} + +\section{Transforming NFA into DFA using subset algorithm} +I will use $\epsilon_{cl}$ instead of $\epsilon$-closure for brevity sake. +Final state - $\underline{q_{19}}$ was marked with an $\underline{underline}$ and so did all the states of DFA that contain it. +\[ A = \epsilon_{cl}(q_0) = (q_0, q_1, q_3, q_4, q_6, q_{12}, q_{18}, \underline{q_{19}}) = \underline{A} \] +\[ \epsilon_{cl}(move(\underline{A}, a)) = (\epsilon_{cl}(move(q_0, q_1, q_3, q_4, q_6, q_{12}, q_{18}, \underline{q_{19}}, a))) = \epsilon_{cl}(q_9) = (q_6, q_9, q_{12}, q_{18}, \underline{q_{19}}) = \underline{B} \] +\[ A = \epsilon_{cl}(move(\underline{A}, b)) = \epsilon_{cl}(move(q_0, q_1, q_3, q_4, q_6, q_{12}, q_{18}, \underline{q_{19}}, b))) = \epsilon_{cl}(q_2, q_7) = (q_2, q_7, q_{10}, q_{15}) = C \] +\[ \epsilon_{cl}(move(\underline{B}, a)) = \epsilon_{cl}(move(q_6, q_9, q_{12}, q_{18}, \underline{q_{19}}), a) = \epsilon_{cl}(q_9) = (q_6, q_9, q_{12}, q_{18}, \underline{q_{19}}) = \underline{B} \] +\[ \epsilon_{cl}(move(\underline{B}, b)) = \epsilon_{cl}(move(q_6, q_9, q_{12}, q_{18}, \underline{q_{19}}), b) = \emptyset \] +\[ \epsilon_{cl}(move(C, a)) = \epsilon_{cl}(move(q_2, q_7, q_{10}, q_{15}), a) = \epsilon_{cl}(q_{13}) = (q_{10}, q_{13}, q_{15}) = D \] +\[ \epsilon_{cl}(move(C, b)) = \epsilon_{cl}(move((q_2, q_7, q_{10}, q_{15}), b) = \epsilon_{cl}(q_{17}) = (q_{17}, q_{18}, \underline{q_{19}}) = \underline{E} \] +\[ \epsilon_{cl}(move(D, a)) = \epsilon_{cl}(move((q_{10}, q_{13}, q_{15}), a) = \epsilon_{cl}(q_{13}) = (q_{10}, q_{13}, q_{15}) = D \] +\[ \epsilon_{cl}(move(D, b)) = \epsilon_{cl}(move(q_{10}, q_{13}, q_{15}, b) = \epsilon_{cl}(q_{17}) = (q_{17}, q_{18}, \underline{q_{19}}) = \underline{E} \] +\[ \epsilon_{cl}(move(\underline{E}, a)) = \epsilon_{cl}(move(q_{17}, q_{18}, \underline{q_{19}}), a) = \epsilon_{cl}(\emptyset) = \emptyset \] +\[ \epsilon_{cl}(move(\underline{E}, b)) = \epsilon_{cl}(move(q_{17}, q_{18}, \underline{q_{19}}), b) = \epsilon_{cl}(\emptyset) = \emptyset \] + +\subsection{State table} +\begin{center} +\begin{tabular}{||c c c||} + \hline + State & a & b \\ + \hline +$\underline{A}$ & $\underline{B}$ & C\\ + \hline + $\underline{B}$ & $\underline{B}$ & $\emptyset$ \\ + \hline + C & D & $\underline{E}$\\ + \hline + D & D & $\underline{E}$\\ + \hline + $\underline{E}$ & $\emptyset$ & $\emptyset$\\ + \hline +$\emptyset$ & $\emptyset$ & $\emptyset$\\ + \hline +\end{tabular} +\end{center} + +\begin{figure}[!htb] +\centering +\begin{tikzpicture} [node distance = 2cm, on grid, auto] + + \node (q0) [state, accepting, initial, initial text = {}] {A}; + \node (q1) [state, accepting, above right = of q0] {B}; + \node (q2) [state, below right = of q0] {C}; + \node (q3) [state, accepting, above right = of q2] {E}; + \node (q4) [state, below right = of q2] {D}; + \node (q5) [state, right = of q1] {$\emptyset$}; + + \path [-stealth, thick] + (q0) edge node {$a$} (q1); + + \path [-stealth, thick] + (q0) edge node {$b$} (q2); + + \path [-stealth, thick] + (q1) edge [loop] node {$a$} (q1); + + \path [-stealth, thick] + (q2) edge node {$b$} (q4); + + \path [-stealth, thick] + (q2) edge node {$b$} (q3); + + \path [-stealth, thick] + (q4) edge [bend right] node {$b$} (q3); + + \path [-stealth, thick] + (q4) edge [loop] node {$a$} (q4); + + \path [-stealth, thick] + (q1) edge [bend left] node {$a$} (q5); + + \path [-stealth, thick] + (q3) edge node {$a, b$} (q5); + + \path [-stealth, thick] + (q5) edge [loop] node {$a, b$} (q5); + + + + +\end{tikzpicture} +\caption{DFA graph before minimalization} \label{dfaNominimalization} +\end{figure} + +\section{Constructing minimal state DFA} + +\begin{tabular}{|*{7}{c|}} + \cline{1-1} + $\underline{A}$ \\ \cline{1-2} + $\underline{B}$ & $x_1$ \\ \cline{1-3} + C & $x_1$ & $x_1$ \\ \cline{1-4} + D & $x_1$ & $x_1$ & $x_2$ \\ \cline{1-5} + $\underline{E}$ & $x_1$ & $x_1$ & $x_1$ & $x_1$ \\ \cline{1-6} + $\emptyset$ & $x_1$ & $x_1$ & $x_2$ & $x_2$ & $x_1$ \\ \hline + & $\underline{A}$ & $\underline{B}$ & C & D & $\underline{E}$ & $\emptyset$ \\ \hline +\end{tabular} + +\begin{enumerate} + \item First I marked (with $x_1$) all the pairs in which at least one of them were final state: + \[ ([\underline{A}, \emptyset], [\underline{A}, \underline{E}], [\underline{A}, D], [\underline{A}, C], [\underline{A}, \underline{B}]) \] + \[ ([\underline{B}, \emptyset], ([\underline{B}, \underline{E}], ([\underline{B}, D], ([\underline{B}, C]) \] + \[ ([\underline{E}, \emptyset], [\underline{E}, C], [\underline{E}, D])\] + + \item We are left with the pairs: + \[ ([\emptyset , C], [\emptyset , D], [D , C] ) \] + For pair: $ [\emptyset , C] $ C goes to final state $\underline{E}$ on transition 'b' therefore we mark it with $x_2$ + For pair: $ [\emptyset , D] $ D goes to final state $\underline{E}$ on transition 'b' therefore we mark it with $x_2$ + For pair: $ [D , C] $ both C and D go to final state $\underline{E}$ on transition 'b' therefore we mark it with $x_2$ +\end{enumerate} + +No states could be minimized! Therefore our final minimal state DFA looks like this: + +\begin{figure}[!htb] +\centering +\begin{tikzpicture} [node distance = 2cm, on grid, auto] + +\node (q0) [state, accepting, initial, initial text = {}] {A}; +\node (q1) [state, accepting, above right = of q0] {B}; +\node (q2) [state, below right = of q0] {C}; +\node (q3) [state, accepting, above right = of q2] {E}; +\node (q4) [state, below right = of q2] {D}; +\node (q5) [state, right = of q1] {$\emptyset$}; + +\path [-stealth, thick] +(q0) edge node {$a$} (q1); + +\path [-stealth, thick] +(q0) edge node {$b$} (q2); + +\path [-stealth, thick] +(q1) edge [loop] node {$a$} (q1); + +\path [-stealth, thick] +(q2) edge node {$a$} (q4); + +\path [-stealth, thick] +(q2) edge node {$b$} (q3); + +\path [-stealth, thick] +(q4) edge node {$b$} (q3); + +\path [-stealth, thick] +(q1) edge [bend left] node {$a, b$} (q5); + +\path [-stealth, thick] +(q3) edge [below loop] node {$a$} (q3); + +\path [-stealth, thick] +(q3) edge node {$a$} (q5); + +\path [-stealth, thick] +(q4) edge [bend right] node {$a$} (q5); + +\path [-stealth, thick] +(q5) edge [loop] node {$a, b$} (q5); + + + + + +\end{tikzpicture} +\caption{DFA graph after minimalization} \label{dfaMinimalization} +\end{figure} + + + + +\end{document}