当前位置:主页 > 教育论文 > 师范教育论文 >

基于本体的程序代码资源算法结构关联研究

发布时间:2018-09-04 19:41
【摘要】:随着计算机技术的高速发展,程序设计教学正在受到各个学校越来越多重视。国际大学生程序设计竞赛(ACM International Collegiate Programming Contest,简称ACM/ICPC)作为一种全新的培养计算机科学顶尖学生的方式很快受到各个大学的积极响应。目前有很多ACM程序设计选手积累自己平时做题的解题思路,并将这些解题思路上传到他们的Blog上以分享给程序设计爱好者参考学习。这些题解报告都是分散地存在网络上,但有些题目之间很类似,重复学习不能带来实质性的进展。目前有一些大牛来根据自己多年的做题经验进行总结分析自己所做过的题目,很多初学者跟着大牛的脚步在前进。但是互联网上的题目浩如烟海,单凭个人的人力是很难对其进行全面的研究。因此,需要一种有效的方法来分析解题报告,包括其中的解题思路和程序代码。最终在解题思路与解题思路之间建立联系,在程序代码与程序代码之间建立联系,和在解题思路与程序代码之间建立联系,形成三维一体的有机体,从而更有效地进行教育教学以及个性化学习。本文分别对解题报告中的程序设计代码和解题思路进行分析处理,具体如下:1)对JAVA程序代码的处理。首先,由于JAVA程序代码编写的灵活性,直接将其送给机器进行处理会比较麻烦。本文将其进行词法分析和语法分析转换成与其一一对应的语法树,处理起来方便了很多。然后,本文想让机器能够根据语义自动处理这些数据,但语法树中并没有明确的语义标签,因此我们了结合拥有语义标签的本体技术,将JAVA程序代码使用本体表示。其次,JAVA程序代码使用本体表示后,我们可以自己写代码来检索想要的算法结构。但这样比较麻烦,本文通过本体查询语句描述算法结构来查询算法,并且这些查询语句是根据代码或伪代码自动生成的。本体查询语言的语法规则很适合描述算法结构,并且本体查询语言拥有强大的推理能力,为算法识别提供了很好的支持。最后,将算法使用本体查询语言描述查找类似的算法,根据查询结果在算法之间建立联系。2)对解题思路的处理。参加ACM比赛的学生很多,数以万计的题目以及解题报告分散在网络中。课题组中已有同学根据专家库中预定义的算法类别对解题报告进行分类,但是预定义的专家库具有一定的局限性。本文首先使用自然语言处理技术处理解题报告中的解题思路,自动获取算法名,形成知识库,用于对题目分类。解题思路中很多描述算法的语句具有一些特定的模式,本文使用斯坦福大学的中文分词器和解析器工具,对这些语句按照特定的模式进行分析处理,自动获取算法名,形成知识库。有了知识库后,我们就可以在解题思路中查找知识库中所包含的算法,并根据具体的算法在解题思路之间建立联系。由于解题报告中解题思路与程序代码是一一对应的,根据一个解题思路,我们可以找到与其有关系的其他解题思路所对应的程序代码,最终在解题思路与程序代码之间建立联系。
[Abstract]:With the rapid development of computer technology, more and more schools are paying attention to the teaching of computer programming. The ACM International Collegiate Programming Contest (ACM/ICPC), as a brand-new way to train top students in computer science, has been actively responded by universities. At present, many ACM programmers accumulate and upload their usual problem-solving ideas to their blogs to share with programming enthusiasts for reference. Many beginners are following Daniel's footsteps. But there are so many problems on the Internet that it is difficult to do a comprehensive research on them solely by human resources. Finally, it establishes the connection between the solution idea and the solution idea, between the program code and the program code, and between the solution idea and the program code, so as to form a three-dimensional organic entity, so as to carry out education, teaching and personalized learning more effectively. First of all, because of the flexibility of JAVA program code writing, it will be more troublesome to send it directly to the machine for processing. This paper converts the lexical analysis and syntax analysis into one-to-one correspondence. The syntax tree is much easier to handle. Then, we want the machine to process the data automatically according to the semantics, but there is no explicit semantic tag in the syntax tree, so we use ontology to represent the JAVA program code. Secondly, after using ontology to represent the JAVA program code, we can This paper describes the algorithm structure by ontology query statements, and these query statements are generated automatically according to code or pseudocode. The syntax rules of ontology query language are very suitable for describing the algorithm structure, and ontology query language has powerful. Finally, the algorithm uses ontology query language to describe and find similar algorithms, and establishes a relationship between algorithms according to the query results. 2) Processing of problem solving ideas. Many students participate in ACM competitions, tens of thousands of topics and problem solving reports are scattered in the network. Some students classify problem-solving reports according to the predefined algorithmic categories in the expert database, but the predefined expert database has some limitations. Firstly, this paper uses natural language processing technology to deal with the problem-solving ideas in the problem-solving reports, automatically acquires algorithm names, and forms a knowledge base for problem classification. The statements of the algorithm have some specific patterns. This paper uses the Chinese word segmentation and parser tools of Stanford University to analyze and process these statements according to the specific patterns, automatically obtain the algorithm name and form a knowledge base. According to the specific algorithm, the connection is established between the solution ideas. Because the solution ideas and program codes are one-to-one correspondence in the solution report, according to a solution idea, we can find the program codes corresponding to other solution ideas related to it, and finally establish the connection between the solution ideas and program codes.
【学位授予单位】:东华大学
【学位级别】:硕士
【学位授予年份】:2013
【分类号】:TP311.1-4;G642

【参考文献】

相关期刊论文 前4条

1 吕金丽;余雪丽;;课程知识本体建模及推理[J];计算机工程;2011年04期

2 徐晓;;基于本体映射和规则推理的排课模型研究[J];软件导刊;2009年02期

3 熊回香;夏立新;;自然语言处理技术在中文全文检索中的应用[J];情报理论与实践;2008年03期

4 陈肇雄;高庆狮;;自然语言处理[J];计算机研究与发展;1989年11期

相关硕士学位论文 前2条

1 傅力超;程序设计网络资源知识联系结构在线同构模型研究[D];东华大学;2012年

2 孙辞海;基于专家系统的程序代码知识点自动识别方法研究[D];东华大学;2010年



本文编号:2223145

资料下载
论文发表

本文链接:https://www.wllwen.com/jiaoyulunwen/shifanjiaoyulunwen/2223145.html


Copyright(c)文论论文网All Rights Reserved | 网站地图 |

版权申明:资料由用户5a46a***提供,本站仅收录摘要或目录,作者需要删除请E-mail邮箱bigeng88@qq.com