converting c++ code to Matlab code using Matlab 9
im working on a project using matlab. i want to use some of the already writen codes in C++. i want to use these codes in my project rather than writing them from scratch. is there some way or a chunk of code that might convert C++ code to matlab code or a ".c" file to ".m" file. please if anyone knows do let me know at the earliest.thanks
"fatima " <email@example.com> wrote in message <firstname.lastname@example.org>...
> im working on a project using matlab. i want to use some of the already writen codes in C++. i want to use these c...converting c code to matlab code
can any one help me in converting c code to matlab code.is there any
software for it.
> can any one help me in converting c code to matlab code.is there
> software for it.
> thanking you.
Look up "MEX" and "Generic DLL" Otherwise, no.
...converting matlab code to C code
when i tried to convert the matlab code into c code using matlab coder i got below mentioned error, I am using R2011b(184.108.40.2064) my program uses image as an input parameter.
>> coder -build len.prj ??? This text contains non-empty top-level expressions. It appears to be a script. Error in ==> length_of_line Line: 1 Column: 1 Code generation failed: Open error report.
[x,y] = ginput(2);
Ired_length = sqrt ((x(2)-x(1))^2 + (y(2)-y(1))^2);
[x,y] = ginp...How to convert Matlab code into C code
I want to convert my matlab code into C code. Please let me know how
to do this? I am also watching for any help manual regarding this.
...How to convert matlab codes into C codes?
anyone knows if matlab offers such a function?
...Converting a matlab code to a c++ code
The SUbject is my question ;-)
How do i convert an existing matlab code into a c++ code ??
with a lot of manual work...
Yair Altman wrote:
> with a lot of manual work...
no automatic commands ??
Sam Rens wrote:
> The SUbject is my question ;-)
> How do i convert an existing matlab code into a c++ code ??
To do the job properly (i.e. C++ rather than C with // comments) the
process is something like:
1) Create yourself a matrix class.
2) Add enough methods and overloads to be able to mimic ML behaviour.
3) Transcribe the code....convert C code to matlab code
for (ix=0; ix< iNx; ix++)
for (iy=0; iy< iNy; iy++)
fMeanIn += pfIm0[X(ix,iy)]*pfu[X(ix,iy)];
fNormalizationIn += pfu[X(ix,iy)];
fMeanOut += pfIm0[X(ix,iy)]*(1.0-pfu[X(ix,iy)]);
fNormalizationOut += 1.0-pfu[X(ix,iy)];
the above code is C code.... how to convert this into matlab code.... i'm getting error in pfIm0[X(ix,iy)].... please help me to solve it out...
...how to convert Matlab code to C code
Can any one tell me how to convert matlab to c??
On 5/8/2012 4:36 PM, WMS wrote:
> Hi everyone,
> Can any one tell me how to convert matlab to c??
"MATLAB Coder™ generates standalone C and C++ code from MATLAB code"
...How to convert matlab code to c or cpp code?
I am basically a c programmer, and very new to matlab. Will the matlab
compiler generate c/cpp equivalent code to matlab code?
I tried with some of my files. Just it is generating a c file with
mail and interanlly calling the matlab code. For example
_retval = mclMain(_mcr_inst, argc, argv, "myFunction", 1);
Where myFunction is the matlab file. I didn't observe any code of my
function inside this c file.
I tried to generate one static dll by using some files and came to
know that i am not getting the entire source code for my files. Just
getting the export file which gi...