Serving the Quantitative Finance Community

 
User avatar
Droplet
Topic Author
Posts: 2
Joined: June 20th, 2004, 7:42 pm

Matlab -> C++ vs. C++

October 13th, 2004, 9:57 pm

Would appreciate yr help:What would be faster for Quasi MC: Matlab routine (reading pre-generated Sobol sequence from the file) compiled into executable using Matlab compiler toolbox and VC++ 6.0 , or the equivalent routine in C++ compiled directly from C++?Thank you, DROPlet
 
User avatar
hmerkinger
Posts: 0
Joined: May 10th, 2004, 6:39 pm

Matlab -> C++ vs. C++

October 14th, 2004, 7:37 am

The Matlab compiler produces executables from m-code. In my experience its mainbenefit is not speed improvement but solving the redistribution issue.Speed improvements are normally very modest, depending on code. You will almost always achieve better speed coding directly in C++, except for caseswhere your C++ code cannot keep up with Matlab's highly-optimized array-routines.Also do not expect that you will see a neat translation of your m-code(and depending Matlab commands called from within) to C++ by using thecompiler. You will get code that is good for compiling but not for directlyusing it.HTH,Hans-Marc
 
User avatar
Dostoevsky
Posts: 0
Joined: August 13th, 2001, 12:59 pm

Matlab -> C++ vs. C++

October 5th, 2005, 3:17 pm

QuoteWhat would be faster for Quasi MC: Matlab routine (reading pre-generated Sobol sequence from the file) compiled into executable using Matlab compiler toolbox and VC++ 6.0 , or the equivalent routine in C++ compiled directly from C++?You can get both routines ( developed by Prof. Sobol himself ) from BRODA and compare yourself