CTAN Comprehensive TeX Archive Network

CTAN update: bezierplot

Date: March 23, 2024 8:40:53 AM CET
Linus Romer submitted an update to the bezierplot package. Version: 1.5 License: lppl1.3c Summary description: Approximate smooth function graphs with cubic bezier splines for use with TikZ or MetaPost Announcement text:
The Lua script bezierplot.lua has to work as a "main" with an external call from pdfLaTeX as well as a "library" with a direct use of the function bezierplot() when used with LuaLaTeX. However, Lua does not seem to support a natural distinction between the main and the library: https://stackoverflow.com/questions/4521085/main-function-in-lua. As https://www.tug.org/pipermail/luatex/2024-February/007935.html states, LuaTeX 1.18.0 has disabled the use of the debug library. Hence, using "pcall(debug.getlocal, 4, 1)" is no longer possible without restriction. The problem with the now chosen method is that arg could be defined as a global variable in the calling code.
The package’s Catalogue entry can be viewed at https://ctan.org/pkg/bezierplot The package’s files themselves can be inspected at https://mirrors.ctan.org/macros/luatex/latex/bezierplot/
Thanks for the upload. For the CTAN Team Petra Rübe-Pugliese
CTAN is run entirely by volunteers and supported by TeX user groups. Please join a user group or donate to one, see https://ctan.org/lugs

bezierplot – Approximate smooth function graphs with cubic bezier splines for use with TikZ or

This package consists of a Lua program as well as a (Lua) .sty file.

Given a smooth function, bezierplot returns a smooth bezier path written in TikZ notation (which also matches ) that approximates the graph of the function. For polynomial functions of degree ≤ 3 and their inverses the approximation is exact (up to numeric precision).

bezierplot also finds special points such as extreme points and inflection points and reduces the number of used points.

Copyright2018–2024 Linus Romer
MaintainerLinus Romer



Guest Book Sitemap Contact Contact Author