Skip to main content

Showing 1–9 of 9 results for author: Jansson, P

Searching in archive cs. Search in all archives.
.
  1. arXiv:2503.18561  [pdf, other

    math.OC cs.SE

    Optimization under uncertainty

    Authors: Nicola Botta, Patrik Jansson, Tim Richter

    Abstract: One of the most ubiquitous problems in optimization is that of finding all the elements of a finite set at which a function $f$ attains its minimum (or maximum) on that set. When the codomain of $f$ is equipped with a reflexive, anti-symmetric and transitive relation, it is easy to specify, implement and verify generic solutions for this problem. But what if $f$ is affected by uncertainties? What… ▽ More

    Submitted 24 March, 2025; originally announced March 2025.

  2. arXiv:2312.02664  [pdf, ps, other

    cs.PL

    Domain-Specific Tensor Languages

    Authors: Jean-Philippe Bernardy, Patrik Jansson

    Abstract: The tensor notation used in several areas of mathematics is a useful one, but it is not widely available to the functional programming community. In a practical sense, the (embedded) domain-specific languages (DSLs) that are currently in use for tensor algebra are either 1. array-oriented languages that do not enforce or take advantage of tensor properties and algebraic structure or 2. follow the… ▽ More

    Submitted 20 January, 2025; v1 submitted 5 December, 2023; originally announced December 2023.

    Comments: 42 pages, 11 figures. Accepted for publication in the Journal of Functional Programming

  3. arXiv:2308.09481  [pdf, ps, other

    cs.PL cs.LO

    Types, equations, dimensions and the Pi theorem

    Authors: Nicola Botta, Patrik Jansson, Guilherme Horta Alvares Da Silva

    Abstract: The languages of mathematical physics and modelling are endowed with a rich "grammar of dimensions" that common abstractions of programming languages fail to represent. We propose a dependently typed domain-specific language (embedded in Idris) that captures this grammar. We apply it to explain basic notions of dimensional analysis and Buckingham's Pi theorem. We hope that the language makes mathe… ▽ More

    Submitted 4 September, 2023; v1 submitted 16 August, 2023; originally announced August 2023.

    Comments: Submitted for publication in the "Journal of Functional Programming" in August 2023

  4. Level-p-complexity of Boolean Functions using Thinning, Memoization, and Polynomials

    Authors: Julia Jansson, Patrik Jansson

    Abstract: This paper describes a purely functional library for computing level-$p$-complexity of Boolean functions, and applies it to two-level iterated majority. Boolean functions are simply functions from $n$ bits to one bit, and they can describe digital circuits, voting systems, etc. An example of a Boolean function is majority, which returns the value that has majority among the $n$ input bits for odd… ▽ More

    Submitted 2 November, 2023; v1 submitted 5 February, 2023; originally announced February 2023.

    Comments: 22 pages, 10 figures

  5. Extensional equality preservation and verified generic programming

    Authors: Nicola Botta, Nuria Brede, Patrik Jansson, Tim Richter

    Abstract: In verified generic programming, one cannot exploit the structure of concrete data types but has to rely on well chosen sets of specifications or abstract data types (ADTs). Functors and monads are at the core of many applications of functional programming. This raises the question of what useful ADTs for verified functors and monads could look like. The functorial map of many important monads pre… ▽ More

    Submitted 10 September, 2021; v1 submitted 5 August, 2020; originally announced August 2020.

    Comments: Accepted for publication in the "Journal of Functional Programming" in August 2021

    Journal ref: J. Funct. Prog. 31 (2021) e24

  6. Examples and Results from a BSc-level Course on Domain Specific Languages of Mathematics

    Authors: Patrik Jansson, Sólrún Halla Einarsdóttir, Cezar Ionescu

    Abstract: At the workshop on Trends in Functional Programming in Education (TFPIE) in 2015 Ionescu and Jansson presented the approach underlying the "Domain Specific Languages of Mathematics" (DSLsofMath) course even before the first course instance. We were then encouraged to come back to present our experience and the student results. Now, three years later, we have seen three groups of learners attend th… ▽ More

    Submitted 26 June, 2019; originally announced August 2019.

    Comments: In Proceedings TFPIE 2018, arXiv:1906.10757

    Journal ref: EPTCS 295, 2019, pp. 79-90

  7. Domain-Specific Languages of Mathematics: Presenting Mathematical Analysis Using Functional Programming

    Authors: Cezar Ionescu, Patrik Jansson

    Abstract: We present the approach underlying a course on "Domain-Specific Languages of Mathematics", currently being developed at Chalmers in response to difficulties faced by third-year students in learning and applying classical mathematics (mainly real and complex analysis). The main idea is to encourage the students to approach mathematical domains from a functional programming perspective: to identify… ▽ More

    Submitted 28 November, 2016; originally announced November 2016.

    Comments: In Proceedings TFPIE 2015/6, arXiv:1611.08651

    Journal ref: EPTCS 230, 2016, pp. 1-15

  8. Sequential decision problems, dependent types and generic solutions

    Authors: Nicola Botta, Patrik Jansson, Cezar Ionescu, David R. Christiansen, Edwin Brady

    Abstract: We present a computer-checked generic implementation for solving finite-horizon sequential decision problems. This is a wide class of problems, including inter-temporal optimizations, knapsack, optimal bracketing, scheduling, etc. The implementation can handle time-step dependent control and state spaces, and monadic representations of uncertainty (such as stochastic, non-deterministic, fuzzy, or… ▽ More

    Submitted 22 March, 2017; v1 submitted 23 October, 2016; originally announced October 2016.

    Comments: 23 pages, 2 figures

    Journal ref: Logical Methods in Computer Science, Volume 13, Issue 1 (March 17, 2017) lmcs:3191

  9. Certified Context-Free Parsing: A formalisation of Valiant's Algorithm in Agda

    Authors: Jean-Philippe Bernardy, Patrik Jansson

    Abstract: Valiant (1975) has developed an algorithm for recognition of context free languages. As of today, it remains the algorithm with the best asymptotic complexity for this purpose. In this paper, we present an algebraic specification, implementation, and proof of correctness of a generalisation of Valiant's algorithm. The generalisation can be used for recognition, parsing or generic calculation of th… ▽ More

    Submitted 12 June, 2016; v1 submitted 28 January, 2016; originally announced January 2016.

    ACM Class: F.4.1; F.4.2

    Journal ref: Logical Methods in Computer Science, Volume 12, Issue 2 (June 14, 2016) lmcs:1638