首页 | 本学科首页   官方微博 | 高级检索  
     检索      

混合编程与FORTRAN计算程序图形界面的实现
引用本文:朱从旭.混合编程与FORTRAN计算程序图形界面的实现[J].中南大学学报(自然科学版),2000,31(6):561-564.
作者姓名:朱从旭
作者单位:中南大学信息科学与工程学院,湖南长沙41∞83
摘    要:针对FORTRAN语言计算效率高而图形功能弱,VisualBasic(VB)计算效率低而图形功能强的特点,采用VB和FORTRAN2种语言混合编程,充分利用各自的优点,实现FORTRAN计算程序资源的再利用.此外,探讨了2种实现FORTRAN计算程序可视化的方法一是通过磁盘文件在VB程序和FORTRAN程序间交换数据,并借助WindowsAPI(应用程序编程接口)函数实现FORTRAN外壳程序在VB中同步运行,使FORTRAN外壳程序的计算结果在VB图形界面上显示;二是将FORTRAN程序转化为动态链接库函数,通过函数参数传递使VB程序和FORTRAN动态链接库函数之间交换数据,将FORTRAN的计算结果在VB窗体上显示并进行作图处理,从而实现了FORTRAN计算程序的图形界面及计算结果的可视化

关 键 词:FORTRAN语言  外壳程序  动态链接库
文章编号:1005-9792(2000)06-0561-04
修稿时间:2000年5月2日

Programming with mixed language on the realizationof graph interface of FORTRAN calculation program
ZHU Cong-xu.Programming with mixed language on the realizationof graph interface of FORTRAN calculation program[J].Journal of Central South University:Science and Technology,2000,31(6):561-564.
Authors:ZHU Cong-xu
Abstract:In the light of the characteristics that Calculating efficiency of FORTRAN language is high but its graphic function of it is weak and the contrary characteristics of Visual Basic (VB) is low but its graphic function of it is powerful, the author programmed with mixed languages of VB and FORTRAN, so that their advantage can be utilized adeqately, and the purpose of reusing resources of FORTRAN calculation program was realized. Two methods of realizing graph interface of FORTRAN calculation programs were explored. One of them is exchanging data between VB program and FORTRAN program by disk files, drawing support from Windows API functions to realize FORTRAN shell program run in VB in synchronism, and showing calculating results of FORTRAN shell program on VB form. The other method is to change FORTRAN program into Dynamic Link Library (DLL) functions, exchange data between VB program and FORTRAN program by transmitting parameters of functions, show calculating results of FORTRAN DLL functions on VB form and draw graphs for these results. Thus the graph interface of FORTRAN calculation program is added and the results of calculation are visualized. Some techniques of programming with mixed language are discussed in this paper.
Keywords:FORTRAN Language  shell program  dynamic  link libraryL
本文献已被 CNKI 万方数据 等数据库收录!
设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司  京ICP备09084417号