- Scientific Computing with Scala
- Vytautas Jan?auskas
- 438字
- 2021-07-16 11:07:23
Chapter 1. Introducing Scientific Computing with Scala
Scala was first publicly released in 2004 by Martin Odersky, then working at école Polytechnique Fédérale de Lausanne in Switzerland. Odersky took part in designing the current generation of the Java compiler javac as well. Scala programs, when compiled, run on the Java Virtual Machine (JVM). Scala is the most popular of all the JVM languages (except for Java.) Like Java, Scala is statically typed. From the perspective of a programmer, this means that variable types will have to be declared (unless they can be inferred by the compiler) and they cannot change during the execution of the program. This is in contrast to dynamic languages, such as Python, where you don't have to specify a variable's type and can assign anything to any variable at runtime. Unlike Java, Scala has strong support for functional programming. Scala draws inspiration from languages such as Haskell, Erlang, and others in this regard.
In this chapter, we will talk about why you would want to use Scala as your primary scientific computing environment. We will consider the advantages it has over other popular programming languages that are used in the scientific computing context. We will then go over Scala packages meant specifically for scientific computing. These will be considered briefly and will be divided into categories depending on what they are used for. Some of these we will consider in detail in later chapters.
Finally, we provide a small introduction on best practices for how to structure, build, test, and distribute your Scala software. This is important even to people who know how to program in Scala already. This chapter introduces concepts that I consider essential, to write scientific software successfully. They are, however, often overlooked by scientists. The reason is that scientists often don't concern themselves with software development techniques; instead, they prefer to get the job done quickly. For example, it is not uncommon to neglect build systems, which are very important no matter what language you are using and are essential when writing software in statically typed, compiled languages. Testing is another area of software development criminally overlooked by the scientists I have had the pleasure to work with. The same is usually true of IDE's, debuggers, and profilers. All of these following topics will be discussed:
- Why Scala for scientific computing?
- Numerical computing packages for Scala
- Data analysis packages for Scala
- Other scientific software
- Alternatives for carrying out plotting
- Using Emacs as the Scala IDE
- Profiling Scala code
- Debugging Scala code
- Building, testing, and distributing your Scala software
- Mixing Java and Scala code
- 深度實踐OpenStack:基于Python的OpenStack組件開發
- The Supervised Learning Workshop
- Mastering Entity Framework Core 2.0
- 騰訊iOS測試實踐
- PHP程序設計(慕課版)
- Flink SQL與DataStream入門、進階與實戰
- AngularJS Web Application Development Blueprints
- Implementing Cisco Networking Solutions
- 單片機應用技術
- Mastering JBoss Enterprise Application Platform 7
- Mobile Device Exploitation Cookbook
- 編程可以很簡單
- OpenCV with Python Blueprints
- Microsoft HoloLens By Example
- Learning WordPress REST API