snegcomplexconstants

◼ snegcomplexconstants[z,w] declares z and w to be complex constants.

◼ Constants are factored out from operator strings within nc blocks.

◼ Note: some Mathematica functions have difficulties with parameters tagged with NumericQ. As a work-around, functions maskconstants and maskOp are provided.

◼ See also: snegintegerconstants, snegrealconstants, snegfreeindexes.

Further examples

Load sneg

<< sneg`sneg`;

Let c be a fermionic operator and z a complex constant

snegfermionoperators[c]
snegcomplexconstants[z]

z is factored out

nc[2  c[CR], z c[AN]]
FullForm[%]
conj[%%]

Functions of z are also factored out

nc[c[CR], Exp[z] c[AN]]
conj[%]
SetAttributes[f, NumericFunction];
nc[c[CR], f[z] c[AN]]
conj[%]