## A Simple Solver for Linear Equations Containing Nonlinear Operators (1996)

Venue: | Software---Practice & Experience |

Citations: | 12 - 10 self |

### BibTeX

@ARTICLE{Ramsey96asimple,

author = {Norman Ramsey},

title = {A Simple Solver for Linear Equations Containing Nonlinear Operators},

journal = {Software---Practice & Experience},

year = {1996},

volume = {26},

pages = {467--487}

}

### OpenURL

### Abstract

This paper presents a simple equation solver. The solver finds solutions for sets of linear equations extended with several nonlinear operators, including integer division and modulus, sign extension, and bit slicing. The solver uses a new technique called balancing, which can eliminate some nonlinear operators from a set of equations before applying Gaussian elimination. The solver's principal advantages are its simplicity and its ability to handle some nonlinear operators, including nonlinear functions of more than one variable. The solver is part of an application generator that provides encoding and decoding of machine instructions based on equational specifications. The solver is presented not as pseudo code but as a literate program, which guarantees that the code shown in the paper is the same code that is actually used. Using real code exposes more detail than using pseudocode, but literate-programming techniques help manage the detail. The detail should benefit readers who wan...

### Citations

579 | Sketchpad: a man-machine graphical communication system
- Sutherland
- 1963
(Show Context)
Citation Context ...ample, where low-level systems make programmers say how to establish relationships among a set of variables, high-level systems can use equations or constraints to say what relationships should hold (=-=Sutherland 1963-=-; Borning 1981; Knuth 1986b; Ladd and Ramming 1994). This paper describes a general-purpose, arithmetic equation solver. The solver is used in a toolkit that transforms equational Author's current add... |

473 | Literate programming
- Knuth
- 1984
(Show Context)
Citation Context ...ine descriptions. A Literate Program This paper not only describes an implementation of a balancing equation solver, it is the implementation. The noweb system (Ramsey 1994) for literate programming (=-=Knuth 1984) extracts-=- this paper and a working implementation from a single source. This source contains the prose of the article interleaved with named "code chunks." The code chunks are written in the order be... |

322 | LARCH: Languages and Tools for formal specification - GUTTAG, HORNING - 1993 |

212 |
The programming language aspects of ThingLab, a constraint-oriented simulation laboratory
- Borning
- 1981
(Show Context)
Citation Context ...level systems make programmers say how to establish relationships among a set of variables, high-level systems can use equations or constraints to say what relationships should hold (Sutherland 1963; =-=Borning 1981-=-; Knuth 1986b; Ladd and Ramming 1994). This paper describes a general-purpose, arithmetic equation solver. The solver is used in a toolkit that transforms equational Author's current address: Dept of ... |

188 |
A practical algorithm for exact array dependence analysis
- Pugh
- 1992
(Show Context)
Citation Context ...rograms. Although integer linear programming is an NP-complete problem (Papadimitriou and Steiglitz 1982), there are powerful, practical methods for solving some classes of integer linear 2 programs (=-=Pugh 1992-=-). These methods are complex; substantial effort is needed to implement them, and sometimes even to reuse existing implementations. In a special-purpose application, little language, program transform... |

71 |
Literate programming simplified
- Ramsey
- 1994
(Show Context)
Citation Context ... equations and balances taken from machine descriptions. A Literate Program This paper not only describes an implementation of a balancing equation solver, it is the implementation. The noweb system (=-=Ramsey 1994) for lite-=-rate programming (Knuth 1984) extracts this paper and a working implementation from a single source. This source contains the prose of the article interleaved with named "code chunks." The c... |

30 | Two application languages in software production
- Ladd, Ramming
- 1994
(Show Context)
Citation Context ...ers say how to establish relationships among a set of variables, high-level systems can use equations or constraints to say what relationships should hold (Sutherland 1963; Borning 1981; Knuth 1986b; =-=Ladd and Ramming 1994-=-). This paper describes a general-purpose, arithmetic equation solver. The solver is used in a toolkit that transforms equational Author's current address: Dept of Computer Sciences, 1398 Computer Sci... |

25 |
Programming with equations
- Hoffman, Oâ€™Donnell
- 1982
(Show Context)
Citation Context ...ime code generation to eliminate the interpretation of the answers. Equations have been used as specifications, both of abstract data types (Guttag and Horning 1993) and of more general computations (=-=Hoffman and O'Donnell 1982-=-). In these kinds of systems, the equations themselves define the meaning of the operators used. Tools that work with such systems work by term rewriting or other kinds of reduction, and they may assu... |

18 |
The Icon Programming Language, second edition
- Griswold, Griswold
- 1990
(Show Context)
Citation Context ...d on the program presented here; I have written the paper that I wished I could read when I was writing my own solver. Icon The solver shown in this paper is written in the Icon programming language (=-=Griswold and Griswold 1990-=-). Icon has several advantages for writing an equation solver: its high-level data structures (lists, sets, and tables) provide direct implementations of mathematically sophisticated ideas, its automa... |

3 | A Simple Equation Solver and its Application to Financial Modelling - Derman, Wyk - 1984 |

2 |
Machine-Code Toolkit architecture specifications
- Ramsey, Fernandez
- 1994
(Show Context)
Citation Context ...o illustrate the techniques involved in balancing nonlinear operators, I have taken equations and operators from the description of the MIPS R3000 architecture in the New Jersey Machine-Code Toolkit (=-=Ramsey and Fernandez 1994-=-). The nonlinear operators used to describe machine code include widening (sign extension), narrowing, bit slicing, and integer division and modulus. The first three operate on a two's-complement repr... |

1 | Volume D, METAFONT: The Program. Addison-Wesley. . 1986b. The Metafontbook - Computers |