English

Introducing the vfunc R package

Symbolic Computation 2026-03-17 v1

Abstract

f,g ⁣:RRf,g\colon\mathbb{R}\longrightarrow\mathbb{R}, it is natural to define f+gf+g as the function that maps xRx\in\mathbb{R} to f(x)+g(x)f(x) + g(x). However, in base R, objects of class function do not have arithmetic methods defined, so idiom such as "f + g" returns an error, even though it has a perfectly reasonable expectation. The vfunc package offers this functionality. Other similar features are provided, which lead to compact and readable idiom. A wide class of coding bugs is eliminated.

Cite

@article{arxiv.2603.15156,
  title  = {Introducing the vfunc R package},
  author = {Robin K. S. Hankin},
  journal= {arXiv preprint arXiv:2603.15156},
  year   = {2026}
}

Comments

4

R2 v1 2026-07-01T11:22:07.075Z