Undirected value

From Xenharmonic Wiki
Jump to navigation Jump to search

The undirected value is a function similar to the absolute value function, except where the absolute value negates if necessary in order to return a non-negative number (greater than or equal to zero), the undirected value reciprocates if necessary in order to return a non-subunison number (greater than or equal to one).

Musical application

Pitch ratios are directed, while interval ratios are undirected.

It is common practice to use the colon operator ":" for undirected interval ratios, and the slash operator "/" for directed pitch ratios. For example, "5/4" means something different than "4/5"; those are two different pitches. But "5:4" means the same thing as "4:5"; they are the same interval.

Notation

Function

In function notation, the undirected value may be written [math]\text{und}(x)[/math]. This is by analogy with the absolute value, whose function notation is [math]\text{abs}(x)[/math].

Mathematical

The undirected value is notated mathematically using horizontal bars above and below the value being undirected: [math]\color{red}{\overline{\underline{\color{black}{x}}}}[/math].

This notation references two existing mathematical notations:

  1. the vertical bars on the sides used to notate the absolute value [math]\color{red}{|}\color{black}{x}\color{red}{|}[/math]
  2. the fraction bar (or division bar), that is, the horizontal line between the numerator and denominator of ratios [math]\color{red}{\frac{\color{black}{n}}{\color{black}{d}}}[/math]

So, by referring to these two notations in these two different ways, the undirected value notation visually helps to convey how the operation itself bridges the concepts of absolute value and fraction bars. Taken together, this notation is designed to express its use for comparing values agnostic to their positions relative to the fraction bar.

Unicode

The undirected value is formatted in this page using [math]\LaTeX[/math], but it can also be typed using Unicode characters, as x̲̅.

This leverages Unicode's "combining characters" technique, where a base character is followed by one or more characters which — instead of appearing immediately after the previous character, as is normal — appear layered on top of that character. This notation requires the use of two combining characters: one for the overline, and one for the underline. The full character sequence here is:

U+0078 : LATIN SMALL LETTER X
U+0332 : COMBINING LOW LINE {underline, underscore}
U+0305 : COMBINING OVERLINE {overscore, vinculum}

Alternative

In situations where it is difficult to realize either the [math]\LaTeX[/math] or Unicode formats, and the function notation is not desired for some reason, an alternative mathematical notation is suggested: the value may be outfixed with colons, as in ":x:".

For example, :4/5: = 4:5 = 5/4.

This alternative is designed to evoke the infix ":" operator which as previously described is the one typically used for undirected ratios.

Definitions

As real

In order for the undirected value to work on negative numbers as well, it is defined to take the absolute value of its input before checking if it is greater than 1.

In plain language, then, we can say that the undirected value of a real number is equal to itself if the absolute value of the number is greater than or equal to 1, or equal to its reciprocal otherwise. As a mathematical formula, we can express this as:


[math] \overline{\underline{x}} = \begin{equation} \begin{cases} x & \text{if} \; |x| \ge 1 \\ \frac{1}{x} & \text{if} \; |x| \lt 1 \\ \end{cases} \end{equation} [/math]


As ratio

An alternative way to think about the undirected value is that it puts its input into ratio form [math]\frac{n}{d}[/math], and then if [math]d \gt n[/math], then [math]n[/math] and [math]d[/math] are flipped.

We still need it to work for negative numbers, though. The sign of a number in ratio form is not associated with its numerator any more or less than its denominator. So essentially we set aside the sign temporarily for the aforementioned process, then reintroduce it afterward.

As a formula, this has an advantage over the previously provided formula, in that it is expressible without the use of a conditional statement. However, this formula does not constitute a strict improvement, as it does have the notable disadvantage of requiring the use of several math functions: [math]\max[/math], [math]\min[/math], and [math]\text{sign}[/math]. Here is that formula:


[math] \overline{\underline{\frac{n}{d}}} = \text{sign}(\frac{n}{d})\frac{\max(|n|, |d|)}{\min(|n|, |d|)} [/math]


To be clear, if the input is not already in ratio form, for example [math]\phi[/math], this formula requires it first to be placed over 1, like [math]\frac{\phi}{1}[/math].

Superunison, subunison, and unison numbers

A superunison number is a real number whose absolute value is greater than 1.

A subunison number, by extension, is a real number whose absolute value is less than 1.

superunison undirected subunison
positive [math]\frac21[/math] 1 [math]\frac12[/math]
unsigned [math]\infty[/math] n/a 0
negative [math]-\frac21[/math] -1 [math]-\frac12[/math]

So just as the absolute value always returns a positive or zero value, the undirected value always returns a superunison or unison value.

The terms "superunison" and "subunison" may be shortened to "super" and "sub" when the context is clear.

"Superunison" and "subunison" can also be used as nouns, similar to how "positive" and "negative" can be used as nouns (e.g. "defined for the positives", "defined for the superunisons").

Direction

The analogy between the undirected value and absolute value can be more clearly seen if the less common name for the absolute value is used: the unsigned value. This sets up a parallel between the sign of a number — whether it is positive, zero, or negative — and the direction of a number — whether it is superunison, unison, or subunison.

The absolute value function [math]\text{abs}[/math] has a partner function, [math]\text{sign}[/math] (which returns 1 for positives, 0 for 0, and -1 for negatives), which when composed with it cancels it out: [math]\text{abs}(x)\text{sign}(x) = x[/math]. So the undirected value may also have a partner function defined which when composed with it cancels it out: direction, expressed as [math]\text{dir}[/math], which returns 1 for superunisons, 0 for unisons, and -1 for subunisons. While the composition between the [math]\text{abs}[/math] and [math]\text{sign}[/math] functions was multiplication, here it is exponentiation: [math]\text{und}(x)^{\text{dir}(x)} = x[/math]. Naming the direction operation with the same etymological root as the undirected value operation clarifies their relationship; [math]\text{dir}[/math] extracts the direction of a value and [math]\text{und}[/math] gives you the value agnostic to what was extracted, just as [math]\text{sign}[/math] works with respect to [math]\text{abs}[/math].

The undirected value may be considered as the multiplicative analog of the unsigned value (and the unsigned value is the additive analog of the undirected value). This corresponds with the fact that the undirected value compares its inputs against the multiplicative identity, 1, and orients its outputs agnostic to their multiplicative relationship with it (removes their direction), whereas the unsigned value compares its inputs against the additive identity, and orients its outputs agnostic to their additive relationship with it (removes their sign).

And so superunison is the multiplicative analog of positive, unison is the multiplicative analog of zero, and subunison is the multiplicative analog of negative.

Examples

[math]\overline{\underline{\frac45}} = \frac54[/math]

[math]\overline{\underline{\frac54}} = \frac54[/math]

[math]\text{und}(\frac45) = \frac54[/math]

[math]\text{und}(\frac54) = \frac54[/math]

These two examples are read as "the undirected value of four over five is five over four", and "the undirected value of five over four is five over four".

Analogies

additive multiplicative
function unsigned (absolute) value undirected value
identity 0 1
property sign direction
operation negation reciprocation
target positive superunison
opposite of target negative subunison
function notation [math]\text{abs}(x)[/math] [math]\text{und}(x)[/math]
mathematical notation [math]|x|[/math] [math]\overline{\underline{x}}[/math]

The following identity shows the relationship between the undirected value and the absolute value, for positive real numbers.


[math] \overline{\underline{x}} = b^{|log_{b}{x}|} \;\; \text{for any base} \; b\gt 1 \; \text{and} \; x\gt 0 \\ [/math]

Graphs

plot of the undirected value of x
plot of the absolute value of x, for comparison


History

The terminology and notation on this page was developed by Dave Keenan and Douglas Blumeyer in 2020[1].

References