Functional validation of numeric and string key processing in a B-Tree visualization simulator

Abstract

This study evaluates the functional correctness and core-operation response of a Java-based B-Tree visualization simulator supporting numeric and string keys. The iterative prototype uses a Model–View–Controller architecture, Observer-based animation, and Memento-based undo/redo. Numeric inputs from 1 to 999 are normalized to three-digit zero-padded strings; alphabetic keys of up to five characters are processed separately. Evaluation comprises seven validator unit tests, four black-box functional scenarios, B-Tree invariant checks, and randomized differential comparison against java.util.TreeSet. Across orders 3–10 and 200 random seeds per mode, 300 operations per scenario yielded 960,000 operations; the reported runs showed no invariant violations or content mismatches. Reported core-operation response times were below 100 ms, excluding interface rendering. Testing also identified defects that were subsequently corrected. These results support software correctness within the tested domain, but do not demonstrate usability or learning gains because no user-based evaluation was conducted.

Keywords
  • B-Tree visualization,
  • Software validation,
  • Differential testing,
  • Invariant checking,
  • Algorithm visualization
References
  1. Ammann, P., & Offutt, J. (2016). Introduction to software testing (2nd ed.). Cambridge University Press.
  2. Amazon Web Services. (n.d.). Zero padding. In Amazon SimpleDB developer guide. https://docs.aws.amazon.com/AmazonSimpleDB/latest/DeveloperGuide/ZeroPadding.html
  3. B+ tree viewer (btview). (n.d.). Minibase documentation. https://itlab.uta.edu/courses/cse5331And4331/mini_doc-2.0/vistools/btview.html
  4. Bayer, R., & McCreight, E. (1972). Organization and maintenance of large ordered indexes. Acta Informatica, 1(3), 173–189.
  5. Bingmann, T. (2007). STX B+ tree. https://panthema.net/2007/stx-btree/
  6. Comer, D. (1979). The ubiquitous B-tree. ACM Computing Surveys, 11(2), 121–137.
  7. Cormen, T. H., Leiserson, C. E., Rivest, R. L., & Stein, C. (2022). Introduction to algorithms (4th ed.). MIT Press.
  8. Galles, D. (n.d.). USFCA data structure visualizations: B-tree. https://www.cs.usfca.edu/~galles/visualization/BTree.html
  9. Gamma, E., Helm, R., Johnson, R., & Vlissides, J. (1994). Design patterns: Elements of reusable object-oriented software. Addison-Wesley.
  10. Halim, S. (n.d.). VisuAlgo. https://visualgo.net
  11. Hundhausen, C., Douglas, S., & Stasko, J. (2002). A meta-study of algorithm visualization effectiveness. Journal of Visual Languages & Computing, 13(3), 259–290.
  12. Knuth, D. E. (1998). The art of computer programming: Vol. 3. Sorting and searching (2nd ed.). Addison-Wesley.
  13. Liu, J., Poulsen, S., Goodwin, E., Chen, H., Williams, G., Gertner, Y., & Franklin, D. (2025). Teaching algorithm design: A literature review. ACM Transactions on Computing Education, 25(2). https://doi.org/10.1145/3727987
  14. MacIver, D. R., Hatfield-Dodds, Z., & Many Other Contributors. (2019). Hypothesis: A new approach to property-based testing. Journal of Open Source Software, 4(43), Article 1891. https://doi.org/10.21105/joss.01891
  15. OpenDSA Project. (n.d.). OpenDSA: Interactive data structures and algorithms eTextbook. Virginia Tech. https://opendsa.org/OpenDSA/Books/Everything/html/BTree.html
  16. Oracle. (n.d.-a). Formatter (Java SE 17 API documentation). https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Formatter.html
  17. Oracle. (n.d.-b). String (Java SE 17 API documentation). https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html
  18. PostgreSQL Global Development Group. (n.d.-a). Operator classes and operator families. In PostgreSQL 18 documentation. https://www.postgresql.org/docs/18/indexes-opclass.html
  19. PostgreSQL Global Development Group. (n.d.-b). String functions and operators. In PostgreSQL 18 documentation. https://www.postgresql.org/docs/18/functions-string.html
  20. Seymour, P. (n.d.). Efficient lexicographic encoding of numbers (ELEN) [Unpublished manuscript]. https://zanopha.com/docs/elen.pdf
  21. Shaffer, C. A., Cooper, M. L., Alon, A. J. D., Akbar, M., Stewart, M., Ponce, S., & Edwards, S. H. (2010). Algorithm visualization: The state of the field. ACM Transactions on Computing Education, 10(3), Article 9. https://doi.org/10.1145/1821996.1821997
  22. Sibia, N., Liut, M., & Nobre, C. (2025). Exploring the role of visualization tools in enhancing computing education: A systematic literature review. In EuroVis 2025—Education papers. The Eurographics Association. https://doi.org/10.2312/eved.20251027