Introduction to Programming with Mathematica, Third Edition

Chapter 8: Numerics

Of the many data types that are available in Mathematica numbers, strings, symbols, lists numbers are perhaps the most familiar. You can work with all kinds of numbers in Mathematica, but, most importantly, what distinguishes it from traditional programming languages and other computational systems is that with it you can operate on numbers of any size and to any degree of precision. In this chapter we will explore some of the issues related to working with numerical quantities and show how you can incorporate some of these ideas into any programs that involve numerical computations.

8.1 Introduction

One of the first things that users of Mathematica notice when they begin to use it is how different is its treatment of numbers from other systems including calculators, traditional programming languages, and other technical computing systems. In most traditional programming languages, you must declare the type of number your functions can take as an argument. Although Mathematica automatically handles such details for you, an understanding of the different number types and how they invoke different algorithms will be helpful for taking full advantage of Mathematica's capabilities and writing efficient programs.

Although you can work with both exact and approximate numbers, Mathematica operates differently depending upon the type of input you give it.

It is important to understand that not only are different kinds of output returned in such cases, but Mathematica uses entirely different algorithms for these two computations. In the first case, Mathematica looks up identities...

UNLIMITED FREE ACCESS TO THE WORLD'S BEST IDEAS

SUBMIT
Already a GlobalSpec user? Log in.

This is embarrasing...

An error occurred while processing the form. Please try again in a few minutes.

Customize Your GlobalSpec Experience

Category: Computational Fluid Dynamics Software (CFD)
Finish!
Privacy Policy

This is embarrasing...

An error occurred while processing the form. Please try again in a few minutes.