{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

cacm-ron - Java and Numerical Computing Ronald F Boisvert...

Info icon This preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
Java and Numerical Computing Ronald F. Boisvert Jos´e Moreira Michael Philippsen Roldan Pozo 1 Introduction We start this article by asking: Does Java have a role to play in the world of numerical computing? We strongly believe so. Java has too much to offer to be ignored. First of all, Java is portable at both the source and object format levels. The source format for Java is the text in a .java file. The object format is the bytecode in a .class file. Either type of file is expected to behave the same on any computer with the appropriate Java compiler and Java virtual machine. Second, Java code is safe to the host computer. Programs (more specifically, applets) can be executed in a sandbox environment that prevents them from doing any operation (such as writing to a file or opening a socket) which they are not authorized to do. The combination of portability and safety opens the way to a new scale of web-based global computing , in which an application can run distributed over the Internet [ ? ]. Third, Java implements a simple object-oriented model with important features ( e.g. , single inheritance, garbage collection) that facilitate the learning curve for newcomers. But the most important thing Java has to offer is its pervasiveness, in all aspects. Java runs on virtually every platform Universities all over the world are teaching Java to their students. Many specialized class libraries, from three-dimensional graphics to online transaction processing, are available in Java. With such universal availability and support, it only makes sense to consider Java for the development of numerical applications. Indeed, a growing community of scientists and engineers developing new appli- cations in Java has been slowly developing. A rallying point for this community has been the Java Grande Forum ( http://www.javagrande.org ) (see sidebar). There are some difficulties, though, with the wide-scale adoption of Java as a language for numerical computing. Java, in its current state of specification and level of implementation, is probably quite adequate for some of the GUI, postprocessing, and coordination components of a large numerical application. It fails, however, to provide some of the features that hard-core numerical programmers have grown accustomed to, such as complex numbers and true multidimensional arrays. Finally, as any language that caters to programmers of numerical applications, Java has to pass the critical test: its performance on floating-point intensive code must be (at least) on par with the incumbents C and Fortran. 2 The Performance of Java A common reaction of numerical programmers when first confronted with the thought of using Java for their code is “But Java is so slow!” Indeed, when the first Java virtual machines appeared, they worked by strictly interpreting the bytecode in .class files, and delivered very poor performance. Some people reported Java programs running up to 500 times slower than the equivalent C or Fortran codes.
Image of page 1

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern