Author Topic: Fortran vs Python?  (Read 3334 times)

0 Members and 1 Guest are viewing this topic.

Offline lifecabal

  • Peasant
  • *
  • Posts: 111
  • Cookies: -1
    • View Profile
Fortran vs Python?
« on: April 17, 2013, 04:03:13 pm »
I am thinking about to learn new language for high performance calculation (Mostly possibility and scientific shit, I think) and It seem that fortran are faster than Python. But there are hardly any tutorial or book on Fortran. I used to work on Matlab, But I can't stand its price(I knew some alternative but some say that their functionality can't compare to Matlab). So which one is a go?
The most difficult thing human will ever face is the decision. Not because we don't know what that decision will bring. It is the responsible that we have to take for the result of that decision we make.

Offline Axon

  • VIP
  • King
  • *
  • Posts: 2047
  • Cookies: 319
    • View Profile
Re: Fortran vs Python?
« Reply #1 on: April 17, 2013, 04:24:09 pm »
I know that python is used heavily in the scientific field, but which one is more powerful.  This I don't know? As for matlab and similar softwares, matlab has the advantage of computational speed over many other softwares like mathematica.

But if you want my advice, I would say go for python.
« Last Edit: April 17, 2013, 04:25:15 pm by Axon »

Offline lifecabal

  • Peasant
  • *
  • Posts: 111
  • Cookies: -1
    • View Profile
Re: Fortran vs Python?
« Reply #2 on: April 17, 2013, 04:38:14 pm »
Some people say that Python is easier for maintenance, and fortran will get confuse when there are a lot of code. And since Fortran is oop now, how confused it can be? BTW alternative, I mean Scilab, SCipy, etc .
The most difficult thing human will ever face is the decision. Not because we don't know what that decision will bring. It is the responsible that we have to take for the result of that decision we make.

Offline proxx

  • Avatarception
  • Global Moderator
  • Titan
  • *
  • Posts: 2803
  • Cookies: 256
  • ФФФ
    • View Profile
Re: Fortran vs Python?
« Reply #3 on: April 18, 2013, 05:42:15 am »
Python is an interpreted language thus being slower thats something you must take under consideration.
However it can be extended with many other languages such as C.
Wtf where you thinking with that signature? - Phage.
This was another little experiment *evillaughter - Proxx.
Evilception... - Phage

Offline Deque

  • P.I.N.N.
  • Global Moderator
  • Overlord
  • *
  • Posts: 1203
  • Cookies: 518
  • Programmer, Malware Analyst
    • View Profile
Re: Fortran vs Python?
« Reply #4 on: April 18, 2013, 06:05:00 am »
Some interesting articles for you:

https://queue.acm.org/detail.cfm?id=1820518
http://ateji.blogspot.de/2010/09/java-for-high-performance-computing.html

My opinion: I don't think you should consider Python for high performance computing. It is bad at multithreading and it is slow. So if high performance is what you want, Python is not your choice.
For readability of code and maintaining code it might be better, though.
« Last Edit: April 18, 2013, 06:09:41 am by Deque »

Offline lifecabal

  • Peasant
  • *
  • Posts: 111
  • Cookies: -1
    • View Profile
Re: Fortran vs Python?
« Reply #5 on: April 18, 2013, 08:12:05 am »
I never think Java is HPC choice, Damnn need more research. BTW thank for useful article.
The most difficult thing human will ever face is the decision. Not because we don't know what that decision will bring. It is the responsible that we have to take for the result of that decision we make.

Offline Stackprotector

  • Administrator
  • Titan
  • *
  • Posts: 2515
  • Cookies: 205
    • View Profile
Re: Fortran vs Python?
« Reply #6 on: April 18, 2013, 09:08:11 am »
Moved. Anyway if you really want "high performance calculation " you should get a compiled language like c++ or a relative. I personally think fortran is kinda outdated and you will learn more from more common and modern languages.
~Factionwars

Offline Deque

  • P.I.N.N.
  • Global Moderator
  • Overlord
  • *
  • Posts: 1203
  • Cookies: 518
  • Programmer, Malware Analyst
    • View Profile
Re: Fortran vs Python?
« Reply #7 on: April 18, 2013, 09:21:43 am »
The capabilities of multi-threading and parallel computing are more important. Most languages suck at parallel computing.

But there is i.e. High Performance Fortran which was just made for parallel computing. I mean there is a good reason Fortran is especially used by scientists on supercomputers, which is the great performance. Looking back how Fortran was made this is no surprise as it was the first high level language at all and had to convince all the assembly programmers that it can create assembly that is as good as their hand crafted assembly programs.

Or you go an entire different way and learn a pure functional language, because they are good with parallelizing tasks too.
« Last Edit: April 18, 2013, 09:27:54 am by Deque »

Offline lifecabal

  • Peasant
  • *
  • Posts: 111
  • Cookies: -1
    • View Profile
Re: Fortran vs Python?
« Reply #8 on: April 18, 2013, 11:08:28 am »
As far as I know, Fortran 2008 can do parallel computing. And its performance is a liitle better than c++. Is there other reason that I should go for c++ other than Fortran?
The most difficult thing human will ever face is the decision. Not because we don't know what that decision will bring. It is the responsible that we have to take for the result of that decision we make.

Offline parad0x

  • VIP
  • Royal Highness
  • *
  • Posts: 638
  • Cookies: 118
    • View Profile
Re: Fortran vs Python?
« Reply #9 on: April 18, 2013, 11:09:26 am »
I agree with Factionwars, if you want multithreading with high speed, you should consider languages like C as it is complied.
Can't say anything about ForTran.

Offline Stackprotector

  • Administrator
  • Titan
  • *
  • Posts: 2515
  • Cookies: 205
    • View Profile
Re: Fortran vs Python?
« Reply #10 on: April 18, 2013, 11:11:13 am »
As far as I know, Fortran 2008 can do parallel computing. And its performance is a liitle better than c++. Is there other reason that I should go for c++ other than Fortran?
If you are looking forward to general programming and security C++ is something good to learn so that may be win/win. Otherwise i think i will go with Deque.
~Factionwars