A Comparison of Functional and Imperative Programming Techniques for Mathematical Software Development

Scott Frame and John W. Coffey

ABSTRACT

Functional programming has traditionally been considered elegant and powerful, but also somewhat impractical for ordinary computing. Proponents of functional programming claim that the evolution of functional languages makes their use feasible in many domains. In this work, a popular imperative language (C++) and the leading functional language (Haskell) are compared in a math-intensive, real-world application using a variety of criteria: ease of implementation, efficiency, and readability. The programming tasks that were used as benchmarks involved mathematical transformations between local and global coordinate systems. Details regarding the application area and how language features of both languages were used to solve critical problems are described. The paper closes with some conclusions regarding applicability of functional programming for mathematical applications.

Full Paper in PDF Document

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: