Even in pure math, the `i` postfix is but a shorthand (by Euler in 1777), and we're not obliged to use it. In Swift it's not directly an option. One could define a variable `i` and write `3 + 4 * i` but this would lock up a very common variable name.

One creative route is to use the upside-down exclamation mark, `¡`. It's a legit postfix operator character, and can't be confused with a variable `i` in the type system. `3 + 4¡` works, and is available on most all keyboard layouts. But the fact that `¡` looks like `i`, _might_ be confusing to coders (though IDEs like Xcode will colorize ¡ as an operator), and the fact that coders wince at using any character that is unusual (even if at everyone's fingertips), means its use may be doomed before it takes off. (Coders are often surprisingly conservative when it comes to code characters. Just try suggesting we use a real arrow `→` instead of the regrettable `->` hack that we've allowed to fester for far too long.)

A different way to go in Swift, is to create a computed variable called `i` as an extension to all numbers that returns a complex number, which would look like this: `3 + 4.i` which isn't bad. Simple. In this and the previous cases, the function takes 4 and maps it to a complex number, and then any real + complex returns a complex number.

Python, Matlab, and the Swift Numerics package, all allow the alternate form `complex(3, 4)`. Not brief, but fairly clear. Numerics also has a nice variant, using argument labels to allow phasor coordinates: `Complex(length: 5, phase: 0.93)`. (But is that phase in radians or degrees? Answer: radians. It seems destined to let in some bugs.) That said, it is an unfortunate amount of clutter to use the `Complex(. . .)` notation _every single time_ you want to pop a number in there.

Are there other choices? There is the character `ℂ`, which is used in Math to represent the complex number set, so one could write `ℂ(3, 4)`, which does look decent, but few have that character on their keyboard layout, so it's a non-starter. Still, it could be an option.

I'm tempted to include all of these in an update to my Physical Framework and see which ones fly: `3 + 4.i`, `3 + 4¡`, `5 ∠ 53°`, `Complex(3, 4)`, and `ℂ(3, 4)`. (Since Physical already has unit-aware angles, it should make phasor notation more intuitive as well.) Probably the most practical and the easiest for everyone is just `3 + 4.i`.

More ideas or suggestions?]]>