Nice, this is a very GNU Radio–ish question 🙂
In GNU Radio, a complex number doesn’t have a “positive” or “negative” sign the way a real number does. If you mean invert the complex signal (i.e. multiply it by −1), that’s easy and very common.
The simple way (recommended)
Use a Multiply Const block:
- Block: Multiply Const
- Type:
complex - Constant:
-1
This turns
z = I + jQ \quad \rightarrow \quad -z = -I - jQ
That’s usually what people mean by “make it negative”.
Alternative: using Add Const
You could also do this with an Add Const block, but it’s less clean:
- Add Const (complex)
- Constant:
(-2*I, -2*Q)after some offset
So… don’t 😄 Multiply Const is the right tool.
If you meant something else
Just to cover the common interpretations:
1️⃣ Flip only the real or imaginary part
Use Complex to Float, negate one stream, then Float to Complex.
Example:
I + jQ \rightarrow -I + jQ
2️⃣ Force magnitude to be negative (not mathematically valid)
Magnitudes are always ≥ 0. If you’re working with magnitude only, you can negate the float magnitude, but it’s no longer a complex number.
3️⃣ Conjugate instead of negate
If you meant:
I + jQ \rightarrow I - jQ
TL;DR
To negate a complex signal in GNU Radio:
Multiply Const (complex) = −1