Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support compositional forms #36

Open
abrudz opened this issue May 31, 2021 · 1 comment
Open

Support compositional forms #36

abrudz opened this issue May 31, 2021 · 1 comment

Comments

@abrudz
Copy link
Contributor

abrudz commented May 31, 2021

It'd be nice if this worked:

>> f(x)=2x
>> g(x)=x^2
>> (f∘g)(4)
32
>> (f+g)(f)
24

etc.

See https://www.mathsisfun.com/sets/functions-composition.html and https://www.mathsisfun.com/sets/functions-operations.html

@PaddiM8
Copy link
Owner

PaddiM8 commented May 31, 2021

Neat, didn't know that was a thing in maths. Hopefully it isn't too awkward to parse. I guess "if function names are used inside a group (parenthesis), expect an argument after this, and parse the group as some sort of function call". This may happen.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants