Part of the LaTeX3 bundle to handle Floating-point operations

learn more… | top users | synonyms

11
votes
2answers
267 views

Factorial (or, even better, binomial coefficient) function

Is there a function in l3fp for calculating factorials or, even better, binomial coefficients directly?
4
votes
1answer
71 views

l3fp “Number too big” error

Consider the following example: \documentclass{article} \usepackage{pstricks-add} \usepackage{expl3} \ExplSyntaxOn \cs_new_eq:NN \calc \fp_eval:n \ExplSyntaxOff ...
9
votes
1answer
226 views

Store results of a calculation automatically under a new macro name

As I am now accessing values from tables via a macro to make dynamic references in the text (see here) and make calculations with it, I need a way to make the resulting variables under which the ...
1
vote
1answer
280 views

Regular Expression for logical implication?

I am massively unfamiliar with the usage and syntax of regular expressions so the following problem is making my brain bleed. Background: I am taking logical expressions, parsing them, making some ...
4
votes
1answer
106 views

Symbolic functions: changing catcodes and \tl_rescan:nn

The goal is to have the user input (for the sake of argument) a linear function in one variable, for example 2*x+3 along with the variable (this isn't crucial) and a value for the variable. I would ...
11
votes
2answers
1k views

Iterative method to solve nonlinear equations

I am trying to solve the following equation (coming from fluid dynamics) using TeX. 1/sqrt(lambda) = 2 * log(Re * sqrt(lambda)) - 0.8 where lambda is the unknown, sqrt means "square root", the log ...
10
votes
1answer
615 views

How can I define NaN in LaTeX3

LaTeX3 l3fp offers a way to check if a variable has a an infinite value. The following code defines a number and then sets its value to π/2. It then calculates tan(π/2) to get a large result. ...