Two combinatoric operators

  • Authors:
  • Kenneth E. Iverson

  • Affiliations:
  • -

  • Venue:
  • APL '76 Proceedings of the eighth international conference on APL
  • Year:
  • 1976

Quantified Score

Hi-index 0.00

Visualization

Abstract

An operator in APL applies to a function or functions (or a function and a variable) and produces a new function. An operator may be dyadic (as the dot in +.×) or monadic (as the slash in +/), and the function produced may be monadic (as in +/) or dyadic (as in +.×). This paper treats two operators which are combinatoric in the sense that they are useful in applying functions over certain subsets of the elements of the array argument. The first is a double generalization of the determinant, applying it to functions other than the alternating sum over products, and extending it to non-square matrices. This operator is dyadic and produces a monadic function. The second applies to a single function f to produce a monadic function which yields f outer products on vectors of the form @@@@N, the final result being of a shape specified by the argument. This function yields function tables and makes it easy to produce a variety of useful Boolean matrices, including upper and lower triangles, identity matrices, and checkerboard patterns. The symbolism chosen to represent the operators under discussion is consistent with APL operator syntax, but is not presented as a considered choice. Zero-origin indexing is used throughout.