### misc: |*>

|*>:
description:
|*>
see label descent.
this special ket is used if we want to define an operator that is defined with respect to all kets
instead of being defined with respect to a single specific ket
so, in some sense it is a function, but be aware it is applied ket-wise
so if you apply it to a superposition or sequence, it will be applied to each sub-ket in turn
this makes it essentially linear, but not quite, depending on the details of the operator
it is usually, but not always, defined with respect to stored or memoizing rules
examples:
-- a quick demonstration of its "linearity":
-- just define an operator that adds the "op" category to a given ket:
op |*> #=> |op> :_ |_self>
-- now invoke it:
-- first to a superposition:
op split |abcde>
|op: a> + |op: b> + |op: c> + |op: d> + |op: e>
-- now to a sequence:
op ssplit |abcde>
|op: a> . |op: b> . |op: c> . |op: d> . |op: e>
-- NB: there is an unsolved bug, where the coefficient of the input ket is squared!
-- so for example:
op rank split |abcde>
|op: a> + 4|op: b> + 9|op: c> + 16|op: d> + 25|op: e>
see also:
label descent, |category: *>, |_self>, #=> , !=>

Home