FORTRAN 95 TO C / C translation system design and analysis
- Author
- HeLingLing
- Advisor
- GongTianFu
- School
- University of Electronic Science and Technology
- Major
- Computer Software and Theory
- Classification
- TP391.2 Translator
- Degree
- Master's thesis
- Year
- 2004
- Downloads
- 161
- Citations
- 1
Abstract
Fortran (Formula Translation in English acronym) in 1954 to design and practice on the IBM 704 machine in 1957 a high-level language, the 1966 American National Standards Institute (American Standards Association) announced ASA FORTRAN, until the development of the Fortran 2000. FORTRAN is the language of the typical emphasis on the implementation efficiency, simple structure, do not emphasize programming skills, and thus achieve the purpose of to improve the efficiency of the implementation. Fortran language is mainly used for scientific computing, as a numerical calculation tools, particularly suitable for solving the data is less computational complexity. In other countries, it is widely used in scientific computing (in areas such as aerospace, geological exploration, weather forecasting and construction works) and engineering simulation calculations. The calculation of a large number of reliable FORTRAN source code developed in DOS system has survived the test of time, is a mature and stable code, which is the sum of rare wealth. With the increasing perfection of Computer Science and Technology, fewer and fewer people using the FORTRAN language. In view of the powerful features and versatility of the C / C language, has become the most fashionable one of the most common language has become widely accepted. Some units, very much hope that FORTRAN77 early and recent FORTRAN95 source code into C / C applications with the same function, so that it continue to play a powerful role to facilitate the development and application of the procedure two. Looking at home and abroad, the existing f2c Automatic Translation Tool can be FORTRAN 77 application translated into the corresponding C language. However, this conversion tool also has some shortcomings. The most important is the the FORTRAN 95 adds many new language features, such as object-oriented functions, word processing functions, F95 competent information management system, office automation tasks to strengthen the power of applications in the field of numerical calculation and so on. This has led to the old translator can not translate existing the FORTRAN applications written with the new version. At this time, the design of the new translation system so that it can Fortran 95 applications translated into C / C applications, and has great market value and the value of scientific research. FTOC / C translation system described in this article is based on the basic principles of the translation program on select projects and programs, object code and object code in C / C did not reduce the reasons for the project difficulty. Furthermore, we project systems analysis, module and FTOC / C preprocessing module, lexical analysis module, syntax analysis module design ideas, and we have listed both FORTRAN 95 and C / C program corresponding to the part of the design language. Re-elaborated in Chapter VII of the end of the significance of the project and the need to pay attention to the problem.
Table of contents
Chapter Introduction 8-17
1.1 translation program 8-9
1.2 Brief Project Background 9-13
1.2.1 FORTRAN 77 application under WINDOWS calling program 9-10
1.2.2 Common program features and optional programs 10-11
1.2.3 select the target language 11 - 12
1.2.4 Analysis of C / C as the target language advantages and disadvantages 12
1.2.5 implementation difficult because 12-13
1.3 Importance translator 13
1.4 new direction 13-17
1.4.1 establish a dynamic link library 13-14
1.4.2 implementation of source-level conversion 14-16
1.4.3 generated intermediate code accepted formal system 16-17
Chapter II system design and implementation analysis 17-24
2.1 System Requirements Analysis 17-18
2.2 System design ideas 18-20
2.2.1 FTOC / C translation systems functional design 18-19
2.2.2 FTOC / C translation system structure design 19-20
2.2.3 FTOC / C translator design analysis 20
2.3 FTOC / C translation system overall idea 20-24
Chapter FTOC / C translation system preprocessing module 24-27
3.1 FTOC / C translation system preprocessing module 24
3.2 preprocessing module features 24-27
3.2.1 Removal editorial FORTRAN character 24-25
3.2.2 FORTRAN label processing 25-26
3.2.3 FORTRAN line continuation character processing 26
3.2.4 FORTREN comment statement translation 26-27
fourth Chapter lexical analysis of specific design and implementation 27-36
4.1 lexical analysis functions and modules introduced 27-31
4.1.1 FORTRAN lexical analysis particularity 27
4.1.2 Description 27-31
4.1.3 lexical analysis module process analysis 31
4.2 lexical analysis process several difficult processing 31-36
4.2.1 fixed format handling 32
4.2.2 Keywords are not reserved word 32-36
first five chapters syntax and semantic analysis of the design and implementation 36-52
5.1 object-oriented programming methods 36
5.2 Description statements translation 36-42 < br /> 5.2.1 Description Type Description statement 36-38
5.2.2 Type Description statements generally translate ideas 38-40
5.2.3 Type Description statement translation should be noted problems 40-42
5.3 data attribute statements translation 42-52
5.3.1 Introduction Data attribute statements 42
5.3.2 Symbols Table 42-52
Chapter FORTRAN 95 and C / C target statement match 52-58
6.1 target statement expressions match 52-53
6.2 part of the property statement match 53-54
6.3 I / O function statement 54-58
6.3.1 I / O content classification 54
6.3.2 FORMAT statement 54-58
Chapter VII Conclusion 58-60
7.1 FTOC / C meaning 58
7.2 FTOC / C where improvement is needed 58-60
References 60-62
Thanks 62
Related dissertations
- A Report on the Translation Practice of Japanese Garden
- A Study on the Exertion of the Translator's Subjectivity from Three English Versions of Wenxin Diaolong
- A Translation Project Report on Sustainability in Interior Design (P90-P106, P154-P177)
- Translator's Adaptation and Selection:a Study on C-E Translation of Signs in Scenic Spots
- A Comparative Analysis of the Translators'Subjectivities on English Versions the Analects of Confucius
- Project Translator Report of Accreditation Scheme for Museums and Galleries in the United Kingdom
- Benefits of Terminology Management in Professional Translation
- Style Consistency in Continuos Translation Projects from a Translator's Perspective
- On Influence of Translator's Cultural Identity upon Translation
- A Study of the Translation of Speech and Thought Presentation in Two English Versions of Chin P'ing Mei
- On the Subjectivity of the Translator in Sense and Sensibility a Comparative Study of the Translations of Sense and Sensibility
- Translators' Role as Reception Subjects in the Translation of Walden
- Feminist Consciousness Represented
- On the Translator's Habitus:a Bourdieusian Perspective on the Translation of Lu Xun's Fictions:Old Stories Retold
- A Study of Foreign Literature Translation Publishing of Zhonghua Book Company:from1914to1949
- Research and Implementation of the Translator for Special Description Language of the Symmetric Cryptographic Algorithm
- Research and Implementation of Several Key Components for SDLSCA
- Design and Implementation of Polynomial and Large-number Operation for SDLCA
- "Magic heart to pity the karma released" on us
- Influence factors of political documents translation