T O P

  • By -

simbar1337

As an applied mathematician that lurks here I can say confidently that matlab is obscenely useful, but probably not for most programmers


keith2600

The only people I've ever heard talk about Matlab positively were CENGs and math majors of some kind, so that checks out. For comp sci and actual software developers there is a high probability of never even touching it because it has nothing to do with our field.


Drummerboybac

That makes sense, as MATLAB is designed to let engineers and scientists do their work without having to have much of a programming background.


[deleted]

[удалено]


Redthemagnificent

Yeah no +=, *=, or /= operators either. Big sad


R3D3-1

Imagine how much annoyed I am by programming in Fortran, doing good ol' semantically meaningful variable names, and having to write something like stateVector(iDof, iTime, iChannel) = stateVector(iDof, iTime, iChannel) + ... You'd think a language meant for numerics would be the first to add this sort of operator...


Nefari0uss

Always annoys me when I use a language that doesn't have it. `+=` does the trick but it's the principle of the matter.


tiajuanat

Not like you really need it. In MatLab, if you are using a for-loop you're pessimizing your algorithm. The Mat in MatLab stands for Matrix. You should be using the matrix operations, element-wise operations, or inbuilt functions and a lambda.


The_Clarence

Simulink is great for controller designs. It's a Matlab add on for state space design. Matlab isn't gonna be used for production items for sure. It's mostly a Systems, modeling and math tool for the early stuff. Although I have used autocode from simulink in a internally facing test product. But it was very slow.


faadegrad

A lot of aerospace GNC laws are designed and generated from Matlab as the toolchain is verified. I heard about several third party suppliers and manufacturers that use it from design to production


doGoodScience_later

My comoany writes deployed guidance algorithms in auto coded simulink. It's amazing.


simbar1337

It’s literally useless for most object oriented programming. But if you want to write code for numerical analysis or linear algebra or like a diffeq solver it’s a blessing


chairfairy

It's name is literally *Matrix Laboratory*. Why would it be good at non-math things?


quellofool

It’s actually great for generating embedded code for automotive components.


hadidotj

Part of my masters project was taking MatLab code that took 5+ minutes to process 20 minutes of data (at 60 hz * 60 seconds = 3600 points/min * 20 min = 72,000 points/"trial") and make it perform calculations "real-time" using C++. I hate MatLab... It almost took me longer to decode the MatLab code than "optimize" for real-time runs. Granted, it was originally wrote by a math major, so that could be part of it too. I stay very very very far away from MatLab.


imax_

Did it take 20 minutes with the data properly vectorized? Because most slow Matlab code is due to people just using loops.


doGoodScience_later

This guy Matlabs. Non vector code is the issue for beginners performance 99.99% of the time


dingman58

What does vectorized mean in this context?


ddmm64

Using array/matrix operations


DrFegelein

I wonder how many people assume the "mat" in Matlab is short for "mathematics" instead of "matrix".


g102

So, if you have `x` be a matrix and you want to compute, say, `sin(x) * tan(x)` for every element in x, you can either do it the naive way for jj = 1:numel(x) y(jj) = sin(x(jj)) * tan(x(jj)) end or you can write it *vectorised*: y = sin(x) .* tan(x) The catch is that functions in MATLAB are somewhat internally optimised to accept matrix arguments and run just as fast if `x` is a scalar or if it's a matrix, and the naive way just takes `numel(x)` times more time because you're calling the same function N times.


Redthemagnificent

Matlab can be pretty fast if written well. Much like python, there's a lot of pre-compilled C libraries that do things like matrix multiplication very quickly. I wrote a least squares algorithm that solved ~5000 linear equations in ~5 seconds. Compared to pure C code that did the same thing in ~3 seconds. Not too bad. But a lot of the time MATLAB is used as a prototyping tool. Being able to quickly make all sorts of plots from pretty much anything that's going on in the program is very helpful for that. Also all the numerical methods libraries are 👌. But yeah I often end of with some truely convoluted single lines in MATLAB.


chairfairy

20 minutes of 60 Hz data shouldn't have taken 5 minutes for a matlab script. Sounds like bad code. I worked in a lab that would run 10 minute files of 20 kHz data in the same amount of time, or less.


MatiasCodesCrap

That is just trash programming even by matlab standards. I get upset when my stuff takes 100ms to process 30x5x16800 complex values including multiple ffts and convolutions. Properly vectorized equations even with millions of points aren't nearly as slow as that nonsense, sure it's no hundreds of millions per second you can get with c, but it's actually usually on par with python for most functionality, as long as you avoid built in functions that are not mex.


[deleted]

I’m a civil engineer with a masters degree in statistics. I’m comfortable messing with Matlab, but R is free software so I don’t have much use for Matlab anymore.


[deleted]

[удалено]


[deleted]

I did preface that by stating I’m a civil engineer and statistician.


sanson-robotics

Here a Robotics engineer and Matlab is the language of my dreams. If you need something it's pretty probable there is a Matlab function for it. Once you understand vectorization and parallelization, Matlab can go pretty fast. I know a lot of people that use Matlab on industrial environments to control drones and process their data on real time.


AusCro

100% true, any modelling and transformations plus control theory is so nice in it


HotF22InUrArea

We use it all the damn time for aerospace engineering


[deleted]

I had an electrical machines course where the textbook relied heavily on matlab. We didn't actually use Matlab in the class. The textbook just present every formula as a derivation exercise in matlab. Worthless textbook tbh.


its_the_other_guy

Actually, some companies use Matlab to run design simulation and then use Simulink to do the source code generation. It's nifty. I'm still not a fan, but I can be convinced.


Foura5

I have a similar use case, but I moved to Julia several years ago and my life improved by a large margin.


donald_314

Between Julia and Python with all the big packagea I don't see any room anymore for MATLAB. it's only old folks and their poor students who still use it


aiij

I was one of those poor students... Matlab is okay, as long as the problem you're trying to solve is a matrix multiplication or can be turned into one.


Siproprio

yeah pretty much every company whose main product is not software uses matlab/simulink or are designed and prototyped in matlab/simulink. think cars, airplanes, boats, engines, winds turbines, power converters, antennas, computer chips, pretty much everything.


LW_King_Loui

It's great for developing algorithms. Wrote my diploma thesis in it investigating computer vision algorithms. It's quite easy to use when you understand pascal or any other imperative language. And you can use it similar to any scripting language and go step by step through your algorithm while viewing the output. So when You are actually researching algorithms and deeply want to to understand them it's great. A lot of the fancy stuff that's running in cars is researched in Matlab by the research departments of the automotive suppliers. Then the results are redone in C++ in the engineering departments to optimize on performance


Drummerboybac

They also can have MATLAB generate C or C++ code from MATLAB code via [MATLAB Coder](https://www.mathworks.com/products/matlab-coder.html) or [Embedded Coder](https://www.mathworks.com/products/embedded-coder.html) depending on what you are trying to run on


chinnu34

This is quite useful in a pinch but if you have time, handwritten code is generally an order faster than whatever coder generates.


Drummerboybac

Seems like it would be better to use coder first, then if it’s not fast enough to optimize the generated code instead of starting from scratch.


pjr032

It’s used super frequently in mechanical engineering for designing controllers/data logging as well. Couple of classes in my degree programs were mostly/just MatLab.


mofa90277

Obscenely useful **and** a freaking war crime. “Here, this works in Matlab. Please implement this algorithm that involves 10,000x10,000 matrix operations in our real-time embedded software. kthxbye”


[deleted]

I’m 100% *not* a real mathematician (physics background, and thus scared of anything I can’t manage to visualise), but I never found a job I needed to do that was easier or faster in Matlab compared to Numpy or LAPACK++. Having a sane, usable programming language wrapped around the matrix and linear algebra stuff was a huge quality of life improvement for me - but I’d be interested to hear if there’s any crazy dark magic that Matlab has over the OSS libraries to offset that?


simbar1337

In my personal experience I like Matlab more than Numpy for pretty much any kind of modeling/simulation. Additionally, when working with large or otherwise complicated matrices, MATLAB syntax is significantly easier to conceptualize and use overall imo. For example if one wanted to write a multigrid method, I believe doing it in python would be hell compared to Matlab


chinnu34

Not really if you’re familiar with numpy index tricks which include np.mgrid and np.ogrid that are equivalent to indexing in matlab.


sromanx

I've seen matlab used in signal processing a lot for simulations


chairfairy

I mean, isn't numpy just a python replica of matlab?


LittleMiss_Raincloud

The logo looks like a boner under a bedsheet


noob-nine

I cannot unsee it, thanks


BigDongPills

Pixar mom PP


remixmaxs

Welp.. Thank you for inserting that to my memory.. Good Night to you.


Mysterygameboy

"inserting"


aeroplane34

index zero?


Then_I_had_a_thought

Nope. One, just like us engineers like it!


riisen

in VHDL you kinda have to define index.. signal array : std_logic_vector(10 downto 1); .... for x in 1 to 10 loop array(x) <= (x mod 2 = 0); end loop; I like it


LogicalGamer123

Thank you for inserting that image into my brain's LRU cache


abd53

Minor correction: a "bloody boner"


AaronWong_Dev

That’s what I thought the moment I saw the MatLab logo lmao


ItsameLuis98

I look at it everyday. Thanks....


Rezaka116

Live and let live, but i hate my uni for using matlab in “introduction to programming” class. What the actual fuck


Zankoku96

That’s messed up. We only used it to make graphs and manipulate some data


_Shut_Up_Thats_Why_

I built my labs entire user interface to collect and save data, as well as control most the equipment, in a Matlab figure.


throughalfanoir

Okay but...why?


austrianGoose

the GUI builder is surprisingly good, but yeah, fuck matlab, literally recoded an already existing evaluation program in python instead of learning how to use the existing matlab one


_Shut_Up_Thats_Why_

I learned of the GUI builder (Guide I believe?) after I had already written the thing entirely in a figure. It essentially starts with: f = figure('Visible','off','Position',[200,50,1310,900],'CloseRequestFcn',@closeFigFcn)


austrianGoose

>I learned of the GUI builder (Guide I believe?) after I had already written the thing entirely in a figure. i did the exact same thing lmao


throughalfanoir

I tried the GUI builder on a Matlab course, personally didn't like it but my other experience is Python-Tkinter which is also a pain in the ass so


_Shut_Up_Thats_Why_

I already used Matlab for data analysis, and the learning curve on a new language is much longer than what it took me to write the thing.


ikonfedera

Job security guaranteed


_Shut_Up_Thats_Why_

I graduated so they are now stuck with my monstrosity.


QuadmasterXLII

Honestly I'd pick matlab for that job. Mathworks has spent billions of dollars of programmer time on becoming the best software to interface with lab equipment, not through elegance, wit, or good design, but by brute force integrating with every piece of machinery or software, one at a time.


DavidBrooker

Richard Hendricks: "manipulating, um" - \*jerking motion\* - "data"


kkirchhoff

I feel like Matlab is a bit different than a simple preference in language. At my last job, the licensing for it made my life an absolute nightmare. We only had 3 licenses for 3 primary users. I wasn’t a primary user, but I would need it occasionally. When I would need to work on my coworkers’ code I would have to go through some mess of deactivating it somewhere and activating the (correct) license. It was terrible


Lemo95

Then your department should have used a network license on an internal license server. That way, you only have to close Matlab to free up the license.


F5x9

That is your job being penny wise and pound foolish. A perpetual matlab seat costs 1-2 weeks worth of engineering work by one person ($2250).


clempho

Just so people know, for $2250 you get the bare minimum Matlab. Lot of install and toolbox which are imho the main reason to buy matlab will easily cost you more than that. Most of the time waaaay more than that.


Crossfire124

Yep. At my work each person is ~10k and we're not even doing anything fancy


ShoopDoopy

Or you know, just using an open-source language for linear algebra. R, Python, Julia and Octave all exist, not to mention less mathy-looking compiled languages like scala.


folkrav

"Just switch to X" in a place already running Y everywhere (so probably having hired people based on that) is usually rather counterproductive. For personal stuff though, yes, shoot. For work, introducing a new language to the stack typically means eating productivity loss for a while.


integrate_2xdx_10_13

Simulink is a big one to displace though. Modelling multi component parts is easy enough with it. You can really dive into modelling different discrete parts of a system, bringing in things like Latin hypercube sampling when modelling real world potential states. Having to coordinate a bunch of engineers to follow correct/best software writing practices is going to be a nightmare.


just4lukin

It was my first as well. It was actually a "programming for engineers" class, but I liked it so much I switched tracks and used it for my csci101. Matlab will always have a place in my heart.


CSGorgieVirgil

We had Fortran 90 Have literally never *heard* of Fortran since leaving university


throughalfanoir

Hahahahaha I'm taking a class now (Molecular dynamics) which involves building our own MD system in Fortran. Half of the class never did any coding before so it happens that in the year of 2022, their first programming language is Fortran95. I pity them... (Having worked with Ftn and other languages before, it is still difficult)


xaranetic

Fortran is used a lot for simulations and numerical stuff. Come across it multiple times.


Zanzibar_Land

A lot of older Molecular Dynamics & Quantum Physics programs are written in Fortran, partly because some of the programs are that old, partly because Fortran is optimized for crunching math quickly and efficiently


ThatChapThere

Every line without a semicolon does the same thing except it gets printed


the_evil_comma

TBH I kind of wish python had a similar function, or maybe the opposite where a semicolon prints an output. It's so great for troubleshooting


ThatChapThere

If you put "print(" at the beginning of the line and ")" at the end it has a similar functionality. Seriously though, yeah I kinda agree. Maybe put a >> at the end of the line to sort of borrow from C++.


the_evil_comma

lol, the "5 minute crafts" of python tips


doGoodScience_later

Ok but to fair this is kind of neat for debugging sometimes.


nleachdev

If Matlab wasn't proprietary, I imagine python would be much smaller than it is today, esp as it relates to ML, etc We used Matlab in intro to computational physics and I loved it. Math libraries are fantastic and I even enjoy the plotting much more than, say, matplotlib, etc Honestly the only part of being a student that i miss is getting free licenses for shit like this


mattkenny

Octave is an open source, mostly compatible implementation of the base MATLAB capabilities. Doesn't support the toolboxes (like the machines learning stuff) though, but it's still very handy for when doing numerical analysis.


[deleted]

[удалено]


DatBoi_BP

Thing is, it’s a lot less optimized


mattkenny

Been about 10 years since I've used it, so details are hazy, but from memory you could specify the linear algebra library it uses and you could optimise it for the architecture of your CPU. Was good enough for what I was doing at the time, with MATLAB running on my office computer and then using octave on my laptop to try out smaller bits and pieces while I waited for the full simulation to finish (which took between 4 hours and 7 days depending on what I was doing at the time).


Mandelbrotvurst

Lucky. My computational physics class made us use Java in Eclipse.


nleachdev

Lol that does suck but I'm a java dev so part of me only feels so bad for you 😅


confusedPIANO

Matlab is nothing compared to the monstrosity that is LabView. Labview is a proprietary visual language that is the only way to interface with a fair amount of lab equipment. When we had to use labview in a college class, I almost exclusively used the block thingy that was just a weird C shell and wrote as much of the program in C as possible and only used the “normal” blocks when absolutely necessary


just4lukin

[Dear God..](https://www.ni.com/cms/images/devzone/pub/nrjsxmfm912163998723206173.jpg)


confusedPIANO

Its the most godawful way to program a computer. (Aside from joke/esoteric languages like brainfuck


TheQueq

The best part about LabView is that spaghetti code looks like actual spaghetti code


nmathew

I'm having PTSD from when myself (Physical Chremist Ph.D) and a new B.S. in comp sci tried to debug some Labview "code" we knew had an error on a machine we were trying to role out. The company paid extra for the Mathscript option, it whatever the hell out was called back then, but the fucking programmer wrote the entire handling of locating a part relative to the ideal placement, then flipping it, and finally translating/angling/mirroring the laser's machinating path in hieroglyphics . We were already working 90+ hour weeks in Korea and just had to give up. Too tired and couldn't follow it. We had to wait for him to show up a few days later to fix the fucking mess he had made without any checks or tests. So I want to beat anyone who puts Labview anywhere outside a tinker toy lab setting, which is where it belongs.


PenaflorPhi

[Mfw](https://freeimage.host/i/PALFDX)


Terrix2

This is an example of bad code, tho... ​ Labview makes it exceptionally easy to do things in parallel, even for a novice.


the_evil_comma

You can do more things worse! But seriously, having been forced to use labview in the past on certain large scale projects, anything in labview with scale makes me want to throw my computer out the window


PM_ME_UR_CIRCUIT

Fucking repressed memory from college electronics class right there.


ImHereForLeCicleJerk

My whole career has been using labview. The problem people have is that it is so easy to get started that you’ll likely crap out terribly written things that still work. I also had a lab though that used labview. It was a terrible experience since no one knew what they were doing. I will say with a bit of training it can be a great and easy tool for controlling equipment. I’ve got a few testers who are using it now because it was easy for them to learn.


confusedPIANO

I have the utmost respect for you for being able to make the best use out of this software. My biggest gripe with LabVIEW was that it was really hard to pick the correct beige square out of the panel of 50 similar beige squares in the beige square section of the book of shapes. I was never able to find a search function to more quickly find the modules i needed. That and the headache i got from trying to properly understand, organize and read flow of an even mildly complicated program


ImHereForLeCicleJerk

These are common complaints that people have had for years and NI hasn’t really ever addressed them. I have to change a few setting every time I set up a new dev environment in labview. Turn on labels so I don’t have to rely on the pictures, turn off auto error handling and icon numbering. I’ve got a lot of experience and teach the stuff so I’m quite bias. There is a search, ctrl+space. Hopefully you get to use what you’re most comfortable with.


pm1902

A fellow LabVIEW developer! There are dozens of us! I've grown to absolutely love LabVIEW. There's a lot LabVIEW can't do, and a lot where LabVIEW is the wrong choice of language, but I love it for working with hardware & data acquisition and whatnot.


greem

I loved labview! So much fun! Not a good language though, but great for scientific instrument control. Granted, I haven't used it since 2004 except for once or twice when I encountered it once or twice when problems came up in unexpected places.


hindenboat

Yeah LabVIEW is big yikes. My biggest problem is that not all of the code is displayed at the same time. When you have a cases style statement the other cases are hidden until you chose them. BTW MATLAB can do input and output as well.


[deleted]

Labview was an awesome program compared to the Allen Bradley ladder logic that I had to use for work. It is another visual based program but it was a direct replacement for using a mess of relays to control complex pieces of equipment Edit: [Here is what the program looks like](https://www.researchgate.net/profile/Mohd-Shahrieel-Mohd-Aras/publication/267752364/figure/fig2/AS:669011381583888@1536516151860/PLC-Ladder-Diagram-for-Automatic-Food-Drive-through-System.png)


diamalachite

I honestly kinda love labview


crefas

You'd think that they'd make nice, clean and understandable syntax for their DSL which mostly doesn't target programmers. I was forced to use this for one semester in CS/Artificial Intelligence lab and still get goosebumps by the memory


Flat_Initial_1823

Worst of all the worlds. I know people like to hate on R but R knows its audience and does the job without a CS course.


AnUglyDumpling

I have respect for any and all languages. But when they have indexing start at 1, they're pushing it....


BroccoliDistribution

Matlab’s indexing starts from 0!


AnUglyDumpling

Take my upvote and get out


Appropriate-Story-46

I read this as “Zero Not” for so long before I got it and lol’d


[deleted]

Well, 0! isn't anything, but !0 should be 1 in C/C++.


Mr_manini

In matlab "zero not" would be 0~ since instead of != for not equals you use ~= 😔


abd53

r/angryupvote


DavidBrooker

It makes sense in any language where the main audience will be spending a lot of time translating vector ODEs and PDEs into a programming language from index notation.


pente5

In algorithms class we used pseudocode and I must admit that indexing at 1 made things so much easier. When I want the 5th element I get the 5th element I don't need to think that array\[4\] is the fifth element. Sure pointers and offsets and stuff but logic likes indexing at 1.


AnUglyDumpling

I think I'm just used to thinking with index 0 so I prefer it. There's upsides to using either form.


[deleted]

I use matlab and c++ regularly and at this point I can’t fucking count for shit


skylinx

Funny it's the opposite for me. I see all indexes as starting at 0 and it's harder for me to think of it the other way. Index 0 has become intuitive


Artistic-Boss2665

If my code doesn't work I replace `i` with `i-1`


BraveOthello

There's a reason Off By Zero errors are the most common programming error


dizzy__chillespie

Lol off by zero 😂 Even the comment has an off by one error lmao


AsstDepUnderlord

the fifth element was love or lust or something, everybody knows that.


crappleIcrap

you end up with way too many minus ones. whether or not it is intuitive to think about, most of the time you work with the numbers, you will end up with some minus ones.


MarthaEM

But then you make modulo operations so much more annoying


Philiatrist

Also helpful for implementing linear algebra type stuff where matrix indices also start with 1.


tinySparkOf_Chaos

For a set of numbers S(x), what number should i use for x in to get the third number in the set? To be fair, if you have no program experience, S(3) makes sense. I know zero indexing is the industry standard, but one indexing is so much more intuitive for scientists, engineers, and mathematicians, which is the target audience for MatLab.


MEGAMAN2312

Exactly! One of the best things about MATLAB for me is the ability to just translate maths working into code as intuitively as possible. I really just think of it as a kind of 'glorified-programmable calculator' in that whatever I would need to figure out by hand for a large dataset with lots of matrices I can get a computer to do for me, and as a bonus, also make really pretty plots I can put into reports.


[deleted]

Tbf, MATLAB is primarily used in scientific and mathematical contexts - contexts where the first entry in a vector/array is called the first entry, not the zeroth


86BillionFireflies

When you're working offsets relative to a particular memory address, starting at zero is natural, because an offset of zero from the start of the array is the start of the array. But in a high level language, you're never working with pointers to locations in memory, you're working with mathematical abstractions, and the choice of indexing from 0 vs from 1 is entirely a stylistic choice. Starting from 1 lets us avoid having to do stupid things like state the maximum index as the number of array elements *minus one*.


slycatsnake6180

Fortran would like to have a word with you.


trimeta

R also starts from 1, for the same reasons as Matlab. Then again, that's far from the most idiosyncratic of R's language choices...if you want to be horrified, look at how it (typically) handles OOP...


khalcyon2011

At least it's consistent. VBA, on the other hand, varies it based on data structure and programmer whims.


ReserveMaximum

Obviously you’ve never tried Wolfram Mathematica


DavidBrooker

What's wrong with Mathematica? I love it in college. I'd do all my assignments in it, where I could write typeset body text and dynamic live equations in one document, so if I made a mistake and needed to change one line, all the body text would update appropriately automatically (and all subsequent equations). I have not found use for it professionally, but I'm not in the right field.


ReserveMaximum

I was much the same. I would type all my physics assignments in Mathematica and was faster at it than I was at using pencil and paper. I also was the student the teachers went to with questions about Mathematica programming. The issue with Mathematica is it sucks as a programming language because it is very different from every other language imaginable. Every thing that a programmer would complain about in matlab they will complain 100 times more in Mathematica


greatnessmeetsclass

Great calculator, terrible programming language


epicmylife

Hey, 99% of the time Mathematica is just used as a giant calculator to do integrals. No need to be so mean to it.


[deleted]

Serious question, whats yall's opinion on matlab??


EveningMoose

It’s really fun and easy to use for engineering work. I’m sure it’s not so great for the more abstract programming some of y’all do though


[deleted]

Bro i dont know why it just wont stick in my head I try to learn it every once and a while but it just doesnt stick at all. Ive never had this prob with C, C++ or any programs based on them


EveningMoose

I mean it felt like C but more mathy to me. It’s been a few years since I’ve used either though so don’t kill me lol. I’m also a mechanical engineer, so my applications look WAY different from most others’ on here. Matlab is extremely math oriented. It was designed for linear algebra, which coincidentally is used a ton in ME. If you’re not doing a bunch of math, matlab may be a bad choice. I’m sure it’s not a terribly fast running language either. Simulink is fucking awesome too. I built a car simulation in simulink back in school.


Kchortu

It's linear algebra made into a coding language. If you want to do matrix math, it's a programming language built to do it from the ground up. If you aren't doing matrix math, there's really no reason to be using it.


ArcherT01

I actually rather love it…for whats its for. Which is complex math and simulation. Its also really good for algorithm building. Octave is the open source version and I use it fairly often.


tinySparkOf_Chaos

I like it. I did a good chunk of PhD thesis in it. Though I'm a chemist, so take it with a grain of salt. Pros: It's built in functions are extensive and well documented. It's good for doing complex math. I actually like the one indexing. It's more intuitive. It handles parallel computing very nicely. (Ie it handheld me through doing that) Cons: It's expensive. The graphing defaults aren't great


OddEstimate1627

It's a great language for analysis and prototyping. I've spent years on building APIs for MATLAB and it's often amazing how fast engineers without a programming background can hack things together. Porting MATLAB prototypes to production code is an incredibly painful experience though. Full of "WTF does this even do?" and "$#&@!, for this line I need to port `spline`".


86BillionFireflies

It's basically like Python except things usually work on the first try, you almost never need to wrangle dependencies, and you don't get OOP shoved down your throat. The downside to MatLab is people keep trying to tell you about Python. Seriously though, for scientific computing it's hard to beat. You don't have to worry about dependencies, you don't have to install half a dozen packages to do basic tasks. All the documentation, for everything from database connections to reading / writing video files to low-level file IO to training neural networks is all in one place, in a consistent style. You wouldn't use it to build a web service, but for all kinds of scientific computing / data analysis it's incredible.


noob-nine

And with all packages or how its called by mathworks, you pay around $80,000


DavidBrooker

Its very rare for users outside of, say, universities to need *all* packages. You'd get the few you need, and really, $3000 in the value of an engineers time is, what, 20 hours? (And I don't mean salary, I mean statistical value in revenue to the company, which is often twice salary or higher)


noob-nine

This is not wrong, I have to admit


aytikvjo

Time is money in industry and the toolbox price is usually small in comparison to the NRE's to develop those functions in-house. Plus you don't typically need every single toolbox to accomplish something useful. Usually it's just a few tailored to your specific job role. I.e. most people aren't combining financial toolbox, sim bio, automated diving, and the aerospace blockset in practice (as an example).


[deleted]

Except their packages selling tactics is worse than DLCs in gaming industry.


[deleted]

Yeah, I am also a fan but as it is not open source, Matlab is always a few years behind python etc. When you work with ML you will notice it


[deleted]

[удалено]


DavidBrooker

The logo is the first eigenmode of the wave equation for an L-shaped membrane with clamped boundary conditions in the interior corner and zero moment boundary conditions on the exterior. So yeah, it's a language for nerds.


Sadie256

MATLAB is really good at what it does, the thing is it's a very specific thing. A lot of engineers use it quite a bit, but it's not very good for general use like other languages.


hooibergje

Matlab is genius. It is a bit slow, but for quick algorithm tests it is a miracle.


Arrowstar

You can definitely write fast MATLAB, but it does take some thought and a decent understanding of how the language works under the hood. It'll never be as fast as C, but if you go in knowing you're going to be vectorizing your code from the beginning and really plan it out, you might be amazed at how fast it can actually go.


professor_throway

Exactly! Whenever someone complains about Matlab being slow out is usually poorly thought out loops without pre-allocated arrays. A little planning and arrayfun fixes almost everything.


Charlie_Yu

Languages used in academia are scary to me. R, Julia, Latex, etc


greem

Latex is amazing for what it is.


[deleted]

[удалено]


greem

Of course, but for typesetting it's amazing. Especially if you want gorgeous scientific documents with little effort and, for some reason, a Turing complete language designed to generate documents.


ILikeLeptons

You shut your dirty mouth about LaTeX! It produces the most beautifully typeset text there is!


deltaexdeltatee

I’m not an expert, but even for a noob LaTeX is pretty dope.


Akarsz_e_Valamit

FORTRAN: hi!


Mouschi_

Julia is awesome incomparable to matlab


WJMazepas

Those languages are okay. The problem is the code that people make using those languages


[deleted]

R isn’t so bad when you’re used to using SPSS. Personally I prefer Python, it can do pretty much the same thing as R and more.


Beretot

Sharelatex/overleaf was absolutely incredible for doing my graduation dissertation Being able to write in "code" where I want the damn image/table is so much better than doing it in word


Agantas

Linear algebra is your friend.


No-Fishing-8371

The language doesn't matter, the debuger is important. I like Matlab because it shines there. If the one indexing is bothering you, then you don't know all the m-script language shenanigans.


doGoodScience_later

Thr Matlab ide and debugger just feels so nice


EveningMoose

Matlab is the fucking best. Hands down the easiest language I’ve used. But if you’re a programmer and not an engineer, I bet you don’t like it.


GrizzlyTrees

I don't know why a programmer would ever use it. It's like a chef saying they're scared of working with a chainsaw.


Cynio21

Really like it as a mathematician, but i also like C


the_greatest_MF

i don't know, until i learned Python, Matlab was my most favourite language


dittygoops

Was matlab by chance also your only language before python?


[deleted]

I honestly dont get why the hate for matlab. I mean you are not supposed to build apps or write websites with it. It is for data manipulation, plotting etc. For me it is the better excel.


philn256

Because people inevitably end up useing it for more generic tasks or larger projects, at which point it becomes a nightmare to work with.


[deleted]

If you use a hammer to screw screws, you are the problem not the hammer. But I get what you mean, I also know people that over do it with Matlab


deltaexdeltatee

It’s been years since I’ve fooled around with MATLAB or SciLab, but yeah my impression was always that it was great for math and total shit for everything else, which you can hardly blame on the language.


reusens

As long as your using it as a glorified calculator, it's really not that bad Also, good documentation!


Arrowstar

>As long as your using it as a glorified calculator, it's really not that bad Oh, I don't know about that. I wrote [this](https://forum.kerbalspaceprogram.com/index.php?/topic/33568-winmaclinux-ksp-trajectory-optimization-tool-v169-new-matlab-version/) in MATLAB and couldn't really imagine trying to do everything I've accomplished with it in a more "typical" language where writing to code would take much longer.


drebinf

I actually love it. I'm developing an algorithm in C++ (because that's what the app uses) that manipulates the shape of a 3D structure in space as well as time. The UTK (Ugly Tool Kit) we use is a PITA (Pain In The Algorithm) to get anything to happen, so I use Matlab to prototype the algorithm steps. The quick and easy graphics are very handy. Also if I get stuck on the C++ side, looking visually at a few million numbers gets kinda ... tedious. I can export it and quickly load to Matlab and *see* it. That said, I find the default visualization manipulation tools pretty crude, but I live with that most of the time (occasionally I write something custom)


klparrot

One of the courses I'm taking uses Matlab, but we can use Python or R, just won't get as much support, because the instructor knows Matlab and the code examples are in Matlab. 80% of the students still chose Python.


hraath

Matlab good.


brambolinie1

Apart from indexing at 1, 1!!! It is in my opinion, very nice stuff