I'll have to check the language reference.  To me, "simple" is something I can talk about for 20 minutes in class and the students will understand it completely.  <br><br><div class="gmail_quote">On Nov 20, 2007 2:43 PM, Gerry Creager <
<a href="mailto:gerry.creager@tamu.edu">gerry.creager@tamu.edu</a>> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Ooh!  Flamebait!
<br><div><div></div><div class="Wj3C7c"><br>Nathan Moore wrote:<br>> I regularly teach a college course in a physics department that deals<br>> with scientific computation.  After students take the course, I expect<br>
> that they'll be able to write simple "c-tran" style programs for data<br>> analysis, write basic MD or MC simulations, and be fairly fluent in<br>> Mathematica.<br>><br>> In the past, I figured that with the breadth of topics included in the
<br>> course, Fortran, specifically the basic, simple, and reliable F77<br>> dialect (w/ some F90 conveniences) was the language to teach.  In my own<br>> head, my rationale was:<br>> - Most students can grasp the basics of fortran in half a day's reading,
<br>> so I can spend more class time on science and math (probably because<br>> there are no pointers - I think that C is much harder for students and<br>> sometimes "seems" less like mathematical syntax than f77)
<br>> - "Classical Fortran" is a great text and is readable for self-study (I<br>> know of no such text for C/C++)<br>> - several free compilers exist (g95 seems ok so far)<br>> - Netlib, lapack, and numerical recipes cover the math library adequately
<br>> - F77 is compiled (Perl/python are too slow for an MD/MC sim and I<br>> figure that students should know at least on compiled language and one<br>> scripting language to be competent)<br>> - MPI is a relatively basic addition to the language (again, no
<br>> pointers, allocation, or addressing)<br>><br>> After reflection though, I've started to wonder about the wisdom of my<br>> choice.  Specifically (like RGB), I love the GSL library, and extending<br>> GSL to fortran in an intro class is non-trivial.  Additionally, most
<br>> vendors supply "fast" hardware libraries in C (I may be ignorant, but if<br>> a student wants to call an AMD ACML fast-math function(<br>> <a href="http://developer.amd.com/acml.jsp" target="_blank">
http://developer.amd.com/acml.jsp</a>), or write a linear algebra function<br>> to run on a graphics card(<a href="http://developer.nvidia.com/object/cuda.html" target="_blank">http://developer.nvidia.com/object/cuda.html
</a><br>> <<a href="http://developer.nvidia.com/object/cuda.html" target="_blank">http://developer.nvidia.com/object/cuda.html</a>>), the vendors seem to<br>> assume that you'll write the code in C).<br>>
<br>> Also, and more relevant, I assume that most employers word-associate<br>> "Fortran is to backwards as C is to competence".<br>><br>> So, I'm thinking about reworking the class to favor C, and fearing 3
<br>> weeks of pointer and addressing hell.  For those of you who teach<br>> scientific computation (and also those of you who hire undergrads), I'd<br>> be grateful for your thoughts.  One specific question I have is what
<br>> text covers scientific programming and touches on MPI using the C language.<br><br></div></div>With the advent of F90 and F95, the ability to call a C/C++ library<br>routine became significantly simpler.  That said, it's not ever
<br>"exactly" simple to port someone else's libs from one language to<br>another, but it's not really that hard, either.<br><br>In the atmospheric sciences community, well, call us backward, but most<br>
of our applications are still coded in the arcane language of our<br>fathe... er, in Fortran.  Mostly for the reasons you originally cite.<br>and, no, they haven't changed.<br><br>As for an employer looking for a C-competent programmer over a
<br>Fortran-competent programmer, well, they'd not get  a great deal if they<br>want someone to work with a suite of models in the "wrong" language.<br>They should be looking for someone who's able to deal with the language
<br>of interest... and perhaps to pick up a new language if the new model of<br>the day warrants it.<br><font color="#888888">--<br>Gerry Creager -- <a href="mailto:gerry.creager@tamu.edu">gerry.creager@tamu.edu</a><br>Texas Mesonet -- AATLT, Texas A&M University
<br>Cell: 979.229.5301 Office: 979.458.4020 FAX: 979.862.3983<br>Office: 1700 Research Parkway Ste 160, TAMU, College Station, TX 77843<br><br></font></blockquote></div><br><br clear="all"><br>-- <br>- - - - - - -   - - - - - - -   - - - - - - - 
<br>Nathan Moore<br>Assistant Professor, Physics<br>Winona State University<br>AIM: nmoorewsu <br>- - - - - - -   - - - - - - -   - - - - - - -