Skip to main content

On the performance of Matlab and Parallel Computing


MATLAB is one of the most powerful scientific computing tools along with Python. Although Python is my favorite scientific programming language since it is opensource, well-documented and has plenty of libraries, I sometimes use MATLAB especially while dealing with very large matrices as MATLAB is highly optimized for large-scale matrix operations, consequently, it performs better at processing very large matrices.


From a parallel computing perspective, MATLAB actually strives to utilize all available CPU cores in a parallel way to maximize its performance and reduce the computation time when it is possible. Therefore, it does a kind of parallel computing when it is possible such as in matrix operations as these operations are very suitable to be run parallelly.  However, the parallel operation of the MATLAB might be restricted by bad coding practice of the users especially using for or while loops, because those loops are generally performed in a serial manner with an increasing or decreasing index.  Of course, MATLAB has advanced parallel processing libraries for more detailed operations, however, the best way to shorten the computing time and improve the performance of the calculation is avoiding implementing loops. For example, instead of performing K times MxN matrix multiplications in a loop, simply one KxMxN matrix (K, M, N are big numbers) multiplication would be enough, then the result matrix could be sliced if necessary for further operations. This would shorten the computation time by a great amount (10 times or more depending on the matrix size and operation) as this operation could be performed parallelly by Matlab using its core libraries.


Popular posts from this blog

Electromagnetic Modelling and Antenna Simulation via Opensource Software

Commercial electromagnetic simulation (EM) software packages such as CST Microwave Studio and  ANSYS HFSS are widely used in commercial applications and educational purposes. Based on my experience, they provide very accurate results which match measurements in most antenna works. On the other hand, there are also very solid opensource software and applications which may also provide similar results in some applications. Antennas are also used in radio telescopes While commercial EM software suits usually have very good documentations, easy-to-use interference, and result visualisation and navigation tools, opensource EM software suits might consist of only the solver and documentation which explains how it should be used and implemented for design and simulation via an interference and a programming language such as Python, MATLAB, C++ . As they are opensource, it is also possible to edit their codes and advance their functions and performance. Thus, these features makes openso...

15 Best IoT Energy Startups

15 Best IoT Energy Startups Energy is one of the common problems all around the world. Without it, all our technology will be useless. The interesting thing about energy is despite we have numerous sustainable and renewable energy sources; we still rely on scarce sources. Renewable energy is important because it provides a clean, sustainable and unlimited source of energy that can reduce our dependence on finite and polluting fossil fuels, helping to mitigate the impacts of climate change. Additionally, renewable energy can lead to local economic development, improve energy security and reliability, and create new jobs and industries. Wind power is one of the most important renewable energy sources.  On the other hand, the Internet of Things will change the trends in the energy industry as well. In fact, the number of IoT energy startups is worth mentioning. If you are interested in this field and love the idea of taking advantage of new technologies, then you need to know the foll...

Most Popular and In-demand Programming Languages in 2021

Top 5 Most Popular Programming Languages in 2021 If you are planning to learn to program, then we believe this guide will be an amazing source for you. We have covered everything that you need to know about the popular programming languages. Although, the programming language you need to use may vary depending on your purpose, this list will still be beneficial for you. Considering that the following programming languages are widely used in industry, learning one or two of these languages will greatly help you find fantastic job opportunities all over the world. Moreover, software programming and engineering jobs are the best options for the people who want to work from home (WFH) and home office. Software Engineer and Programmer What are the Best Programming Languages to Find a Great Job? We here present the obviously best programming languages that will also dominate the markets in 2022. It is still not too late to learn any of them since they will be around for at least a decade a...