MATLAB有什么用?为什么大学如此使用它?什么时候比Python更好? [英] What is MATLAB good for? Why is it so used by universities? When is it better than Python?

查看:256
本文介绍了MATLAB有什么用?为什么大学如此使用它?什么时候比Python更好?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

最近有人要求我为一堂课学习一些MATLAB基础知识.

I've been recently asked to learn some MATLAB basics for a class.

是什么让它对研究人员和大学工作人员来说如此酷? 我看到处理矩阵和绘制事物是很酷的……(可以使用某些库在Python中轻松完成的事情).

What does make it so cool for researchers and people that works in university? I saw it's cool to work with matrices and plotting things... (things that can be done easily in Python using some libraries).

编写函数或解析文件很痛苦.我还处于起步阶段,我想念什么?

Writing a function or parsing a file is just painful. I'm still at the start, what am I missing?

在现实"世界中,我应该考虑将其用于什么?什么时候可以比Python做得更好?为了更好,我的意思是:写一些表演的简便方法.

In the "real" world, what should I think to use it for? When should it can do better than Python? For better I mean: easy way to write something performing.

更新1:我最想知道的一件事是我错过了什么吗?" :D

UPDATE 1: One of the things I'd like to know the most is "Am I missing something?" :D

更新2::感谢您的回答.我的问题不是关于购买还是不购买MATLAB.大学有可能免费提供我旧版本的MATLAB副本(我猜是MATLAB 5),而不会违反许可证.我对它的功能很感兴趣,如果它值得更深入的研究(我不需要除 basic MATLAB以外的其他东西即可通过考试:P),那么它的确比Python更好.现实世界中特定的任务.

UPDATE 2: Thank you for your answers. My question is not about buy or not to buy MATLAB. The university has the possibility to give me a copy of an old version of MATLAB (MATLAB 5 I guess) for free, without breaking the license. I'm interested in its capabilities and if it deserves a deeper study (I won't need anything more than basic MATLAB in oder to pass the exam :P ) it will really be better than Python for a specific kind of task in the real world.

推荐答案

亚当只是部分正确.许多,即使不是大多数,数学家也永远不会碰它.如果完全使用了计算机工具,它将类似于 Mathematica .另一方面,工程部门经常依靠它,并且对于某些应用数学家来说肯定有有用的东西.在某些领域,它也在行业中大量使用.

Adam is only partially right. Many, if not most, mathematicians will never touch it. If there is a computer tool used at all, it's going to be something like Mathematica or Maple. Engineering departments, on the other hand, often rely on it and there are definitely useful things for some applied mathematicians. It's also used heavily in industry in some areas.

关于MATLAB,您必须意识到的一点是,它是作为 Fortran 库上的包装器开始的用于线性代数.长期以来,它的态度是全世界都是双打(浮点数)".作为一种语言,它已经有机地增长了,如果您仅将其视为编程语言,就会发现很多缺陷.

Something you have to realize about MATLAB is that it started off as a wrapper on Fortran libraries for linear algebra. For a long time, it had an attitude that "all the world is an array of doubles (floats)". As a language, it has grown very organically, and there are some flaws that are very much baked in, if you look at it just as a programming language.

但是,如果您将其视为进行某些类型研究的环境,则它具有某些真正的优势.它和做浮点线性代数一样好.该符号简单而强大,实现快速且值得信赖.它非常擅长生成图和其他交互式任务.有大量的工具箱"带有良好的代码,可以很好地完成特定任务.有很多共享数字代码的用户社区(Python + NumPy 在同一个联盟中完全没有,至少还没有)

However, if you look at it as an environment for doing certain types of research in, it has some real strengths. It's about as good as it gets for doing floating point linear algebra. The notation is simple and powerful, the implementation fast and trusted. It is very good at generating plots and other interactive tasks. There are a large number of `toolboxes' with good code for particular tasks, that are affordable. There is a large community of users that share numerical codes (Python + NumPy has nothing in the same league, at least yet)

无论是疣还是其他,Python都是一种更好的编程语言(与其他许多语言一样).但是,在工具方面却落后了十年左右.

Python, warts and all, is a much better programming language (as are many others). However, it's a decade or so behind in terms of the tools.

关键点在于,大多数使用MATLAB的人实际上并不是程序员,也不想成为程序员.

The key point is that the majority of people who use MATLAB are not programmers really, and don't want to be.

对于通用编程语言而言,这是一个糟糕的选择;这很古怪,对许多任务来说很慢(您需要对事物进行矢量化处理才能获得有效的代码),并且不容易与外界集成.另一方面,对于它擅长的事情,它非常非常好.比较的东西很少.有一家公司在合理的支持下,谁知道投入了多少年工夫.这在工业中可能很重要.

It's a lousy choice for a general programming language; it's quirky, slow for many tasks (you need to vectorize things to get efficient codes), and not easy to integrate with the outside world. On the other hand, for the things it is good at, it is very very good. Very few things compare. There's a company with reasonable support and who knows how many man-years put into it. This can matter in industry.

严格地检查您的Python与MATLAB的比较,它们大多数是用于不同工作的不同工具.在它们确实重叠的区域中,很难说出更好的选择是什么(很大程度上取决于您要尝试做的事情).但是大多数情况下,Python并不能充分发挥MATLAB的核心优势,反之亦然.

Strictly looking at your Python vs. MATLAB comparison, they are mostly different tools for different jobs. In the areas where they do overlap a bit, it's hard to say what the better route to go is (depends a lot on what you're trying to do). But mostly Python isn't all that good at MATLAB's core strengths, and vice versa.

这篇关于MATLAB有什么用?为什么大学如此使用它?什么时候比Python更好?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆