Skip to main content

Vector Representation of Abstract Program Tree for Assessing Algorithm Variety for the Same Purpose

  • Conference paper
  • First Online:
Book cover Integrated Uncertainty in Knowledge Modelling and Decision Making (IUKM 2018)

Part of the book series: Lecture Notes in Computer Science ((LNAI,volume 10758))

  • 1359 Accesses

Abstract

There are various ways to realize programs to meet the same requirements. Therefore, for evaluation of a program code, it is necessary not only to satisfy the requirement for it but also to evaluate how it achieves the purpose. We think that the knowledge of such alternative ways to achieve the same purpose is important for program education and software engineering. In this paper, we propose a method to analyze how the program achieves requirements. We propose particularly a vector representation that appropriately indicates the structure of an abstract syntax tree. We confirmed that our proposal not only analyzes fundamental programs as appears in textbooks effectively but also classifies algorithms that are adopted in various programs submitted to a programming contest. Based on this confirmation, we further investigated the relationship between the class name of the Java language and the program structure. As a result, it was shown that classes with similar program structure are named by certain similar linguistic expressions. Therefore, we conclude that our proposed method is a useful basis for representing the diversity of programs on vector space.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

References

  1. Mechtaev, S., Yi, J., Roychoudhury, A.: Directfix: looking for simple program repairs. In: Proceedings of the 37th International Conference on Software Engineering, vol. 1, pp. 448–458. IEEE Press (2015)

    Google Scholar 

  2. Nguyen, H.D.T., Qi, D., Roychoudhury, A., Chandra, S.: Semfix: program repair via semantic analysis. In: Proceedings of the 2013 International Conference on Software Engineering, pp. 772–781. IEEE Press (2013)

    Google Scholar 

  3. Le Goues, C., Nguyen, T., Forrest, S., Weimer, W.: Genprog: a generic method for automatic software repair. IEEE Trans. Softw. Eng. 38(1), 54–72 (2012)

    Article  Google Scholar 

  4. Murakami, H., Hotta, K., Higo, Y., Kusumoto, S.: Predicting next changes at the fine-grained level. In: 2014 21st Asia-Pacific Software Engineering Conference (APSEC), vol. 1, pp. 119–126. IEEE (2014)

    Google Scholar 

  5. Mou, L., Li, G., Liu, Y., Peng, H., Jin, Z., Xu, Y., Zhang, L.: Building program vector representations for deep learning. arXiv preprint arXiv:1409.3358 (2014)

  6. Gvero, T., Kuncak, V.: Synthesizing Java expressions from free-form queries. ACM SIGPLAN Not. 50(10), 416–432 (2015)

    Article  Google Scholar 

  7. EclipseJDT: Eclipsejdt. http://www.eclipse.org/jdt. Accessed 27 Sept 2017

  8. Allamanis, M., Sutton, C.: Mining source code repositories at massive scale using language modeling. In: The 10th Working Conference on Mining Software Repositories, pp. 207–216. IEEE (2013)

    Google Scholar 

  9. Lafore, R.: Java de manabu algorithm to data kouzou Java (Japanese). SB Creative (1999)

    Google Scholar 

  10. Kondou, Y.: Teihon Java programmer no tameno algorithm to data kouzou Java (Japanese). SB Creative (2011)

    Google Scholar 

  11. Igarashi, T.: Data kouzou to algorithm (Japanese). Suurikougaku-Sha (2007)

    Google Scholar 

  12. Shibata, B.: Meikai Java niyoru algorithm to data kouzou Java (Japanese). SB Creative (2007)

    Google Scholar 

  13. Watanobe, Y.: Aizu online judge. http://judge.u-aizu.ac.jp/onlinejudge/. Accessed 27 Sept 2017

Download references

Acknowledgment

This work was supported by JSPS KAKENHI (Grant-in-Aid for Scientific Research(C), Grant Number: 15K01100).

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Yoshiki Mashima .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2018 Springer International Publishing AG, part of Springer Nature

About this paper

Check for updates. Verify currency and authenticity via CrossMark

Cite this paper

Mashima, Y., Takeuchi, K. (2018). Vector Representation of Abstract Program Tree for Assessing Algorithm Variety for the Same Purpose. In: Huynh, VN., Inuiguchi, M., Tran, D., Denoeux, T. (eds) Integrated Uncertainty in Knowledge Modelling and Decision Making. IUKM 2018. Lecture Notes in Computer Science(), vol 10758. Springer, Cham. https://doi.org/10.1007/978-3-319-75429-1_11

Download citation

  • DOI: https://doi.org/10.1007/978-3-319-75429-1_11

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-319-75428-4

  • Online ISBN: 978-3-319-75429-1

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics