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

Fortran与C/C + +共享公用外部数据
引用本文:任慧,周振红.Fortran与C/C + +共享公用外部数据[J].郑州大学学报(工学版),2007,28(4):63-65.
作者姓名:任慧  周振红
作者单位:1. 郑州大学,电气工程学院,河南,郑州,450001
2. 郑州大学,环境与水利学院,河南,郑州,450001
摘    要:在Fortran与C/C 的混合编程中,数据主要通过例程参数传递,这使得被调用例程接口的设计趋于复杂化,有时不能直接利用现有的算法例程.现提出另一种数据传递方式,即在这两种语言间共享公用外部数据,包括全局变量和共用区/结构体.示例结果表明,只要采取适当措施,Fortran与C/C 共享公用外部数据是完全可行的,从而为这两种语言间传递数据提供了一条新途径.

关 键 词:数值计算  混合编程  公用外部数据  共用区  结构体
文章编号:1671-6833(2007)04-0063-03
修稿时间:2007年9月10日

Fortran and C/C + + Sharing Common External Data
REN Hui,ZHOU Zhen-hong.Fortran and C/C + + Sharing Common External Data[J].Journal of Zhengzhou University: Eng Sci,2007,28(4):63-65.
Authors:REN Hui  ZHOU Zhen-hong
Abstract:In mixed-language programming with Fortran and C/C ,data are mainly passed through calling argument lists,resulting in routine interfaces becoming complex and making it hard to use directly some routines at hand.In the paper,a new way of data passing is presented,namely Fortran and C/C sharing common external data,including global variables and common blocks/ structures.It has been proved by the experiment to be workable only of appropriate measures are taken,so it is a new method in which data are passed between Fortran and C/C .
Keywords:numerical computation  mixed-language programming  common external data  common block  structure
本文献已被 CNKI 万方数据 等数据库收录!
设为首页 | 免责声明 | 关于勤云 | 加入收藏

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