(C-mexfilesforMATLABencounterthefollowingproblemwhencompilingthemwithWATCOM11.0:Allaccess-functionstofiles(fprintf,fscanf)cannothandledoublevariables,onlyintegerandstringsarereadorwrittencorrectly.Thefileconvert.ccontainstwofunctions:Youmayreadadouble-variableasastringfromthefileandconvertittoadouble(functionstring2double)andyoumayconvertadoubletoastring(functiondouble2string)andwriteittoafile(seemain()inconvert.c).Thefileconditio.datisanexampleofnumbersreadbyconvert.c.Theconv.exewascompiledonaWindows95-system.ThefilesweretestedforMATLAB5.2andWATCOM11.0aresultof"ver"is:MATLABVersion5.2.1.1420onPCWIN) - IMDN开发者社群-imdn.cn">
登录
首页 » C++ Builder » BerndHafner

BerndHafner

于 2009-12-23 发布 文件大小:34KB
0 178
下载积分: 1 下载次数: 3

代码说明:

  C-mex files for MATLAB encounter the following problem when compiling them with WATCOM 11.0: All access-functions to files (fprintf, fscanf) cannot handle double variables, only integer and strings are read or written correctly. The file convert.c contains two functions: You may read a double-variable as a string from the file and convert it to a double (function string2double) and you may convert a double to a string (function double2string) and write it to a file (see main() in convert.c). The file conditio.dat is an example of numbers read by convert.c. The conv.exe was compiled on a Windows95-system. The files were tested for MATLAB 5.2 and WATCOM 11.0a result of "ver" is: MATLAB Version 5.2.1.1420 on PCWIN (C-mex files for MATLAB encounter the following problem when compiling them with WATCOM 11.0: All access-functions to files (fprintf, fscanf) cannot handle double variables, only integer and strings are read or written correctly. The file convert.c contains two functions: You may read a double-variable as a string from the file and convert it to a double (function string2double) and you may convert a double to a string (function double2string) and write it to a file (see main () in convert.c). The file conditio.dat is an example of numbers read by convert.c. The conv.exe was compiled on a Windows95-system. The files were tested for MATLAB 5.2 and WATCOM 11.0a result of " ver" is : MATLAB Version 5.2.1.1420 on PCWIN)

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • DAGUIMO-MIMO
    一个大规模的MIMO仿真平台开发程序,MATLAB仿真(A large-scale MIMO simulation platform development process, MATLAB simulation)
    2020-12-11 18:29:17下载
    积分:1
  • EndpointDetection
    基于短时能量的语音信号端点检测MATLAB源代码(Speech signal based on short-term energy source endpoint detection MATLAB)
    2010-10-13 22:55:28下载
    积分:1
  • GCD
    get Greate Common Divisor of two number (matematics)
    2010-02-07 03:23:27下载
    积分:1
  • CTPhf
    ctp海风实例 有修改 非常好的交易实例(ctp cthostftdctraderapi)
    2013-12-24 19:59:50下载
    积分:1
  • 可变遗忘因子
    本程序为遗忘因子最小二乘法,可以拷贝至matlab的M文件中适应(Matlab for ] least square method)
    2018-07-31 17:19:26下载
    积分:1
  • fuhe12110--o
    一个MATLAB报告,是电力系统负荷预测方面的(Report of a communication theory, written in great detail, is what MATLAB side)
    2010-06-07 21:31:31下载
    积分:1
  • ys
    说明:  用户在控制台输入任何一年份,可显示出该年的全部日历。(User at the console to enter any one year can be shown that all of the calendar year.)
    2015-04-13 12:53:39下载
    积分:1
  • mobile-robot
    移动机器人寻找目标的程序,让机器人从初始坐标到达目标坐标(Mobile robot to find the target program that allows the robot to reach the target coordinates from the initial coordinates)
    2014-08-13 11:12:35下载
    积分:1
  • matlab
    说明:  基于线性控制的分数阶统一混沌系统的同步的仿真设计(Synchronization of Fractional Order Unified Chaotic Systems Based on Linear Control)
    2019-05-09 01:05:44下载
    积分:1
  • jia
    说明:  多项式相加简单程序,欢迎大家评价~~~~~(Add a simple polynomial procedure, welcome to evaluate ~~~~~)
    2010-04-05 17:40:38下载
    积分:1
  • 696518资源总数
  • 106148会员总数
  • 10今日下载