2k views

### How is + as an infix operator associated with Plus?

How is + associated with Plus? Suppose I want to define a head FooBar and have it ...
2k views

### Going full functional (Haskell style)

I'm trying to define some notation so that Mathematica code would be more functional, similar to Haskell (just for fun): currying, lambdas, infix operator to function conversion, etc.. And I have some ...
684 views

### Is it possible to define custom compound assignment operators like ⊕= similar to built-ins +=, *= etc?

I would like to do something like this: ...
146 views

### Left-associative Apply

Often I want a version of @ that is left-associative (might not be using that term correctly). What I mean is I'd like some operator ...
814 views

### How to make a binary function associative? (Or define an n-ary function?)

Suppose I have a simple function that I assign to an operator f[a_, b_] := a + b CirclePlus = f Then I want to write ...
394 views

### Change associativity of the @ operator

The @ operator in Mathematica is right-associative by default, i.e. f@g@h evaluates as f@(g@h) Is it possible to make the ...
259 views

### Which operators are missing from the official precedence table?

I often use the Operator Input Forms page as a reference for operator precedence as well as which (used or unused) operators exist. However, I just noticed that at least one operator is missing from ...
145 views

### How to construct infix operator with usual behavior?

I am trying to define my own infix operator and having problems with strung-together evaluation. The code below is a simple example. What I would like is to have the operator treated associatively, ...
180 views

### How do I mimic the functionality of “<>”?

The Cell expression for: <> is Cell[BoxData["<>"], "Input"] However similar expressions are parsed into RowBox(...
223 views

### How to define a number of infix operators with predefined relative precedences

Reading a number of questions about infix operator notations I want to ask if somebody could reimplement the problem below in a simpler way, say modifying ...
331 views

### Create a new infix operator [duplicate]

It is well known that the infix operator @@ is used as a short form of Apply. For example, both ...