CFC: Filter "shapes"?

JJ4SDR
Posts: 447
Joined: Fri Jul 30, 2021 10:09 pm
Location: TEXAS, USA

CFC: Filter "shapes"?

Postby JJ4SDR » Thu Oct 19, 2023 1:42 pm

I was playing around with the CFC this morning and decided to add a boost at only two frequency nodes, thinking that this would be roughly equivalent to a 3-band compressor. Splitting frequency bands into just 2 or 3 (perhaps 4) has produced reasonably good "separation" between
sub-bands which is my preference although I have not attempted this with the CFC. Most of the time I would be using either a DEQ or a VST plug-in inside a DAW to achieve this "separation."

Can someone shed light on the "filter" shapes that the CFC algorithm provides? Mainly, I am wondering if using CFC with only a few frequency nodes (I would like to think using the CFC in this fashion is akin to setting crossover frequencies that can be defined in multi-band compressors) is fine? At least, based on what I am hearing when going from the "full" (Continuous) range afforded in the CFC to just 3 or perhaps 4 frequency bands, it appears to be working the way I am conjecturing it might. However, I may be fooled by having heard my own voice for so long into thinking that I am hearing improved audio. I lay this likely mis-perception at the feet of psycho-acoustics.

Awaiting feedback on this sort of application or use on the CFC.

Juha
NI2M
PC: 8 Core i7-10700 CPU @ 2.90GHz, NVMe SK Hynix 512 GB SSD, 32GB RAM
Windows 10 Home, Version 22H2
Thetis v2.10.4.3 x64
Protocol 2 v2.1.18
Warren_NR0V
Posts: 10
Joined: Sun Apr 09, 2017 9:59 pm

Re: CFC: Filter "shapes"?

Postby Warren_NR0V » Fri Oct 27, 2023 3:58 pm

Hi Juha,

With the CFC you can create a wide variety of compression profiles, including emulating a compressor with a small number of bands. The key here is to remember that the compression profile will be interpolated between the frequency points that you specify. So, for example, let's say you have a frequency point at 1000Hz, specified at +10dB, and a point at 1500Hz, at +5dB, and no points in between those. The profile you'll get is +10dB at 1000Hz and reasonably smoothly moving down to +5dB at 1500Hz.

Keep in mind that when dealing with the CFC settings, you're dealing with the compression profile, not specifically a boost in certain audio frequencies -- use the Post-EQ Gain settings for audio frequency response. Compressors are also by their nature non-linear devices. So, the amount of compression you actually get will be impacted by how hard you drive the compressor. Richie has provided a nice display on the CFC tab so you can see whether you're getting the compression profile you desire.

The CFC operates in the frequency domain, working with an FFT output. Therefore it does not have separate "band" filters. The FFT effectively provides a "filter bank" where each bin has a width of about 93.7Hz. The cutoffs between these bins are largely determined by the "window function" used with the FFT and, in this case, are quite sharp.

73,
Warren NR0V
User avatar
KA5KKT
Posts: 129
Joined: Thu Aug 06, 2020 6:51 pm

Re: CFC: Filter "shapes"?

Postby KA5KKT » Fri Oct 27, 2023 7:32 pm

Upon the reading of this topic I watched W1AEX's video on ANAN CFC Audio Tools Setup Guide. Anan never ceases to amaze.

Early in the video there was a quick reference to the RX EQ. Do or can CFC settings apply to RX as well as TX?


Kind regards,
Dick - KA5KKT

- Still wandering around this international rabbit hole :)
User avatar
w-u-2-o
Posts: 5578
Joined: Fri Mar 10, 2017 1:47 pm

Re: CFC: Filter "shapes"?

Postby w-u-2-o » Fri Oct 27, 2023 8:02 pm

None of the TX audio functions affect RX. This includes mic gain, phase rotator, leveler, pre-EQ, CFC, post-EQ, and, for those inclined to use the older methods, COMP and CESSB.
NC3Z
Posts: 466
Joined: Sun Oct 29, 2017 8:57 pm
Location: Merritt, NC

Re: CFC: Filter "shapes"?

Postby NC3Z » Fri Oct 27, 2023 8:14 pm

w-u-2-o wrote: COMP and CESSB.


Does anyone still use that??
Gary NC3Z
User avatar
w-u-2-o
Posts: 5578
Joined: Fri Mar 10, 2017 1:47 pm

Re: CFC: Filter "shapes"?

Postby w-u-2-o » Fri Oct 27, 2023 9:30 pm

I hope not! Undoubtedly there are bound to be some die-hards, though. :?
User avatar
ramdor
Posts: 1468
Joined: Wed Jul 03, 2019 3:07 pm
Contact:

Re: CFC: Filter "shapes"?

Postby ramdor » Fri Oct 27, 2023 9:33 pm

changelog
-removed COMP and CESSB

:o ;)
JJ4SDR
Posts: 447
Joined: Fri Jul 30, 2021 10:09 pm
Location: TEXAS, USA

Re: CFC: Filter "shapes"?

Postby JJ4SDR » Sat Oct 28, 2023 10:28 pm

Hi Warren!

Very nice to get your response and expert feedback on my question. I have used a gamut of compressors (software emulations for the most part), including Opto, Tube and FET which all sound different, at least in my ears. My query was in part prompted by Dynamic EQ's (DEQs) as they and multi-band compressors represent two sides of the same coin in a way, with one key difference having to do with filter "shapes" between the two.

Now, taking your example of the 2 frequency nodes, what would the profile look like at 500Hz, an octave below 1000Hz? How about at 2000Hz?

Ok on Post-EQ as well. I am not currently engaging it and have an EQ working on my audio in the Audio Frequency (AF) domain, before the processed audio hits the ANAN. I assume that the Post-EQ also operates in the AF domain.

Thank you again and the ANAN is really a marvel to behold :D !

73!
Juha
NI2M
PC: 8 Core i7-10700 CPU @ 2.90GHz, NVMe SK Hynix 512 GB SSD, 32GB RAM
Windows 10 Home, Version 22H2
Thetis v2.10.4.3 x64
Protocol 2 v2.1.18
Warren_NR0V
Posts: 10
Joined: Sun Apr 09, 2017 9:59 pm

Re: CFC: Filter "shapes"?

Postby Warren_NR0V » Sun Oct 29, 2023 4:34 pm

Hi Juha,

In the example I gave, the response below 1000Hz and above 1500Hz will depend upon other frequency points at which you may have specified the compression profile. First, I should explain that there are two "hidden" frequency points -- one at 0Hz and the other at the maximum frequency supported by the sample_rate. If 1000Hz was the lowest frequency you specified, the compression profile would remain constant from the specified level there to 0 Hz and if 1500Hz was the highest frequency you specified, the compression profile would remain constant from there to the maximum frequency.

To clarify, let me give another example. Let's say your lowest specified frequency is 500Hz and that's at 0dB. Then, next 1000Hz at +10dB, then 1500Hz at +5dB. From 0Hz to 500Hz, you get 0dB. This ramps up to +10dB at 1000Hz, it then ramps down to +5dB at 1500Hz. What happens at higher frequencies depends upon the values you've set for other frequency points. If you're next point is 2000Hz, 0dB, we ramp down to 0dB at 2000Hz. If 2000Hz is your highest specified point, we remain at that level with increasing frequency.

From the DSP point-of-view, there's no particular reason to allow you to specify only 10 frequency points -- this was simply a user interface choice that seemed sufficient.

The post-EQ operates in the frequency domain ... it's a simple addition to the CFC code. Since the signal is already in the frequency domain, we just ramp the audio gain levels versus frequencies.

Note that a pre-equalizer, before the CFC, will affect compression levels since a compressor is a non-linear device. However, a post-equalizer, after the CFC, affects the audio "boost" profile after compression. This is the reason we have both.

I'm getting into details here; however, I can't help but do so since the signal processing is my passion. I use the approach of changing gains versus frequency a few places in the DSP code, including for noise reduction (NR2). It is more complicated than just FFT / change-bins / Inverse-FFT. One cannot do this correctly without something called Weighted-OverLap-Add which requires applying certain window functions on overlapped sequences of samples.

73,
Warren NR0V
JJ4SDR
Posts: 447
Joined: Fri Jul 30, 2021 10:09 pm
Location: TEXAS, USA

Re: CFC: Filter "shapes"?

Postby JJ4SDR » Mon Oct 30, 2023 7:11 pm

Hello Warren,

Below, see my follow-up queries.

Now, I see the filter "shapes" of the CFC, going off your follow-on examples. That definitely answered my initial question. :)

"The post-EQ operates in the frequency domain ... it's a simple addition to the CFC code. Since the signal is already in the frequency domain, we just ramp the audio gain levels versus frequencies."
Juha: Not sure if I follow, due to brain-fog, are you saying that Post-EQ'ing occurs in the RF domain? I am more experienced in doing EQ'ing in the Audio Frequency (AF) domain prior to audio being injected into a modulator. Again, if the EQ'ing occurs in the RF domain I am not sure if the resulting tonality is different and why it may be different from EQ'ing in the AF domain.

"Note that a pre-equalizer, before the CFC, will affect compression levels since a compressor is a non-linear device. However, a post-equalizer, after the CFC, affects the audio "boost" profile after compression. This is the reason we have both."
Juha: Looking at Thetis block diagrams (Thetis Manual version1.0), I see audio from MIC feeding the pre-EQ ("TX EQ") circuitry so, I presume that pre-EQ occurs in the AF domain? Also,I see that Post-EQ figures inside the same block diagram above the 2nd one along with TX EQ (NOT the 2nd one that says "HPSDR Radio - FPGA DSP and RF") making me think that it, too, forms audio level signals in the AF domain, correct?
Juha: If my understanding outlined above is not off-base, then, may I assume that CFC also operates in the Audio Frequency rather than Radio Frequency domain?

I value your patience despite a clearly deficient understanding on my part on this.

73!
Juha
PC: 8 Core i7-10700 CPU @ 2.90GHz, NVMe SK Hynix 512 GB SSD, 32GB RAM
Windows 10 Home, Version 22H2
Thetis v2.10.4.3 x64
Protocol 2 v2.1.18
Warren_NR0V
Posts: 10
Joined: Sun Apr 09, 2017 9:59 pm

Re: CFC: Filter "shapes"?

Postby Warren_NR0V » Tue Oct 31, 2023 8:13 pm

Hello Juha,

The EQ and CFC do not operate at RF frequencies; however, they also do not happen to audio samples in time. When I say "in the frequency domain," I mean that we have taken a sequence of audio samples and done a Fast Fourier Transform (FFT) on those to convert them to a set of frequency "bins". These frequency bins have no time sequence, they are just magnitudes and phases at a set of audio frequencies. We can then modify the values of the these "bins" at the various frequencies and, when we're done, we do an Inverse-FFT to convert back to a sequence of audio samples in time. For example, we could take a sequence of 2048 audio samples, convert them to values at 2048 frequencies, and then later convert them back to 2048 modified audio samples. You may wish to consult some of the online references discussing Fourier Transforms, Discrete Fourier Transforms, and Fast Fourier Transforms.

The modulation is done with the audio time-sequenced samples. For SSB, I use a simple "filter" approach where I cut off the USB or the LSB. For AM, I leave both sidebands but add a constant value which is the carrier at 0 Hz. The up-conversion to RF is actually the last thing that happens before the DAC and that's done at a high sample-rate in the FPGA.

The Pre-EQ is some code that I wrote sometime before the CFC/Post-EQ code. However, it operates somewhat similarly. Based upon the frequency profile that's provided by the operator, I design, on the fly, a single filter that implements that profile. The filter is created using a technique called "frequency sampling" and it again uses FFTs to operate efficiently. So, again, this is not a frequency band approach with several filters. It is just a single filter implementing whatever frequency profile that was requested by the operator.

73,
Warren NR0V
JJ4SDR
Posts: 447
Joined: Fri Jul 30, 2021 10:09 pm
Location: TEXAS, USA

Re: CFC: Filter "shapes"?

Postby JJ4SDR » Tue Oct 31, 2023 8:25 pm

Hello Warren,

Your kind response is much valued and leads me to a clear conclusion; I need to do a lot more digging into this topic as my questions to you were clearly formulated going off the wrong premise.

Best 73!

Juha
PC: 8 Core i7-10700 CPU @ 2.90GHz, NVMe SK Hynix 512 GB SSD, 32GB RAM
Windows 10 Home, Version 22H2
Thetis v2.10.4.3 x64
Protocol 2 v2.1.18
Warren_NR0V
Posts: 10
Joined: Sun Apr 09, 2017 9:59 pm

Re: CFC: Filter "shapes"?

Postby Warren_NR0V » Tue Oct 31, 2023 8:31 pm

Hello Juha,

There are many ways to do things in DSP and these are not simple topics. I welcome your involvement.

73,
Warren NR0V
rdwing
Posts: 95
Joined: Sat May 21, 2022 2:05 am

Re: CFC: Filter "shapes"?

Postby rdwing » Thu Nov 02, 2023 6:29 am

w-u-2-o wrote:I hope not! Undoubtedly there are bound to be some die-hards, though. :?

Not to be that guy, but I guess I'm that guy. CESSB works without adding "compression". I don't think it should be removed.
Having done empirical testing, CESSB serves a separate function from the CFC. Perhaps it can be unbound from the COMP slider though.

Return to “Thetis”