Hostname: page-component-77f85d65b8-t6st2 Total loading time: 0 Render date: 2026-03-29T12:05:03.426Z Has data issue: false hasContentIssue false

Comparing Id and Haskell in a Monte Carlo photon transport code

Published online by Cambridge University Press:  07 November 2008

Jeffrey Hammes
Affiliation:
Colorado State University, CO, USA (e-mail: hammes@cs.colostate.edu, jhammes@lanl.gov)
Olaf Lubeck
Affiliation:
Los Alamos National Laboratory, CA, USA (e-mail:oml@lanl.gov)
Wim Böhm
Affiliation:
Colorado State University, CO, USA (e-mail:bohm@cs.colostate.edu)
Rights & Permissions [Opens in a new window]

Abstract

Core share and HTML view are not available for this content. However, as you have access to this content, a full PDF is available via the 'Save PDF' action button.

In this paper we present functional Id and Haskell versions of a large Monte Carlo radiation transport code, and compare the two languages with respect to their expressiveness. Monte Carlo transport simulation exercises such abilities as parsing, input/output, recursive data structures and traditional number crunching, which makes it a good test problem for languages and compilers. Using some code examples, we compare the programming styles encouraged by the two languages. In particular, we discuss the effect of laziness on programming style. We point out that resource management problems currently prevent running realistically large problem sizes in the functional versions of the code.

Information

Type
Research Article
Copyright
Copyright © Cambridge University Press 1995
Submit a response

Discussions

No Discussions have been published for this article.