The Mathematical Institute, University of Oxford, Eprints Archive

Automatic linearity detection

Birkisson, Asgeir and Driscoll, Tobin A. (2013) Automatic linearity detection. Technical Report. SICS. (Submitted)



Given a function, or more generally an operator, the question "Is it linear?" seems simple to answer. In many applications of scientific computing it might be worth determining the answer to this question in an automated way; some functionality, such as operator exponentiation, is only defined for linear operators, and in other problems, time saving is available if it is known that the problem being solved is linear. Linearity detection is closely connected to sparsity detection of Hessians, so for large-scale applications, memory savings can be made if linearity information is known. However, implementing such an automated detection is not as straightforward as one might expect. This paper describes how automatic linearity detection can be implemented in combination with automatic differentiation, both for standard scientific computing software, and within the Chebfun software system. The key ingredients for the method are the observation that linear operators have constant derivatives, and the propagation of two logical vectors, $\ell$ and $c$, as computations are carried out. The values of $\ell$ and $c$ are determined by whether output variables have constant derivatives and constant values with respect to each input variable. The propagation of their values through an evaluation trace of an operator yields the desired information about the linearity of that operator.

Item Type:Technical Report (Technical Report)
Subjects:H - N > Numerical analysis
Research Groups:Numerical Analysis Group
ID Code:1672
Deposited By: Lotti Ekert
Deposited On:22 Feb 2013 09:55
Last Modified:29 May 2015 19:22

Repository Staff Only: item control page