Programming language for Mechatronics

AI Thread Summary
In the discussion, the focus is on the programming languages beneficial for someone preparing for a mechatronics program. Key recommendations include starting with C and C++, as these languages are essential for embedded systems in mechatronics. MATLAB is also highlighted for its ease of use and utility in mathematical calculations, making it a good choice for beginners. Python is mentioned as a user-friendly language, but its application in embedded environments is limited compared to C/C++. The conversation emphasizes the importance of understanding C/C++ for foundational knowledge in mechatronics, while MATLAB can complement this learning. Additionally, there are mentions of Fortran for specific applications like computational fluid dynamics (CFD). The discussion concludes with participants sharing resources and experiences related to MATLAB and C/C++.
arianabedi
Messages
36
Reaction score
0
Hey,

I was wondering, since mechatronics deals with control system and computer programming, what sort of programming language would be beneficial for me to start learning now before my university starts?

since i have around 6 months i though i would be good idea to start learning some stuff before hand (reading mechatronics books failed me...cant understand them yet)

Replies will be appreciated.

Arian
 
Physics news on Phys.org
matlab and C (or any derivative, better yet know them all).
 
viscousflow said:
matlab and C (or any derivative, better yet know them all).

i just got some C,C++ and C# books, guess i'll start by C then, thnx.

googled MATLAB and seemed to high tech for my right now, still have time till uni starts and kicks in (+1 year?)
 
On the contrary MATLAB is probably one of the easiest languages/programs you could ever learn to use. With functions such as plot(x,y) and simple( <expression> ) [simplifies expression terms], its pretty darn easy. For most things you want to do all you have to do is say it and that is the function you're looking for, e.g. "polyfit". I learned C a while back and now its a pain to go back to it when I have to.
 
viscousflow said:
On the contrary MATLAB is probably one of the easiest languages/programs you could ever learn to use. With functions such as plot(x,y) and simple( <expression> ) [simplifies expression terms], its pretty darn easy. For most things you want to do all you have to do is say it and that is the function you're looking for, e.g. "polyfit". I learned C a while back and now its a pain to go back to it when I have to.

I agree, python and MATLAB are really easy to work with compared with their cousin languages.
 
viscousflow said:
On the contrary MATLAB is probably one of the easiest languages/programs you could ever learn to use. With functions such as plot(x,y) and simple( <expression> ) [simplifies expression terms], its pretty darn easy. For most things you want to do all you have to do is say it and that is the function you're looking for, e.g. "polyfit". I learned C a while back and now its a pain to go back to it when I have to.

i see, well main reason i thought that was the big 3d charts they had, on the other hand I am really sure where we use this in the first place (other than HTML and java which I've had experience with in web making)

clope023 said:
I agree, python and MATLAB are really easy to work with compared with their cousin languages.
Thnx for the info both of u, how ever my question now is:

if so, would u recommend going for phyton/mathlab instead of starting C/C++?
As mentioned, i wanted to have a pre knowledge for fields of Mechatronics (and Mechanical engineering).
 
You will need C/C++ in mechatronics, if you can do embedded C it would be perfect. Python and other high level languages will be great to learn computer science with but won't be that useful in an embedded environment. Matlab will be very useful for the mathematical calculations. Depending on what you do Fortran may come in useful, especially if you need to do heavy number crunching (though this is more if you get into things like CFD which is more pure mech rather than mechatronics).
 
denks said:
You will need C/C++ in mechatronics, if you can do embedded C it would be perfect. Python and other high level languages will be great to learn computer science with but won't be that useful in an embedded environment. Matlab will be very useful for the mathematical calculations. Depending on what you do Fortran may come in useful, especially if you need to do heavy number crunching (though this is more if you get into things like CFD which is more pure mech rather than mechatronics).

ah i see, is embedded in C# ? either ways i'll have to do some researching.

Now I am starting to see this mental image of different languages. Guess C/C++ is way to go as a start, since i don't know anything other than very basic HMTL (for my front-page high school exam).

I assume other specific usage languages will be taught to be later when their used, but i guess the C series have more usage.

Time to go read my "C/C++/C# for dummies" :D

thnx all for the replies
 
C# is like the total opposite of embedded C in what it is used for :) Stick to C/C++ as a starting point and you can't go wrong.
 
  • #10
denks said:
C# is like the total opposite of embedded C in what it is used for :) Stick to C/C++ as a starting point and you can't go wrong.

hehe :P well then now i know my path :D

thank you
 
  • #11
C will be a lot more universal the C++. And at the embedded level, there's little need for the extensions to C that C++ offers.
 
  • #12
About MATLAB, from my understanding it can read C/C++ code. Is this true?
 
  • #13
Jokerhelper said:
About MATLAB, from my understanding it can read C/C++ code. Is this true?

http://cnx.org/content/m12348/latest/

http://www.mathworks.com/help/techdoc/matlab_external/f29502.html
 
Last edited by a moderator:
  • #14
physiker_192 said:
http://cnx.org/content/m12348/latest/

http://www.mathworks.com/help/techdoc/matlab_external/f29502.html

That's great. I was trying to use MATLAB a few months ago at school but I could never get it to do anything meaningful since I was trying to work with symbolic data. Now that I'm taking this C++ course I might try it out again. Thanks!
 
Last edited by a moderator:
  • #15
Last edited by a moderator:
  • #16
Same. I haven't heard about that, pretty awesome. Too bad I'm running linux with no access to MATLAB... I'll just have to write my C++ and compile it like normal programmers.
 
  • #17
hadsed said:
Same. I haven't heard about that, pretty awesome. Too bad I'm running linux with no access to MATLAB... I'll just have to write my C++ and compile it like normal programmers.

Have you heard about Octave?
 
  • #18
Yes, I use that and SAGE [with Python] for quick computations. I use SAGE because of their symbolic stuff that's somewhat like Mathematica, although MATLAB has a symbolic toolbox as well but Octave doesn't come with it. There's a way to get symbolic algebra/calculus/DE's working with Octave but I've never been able to make it work.
 

Similar threads

Replies
4
Views
2K
Replies
6
Views
2K
Replies
10
Views
3K
Replies
12
Views
2K
Replies
4
Views
1K
Replies
1
Views
3K
Replies
1
Views
2K
Replies
2
Views
5K
Replies
3
Views
3K
Back
Top