Have some of you tried the programming language Julia (The Julia Language) ?
I had starting its study and it is very interesting because it is a high level language like python, but it is pretty fast.
Have some of you tried the programming language Julia (The Julia Language) ?
I had starting its study and it is very interesting because it is a high level language like python, but it is pretty fast.
I think I had heard something about it in the past. It's supposed to be a scientific-based language, right? I think I did hear something about how it's supposed to decently fast too. Hmm... Maybe I'll check into it.
John, pretty sure you and I discussed this in an older thread. I ........ all over it because when I tried it like 2 years ago it barely worked.
After my first fast looking, Julia seems more a general purpose language than a specific language for scientific calculation. The very interesting think is that is fast a little bit less than C, but it is not typed like C, C++ and Java, i.e., it allows a fast code developing.
If in the future I will implement some software in Julia I will write my impressions with more details. For now I'm using C and Python.
My C programs and Linux resources...
printf ("Hello to everyone!\n");
fprintf(stderr, "CIAO A TUTTI!\n");
Their choice of going with dynamic dispatch over OO inheritance is a good one, for sure.
But GC.
Well, Julia needs to be a general-purpose programming language, otherwise it would look like Matlab, Octave or Scilab. 4th generation programming languages are domain-specific languages. Julia is a 3rd generation PL meant to support a vast array of scientific and statistical problem domains. Not just static data analysis as the languages above do, but also allow for instance the programming of dynamic models.
Thematic 3rd generation languages like Julia, Scala and R face some incredulity when first met, I agree. But this is because we are used to the idea that a focused language isn't a general-purpose language. This is wrong, and this line of thought has created many problems in the past for the scientific community (why Julia, Scala and R are looked upon by the scientific community as a blessing).
And here's the problem:
Doing any form of scientific or statistical analysis in the past required the use of either a 3rd generation programming language like Java, C or C++, or a 4th generation, depending on what the researcher was trying to do. For sure, scientific models would require C, C++, or Java.
The problem with C++ and Java was that object oriented programming is rarely a practical abstraction for the usual scientific research problem-domains. And the problem with C and C++ (C++ also allows for procedural programming, so it is included here twice) was that they are complex tools requiring high expertise and, what's worse, with nearly no support for scientific computing in their standard libraries. This would force researchers to master the programming languages to solve scientific problems that usually require high code quality and output precision. They would also need to decide between either develop their own scientific libraries or pay high prices for commercial licenses.
So, when you hear today of a programming language for scientific computing, chances are you are not hearing anymore about 4th generation languages (that field is pretty much covered). Instead you are hearing of 3rd generation programming languages, general-purpose, and with the following two key features:
- High level languages tasked on easy-to-program syntax and semantics.
- A standard library with a strong focus on scientific and/or statistical computing.
It's for this reason that I actually don't advise these languages for general-purpose computing. Either you are on the scientific field or you aren't. If you aren't, learning Julia, Scala or R is pretty much a waste of time. Their general-purpose paradigm is, nonetheless, focused. So it makes as much sense programming an accounting program in Julia as it does programming weather models in C++.
Last edited by Mario F.; 06-07-2015 at 03:15 PM.
Originally Posted by brewbuck:
Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.
Don't be. I meant that in the actual context. Think of it this way:
We all like the idea of interdisciplinary study. I mean, it's the life and blood of scientific work! But asking a geologist to learn C or C++ so that she can program her models of earth crust formation is a bit of a stretch and will draw quite a few groans. Especially when you consider how important Accuracy and Validity is to a scientific researcher, which means our geologist needs to learn C or C++ to a level of mastery that many of us doing games or accounting applications shouldn't worry much about. My accounting application and your game may ship with plenty of bugs, incorrect implementations of initial requirements and other deviations without much of a problem. Some of these things may never even be corrected. Our lady geologist can't be so graced if she ever hopes to produce an accurate model of her theory.
In addition, C and C++ offer no support for linear algebra or calculus in their standard libraries. Our geologist needs to decide whether to program her own supporting library, buy a commercial library or adopt an open source library which may come with its own set of problems.
Now, when you consider there are alternatives that fully support her requirements and are easier to learn and to program, suddenly C or C++ may just not make much sense anymore due to all the work involved in mastering and programming in such languages.
I mean, this is what we have been saying all the time when there is a language war in these forums. Languages are tools. Some tools are better for some tasks. No language is better than another, except when you specify what you want to program. And in the presence of languages like Julia or R, it makes little sense to learn C or C++ to do what Julia or R can do much better and much faster. And the opposite is also true.
Last edited by Mario F.; 06-08-2015 at 01:09 PM.
Originally Posted by brewbuck:
Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.
O_oI... I honest to God don't know if this is facetious or not. I mean, on paper Julia sounds fine and C++ is a fantastic scientific language (for most of the reasons you mentioned) so I'm... I'm confused.
I don't agree the statement, but I probably wouldn't choose Julia over a pen and paper.
The general sense of the statement is fine.
The C++ language is a "fantastic scientific language" if you are a competent C++ programmer and have support libraries available.
The reality that other languages offer native support in relevant domains, thus being "fantastic scientific language", doesn't have any effect on the C++ language.
Soma
“Salem Was Wrong!” -- Pedant Necromancer
“Four isn't random!” -- Gibbering Mouther
O_oThe geologist should be collaborating with a programmer to create her models.
Of course, management will decide his nephew with two semesters of Java is the programmer for the job.
The geologist knows better...
Soma
“Salem Was Wrong!” -- Pedant Necromancer
“Four isn't random!” -- Gibbering Mouther
You'd be surprised how often this happens. And with much research being done on low or no funds by independent researchers or small teams. This isn't even new. The dynsfunctional scientific team has been historically the one you describe with ready access to top programmers... *sigh* No, Yarin. Much of what you see being done on a computer by research teams has been done by the actual researchers.
I'm thinking of ways of coming with a few sources for my claim though.
Last edited by Mario F.; 06-08-2015 at 01:29 PM.
Originally Posted by brewbuck:
Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.
There's Arepo and Gadget by Volker Springel. He's a hardcore physicist but he's an amazing programmer.
The problem with scientific computing is that it's hard. If you're a "true" researcher, you need to be able to write massively-parallel code and use rather complex algorithms.
Which makes me wonder, does Julia support distributed implementations? Does it support exact/arbitrary arithmetic?
O_oIf you're a "true" researcher, you need to be able to write massively-parallel code and use rather complex algorithms.
How do domains with embarrassingly parallel algorithms fit into your logic?
Soma
“Salem Was Wrong!” -- Pedant Necromancer
“Four isn't random!” -- Gibbering Mouther