Welcome to the Aho-Corasick Visualization Project! This project visualizes the Aho-Corasick string matching algorithm using wxWidgets for the graphical user interface. The algorithm efficiently searches for multiple patterns in a given text, providing visualization of its steps, memory consumption, and results.
AhoCorasickProject/
├── AhoCorasickProject/
│ ├── AhoCorasickProject.vcxproj
│ ├── AhoCorasickProject.vcxproj.user
│ ├── Ahocorasick.cpp
│ ├── Ahocorasick.h
│ ├── Visualization.h
│ ├── main.cpp
│ ├── patterns.txt
│ └── visualization.cpp
├── .gitattributes
├── .gitignore
├── AhoCorasickProject.sln
├── LICENSE.txt
└── README.md
- AhoCorasickProject.vcxproj: The Visual Studio project file.
- AhoCorasickProject.vcxproj.user: User-specific project settings.
- AhoCorasickProject.sln: The Visual Studio solution file.
- Ahocorasick.cpp: Implementation of the Aho-Corasick algorithm.
- Ahocorasick.h: Header file for the Aho-Corasick algorithm.
- Visualization.h: Header file for the wxWidgets-based visualization.
- main.cpp: Entry point of the application.
- patterns.txt: Sample file containing patterns to search.
- visualization.cpp: Implementation of the wxWidgets-based visualization.
- .gitattributes: Git attributes file.
- .gitignore: Git ignore file.
- LICENSE.txt: License for the project.
- README.md: This README file.
- wxWidgets
- C++17 or higher
- Visual Studio 2019 or later (for building the project)
-
Clone the repository:
git clone https://github.com/EchoSingh/AhoCorasickProject.git cd AhoCorasickProject
-
Open the Solution in Visual Studio: Open
AhoCorasickProject.sln
with Visual Studio. -
Build the Project: Build the solution using Visual Studio.
-
Load Patterns: Use the "Open Patterns..." menu option to load the
patterns.txt
file. -
Run the Algorithm: Use the "Run Algorithm..." menu option to input a text and search for the patterns.
-
Visualization: The results of the search will be displayed in the GUI, showing where each pattern is found in the text.
The patterns.txt
file should contain one pattern per line. Example:
he
she
his
hers
her
hero
sh
This project is licensed under the MIT License - see the LICENSE.txt file for details.
- GitHub: aditya26062003