Slashdot Mirror


Should Undergraduates Be Taught Fortran?

Mike Croucher writes "Despite the fact that it is over 40 years old, Fortran is still taught at many Universities to students of Physics, Chemistry, Engineering and more as their first ever formal introduction to programming. According to this article that shouldn't be happening anymore, since there are much better alternatives, such as Python, that would serve a physical science undergraduate much better. There may come a time in some researchers' lives where they need Fortran, but this time isn't in 'programming for chemists 101.' What do people in the Slashdot community think?"

132 of 794 comments (clear)

  1. It's okay to teach them FORTRAN by sharkette66 · · Score: 5, Funny

    But only if they have to do it on punch cards, like I did. Give each student a can of WD40 to keep the machines working smoothly, too.

    1. Re:It's okay to teach them FORTRAN by hairyfeet · · Score: 4, Funny

      Nah, make them learn VB6, if for no other reason for enjoying the screams of horror from 'real" programmers when they come across some VB6 app. Take that, real programmers! For extra evil teach them GOTO. I've found watching the facial ticks and foam build up around the mouth from real programmers when they encounter a GOTO to be quite entertaining!

      --
      ACs don't waste your time replying, your posts are never seen by me.
    2. Re:It's okay to teach them FORTRAN by maj_id10t · · Score: 3, Insightful

      I too had to learn FORTRAN (it was v77 then) as part of my undergraduate degree as did my now wife. We were both studying Environmental Engineering. There are many US Federal government agencies (e.g. EPA) who have mathematical models that are programmed in FORTRAN as per the federal regulations mandate. For those students who will be studying to work in this field it makes perfect sense for them to study FORTRAN. There are no plans I am aware of to update these environmental modeling programs from FORTRAN to a 'better' language. For the non-computer science students / environmental engineers it is a good place to start with computer programming and will add to their skills required for the work place. If they have the desire to enhance their computer programming skills they should be encouraged to minor in CS etc. For anyone else, dear God NO! Do not subject them to this language. My $0.02.

    3. Re:It's okay to teach them FORTRAN by Cor-cor · · Score: 2, Insightful

      I realize you're probably joking, but our intro class actually teaches VBA, and even though it's a general overview for engineers of all shapes and sizes, they really do a poor job of teaching the fundamentals of programming, choosing instead to focus mainly on the syntax and the language itself. As far as I know, no subsequent class ever uses VBA, so we struggle with any future programming almost as much as we would have without an intro class. They may be looking to fix that, but for now it functions primarily as a weedout class and nothing else.

      I didn't go into computer/software engineering, but I did TA the intro class for a semester and have worked with its graduates (my engineering peers) on group projects and the like. In my opinion, they really ought to teach the logic of programming (flowcharts and the like) much more heavily than focusing on any one language. That way, you don't have people sitting and memorizing the way a certain program is written but lacking the common sense to so much as use a loop rather than writing the same calculation over and over again.

      So teach FORTRAN, teach VB6, teach them LOLCODE or whatever the hell you want but please make sure you're teaching them why the code is written the way it is and that computers don't necessarily think the way you do.

    4. Re:It's okay to teach them FORTRAN by psmears · · Score: 2, Informative

      WD40 is a drying agent, not a lubricant.

      Uh... isn't it both? The manufacturers of WD40 certainly seem to think so:

      WD-40 protects metal from rust and corrosion, penetrates stuck parts, displaces moisture, and lubricates just about anything

    5. Re:It's okay to teach them FORTRAN by v1 · · Score: 3, Insightful

      I specialized in programming languages in general in school. I'm one of those people that can honestly say he has forgotten more languages than most people will ever learn. While fortran isn't a language I ever intend to use, having learned it was a useful experience. Other odd languages like lisp, algol, assy, sequence/state, etc, also provide you with unique insight into how to do things. I occasionally run into problems today where I think "that would be SO much easier to do in (name a language)", and that gets me to thinking of how to modify the simple solution in the other language to the language I'm currently working with. It's a bit like the towers of hanoi problem, it seems dreadfully complicated until you realize that done correctly the solution is very simple, and you just need to change your point of view.

      This also makes you extremely flexible. I have absolute confidence that I can sit down at any new job using any language I've never so much as heard of before, and be able to read and understand the existing code immediately, write useful code that same day, and be highly proficient with it in under a week. The only reason I can do this is I've "seen it all" for the most part and so I've already beaten the basic obstacles like "object oriented", "pointers", "procedural based" etc that a new language might throw at me and would at least temporarily derail/disorient another newbie.

      --
      I work for the Department of Redundancy Department.
    6. Re:It's okay to teach them FORTRAN by hairyfeet · · Score: 5, Interesting

      Well, I'll tell you like my former VB teacher told me, funnily enough after some kid tried to steal my code and pass it off as his own. After Mike(my teacher) got done laughing his ass off he told the kid "BTW you are getting an F for stealing from Kevin". "How do you know that he didn't steal it from me?" Again after Mike got done laughing his ass off he projected the code onto the board and said to the class "Do you notice anything a little odd about this code?" And one said "It has numbers in front of all the lines...and what is a GOTO?"

      And Mike said "How old are you Shawn?" and after the kid said 19 he said "And THAT class is why I know Shawn stole this code from Kevin. He turned to me and said "You're what? 35?" and when I confirmed he said "You see class, in the days before PCs became standard with pretty desktops like you have now, all the machines ran BASIC. The numbering and the use of GOTO to call a sub is a classic tell that the person who wrote this cut his teeth on one of the old BASIC computers." He tilted his head and said "Commodore or Atari?" and I sat there with my mouth gaping and said "Commodore VIC20. How did you know that?" he said "Because your code is classic Commodore and Atari style. Very efficient but as subtle as a chainsaw."

      After some of the kids started coping pieces of my code and trying to use GOTO and crashing all over the place Mike explained it to me like this-"To an old greybeard like you or me, that actually understands what the code is doing a GOTO can be a quick and efficient way to get something done quick. Subtle as a chainsaw, but it gets the job done. But you give it to these kids, that don't really understand what they are trying to accomplish or understand how the codes works in the machine? It is like handing a monkey a sledgehammer and letting him loose in a room full of bombs. He is gonna blow something up, the only question is when."

      So if you want to know why teachers like Mike would cringe when they saw a GOTO, it is because it works fine IF you know what you are doing and how the code will be processed. But with so many learning code the VS way, with everything drag and drop, for many of those GOTO will simply blow up in their faces. Better just to not let them know it exists in the first place.

      --
      ACs don't waste your time replying, your posts are never seen by me.
  2. Oh come on. by geminidomino · · Score: 5, Funny

    --No one-- should be taught FORTRAN. Ever...

    *sobs in fetal position*

    1. Re:Oh come on. by Opportunist · · Score: 4, Insightful

      Right. Teach COBOL instead!

      Job security well into the next millenium!

      --
      We used to have a Bill of Rights. Now, with the rights gone, all we have left is the bill.
    2. Re:Oh come on. by scubamage · · Score: 5, Funny
      Yep, real men use ADA.

      ...And drink very heavily.

    3. Re:Oh come on. by mabhatter654 · · Score: 4, Interesting

      but for math geeks FORTRAN is probably the easiest language to get from pencil-n-paper to computer. Math functions in FORTRAN translate nicely from their paper counter parts. If you can do math and "show your work", or punch numbers in a calculator, you're 2/3 of the way to a FORTRAN command line program.

      I don't think it's a useful first language anymore. Something like Python would be more useful "out of college". FORTRAN is really easy to pick up later anyway as it's "old fashioned" and line numbered based. I'd think the biggest problem teaching the class now would be getting students to take it seriously because it's a much older way of thinking about programs from our modern OOP languages.

    4. Re:Oh come on. by joss · · Score: 5, Insightful

      God forbid, don't teach em python first. Learn assembly, c++, ML, fortran even fucking visual basic. You can't learn python first, it's like eating the pudding before the salad. Python is the *last* language you should learn.

      Yes, I'm serious.

      --
      http://rareformnewmedia.com/
    5. Re:Oh come on. by beelsebob · · Score: 4, Interesting

      Indeed, even the creator of Fortran said "actually, that was a shit idea, we should all ignore it and use functional programming instead" in this paper.

    6. Re:Oh come on. by beelsebob · · Score: 3, Interesting

      but for math geeks FORTRAN is probably the easiest language to get from pencil-n-paper to computer. Math functions in FORTRAN translate nicely from their paper counter parts. If you can do math and "show your work", or punch numbers in a calculator, you're 2/3 of the way to a FORTRAN command line program.

      Yes, but with a good functional language like Haskell, you're 9/10 of the way there, not 2/3.

    7. Re:Oh come on. by boneglorious · · Score: 5, Interesting

      I absolutely agree. With a background in c++, learning python (my new department's introductory language) was cake, but I'm watching the people who learned python first struggle to go beyond it. They're even more hindered by the fact that they keep thinking, "But python was so easy..."

      --
      Can I mod something +1 Scary if it's true but I wish it weren't?
    8. Re:Oh come on. by gestalt_n_pepper · · Score: 3, Interesting

      A more interesting questions is "Why are other programming languages so hard? And is the difficulty justified by the additional power?" Bonus question: Is it *necessary* that a language (cough, cough, C++) be an ergonomic disaster to be powerful?

      --
      Please do not read this sig. Thank you.
    9. Re:Oh come on. by Kotoku · · Score: 2, Funny

      You can't have any pudding if you don't eat your meat!

    10. Re:Oh come on. by quakehead3 · · Score: 2, Funny

      "Yes, but with a good functional language like Haskell, you're 9/10 of the way there, not 2/3."
      But then students would be too lazy to do their homework.

    11. Re:Oh come on. by Joce640k · · Score: 5, Insightful

      The idea of programming as a semiskilled task, practiced by people with a few months' training, is dangerous. We wouldn't tolerate plumbers or accountants that poorly educated. We don't have as an aim that architecture (of buildings) and engineering (of bridges and trains) should become more accessible to people with progressively less training. Indeed, one serious problem is that currently, too many software developers are undereducated and undertrained.

      Obviously, we don't want our tools--including our programming languages--to be more complex than necessary. But one aim should be to make tools that will serve skilled professionals--not to lower the level of expressiveness to serve people who can hardly understand the problems, let alone express solutions. We can and do build tools that make simple tasks simple for more people, but let's not let most people loose on the infrastructure of our technical civilization or force the professionals to use only tools designed for amateurs.

      - Bjarne S.

      --
      No sig today...
    12. Re:Oh come on. by Anonymous Coward · · Score: 2, Informative

      Real men know that the name of the programming language 'Ada' is not an acronym.

    13. Re:Oh come on. by jason.sweet · · Score: 2, Insightful

      I believe that it is the architecture that COBOL usually runs on that is what makes it so conducive to "manipulating and moving massive amounts of data". As far as maintainability is concerned, COBOL makes good software engineering a hard and frustrating task. That being said, I am always amused at attempts to marginalize COBOL. I am quite certain that in the 2 1/2 hours that I have been awake this morning, at least two of my actions have been processed by COBOL code. I don't buy that "nothing beats COBOL," but I am convinced that COBOL does make the world go 'round.

    14. Re:Oh come on. by quanticle · · Score: 2, Informative

      Why are other programming languages so hard? And is the difficulty justified by the additional power?

      Well, that all depends on what you mean by "power". In one sense, all Turing-complete languages are equally powerful, since the set of solvable problems for all is the same.

      In the sense of being "easy to use" or "easy to learn", however, I would say that it is necessary for some languages to be "hard", in the sense of having fewer layers of abstraction between the programmer and the hardware-level instruction set. These languages allow those that need finer grained control to have it. In more concrete terms, I'm glad Assembler exists (for the sake of those making device drivers), even if I'll never personally use it.

      Is it *necessary* that a language (cough, cough, C++) be an ergonomic disaster to be powerful?

      Again, it all depends on how you define "ergonomic disaster". There are those who feel that C++ is a useful addition to C that makes object orientation easier while still not obscuring the central structure of C. C++ is no more powerful (in absolute terms) than any other Turing complete language - it just makes some problems easy while making others hard.

      Trying to say that one programming language is more "powerful" than another is like trying to say that a hammer is "more powerful" than a screwdriver.

      --
      We all know what to do, but we don't know how to get re-elected once we have done it
    15. Re:Oh come on. by Culture20 · · Score: 5, Insightful

      God forbid, don't teach em python first. Learn assembly, c++, ML, fortran

      This seems to me like saying you should learn to drive an F1 car, or a Model T, before being allowed anything with an automatic gearbox.

      I would say driving a car is like running a program. Designing or repairing a car is a much better analogy. And in that case, learning the old designs, and the physics they used is much better than "run this diagnostic tool; replace factory-made black-box widget". Learning assembly or C forces a person to recognize the limits of the machine (and thus the limits of interpreted languages).

    16. Re:Oh come on. by Z00L00K · · Score: 4, Insightful

      Fortran has it's place, even though it's a bit of a fringe language today.

      It has evolved since Fortran 77, and is better. It's also one of the languages where it doesn't require the programmer to have a detailed knowledge about how to parallelize a problem since later versions has those features built in. The programmer just have to be aware that it can be parallelized, but not waste time on the details about how to do it. Unfortunately GNU Fortran doesn't support this yet (unless it has been enabled lately).

      Python is certainly not an alternative - unless you want to have a replacement for Basic.

      Education shall primarily be done in type-safe languages that forces the developers to learn the importance of type safety. Way too many bugs have been created through history that are related to operations that aren't type-safe. Ada is one language that is really strict. Java is acceptable. C# is not acceptable since it has some unsafe parts when it comes to data typing.

      And Visual Basic should be taken out, shot, drowned, burnt and sterilized for all it's abilities to make things unsafe and bug-ridden.

      --
      If builders built buildings the way programmers wrote programs, then the first woodpecker would destroy civilization.
    17. Re:Oh come on. by sycodon · · Score: 2, Insightful

      I believe that what gives COBOL the edge when it comes to working with large amounts of data (in addition to the fact that it runs on mainframes built for throughput) is that...

      1. The data record can be/is defined clearly in the application (it's required).

      2. The data record can be redefined many many times, allowing you to subdivide the data many ways, naming each individual part, retyping it, etc. If done with just a little bit of common sense, it makes the code fairly clear about what's going on.

      3. What some would see as a weakness is actually a strength when used in the normal COBOL processing environment. That is that you really can't get too fancy in the code without it becoming unreadable and unmaintainable.

      So you are forced to break up your processing into steps, which are managed by some kind of process management system. OK, JCL in 99% of the cases.

      While seemingly clunky, it provides a great amount of resilience because you are able to restart jobs after failures from just before the failure, not from the beginning.

      Bottom line, is that COBOL and the surrounding technologies and procedures are designed to get the job done, every day, 365 days a year.

      It's not as pretty as the O'Rielly Animal House series of languages (perl, python, rattler, donkey, whatever) but it's rock solid and unstoppable when done with even just a bit of care.

      Contrast this with the ASP.net web app development I'm doing now. Talk about finicky, temperamental code. Speaking of which...need to deal with the Object not set to an Instance of an Object.

      --
      When Fascism comes to America, it will call itself Anti-Fascism, and tell you to give up your guns.
    18. Re:Oh come on. by Glonoinha · · Score: 5, Interesting

      Trust me, while you may wish you were learning how to write applications in the latest pop language during undergrad, the rest of the world wishes you had been taught computer language theory, set theory, data analysis by inference, proper documentation of your code, the 'non-coding' aspects of any number of different SDLC lifecycles, complete code coverage testing approaches, the interaction between software and the machine (where the machine is the network of machines, and the rest of the software running on those machines) and critical thought / problem solving during your undergrad years.

      Your disdain for COBOL, FORTRAN, and Pascal show exactly why it's a bad idea to teach a single 'current' language and spend four years focusing on all the APIs and subtle language quirks - languages come and go. Entire platforms come and go. And yet the same people adapt over time (if they are good) and continue to implement strong software engineering principles in whatever comes along to replace those obsolete technologies.

      Perhaps during those classes you weren't supposed to be focusing on the medium (the language) and rather be focusing on the lesson (data structures, analysis of algorithms, queue theory, set theory, or the one that has caused the world the most problems - handling every input that could possibly be handed to a routine.)

      All of the above can be taught in any language, including one made up by the professor (RIP Edgar Dykstra.)

      --
      Glonoinha the MebiByte Slayer
    19. Re:Oh come on. by DrgnDancer · · Score: 2, Insightful

      The problem with scripting languages is that they hide the architectural details of the system they are running on. They abstract everything to the point where programming becomes simply algorithm design implemented in a language so simple that it could have been pseudo-code 20 years ago. This is fine under two circumstances:

      1) You are only interested in training "programmers", not computer scientists or computer engineers. In the case of this article, you could have a valid argument, since these are not computer science students. They're scientists in other disciplines who's primary goal is to write programs to figure out problems in their own fields of study. It is clearly not acceptable for computer science students who, in theory at least, need to understand the fundamental concepts of how computers work. Much of that understanding comes from learning "close to the metal" languages that are harder to learn, but remove abstraction and aid low level understanding.

      2) You don't expect to need the power present in "close to the metal" programming languages. Because they are less abstracted (and because they are compiled), languages like C, C++, and Fortran tend to run much more efficiently than abstracted (and usually interrupted) languages like Python and Perl. This is where the argument from the article breaks down IMO. I've never seen Python used in scientific research, except in control scripts or GUI front ends. I'm not myself a scientific researcher, but I've spent a good chunk of my career doing admin work for various kinds of academics, so I have some idea what I'm talking about. When you've just spent 10 gajillion dollars on a 7000 CPU cluster (or even $300,000 on a 200 CPU cluster), you're not going to waste computational CPU cycles on less efficient language. There's not WRONG with python, don't misunderstand me. It has many valid uses, i just don't see it as a scientific research language.

      --
      I don't need a million points of light, just two points of multi-mode fiber and a 10 Gig-E router.
    20. Re:Oh come on. by avilliers · · Score: 5, Insightful

      The idea of programming as a semiskilled task, practiced by people with a few months' training, is dangerous. We wouldn't tolerate plumbers or accountants that poorly educated.

      Not at all. Most homeowners do a lot more around the house with a lot less training, whether opening up the garbage disposal or trying to manage their retirement accoutns. The goal of these classes--especially for scientists--is the equivalent: Not to get people ready for programming a bug-free third party app; it's so they don't have to sit on their hands waiting for someone else to "build tools" to solve a perfectly manageable, one-off program that will let them move their research forward.

      There may be things where there's a nice pre-built commercial or open source app; there will also be problems where there's a need for paid consultants. But there's a lot of ground in the middle, especially in specialized fields.

    21. Re:Oh come on. by TopherC · · Score: 2, Insightful

      While I basically agree with you, in that programming is a task best done well or not at all, it's a common mistake to think that everyone who programs should be a career programmer. It must be possible to teach the necessary programming skills (and they are necessary) to college students in engineering, science, and a few other fields. It's a little bit like mathematics except that many students don't start learning it early enough. If one doesn't start learning programming before college, then it's possibly too late to really learn enough in college. I think these days really successful students primarily learn it outside of formal classes.

      My take on the topic of Fortran is that it is not important to learn in school. I've written a lot of Fortran, but with a strong background in C it was not hard to learn when it was necessary for me to. Even in experimental physics, Fortran is used increasingly rarely so most students would not have a need to use it.

      I think that learning one programming language in school is not nearly enough. Students should learn basic procedural programming concepts, something about data structures, object oriented design, and good practices in some scripting language to get comfortable with hashes and regular expressions. Python is great for a lot of this, but it's probably better to establish more low-level concepts first, including pointers. Maybe learning C and then Python could be a reasonable, minimalistic approach? C++ could actually be avoided since the syntax and rules are so complex. (I'm not talking about comp-sci majors who should certainly learn C++.) Perl is awesome of course, but again the syntax is complex and in the context of a college course that just takes time away from learning the essential concepts. Java is possible but doesn't really get either low-level or high-level enough for my tastes.

      Whatever a student learns, they should have enough breadth, conceptual knowledge, and practice so that whatever language is required for a given project would not be too hard to learn on the job.

    22. Re:Oh come on. by Sudheer_BV · · Score: 2, Insightful

      Many of the subjects you mention are directly related to writing applications like code coverage testing approaches, SDLC, documentation of code, etc. I agree there are two aspects involved here - learning to program and learning a particular programming language. It doesn't mean you can't learn software engineering if you narrow down the academic focus to current programming languages. Studying arcane programming languages like COBOL doesn't prepare you well to write a business application.

      --
      Sudheer Satyanarayana
      www.techchorus.net
    23. Re:Oh come on. by XDirtypunkX · · Score: 4, Funny

      Actually, the most hardcore lecturer/professor at my University in Australia both promoted the use of Ada and drinking heavily. I guess he taught me how to be a man.

    24. Re:Oh come on. by tthomas48 · · Score: 2, Insightful

      Seriously? Most scientists just need to do either:

      1) Lots of math that would be tedious to do manually.
      2) Lots of pattern matching in large data files.

      Both of these things can be accomplished with small scripts by semi-skilled programmers. This isn't application programming. It's on par with macros.

    25. Re:Oh come on. by Just+Some+Guy · · Score: 2, Interesting

      But one aim should be to make tools that will serve skilled professionals--not to lower the level of expressiveness to serve people who can hardly understand the problems, let alone express solutions.

      It's ironic to me that this came from the inventor of C++, IMHO one of the least expressive languages around. I spend most of my time in C{,++} explaining the means to an end, but most of my time in Python telling it what that end is.

      For example, I have a list of values (int, float, string, or whatever else) and I want to double each of them. A typical Python expression would be list2 = [item * 2 for item in list1]. The C++ equivalent would involve explicitly stating what list2 will be, how to iterate across list1, and that the items might be of different types. I have better things to do with my programming time than to hold the compiler's hand and spell out every single detail.

      --
      Dewey, what part of this looks like authorities should be involved?
    26. Re:Oh come on. by skeeto · · Score: 2, Interesting

      We aren't talking about computer science students here. This is about teaching a useful tool to other disciplines. Physicists, for example, don't need to learn about pointer arithmetic and computer architectures to use programming as a useful tool. They are working at the level of mathematics, with high level concepts.

      And Python is one of the better languages for that. They probably wouldn't need anything else for a long time.

      The situation right now is that if they aren't learning Fortran, then they are probably learning Matlab, which, frankly, seriously sucks.

    27. Re:Oh come on. by jbolden · · Score: 2, Informative

      What makes C++ difficult is C. That is

      1) Deallocation of memory, bounds checking in arrays... is done manually

      2) Lots of direct pointer manipulation. You can't abstract away the "how the computer is going to do this"

      3) Multiple inheritance

      Getting rid of those things gives you Java which is much easier to learn but doesn't have the performance. The question is why did you choose C++ in the first place if you don't want the excellent performance?

    28. Re:Oh come on. by iluvcapra · · Score: 2, Insightful

      TAIL-CALL RECURSIVE PROGRAMMING is probably the number one thing that sets real programmers apart from the wanna-be's.

      There, fixed it for you...

      --
      Don't blame me, I voted for Baltar.
    29. Re:Oh come on. by Will.Woodhull · · Score: 2, Interesting

      Amusing post.

      Things are changing pretty rapidly now. Please try to keep up.

      Most high school students interested in science or engineering careers learn a bit of some programming language in the same way they learn a bit about sex: from each other, Typically in a guy's basement on his family's old Win98 or WinXP computer, rather than in the back seat of Mom's car... but the kind of fooling around is the similar.

      The scripting languages are easy to come by. Firefox with Firebug and a foss text editor like Notepad++ make an excellent Javascript development environment. Heck, for the cost of a dozen good condoms and a visit to Portable Apps a geek-thinking high schooler can put an entire development package, complete with web server and database, on a 2 GB stick and have huge amounts of room for code monkey play. How could any kid interested in science or engineering resist this? And it is SO much easier than finding someone who would be interested in exploring the intended use of the condoms...

      So no, I'm pretty sure parent post is wrong. That is, I doubt very much that most of the college freshmen in any of the technical schools today are programming virgins. The majority of high school students may still be virgins wrt programming experience... but those are not the ones who apply to, and get accepted into, technical schools.

      --
      Will
    30. Re:Oh come on. by beelsebob · · Score: 2, Interesting

      Rather, he was referring to a style of programming where everything (even numbers) are functions, and complex functions are created solely by composing other functions. In other words, there are no variables.

      Yes, he meant lambda calculus based languages... Like Haskell, in fact, Haskell is one of the most heavily lambda calculus based languages.

      but there's a reason that no one uses the language he described in that paper.
      Yes, because the language he describes there is the assembly code of functional programming. There's similarly a reason why people don't (usually) use asm.

  3. How would you learn? by CRCulver · · Score: 3, Interesting

    Are there any cheap but quality tutorial for Fortran? O'Reilly has no contemporary introduction to the language and their last book on Fortran, Migrating to Fortran 90 , came out nearly two decades ago.

    1. Re:How would you learn? by wireloose · · Score: 4, Informative

      google Fortran tutorial download

      How new does the book need to be for the language standard when it hasn't changed much in 2 decades? It's a simple, easy to use tool for serious engineering.

    2. Re:How would you learn? by oldspewey · · Score: 3, Funny

      All the good tutorials are on punch cards, so unless you have a reader handy you're SOL.

      --
      If libertarians are so opposed to effective government, why don't they all move to Somalia?
    3. Re:How would you learn? by bunratty · · Score: 4, Interesting

      How new does the book need to be for the language standard when it hasn't changed much in 2 decades? It's a simple, easy to use tool for serious engineering.

      Actually, Fortran has changed quite a bit in the last two decades. The Fortran 90, Fortran 95, and Fortran 2003 standards have come out during that time. They added quite a number of major features, such as free-form source code, recursive procedures, operator overloading, dynamic memory allocation, and object-oriented programming. The Fortran of 2009 is not like the Fortran of 1989 at all.

      --
      What a fool believes, he sees, no wise man has the power to reason away.
    4. Re:How would you learn? by idontgno · · Score: 2, Funny

      Real men can read Hollerith like Braille.

      At 20 cards per second.

      --
      Welcome to the Panopticon. Used to be a prison, now it's your home.
    5. Re:How would you learn? by wireloose · · Score: 2, Interesting

      I really just meant from Fortran 90 like the previous poster. 95 is really pretty minor in changes. 2003, yeah, big changes. How many systems are likely to have 2003 on them? I can usually find a Fortran 90 compiler freely available for lots of platforms, and lots of the companies I know that use it use 90 or 95 because they had it already for their older legacy hardware. Specifically, I prefer Gnu and its current production release (4.30) really isn't 2003 compliant yet. http://gcc.gnu.org/onlinedocs/gcc-4.3.0/gfortran/Standards.html#Standards

  4. While there may be "newer" languages by wireloose · · Score: 5, Insightful

    Fortran is still one of the best, fastest, most optimized tools for number crunching. It's also very easy to write simple programs in it. No way I'd use Python for serious large data set numerical calculations.

    1. Re:While there may be "newer" languages by k2enemy · · Score: 5, Insightful

      Citation needed.

      Even if not phython, what does Fortran have over modern compiled languages, for example?

      Lots of libraries for numerical work. Fortunately many of them are being ported to Python modules so you can get the speed/convenience advantage and work in a modern language at the same time.

    2. Re:While there may be "newer" languages by Falstius · · Score: 4, Informative

      Fortran has tons of libraries specialized to whatever scientific field you are working in, and is unavoidable in high energy physics especially. Of course, most of these can be wrapped in C and then used in whatever high level language you like.

    3. Re:While there may be "newer" languages by MathFox · · Score: 3, Insightful
      First I wonder which Fortran you refer to; Fortran 66 is quite a different language from Fortran 95. I agree that all Fortran variants are pretty good languages for number crunching, but Fortran 77 and older lacked support for data structures, making it hard to teach students about them and advanced algorithms in general. (Yes, I've tried.) Fortran 90 and 95 are much better in those respects. On the other hand: C and C++ are not so far behind in speed to rule them out.

      It is my opinion that learning two fundamentally different languages makes someone a better programmer. I see value in teaching both Fortran and (for example) Python, using Fortran for number crunching and Python for smarter algorithms.

      --
      extern warranty;
      main()
      {
      (void)warranty;
      }
    4. Re:While there may be "newer" languages by ChienAndalu · · Score: 4, Interesting

      Use both. I used Fortran to create some python modules at my last job, and it was dead easy. Take a look at this.

    5. Re:While there may be "newer" languages by jstults · · Score: 5, Informative

      Fortran is still one of the best, fastest, most optimized tools for number crunching.

      Agreed.

      It's also very easy to write simple programs in it.

      This is a strength of Python too.

      No way I'd use Python for serious large data set numerical calculations.

      It's not either/or, with F2Py you can put your inner loops in Fortran, and deal with the higher level abstractions with Python. So you get fast number crunching and all the 'batteries included' too.

    6. Re:While there may be "newer" languages by aaaaaaargh! · · Score: 4, Insightful

      Mod parent up. Students should learn to choose the right tool for the right purpose and not be drawn into stupid "my language is best" discussions. Python is too slow for serious number crunching and Fortran is widely in use for exactly this purpose. Python is suitable for many other tasks, though. To give another example, if somebody studies astronomy and will have to work with old legacy Forth code, he should better be taught to program in Forth at university. And somebody who needs to quench maximum speed out of hardware or wants to implement compilers should better learn assembler. I've studied linguistics and learned to program in Prolog and Common Lisp at University, now what's wrong with that? Both are still widely in use in NLP and you need to no the basics of them when you're working in that domain even if you don't use them.

      In my experience the majority of people that think that advertise one programming language above all others tend to have no clue about programming languages in general and what other languages exist apart from mainstream languages like C/C++ or Ruby, and I'm afraid this holds particularly for Python and Java enthusiasts---both of which are relatively mediocre and outdated languages in terms of their general features and usefulness, although they can of course be the right choice for many tasks.

    7. Re:While there may be "newer" languages by fph+il+quozientatore · · Score: 5, Informative

      Citation needed. Even if not phython, what does Fortran have over modern compiled languages, for example?

      0) A lot of legacy code people still have to work with is written in FORTRAN. Sad but true.
      1) Many very optimized libraries available. Check if your language du jour has an implementation of a routine for solving a linear system using BLAS. That provides a huge improvement.
      2) Many libraries are in fact only available for FORTRAN. For calculating the eigenvalues of a sparse matrix, there is only ARPACK (for Fortran), Arpack++ (a kludgy C++ interface to the very same FORTRAN library), and Matlab's "eigs" (a Visual Basic-style interface to the very same FORTRAN library).
      3) Very expressive. For instance, you can reverse the entries of a vector of complex numbers in a single compiler instruction. This is a toy example, but for more complicate stuff this expressiveness pays: the compiler has an easier job in understanding what code can be safely optimized and what cannot. More complicate stuff involving e.g. C++ method calls suffers in terms of pointer aliasing problems and similar stuff. Of course you may write the very same thing in C or machine code, but for 99% of the computations you would use the "standard" interface to vectors/arrays of your languages and forget about this sort of micro-optimizations. A good commercial FORTRAN compiler (forget about gfortran, sorry GNU but sadly it's true) does this automatically.
      4) FORTRAN 95 is not a punch-card language anymore, it has most of the fancy modern stuff if you wish to use it. While "bad programmers can write FORTRAN in every language", good programmers can write well-factored and perfectly readable FORTRAN code.

      Nevertheless, I do matrix computations, and still I try to avoid it as much as I can. Most people in our field use MATLAB (which is essentially a Visual Basic-style interface to most of the awesome number-crunching FORTRAN libraries) even though for tight "for" loops its performance sucks. If performance is mission-critical, you may write FORTRAN subroutines and call them from MATLAB, and that's very convenient. Python still lacks many of Matlab's features, its only advantage is being Free Software.

      BTW, a very ill-advised design choice of Python: http://www.python.org/dev/peps/pep-0211/ Ask any numerical analyst to know why it is a terrible idea to solve a linear system with inv(A)*b. But make sure you have at least half an hour free.

      --
      My first program:

      Hell Segmentation fault

    8. Re:While there may be "newer" languages by koutbo6 · · Score: 3, Interesting

      FYI, numpy is just a wrapper around C and fortan based modules
      So you get best of both worlds, I think Python is a better introductory programming language.

      --
      You speak London? I speak London very best.
    9. Re:While there may be "newer" languages by wireloose · · Score: 4, Insightful

      Granted. But it's still easier to write simple, basic Fortran code to solve a quick engineering problem and to use/incorporate some of the nice math libraries. If you're really good, you can wrap it all in C and includes to bring in Fortran libs, but why bother for an undergrad's first course? The student only has 16 weeks to learn the basics, while taking other classes. There is always opportunity for more advanced coursework. Plus, Fortran is readily available on lots of systems, new and old. Even C isn't available on every system in every organization where a new engineer could be employed. So start with the basics, and then advance.

    10. Re:While there may be "newer" languages by SatanicPuppy · · Score: 5, Insightful

      ...if somebody studies astronomy and will have to work with old legacy Forth code, he should better be taught to program in Forth at university...

      This is exactly the wrong reason to teach any programming language. You teach a language to teach programming concepts and methodologies, and so you use languages that emphasize the concepts you want to teach.

      You don't teach a language so someone will know it later. That makes no sense at all.

      The plus of teaching Python is that it's a badass OOP language with clean and simple syntax. It's an excellent language for conveying object oriented methodologies.

      You learned Lisp and Prolog? I learned Scheme and Prolog. Wasn't because anyone thought I'd ever actually professionally program in those langauges, it's because they represent different paradigms, and, as a student, I learned something from seeing the different types of programming languages.

      After you've mastered the basics, you go out in the world, and use the right tool for the job. For all that you argue against fanboyisms, you commit a few of them yourself. Keep an open mind.

      --
      ad logicam Claiming a proposition is false because it was presented as the conclusion of a fallacious argument.
    11. Re:While there may be "newer" languages by gwait · · Score: 2, Insightful

      Quad precision floating point.

      Doesn't look (after a short google session) that python has this. It's used in nuclear physics still for this reason.

      --
      Bavarian Purity Law of Rice Krispie Squares: Rice Krispies, Marshmallows, Butter, Vanilla.
    12. Re:While there may be "newer" languages by ObsessiveMathsFreak · · Score: 5, Informative

      BTW, a very ill-advised design choice of Python: http://www.python.org/dev/peps/pep-0211/ Ask any numerical analyst to know why it is a terrible idea to solve a linear system with inv(A)*b. But make sure you have at least half an hour free.

      To make a long story short; solving Ax=b by calculating x=inv(A)*b is a terrible idea because calculating inv(A) is an inherently difficult thing. While it would be extremely useful to have inv(A), it's not strictly neccessary to obtain in in order to solve Ax=b.

      At the most basic level, the technique which most would be aware of to solve Ax=b is basic Gauss Elimination, with an augmented matrix and back substitution. In fact, this is often the very first thing people learn how to do in a linear algebra course. It isn't much better than finding the inverse, but it saves a lot of computation in the long run.

      Of course there are many other techniques. Happily however, most packages can now automatically make the best choice on which technique to use, depending on the properties of A. In Matlab and Octave, it all boils down to using the left division operator like so
      x=A\b
      instead of the inverse calculating
      x=inv(A)*b

      Using the first command, Matlab and Octave will choose a technique that best suits the matrix A. This page has a list of all the techniques that Matlab can use to solve the linear system. To my knowledge, Octave has a number of techniques as well, but I'm not sure if it's as comprehensive as Matlab. Also, Octave's left division operator has been known to have bugs.

      And to return to the main topic, Octave and Matlab both use LAPACK extensively, which is written completely in Fortran(and based on BLAS). There's really no other language for linear algebra.

      --
      May the Maths Be with you!
    13. Re:While there may be "newer" languages by Fred_A · · Score: 2, Funny

      I really expected that to be a link to TdWTF...

      --

      May contain traces of nut.
      Made from the freshest electrons.
    14. Re:While there may be "newer" languages by ceoyoyo · · Score: 2, Informative

      Python includes a great deal of MatLab functionality if you go look for it, and has lots of other advantages over MatLab. It's a modern, general purpose, object oriented language that scales well. You can write multi-thousand line apps in Python that are elegant and easy to maintain and understand. MatLab is designed to write very short programs in, but people are always trying to write big, full fledged apps anyway.

      Plus Python is free and MatLab costs thousands.

  5. How about Cobol? by PIPBoy3000 · · Score: 2, Informative

    Ironically we're doing an implementation of a "new" HR system and a big chunk of it was written in Cobol. We have one guy past retirement age who knows it, but otherwise the bulk of our developers just know those fancy new languages.

    Some of those older languages have a surprising amount of life left in them, out in the real world.

  6. Python is hard too by vikstar · · Score: 2, Interesting

    Isn't as hard to write fast python code as fortran code? When you're paying large money for supercomputer time, your multi-day molecular dynamics simulations better run quickly.

    --
    The question of whether a computer can think is no more interesting than the question of whether a submarine can swim.
    1. Re:Python is hard too by sakdoctor · · Score: 2, Funny

      No,
                            not really.

    2. Re:Python is hard too by Bill+Barth · · Score: 2, Insightful

      End users rarely pay for supercomputer time. Very rarely. There's an application process and peer review in most cases, but the time is, in the end, free.

      --
      Yes...I am a rocket scientist.
    3. Re:Python is hard too by SatanicPuppy · · Score: 3, Informative

      The point everyone misses with Python is that Python was designed to play very nicely with external libraries. Python isn't as fast as C at some things, and isn't as fast as Fortran at some things, but is much easier to develop in than either, and can incorporate libraries in both of those languages.

      You can eat your cake and have it to.

      --
      ad logicam Claiming a proposition is false because it was presented as the conclusion of a fallacious argument.
  7. So what? by bsDaemon · · Score: 3, Insightful

    Does it really matter what language they're taught in? They should be learning the concepts of programming, not just a language. However, FORTRAN has the benefit of already having a large existing code base and deployment in the field in which students in those particular disciplines are studying. There's no reason for them NOT to learn it, and if they feel like learning Python later, then then may. Python isn't the solution for every god damned thing in the world, even if it can do it.

    1. Re:So what? by icebrain · · Score: 2, Interesting

      I think you're missing the point.

      See, the point is not to teach all students FORTRAN (or Matlab, or whatever). The point is to teach it to those who might actually use it.

      RTFS--the author was asking what language NON-CS people should be learning. For example, I was an engineering major (aerospace). Teaching me Java or php would be absolutely useless, because I am never going to use those in the real world. Matlab and FORTRAN are quite fine, though, because there's a decent chance that I would wind up using them later on in my career.

      (Of course, at the time, GT made everyone take Scheme, which was completely pointless for about 80% of the student body... I would have much rather learned Matlab properly than try to figure it out on the fly later)

      --
      The meek may inherit the earth, but the strong shall take the stars.
  8. Considering Professors Teach What They See Fit by eldavojohn · · Score: 3, Insightful
    Disclaimer: I went to the University of Minnesota for my BS and George Mason University for my MS both in Computer Science and I didn't learn one single thing about Fortran other then that it existed. People in other disciplines around me (ME, EE, etc) seemed to bitch about 77 versus 44 or whatever--I was too busy studying to care.

    What do people in the Slashdot community think?

    The easy route is just to let them teach what they want to. Professors will talk and push whatever they feel is valuable and they sure the hell aren't going to listen to a Slashdot user half their age that will get on his knees and write Java for an extra buck. If you get a whack job professor teaching only archaic languages, the University will probably hear complaints from alums about getting into the job market and wishing they had learned R instead of Fortran. I don't know about the other engineering programs but I'd sure rather be a master with R than Fortran. Is Fortran more efficient? Depends on if you're talking about cycles or amount of time it takes to write a quadratic sieve for prime numbers.

    I had to learn C and I actually like plain jane C in all its simplicity. I think colleges should stick to a low level language for numerical computation courses (in my case C but I believe Fortran would function fine), an intro course to an interpreted language like lisp scheme perl whatever and should of course offer full courses in whatever is the latest craze for usable languages like C++, Java ... maybe even Ruby?

    I wager this will be a hot debate and I think it's fine if people want to teach Fortran, I learned scheme and I've never used it in my professional work! Just so long as when they enter the job market, they're prepared.

    --
    My work here is dung.
  9. libraries. gigabytes of libraries by lkcl · · Score: 5, Informative

    i spoke to someone studying engineering in 1990 who was being taught fortran. they were using a mathematical library that would solve partial differential equations, by presenting the user with the actual mathematical formulae to them.

    these kinds of libraries are staggeringly complex to write, and they have been empirically proven over decades of use to actually work.

    to start again from scratch with such libraries would require man-centuries or possibly man-millenia of development effort to reproduce and debug, regardless of the programming language.

    so it doesn't matter what people in the slashdot community think: for engineers to use anything but these tried-and-tested engineering libraries, that happen to be written in fortran, would just be genuinely stupid of them.

  10. I still use Fortran for sciantific calculations by sigxcpu · · Score: 5, Informative

    If all you need is to crunch numbers, Fortran is a good choice even today.
    It might not be the best language to introduce someone to computer science, but it is very powerful for anything that has to do with matrix operations.

    A few years ago in a physics graduate course we had a simulation project which left the choice of language to the student.
    We compared performance between implementations in C C++ and Fortran.
    Fortran was consistently faster by a big margin.
    It's also very easy to learn.

    That said, I do most of my coding in C.

    --
    As of Postgres v6.2, time travel is no longer supported.
    1. Re:I still use Fortran for sciantific calculations by NekSnappa · · Score: 2, Interesting

      My first engineering class after leaving the Marine Corps in '86 was a 3 credit hour class that met twice a week. The first class each week focused on engineering graphics (drafting), the second was Fortran 77 programming.

      The computers in the lab were, I believe, 286 based Epson machines with dual 5.25" drives, running MS-DOS. As an added bonus our "development environment" as you say now, was edlin!

      At that time I had no personal experience with computers. I didn't know the difference between the OS, the text editor, and the compiler. Yet I had no problems with picking up the concepts and learning how to use both the language and a general use computer. I guess it was unofficially a trial by fire computer literacy class too.

      Since then I've taught myself enough of a couple of different programming languages that I needed in the course of my work. Back in the day Lisp was the daddy for customizing and automating AutoCAD!

      --
      I want to shoot the messenger!
  11. Re:In a word... by Anonymous Coward · · Score: 2, Funny

    No.

    You make a persuasive argument, but on the other hand, yes.

  12. different languages for different purposes by rotor · · Score: 3, Insightful

    There's no problem for teaching Fortran if it's the right tool for the job. It was 13 years ago that I took Fortran in College. It went great with physics and modeling courses. These days I write web-based database apps in Java/Perl/whatever language-du-jour is required of me, but I wouldn't want to use many of these languages for scientific purposes. I'll leave that to Fortran and C.

    --
    Addlepated - punk & metal
  13. Re:Fortran is weak sauce buddy by conspirator57 · · Score: 4, Funny

    Yes, everything should be written in a fresh, clean language.

    I nominate VBScript.

    --
    "If still these truths be held to be
    Self evident."
    -Edna St. Vincent Millay
  14. Python is not programming. by Weather · · Score: 2, Informative

    Python is scripting. FORTRAN is programming. MPI is vastly more supported by FORTRAN than any other language - grow MPI support for C++ or Object C, and then FORTRAN can go away.

  15. Don't fear modern languages by ZenGeek · · Score: 3, Interesting

    I work at a university research lab and Fortran is still very much present. If nothing else, students need to be able to work with legacy code. I agree, however, that new projects should make use of more modern languages. Special consideration should be given to functional programming which naturally fits many science problems and is easily parallelizable due to its "no side effects" philosophy.

  16. Yes by tygerstripes · · Score: 4, Insightful

    It's called Scheme.

    --
    Meta will eat itself
  17. Re:Not so easy by Anonymous Coward · · Score: 2, Informative

    They ditched those line length limitations, special columns etc. twenty years ago. I suppose that is the burden of being the oldest computer language in use today: lots of people evaluate it on the basis of what the language was way back when they learned it.

  18. Still going to be around for a while by gustgr · · Score: 2, Interesting

    In my opinion, yes. I am an undergrad Physics student (senior) and had my first contact with Fortran in my third semester, in a course called Computational Physics I. We learned the basics of Fortran 77/90 and how to solve some numerical problems using it. We also simulated some interesting problems that amazes undergrad students such as chaotic oscillators, Magnus effect in action and a few other simple yet curious systems. I had already some programming experience, but most other students didn't. They got it quite quickly and I think this is due Fortran's simplicity.

    Even if you are never going to use Fortran in your own projects, you will stumble on it now and then if you are going seriously into applied and theoretical research field. NASA, for example, has tons of production code written in Fortran and even new codes are written on it. Many many Physics and Chemistry groups around the world have their most important codes in Fortran, and sometimes they use clever hacks to make the code faster, so a minimum understanding of it is necessary. I work with a Computational Chemistry group and much of the code they still develop, even for new applications, is Fortran. It is good and solid code, they are very experienced on it, and they are not willing to change to another technology so easily.

    As a first language I don't know if Fortran is the best, maybe Python or Java would be my choice in this case, but it is definitely worth learning.

  19. No fortran - just Python by Anonymous Coward · · Score: 2, Insightful

    > It's also very easy to write simple programs in it.

    99% of programs are not simple any more...

    > No way I'd use Python for serious large data set numerical calculations.

    No way I'd us Fortran for serious large data set numerical calculations...

    First I use Python - it is fastest to write and debug and has advanced data structures that simplify algorithms...
    What good is that my program run one day shorter if it took me 2 weeks more to write and debug...

    If I need to optimize - I am moving the internal part to C - it optimizes almost as well as Fortran...

    There is Also NumPy ...

    The key thing is that it is algorithms what are more important - and these are easier to write/learn
    in Python - so it students should learn Python first and only some need to learn fortran..

    1. Re:No fortran - just Python by dodobh · · Score: 2, Insightful

      Until you realise that Fortran has well tested and proven libraries which you would need to mostly reimplement in Python. See this comment for example.

      --
      I can throw myself at the ground, and miss.
  20. PYTHON???? by Fantom42 · · Score: 5, Insightful

    Are you serious? Python?

    I am somewhat a Python fan boy. I love it. Its freaking wonderful for prototyping and really has a great, natural flow that reminds me a lot of pseudocode I might just invent on a napkin. Great language. But its also a factor of 30 times slower than a compiled language like C.

    (http://www.osnews.com/story/5602/Nine_Language_Performance_Round-up_Benchmarking_Math_File_I_O/page3/)*

    And Fortran is able to do optimizations (due to differences in the language for evaluation of expressions) that C is unable to do. This has to do with guarantees of ordering that Fortran does not give that C does. My point is that Fortran is even faster than C. Why do you think its still around?

    The physical sciences aren't using a fast language because they are bored, or obsessed with speed for the hell of it. They use them because the problems they solve are typically deep into polynomial space, like O(n^3) or O(n^4). Having something 30 times faster means they can run 30 simulations instead of just 1. It makes a big difference to them.

    I think the author of this article has lost some of this perspective.

    That said, what this article should have tackled is, what do we want to teach engineering students about computer science? Right now, they take a class that teaches them C++, Java, Python, or whatever. They get some procedural programming skills with maybe a little tiny bit of object-oriented stuff (without really covering OO fundamentals IMHO, which are a more advanced topic) and they are thrown into a world where they are writing code in C for embedded controllers or Fortran for computational codes. As a result, there is a huge body of code out there written by people who know how to get the job done, but don't exactly write code that is very maintainable. They relearn the lessons of CS he hard way over 10-20-30-40(?) years of experience. Are we really giving these young students (who are not CS majors) what they need? What kind of curriculum would be ideal for someone who is going to end up writing code for something like a robot control system in C?

    * I didn't really look too closely at this particular source, but I've seen numerous benchmarks all saying the same thing. If you want a surprise, go look at how LISP stacks up compared to C. It is better than you think.

    1. Re:PYTHON???? by slim · · Score: 2, Insightful

      You're advocating premature optimisation.

      Now, I'm speaking from a position of ignorance about Fortran - but I'm guessing if it were as expressive as a modern scripting language (Python, Ruby, Groovy etc.) then it would be more generally popular.

      The new scripting languages are *so* condusive to exploratory programming, it seems to me a no-brainer that undergrads would benefit from learning one. When speed becomes an issue, optimise whichever 1% of the routines are taking up the time.

    2. Re:PYTHON???? by Fantom42 · · Score: 2, Interesting

      They get some procedural programming skills with maybe a little tiny bit of object-oriented stuff (without really covering OO fundamentals IMHO, which are a more advanced topic)

      It seems kind of backwards when the fundamentals of a subject is considered an advanced topic.

      I agree with you in principle. However, do engineers really need to understand the intricacies of ZF set theory and peano axioms to formulate and solve a differential equation? What are considered fundamentals for a given topic really depends on how you intend to use it (in a practical sense, at least). People only have limited times, and limited brains, and while it would be nice to understand _everything_ from the ground up, and first principles, sometimes you have to settle for just knowing how to effectively use a tool and focus on your own area of expertise.

    3. Re:PYTHON???? by dodobh · · Score: 2, Insightful

      Think of Fortran as a specialist little language/DSL. Most people don't learn many DSLs in university (except UML and SQL).

      Fortran is a DSL for number crunching and matrix algebra.

      --
      I can throw myself at the ground, and miss.
  21. Re:Agreed, but engineers still use Fortran by stewbee · · Score: 4, Informative

    I did my graduate studies in a university electromagnetics lab. Two of the professors main research area was FEA. By default, we still ended up learning some even if it wasn't our research area. Most the students were pro Matlab, where as the professors were pro Fortran. As a result, if you were doing FEA for your research, you were learning fortran. If you are doing small simulations, then go ahead and use Matlab, since it will be easier to code and debug. Once you start creating 3D meshes, the number of unknowns becomes huge. At that point a compiled language is a better choice. At least fortran has complex numbers native to the language, so its implementation is a bit more elegant than say C/C++.

  22. University != Trade school by SpinyNorman · · Score: 5, Insightful

    IMO universities should be teaching core principles and methods, not attempting to impart up-to-date job skills.

    If you are going to teach FORTRAN because it's of use in the real world, then why stop there? Why not also (god forbid) teach .NET. JavaScript, C#, etc. May as well teach them Excel macros and how to interact with Microsoft Clippy while you're at it.

    No!

    Teaching programming should be done in a langauge that imparts the principles easily and teaches good habits. You could do a lot worse than Pascal which was often used in this role, or maybe today just C++. I'd argue against Java and scripting languages as the core language since they are too high level to learn all the basics. You could throw in Perl, Python or any modern scripting langauge as a secondary, and for a Computer Science (vs. Physics, Engineering, etc) it's appropriate to teach a couple of other styles of programming - e.g. assembler, and functional programming.

    1. Re:University != Trade school by Rhys · · Score: 4, Insightful

      We're not talking CS here, we're talking Engineering. Teaching them a specific language used in their field /is/ teaching them core principles and methods. Think of it like a basic diffeq class, giving them the tools to be able to learn their field, as opposed to more advanced math classes that underly diffeq.

      --
      Slashdot Patriotism: We Support our Dupes!
  23. Short answer, no. by sizzzzlerz · · Score: 2, Insightful

    While used extensively in a number of scientific research programs, it isn't used commercially in any great amount, if at all. Unless the student is planning to work in an area where the language is used, there aren't any great benefits to knowing it. College should be more about leaning the discipline of software engineering, not learning a multitude of programming languages. C or Java serve that purpose perfectly well and have extensive use in the non-academic world. It it is needed at some point, learning it won't be terribly difficult if one is already conversant with other languages.

    I used fortran 30 years ago, stopped using 25 years ago, and, outside of a few PhDs who use it where I work, nobody uses it for anything.

  24. Newer doesn't always mean better. by Churla · · Score: 3, Insightful

    Nail guns have been around for a while, but a lot of houses still get built with hammers.

    If a simple tool does a job efficiently and effectively then why "change for the sake of change"?

    --
    I'm a fiscal conservative, it's a pity we don't have a political party anymore
    1. Re:Newer doesn't always mean better. by Jawn98685 · · Score: 2, Insightful

      Errrmmm..., you haven't built many houses, have you? If you had, you'd know that nail guns are far more efficient for most fastening tasks. Even the fastest old-school framer or roofer with a hammer can't come close to keeping up with a worker armed with a nailer. Yes, there are tasks where the nailer won't do the job; because it's to big to fit into the work area, or because the work demands a level of precision that the nailer can't provide. Both cases represent a tiny fraction of the set. So to, I guess, is the case for data processing tools.

    2. Re:Newer doesn't always mean better. by Jawn98685 · · Score: 4, Insightful

      But the original point of the article is about teaching people who are mathematicians (not programmers) FORTRAN or a newer language such as Python. These aren't people who, most probably, won't be coding for a living. Although knowing how a code a little will come in handy. To that extent it's more like the fact that most homeowner own a hammer and know how to use it, but don't have a need to buy a nail gun and learn how to use that. (admittedly buying a nail gun for a homeowner is really about how much FUN it is to have a nail gun handy all the time!)

      On a side note : How many of those roofers and framers learned to use a nail gun before a hammer?

      Most roofers and framers learned to use a nail gun first, and many, if not most, will never learn to use a hammer at any level that could be called proficient in the real-world "production" environment of housebuilding. Remember, we're talking mastery of the tools at a level that allows "efficiency". That's a plateau that is far lower for the nail gun.

      Same goes for programming skills. Python, for example, is far easier to master at that level (efficient production) than FORTRAN, for most tasks. Yes, there are those tasks for which FORTRAN is the right tool for the job (number crunching), but such a case is a very rare exception. So if "knowing how to code a little" is a good thing, spending x hours of the undergraduate's time teaching him a more utilitarian tool is the better expenditure of time, is it not? And BTW, let's dispense with the "but it doesn't teach good programming practice". We're not talking about BASIC here. There are a number of candidates that would fit the bill. Hell, I'd suggest that PERL is a far better choice than FORTRAN.

  25. More FORTRAN please?! by laxsu19 · · Score: 3, Interesting

    I am a manager in a highly technical organization that relies on computer codes to do our job. In my experience, there isn't ENOUGH FORTRAN teaching in the college level. Maybe its location based, but most of our new-hires (we get most from the northeast, but still get a noticeable amount from as far away as University of Washington, Univ of Hawaii, and USC) actually are NOT taught FORTRAN and instead are taught something object-oriented, typically C++ or Java. I know for a fact that Penn State suggests C++ for all undergrad engineers (FORTRAN is offered though - the classes hold less than 50% total students than does the C++ course). In my organization we also have a 'double-hump' age distribution: lots of people ready to retire (or could have retired 5 years ago...) and lots of people who are within 5 years of their first day on the job. This creates a problem of knowledge management; our new guys need to know the details of the FORTRAN code they are using every day to the extent that our ready-to-retire guys know it, and fast. If they are not taught FORTRAN, this creates an even larger learning curve for them which isn't desirable. So one option would be to 'rewrite the code for the future generation'.. We definitely do not have the resources to rewrite our workhorse codes that have been in use and development since the 70s. I don't know if an organization as large as Microsoft could rewrite Windows in a new language. Also, we can't retire our old codes because they are still actively needed to respond to emergent issues (it is easier to maintain the codes than it is to make a new model to be inputted into a new code). So, our hands are tied (mine specifically!) and my organization actually needs MORE FORTRAN programmers coming from the university just to maintain the status quo.

  26. Re:Not so easy by teg · · Score: 4, Insightful

    Fortran hasn't had those limitations for decades - Fortran 90 and later are ideal languages for expressing mathematical algorithms and crunching numbers

    Fortran hasn't had those limitations for decades - Fortran 90 and later are ideal languages for expressing mathematical algorithms and crunching numbers. The handling of arrays, matrices are just what they should be.

    I wouldn't use Fortran as a general purpose language - having used Python for more 10 years I shudder at using Fortran for string handling, databases, user interfaces and more - but as a tool for expressing math it's the best, and also the most widely used. The alternative would be matlab (much of the syntax isn't that different).

  27. Re:Agreed, but engineers still use Fortran by T+Murphy · · Score: 2, Interesting

    I'm an ME student at Rose-Hulman and we're taught Matlab in two quarters. I've used it for a few other classes, though I've also elected to take a couple of Java courses so I can't say I learned anything from the Matlab courses beyond Matlab syntax.

    As for Python, I've never used it, but I've heard it's basically pseudo-code. If Python isn't likely to be used by the students in a real job, I don't see why you'd teach it to them. It makes sense to use for an introductory CS course with the intention of then rapidly teaching students Java or C or something, but if one class is all students will have to prepare them for when an employer asks them to write up a quick program, I'd give them a full immersion with the 'real thing'. In my Matlab courses you have the whole array from students that could just as well be CS majors to those who never feel comfortable with programming. If you teach them Python, only to tell them anything they'd do at work would be more complicated, the latter half of the students would never feel ready to program on the job.

  28. Y2012 problem: Mayan calendar runs out by David+Gerard · · Score: 5, Funny

    The Mayan Long Count Calendar turns over in 2012. Mayan date 12.19.19.17.19 will occur on December 20, 2012, followed by the start of the fourteenth cycle, 13.0.0.0.0, on December 21st.

    The event was first flagged by megalith scientist Terence McKenna. The end of the thirteenth cycle would break many megalith calculations — which conventionally use only the last four numbers to save on standing stones — with fears of spiritual collapse, disruption of ley lines, Ben Goldacre driving the chiropractors back into the sea and the return of the great god Quetzalcoatl and the consequent destruction of all life on earth.

    Megalith programmers from 4000 years ago are being dredged up from peat bogs and pressed into service to get the henges updated to handle the turnover in the date. "It could be worse," said one. "I could still be programming COBOL."

    --
    http://rocknerd.co.uk
    1. Re:Y2012 problem: Mayan calendar runs out by juggledean · · Score: 2, Funny

      Get a grip, it's only been about 400 years since the last turnover.

    2. Re:Y2012 problem: Mayan calendar runs out by sycodon · · Score: 2, Funny

      The only reason it stops at 2012 is that they ran out of space on the stone and the quarry workers were on strike.

      --
      When Fascism comes to America, it will call itself Anti-Fascism, and tell you to give up your guns.
  29. Sillyness by T.E.D. · · Score: 4, Insightful

    This was clearly written by someone who doesn't actually do any scientific computing.

    As hard as it may be for some CS-types (myself included) to believe, Fortran is still the language for scientific computing. I've worked at flight simulation companies for two different companies (and 5 different groups) for the last 15 years. The math required to simulate a flying aircraft in realtime is ungodly hairy. It also has to get done fast. We typically have 50 or so different simulation models (plus all the I/O) that have to run to completion 60 times a second. That's about 17ms, or 8ms if we want %50 spare. In addition, for a realtime app like a simulatior it needs to take the same time to execute every time (no runtime dynamic allocations, GC, etc.) or things "jitter".

    Everywhere I've worked, with the exception of Ada mandated jobs, had this code done in Fortran. Yes that includes today. We are today writing new Fortran, and we are not alone. When we request models from the aircract manufacturers, they come in Fortran (or occasionally Ada). Fortran is still, and quite possibly always will be, the language for Scientific Computing.

    Suggesting non-CS math and science students learn some other programming language instead is just wrong. Further suggesting that it should be the author's favorite hip new interpreted languge is just laughable.

    1. Re:Sillyness by apoc.famine · · Score: 4, Informative

      I'll add a "+2" to this. My background is in Astrophysics, and the coding there is largely done in Fortran. The friends and people I know spread between 4-5 different universities all program in Fortran. I'm moving into Geophysics/Atmospheric/Oceanic sciences, and all that work is done in Fortran. From fluid dynamics to stress fault calculations, Fortran is the de facto language.
       
      To be clear, we're not talking about programming here. We're talking about math. Pure, hardcore, overwhelming math. The crunching of terabytes of data. Matrices with millions upon millions of cells, being combined with more of the same.
       
      If we were talking about pure programming, Fortran is a terrible language. What we're talking about here is automating massively complex mathematical calculations on enormous amounts of data.

      --
      Velociraptor = Distiraptor / Timeraptor
  30. Re:Not punched cards by AllergicToMilk · · Score: 2, Informative

    I spent an entire summer doing exactly that (data entry on an 029). I spent every penny I made on AD&D :-)

    --
    There are only 6,863,795,529 types of people in the world.
  31. Re:libraries. gigabytes of libraries by bmcage · · Score: 2, Informative
    Maple does not solve PDE's. It can solve some simplified things on rectangular grids with FD. MatLab has a toolbox for FEM analysis, but it takes skill to set that up.

    Freefem++ (GPL code) however is C++ and solves PDE's by writing the weak formulation. I never saw fortran recently.

    Even the famous VODE fortran code to solve ODE's has been rewritten to C++. It's now called sundials (BSD code), and guess what, there is a python implementation, pysundials.

  32. Newsflash - science is real by SuperKendall · · Score: 2, Insightful

    IMO universities should be teaching core principles and methods, not attempting to impart up-to-date job skills.

    IMIO, Fortran is not about "imparting up to the date job skills" as much as showing students a powerful tool to accomplish a high-level task that they'd otherwise have to learn more programming to do - and that takes from time spent with the science they are trying to learn.

    Just because something is real does not make it a "trade skill" with al of the scorn you heaped upon it bountifully.

    --
    "There is more worth loving than we have strength to love." - Brian Jay Stanley
  33. Re:Python is just a fad. by infamous_blah · · Score: 2, Insightful

    Unlike Pascal, Prolog, Smalltalk and the rest of the fad languages, Fortran is still here, and it will still be here when Python is long-forgotten.

    I would suggest teaching them C, but it may be too complex for a first language.

    Python will be 20 years old soon and is used in many, many contexts. Whatever your opinion of FORTRAN or Python's applicability for engineering students in particular, calling Python a fad is disingenuous.

  34. From an engineer's viewpoint by dw_g · · Score: 4, Informative

    I'm an engineer with a large aerospace firm. All our major programs are in Fortran and have to be used, modified, and maintained. I remember a few years ago we hired a new grad from MIT; she had studied Basic, Pascal, and C; so of course we had to teach her Fortran so she could do her work. The engineering world is heavily dependant upon Fortran, and to not know it puts you at a huge disadvantage.

  35. Re:libraries. gigabytes of libraries by jstults · · Score: 3, Informative

    Except I'm pretty sure that there are modern languages and libraries that can handle this without Fortran. I don't have much experience with it myself, but I'm pretty sure that's exactly what MATLAB is for, for one.

    Dude, what do you think the libraries Matlab uses are written in? Check out netlib to get an idea, ATLAS, BLAS, LAPACK, LINPACK, etc. Matlab stands on the shoulders of the giants of scientific computing (implemented for the most part in Fortran).

  36. Dude... by Balinares · · Score: 2, Interesting

    ... You're WAY behind the times.

    I got a buddy who is an astrophysicist and worked at NASA, and he tells me his department ditched FORTRAN years ago in favor of Python+Numeric.

    I hear you about the need for badass number crunching tools. It's your assumption that only FORTRAN fits that particular bill which is erroneous.

    Not to say that FORTRAN doesn't have its use. It's just that other tools have since become better at some of those.

    Python Numeric homepage. Check it out.

    --

    -- B.
    This sig does in fact not have the property it claims not to have.
  37. Fortran is analogous to hazing by 93+Escort+Wagon · · Score: 3, Interesting

    The Elders feel that if they had to go through it, so do the young'uns gol durn it!

    Seriously, though - as far as I know, Fortran has always been the language of those humonguous numerical models because of its optimizations with regard to array handling. I think it makes perfect sense as a first (or second) language for science majors. However I imagine the person asking this question is likely one of the young'uns being forced to learn it; and that person doesn't really have the perspective as to *why* this is so. After all, he's been hacking around in C and Python for years - they're in his comfort zone and have been good enough for the sorts of things he's been dealing with.

    --
    #DeleteChrome
  38. Re:luxury by alexj33 · · Score: 2, Funny

    ...And we liked it.

  39. Python (and C, and Fortran) by AaronParsons · · Score: 3, Interesting

    I'm a scientist who does the bulk of his programming in Python. Numpy (the numerical package for Python) runs at only a 30% overhead over C. When that's not fast enough, I drop into C/C++ for bottlenecks and wrap that back into Python (using the Python C API more often than swig/boost). When there's a great Fortran library that's fast and battle tested, I wrap that into Python using F2Py--and I don't even know that much Fortran.

    Just like it's good to know more than one spoken language, it's good to know more than one programming language. It's a mistake to think one programming language fits all needs. That said, it can also be helpful to know one really well, and others enough to convert them into your primary language. For me, Python fills that role very adequately, and I would highly recommend it be a part (read: part) of the undergraduate programming curriculum.

  40. Re:Agreed, but engineers still use Fortran by 0100010001010011 · · Score: 3, Informative

    Matlab stops being a 'slow' language once you learn how to use it.

    Matlab stands for MATtrix LABoratory. It loves to do matrix algebra more than any other kind. The worst offenders I see are people that try to use for loops for everything.

    for i=1:10
      y(i)=sin(i);
    end

    is much slower than:

    y=sin(1:10).

    And it just scales up from there. There were only a very few times I've ever had to use for loops and that's because of memory issues (on Win32).

    Unless your current state depends on the previous one, there is no reason to use a for loop.
    -
    I never learned FORTRAN, but I make my living on Matlab. Matlab is good for quick turn around. If I need to make a script NOW that does X for me, I can turn it around in a few minutes. No compiling, etc. If I really want speed, I can write MEX (compiled) code.

  41. Re:libraries. gigabytes of libraries by UID30 · · Score: 3, Insightful
    Awwww c'mon. This is just plain silly. Since the late 80s, "Fortran" on most major computing platforms has been nothing more than front end language parser for a multi-pass compiler system ... just like "C" and "Pascal". Whatever language you choose, they all pass their assembly output to the same back-end assembler, and binary machine code generated is pretty generic.

    Back when I was in college, I maintained a Fortran77 program that was a custom built TCP/IP client-server system. But wait! F77 didn't know what a socket was! right. The network code was written in C and compiled into object code which was directly linked into the F77 project.

    Great. So there are these massive libraries written in Fortran to do wonderful things. Best case scenario is you can link them directly into your language of choice. Worst case, call them from the scripted language of your choice with a wrapper ... Swig anyone?

    Bottom line? Program in what you are comfortable with. Would your peers would frown on your efforts if you learned anything but ALGOL? Fine. Use ALGOL. There are valuable lessons to be learned in any language. Strong vs weak typed, functional vs object oriented, structure, best practices ... hell, how to write "fast" code. I've been a programmer for near 20 years and I'm still learning that lesson on a daily basis.

    The surest way to corrupt a youth is to instruct him to hold in higher esteem those who think alike than those who think differently. - Nietzsche

    --
    "Glory is fleeting, but obscurity is forever." - Napoleon Bonaparte
  42. Fortran is still useful for calculations by golodh · · Score: 5, Insightful
    Lets face it: Fortran (even Fortran-90) might not be fashionable, but it's a lot simpler (and therefore quicker and easier to learn) than C++, much faster than Python, and it lends itself well to the implementation of massive calculations.

    It's definitely not a language for amateurs in the sense of people who like to fiddle with the system, are interested in how the compiler works, or who just want to make gee-whizz web mashups. It's a language for people who don't care a rat's *ss about computers or programming, but who need to get their calculations done without wasting time on fiddling with pointers and who need reliable answers without being bitten by silent array-boundary overflows to boot. So Slashdot might not be the best place to ask for an opinion.

    Besides, most of today's numerical libraries (BLAS, LAPACK, ATLAS, EISPACK, FFT) are written in Fortran. If you want to use them, you could do worse than learn Fortran.

    True, it's not a language you'd want to do sophisticated datastructures in, or tree-searches or text-processing or payroll accounting or database manipulation. But especially chemists (and to a lesser extent physicists) have more call for numerical software than they have for non-numerical software.

    So no. It's not at all ridiculous to teach Fortran as a first programming language to non-computer-science students. Alongside Matlab (or Octave or Scilab) it will do fine for chemists.

    1. Re:Fortran is still useful for calculations by iron-kurton · · Score: 2, Insightful

      It's a language for people ... who need to get their calculations done without wasting time on fiddling with pointers and who need reliable answers without being bitten by silent array-boundary overflows to boot.

      There are tons of mathematical packages like Matlab, Octave and Mathematica if you just want to get your calculations done. So what's the advantage of Fortran?

      --
      Change is inevitable, except from a vending machine -- Robert C. Gallagher
  43. Re:Python? by DrgnDancer · · Score: 2, Interesting

    That was my thought. An general purpose, interrupted scripting language for scientific computing? Say what? I've never seen anyone do any sort of scientific research programming with Python, unless it was a control script or GUI interface to something written in Fortran or a C derivative. What's the point of running on the kind of huge multi-CPU systems they use for scientific modeling, if you're going to use a an interrupted language?

    --
    I don't need a million points of light, just two points of multi-mode fiber and a 10 Gig-E router.
  44. Since I'm on both sides of the fence by jinxed_one · · Score: 2, Interesting

    Ok here goes:
        Should science undergraduates be taught Fortran? Yes
        Should it be the FIRST language, NO, not any more

    So much of science, especially physics, is done on computers now - as both a software engineer and someone transitioning into Physics I ran into many people that had severe problems learning FORTRAN and applying it to problems. I really feel science students should have a couple of general courses in programming in C before moving on to other languages or even programming classes specific to their science. Here's the reasoning:
    A) Science students need to learn programming basics away from the pressure of also learning within their science field at the same time - if your learning the science at the same time, the actual basic programming concepts get lost and muddied with the science being learned.

    B) It can allow a science major to learn the concepts of programming in a general purpose language without muddying it with a lot of OS specific, library specific, attitude specific usage (aside from the compiler use)

    C) There is a C compiler on almost every system you will most likely use in your lifetime as a scientist

    D) C has enough structure to be "readable", but doesn't have so many constraints that it has problems being fast

    E) C syntax is the basis for many other programming languages including Python and Java (both of which are heavily used in science as well)

    and finally if a science major has a good understanding of programming concepts they can know what to look for when they're learning a new language (whatever it might be) - they will know that they have to learn the syntax for control structures in the new language (for, while, if, etc) as well know they'll have to find out more esoteric language specific concepts like how do I create functions and libraries? How do I use them?

    ALL THAT being said, yes FORTRAN is a critical language to know with the sciences, because of the availability of libraries. HOWEVER, many of those libraries are now available in other languages and/or can be called from a different language via an abstraction (a concept that would be taught in a more general computing course)

  45. Re:Python? by motek · · Score: 4, Insightful

    Evidently, you don't go out that much. People use interpreted languages in science all the time. At least I do. Where I sit, there is quite a bit of spare capacity waiting. When I try to figure something out it is way more reasonable to write a program in three-four hours and have it run overnight than to write it in two days and have it run in (say) thirty minutes.

    --
    I would like to die like my grandfather did - sleeping. And not screaming in terror, like his passengers.
  46. Engineers use Numerical Methods, not OOP by Carbaholic · · Score: 2, Interesting

    It doesn't matter what language Engineers and physicists learn as undergrads, the language isn't what matters. It's the numerical methods that matter.

    In fact, I think it's good that they learn FORTRAN because so much of the code they'll work with in industry is written in FORTRAN.

    In my first programming class we spent the vast majority of the time learning numerical methods like taylor expansions and how to write them. In the very last few lectures we talked about what OOP did one homework assignment where we wrote and used a class. This was the right way to go because for an engineer, because the mathematics are far more important than the structure.

    I've seen aerodynamic, structural, and acoustic calculations where the mathematics make your head spin, but it only takes two or three functions to write the numerical method to solve the equations. This is the kind of program engineers need to be good at.

  47. Re:Python? by digitig · · Score: 3, Informative

    Not all scientific programming is heavy duty number crunching -- I'd suggest that only a minority is. My postgrad research proposal (involving Monte-Carlo simulation) said that I'd use Python for the framework and would swictch to C/C++ where Python got too slow. Python never did get too slow, and I never needed a single line of a C-derivative language. I also used Python for some continuation of Robert Axelrod's classic work on game theory (is that science, math, or psychology?).

    Anyway, you're making the classic assumption that undergrads are taught the language for the sake of the language; that it will be the language they will use in the real world. Rather (even in the sciences, not just in computing) it's programming that's being taught, and the language is simply a means to an end. It's futile to try to double-guess what they will be using when they get out into the real world; even if you look at what's in demand now, no language has a monopoly and the language-of-the-moment will change anyway during their career. The person who can program Python will pick up any other procedural language quickly enough, because Python has pretty much all of the relevant constructs, and Python has the advantage of being easy to learn. FORTRAN certainly isn't easy to learn (I did my undergraduate project in FORTRAN), and even the newer versions of FORTRAN that have things like Object Orientation don't present the constructs as clearly as modern languages such as Python. I agree that Python is unlikely to be the only language they'll ever need (don't try saying that on the Python mailing list, though!) but it's at least a contender for the best first language.

    --
    Quidnam Latine loqui modo coepi?
  48. Re:Python? by XDirtypunkX · · Score: 2, Interesting

    One thing that Python doesn't teach is static typing. I'd say having 2 languages (one static typing, one dynamic) and talking about the advantages of both. Hell, you could even use Boo as the statically typed language, which is very close to Python.

  49. FORTAN alive and kicking in meteorological world by klchoward · · Score: 2, Insightful

    A resounding YES to undergrads being taught FORTRAN. I am a graduate student in Meteorology and FORTRAN is alive and kicking in the meteorological community. It is a vital part of many of our programs and models. Perl and Cshell are also very important but I wouldn't be able to do major parts of my thesis without the aid of FORTRAN. The undergrads at my graduate school are required to take FORTRAN (especially if they are in the met program) and they use it in their upper-level core classes. I wish I'd taken the FORTRAN class at my undergrad so I wouldn't have had to catch up during my thesis. Knowing FORTRAN definitely helped me grasp other languages faster.

    --
    âoeQuestion with boldness even the existence of God.â - Thomas Jefferson
  50. Re:Python? by digitig · · Score: 3, Interesting

    If it were a computer science course then I'd say that something in the Lisp family, something in the OCAML or Haskell family, and somthing from the Prolog family. I agree that they're likely to encounter static typing at some point but this isn't a computer science course so it shouldn't try to teach everything, and static typing shouldn't come as too much of a shock. Heck, my first language was FOCAL, and I managed to learn to cope with it.

    --
    Quidnam Latine loqui modo coepi?
  51. Fortran is very important by NotNormallyNormal · · Score: 2, Interesting

    Fortran is very important in the world of modelling and high speed computation. When I was an undergrad Fortran was taught for the physical sciences but the computer science dept refused to teach it so it was being taught by some geophysical modellers. I'm not sure that the university even offers Fortran anymore.

    However, frustrated by that, the dept of physics and astronomy now has two courses in computational physics (both in Fortran) taught by modellers from the department. They deal with real world issues (well, real world modelling issues when applied to a spherical cow right?). Only one course is mandatory but both courses are very popular.

    For myself, I use several modelling programs that are purely Fortran that I've had problems dealing with. I'm glad I did take a bit of Fortran though I am much more fluent in other languages these days. In fact my wife, in the private sector, has proprietary software that they use for modelling digital elevations and gravity fluctuation that is written purely in Fortran as well - simply for speed. Until someone invents a real quantum computer, I don't think Fortran in the physical sciences is going anywhere.

  52. MOD Parent up by DeadDecoy · · Score: 3, Insightful

    A program language should be taught on the basis that it teaches the student programming and not that it jigsaws them into the world of business. I student that can transcend languages is likely to be a better programmer anyways, as they'll have more tools and models with which to get a task done. Note that some languages are more suitable than others. For example, Python is useful in the academic setting, where a quick turnaround is important for meeting deadlines and finding solutions. In the business world, languages like C/C++/Cobol/Java might be more suitable for performance or legacy code. That being said, any student interested in programming should be taught languages that are based on different paradigms like structural, functional, object oriented, or shits-n-giggles code (intercal, befunge), that will ultimately enable the student to learn other languages which were not taught, more easily.

    My favorite class with respect to this was assembly. It was fairly easy to pick up and taught you how the computer interpreted commands at a relatively low level.

    1. Re:MOD Parent up by anotherdjohnson · · Score: 5, Insightful

      A program language should be taught on the basis that it teaches the student programming and not that it jigsaws them into the world of business. I student that can transcend languages is likely to be a better programmer anyways, as they'll have more tools and models with which to get a task done.

      I would agree with this in theory, however in practice it doesn't create a programmer who can transcend languages. In fact, they generally become very tied to specific language paradigms or capabilities. For instance, most universities seem to have selected Java as the language for CS. The problem here is that when they get into the "real world" they can't find a job doing anything but java. Why? Because they have no clue what a pointer is or how to use it. Most CS and related programs are hurting our students simply because the instructors don't want to teach about certain things, or because they or the students think it's just too hard. Most people I work with don't really understand how programming really works. I once had a co-worker who had been programming for 20 years, but had no idea that the CPU had registers, what they were for, or how they would be used. That's just sad.

      My favorite class with respect to this was assembly. It was fairly easy to pick up and taught you how the computer interpreted commands at a relatively low level.

      You (and I) are becoming something of a rarity now days, most people I work with know absolutely nothing about assembly. :-(

  53. Legacy code vs new rewrite by cwills · · Score: 2, Interesting
    The fact is, there is an enormous base of existing tested FORTRAN code that is still in use and still being developed within the scientific community. The issue is not simply writing new code in a newer language, the problem is setting up a new tested base in the new language.

    Lets say that you are working on a project to evaluate the effects of theoretical gravity waves through a nebulae. You have a choice

    1. Use 3 college interns to modify some code that you have been working on using a library of subroutines that have you and your prior researchers have been building up and using over the last 40 years
    2. -or- Use 3 college interns to write new code from scratch in a new language that the compiler/interpreter was just released 2 years ago.

    And oh, you have to publish results in 2 months in order to get your next NSF grant.

    Yes, the new code might be all object orienty, and you can use the latest IDE to develop in, and you can hire a bunch of fresh young (cheap) grad students that are familiar with the latest python, perl, C#, etc. development and they can bang out thousands of lines of code a day. But are you really really sure that that freshly written eigenvalue routine produces the correct result? Has that new compiler been tested on the super-computer you have limited access to, can it even take advantage of all the power of that system?

    I'm not saying that FORTRAN compilers are not bug free, but I suspect that the chances of finding a basic compiler or runtime library bug is lower in FORTRAN then in say Perl 6.

    A couple of years ago my son spent some time doing some intern coding work for a private atmospheric research group. The group was/is doing bleeding edge research. My son was helping out one of the researchers in updating code that handled 2D models to 3D models. All the code was in FORTRAN and there was no desire to move away from it.

  54. Re:Are You Serious? by blueturffan · · Score: 3, Funny

    An operating system is staggeringly complex to write yet a single man can write one.

    That's because a married man has to spend so much time trying to figure out how to keep his staggeringly complex wife happy.

  55. Re:Python? by story645 · · Score: 2, Informative

    Say what? I've never seen anyone do any sort of scientific research programming with Python

    My research lab (satellite data processing) is all python and the psychology department in my school is thinking of switching over to python. There are tons of great scientific computing libraries either written or wrapped in python. It's a great language for social science research because it's so simple and clean, and the libraries make it easily extensible to the hard science crowd. I'm working with pretty big data sets at the moment and don't find python that slow in comparison, plus it simplifies so much of the data organization/sorting/filtering tasks.

    --
    open source modern art: laser taggi
  56. Re:Python? by SSCGWLB · · Score: 2, Informative

    I guess it depends on the type of scientific computing you are doing. If you need a cluster to crunch numbers, don't use python. However, there are huge areas in scientific computing where: 1) speed isn't the primary concern or 2) languages like python are fast enough. Also, python has some pretty significant scientific computing tools like scipy (see http://www.scipy.org/), visualization using matplotlib (see http://matplotlib.sourceforge.net/ ), etc. I personally know a lot of people doing scientific computing and general research who use python.

    If speed was the only concern, people wouldn't be using tools like Matlab, IDL, python, and the like. Obviously, a significant number of people doing scientific computing find these tools fast enough.

  57. LHC languages. by Bill,+Shooter+of+Bul · · Score: 2, Informative

    My friend at cern working on programs for the LHC has to do everything in c++ or python. So python might be a good one to learn. I love fortran 90/95 its a good language that only has a hint of the unpleasantness that was fortran 66. As, I'm sure others have posted there are some very high performance libraries/compilers for fortran number crunching. But, its not that hard to pick up if you know c/python.

    But it was pretty funny taking that FORTRAN class with some cs students who only knew ADA. They were sort of freaked out by its "modern" features and "easy" string handling. It was right then and there that I realized I had dodged a major bullet by not becoming a cs major at the school.

    --
    Well.. maybe. Or Maybe not. But Definitely not sort of.
  58. Re:Python? by Darinbob · · Score: 4, Insightful

    Python? As an intro language? And I thought people were misguided teaching Java as the first (and often only) language.

    Second, while some of these scientific programs can run overnight, a lot of them will take a day or more to run, even when compiled and on a super or parallel computer. I don't know of any highly optimized Python compilers for big metal. Fortran is still the number one language for performance computing.

    Third, there seriously needs to be major scientific libraries pre-existing for the language to be useful. An added benefit is being able to support more than one floating point number format.

    Finally, the number one most important reason that Fortran is used in the sciences, is because everyone else uses it in the field. Seriously, what good is Python if all your prof's and advisor's and boss's programs that you need to maintain are in Fortran 66? It's faster to learn Fortran than to port it all. This is part of the "dusty deck" problem, where decades old libraries still have to be used and supported. This applies to many languages - many languages are popular precisely because they are popular, not because of inherent elegance or suitability.

    In the sciences, the students are not being taught programming for the sake of programming, and they're not even being taught to write good programs necessarily. They're being taught to program as a mere tool for the important stuff being taught. Some classes may not even care what language you use, as long as you can read and understand the sample programs and the math library is correct.

    Being in the sciences and not knowing Fortran will be a drawback. In some areas it may not be as big a drawback, but it will be there. This is like trying to do embedded systems without knowing C.

  59. Computers can become much more empowering by GPS+Pilot · · Score: 3, Insightful

    one aim should be to make tools that will serve skilled professionals--not to lower the level of expressiveness to serve people who can hardly understand the problems, let alone express solutions.

    But shouldn't we keep an eye toward eventually moving into a Star Trek-like future, where anyone can ask things like, "Computer: is there a compound that is superconducting at 50 deg C? If so, what is the formula?" And the 48-core, terahertz processor cranks through sophisticated molecular models to find the answer.

    --
    That that is is that that that that is not is not.
  60. Re:Python? by tb()ne · · Score: 5, Informative

    I think you are mistaken regarding what most undergraduate science students actually do (they are not maintaining/upgrading old fortran libraries). Most of the high performance capability that undergrads need involves matrix computations, FFTs, convolution, etc., all of which are included in the python numpy/Numeric module (which is a wrapper around fortran libraries, so they're just as efficient). And since they'll likely spend as much time analyzing data as producing it, python + numpy + matplotlib is a perfectly suitable solution.

    I'm not suggesting that fortran isn't of value to some scientists in some situations but many science students will never have to touch fortran code unless they're forced to take a class that teaches it. As you said: "They're being taught to program as a mere tool for the important stuff being taught." Which is why it makes sense that their intro language is one that is easy to learn, supports multiple programming paradigms, has efficient numerical libraries, has easy-to-use visualization tools, an interactive interpreter, and can be used as a general purpose programming language. And while I personally prefer python for a high level language, there are others that could serve the same purpose.