Question: Why is Python (using NumPy) being significantly faster than MATLAB for my case? I am making a script in both MATLAB and Python which reads

Why is Python (using NumPy) being significantly faster than MATLAB for my case? I am making a script in both MATLAB and Python which reads an input mesh file (.inp) of about 2000~5000 elements of arrays (1 element ID and 8 nodes ID per line) to create a 3D file of the input (.stl format)

but for the same result, Python is currently about 10~20times faster than MATLAB, I've heard that MATLAB and Python speeds do not differ much for most cases, but in my case

python is significantly faster even though I've tried to optimize MATLAB codes (From loops to vectorization and etc)

Why do you think this may happen?

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!