(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 213
下载积分: 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 个回复

  • PhoneMS
    Phone Management System
    2014-11-25 19:16:10下载
    积分:1
  • MatlabaCSharpmitrix
    C#和matlab的混合编程,总结了一些matlab与C#的相关方法(C# and matlab mixed programming, summarizes some relevant methods of matlab and C#)
    2013-12-25 12:23:11下载
    积分:1
  • MPC_TrajPlanner
    说明:  基于模型预测控制算法做自动驾驶车辆轨迹规划(Trajectory planning of autonomous vehicle based on model predictive control algorithm)
    2020-05-16 19:24:48下载
    积分:1
  • Final-Game
    "Guess The Number" Gae For Beginers.
    2013-12-12 21:10:34下载
    积分:1
  • xinxilun
    排队论模型仿真程序。用MATLAB实现 。欢迎大家一起讨论(Queuing theory model simulation program. Use MATLAB to achieve. Welcome to discuss with)
    2010-01-26 18:06:55下载
    积分:1
  • art-cpp
    《實戰C++ — 八個別具特色的實作經驗》與目前市面㆖ 眾多C++ 書籍的最大不同,在於 本書既非基礎觀念之教㈻ 書籍,亦非開發工具之使用手冊,而是以「㆒ 章㆒ 專案」的方式, 從實際應用面引領讀者領略C++。 本書是《The Art of C++》的㆗ 文譯本。原作者Herbert Schildt 是㆒ 位㈻ ㈲ 專精、著作等身的 IT 技術作家,其作品普遍獲得良好評價。(err)
    2007-11-22 15:39:38下载
    积分:1
  • kalmanfilter
    说明:  包含一个VC程序和几个matlab程序一个基于Opencv的预测随机运动的点的经典例子(kalman fiter)
    2009-08-04 09:12:10下载
    积分:1
  • MPC_project_dehghani
    This mfile is the simulation of CSTR control with new GPC
    2013-07-26 16:16:16下载
    积分:1
  • utd
    文章有utd对爬行波进行循迹 给出微分几何算法 可在matlab 及vc来开发(Utd article has crawling wave of differential geometry tracking algorithm is given in the matlab and vc to develop)
    2008-07-07 16:40:00下载
    积分:1
  • fmeasure
    MATLAB FocusMeasure to C++ Convert alg
    2015-04-02 14:48:40下载
    积分:1
  • 696516资源总数
  • 106914会员总数
  • 0今日下载