Skip to content

conj, arg, re, im, bar and det are read as products, not refused like conjugate #2136

Closed

Description

@Rafael-SOWNet

#733 made the parser refuse, by name, a function that AngouriMath does not have, rather than read f(x) as the product of a variable f with x. conjugate is on that list. These names are not:

Input Parsed as
conj(z) conj * z
arg(z) arg * z
re(z), im(z) re * z, im * z
bar(z) bar * z
det(M) det * M
([1, 2])T [1, 2] * T

Each is a common name for something a reader expects to be computed. ]T is read as a transpose only straight after a bracket literal, so a transposed expression in parentheses becomes a product with a variable T.

Found while reading Modenov's Problems in Geometry for #2131, which uses the conjugate, the argument and the determinant throughout. Giving them meaning is #809 §3's conjugate and a determinant function. Until then, refusing them keeps a silent product from becoming a wrong answer.

Activity

  1. added this to the 2.7.0 milestone on Oct 27, 2026
  2. moved this from Todo to In Progress in AngouriMathon Oct 27, 2026
  3. Rafael-SOWNet commented on Oct 27, 2026

    @Rafael-SOWNet
    MemberAuthor

    #2157 refuses conj, arg and det. It does not refuse re and im: MissingFunctionNamesRefusedTest.TheTwoLetterNamesAreLeftAsProducts already records that as a deliberate choice, since two letters is short enough to be a variable's name and refusing them would break such an expression. I left that decision as it stands. If you would rather refuse them too, it is two lines in the grammar. bar and (expr)T are also left, for the reasons in the PR.

  4. moved this from In Progress to Done in AngouriMathon Oct 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions