High Quality (no alias) Tone generator

Archive of Nyquist Plug-ins.
Many of the plug-ins here will be available on the Audacity Wiki.
Forum rules
This Forum is an archive of old topics concerning Nyquist plug-ins.

Feedback and questions relating to topics may be posted, but please
DO NOT POST NEW TOPICS HERE.

New plug-ins may be posted on the New Plug-Ins board.
Other posts relating to Nyquist should be posted to the main Nyquist board.

The main repository for Audacity/Nyquist Plug-ins is on the Audacity Wiki.
Post Reply
steve
Site Admin
Posts: 81869
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

High Quality (no alias) Tone generator

Post by steve » Sun Sep 11, 2011 10:59 pm

hq-tone.ny
*** OBSOLETE ***
(4.07 KiB) Downloaded 543 times
Generates the following types of wave:
  • Sine
  • Square
  • Triangle
  • Sawtooth
  • Inverse sawtooth
This is slower than the standard Sine, Square and Sawtooth tone generators, but this plug-in produces tones without aliasing distortion.
The standard Tone generator can produce no-alias square waves, but it is very slow, particularly for lower frequencies.

Highlights:
  • All generated tones have extremely low aliasing distortion.
  • Much faster than the built-in no-alias square generator at low frequencies.
  • The starting phase of the waveform is adjustable
  • When applied to multiple tracks, all tracks have the same phase (regardless of frequency and duration)
  • Square wave is more square at low frequencies than the standard no-alias version.
  • Optimised for best waveform shape, frequency content and speed.
  • Works with Audacity 1.3.4 or later (1.3.12 or later recommended)
  • Very low memory usage on Audacity 1.3.13.
Install in the usual way.
Comments, feedback and bug reports welcome as always.
hq-tone.ny
*** OBSOLETE ***
(4.07 KiB) Downloaded 543 times
Latest Version available on the Audacity wiki
Last edited by steve on Fri Apr 24, 2015 3:46 pm, edited 2 times in total.
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

steve
Site Admin
Posts: 81869
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: High Quality (no alias) Tone generator

Post by steve » Tue Sep 13, 2011 5:15 pm

Here's a new version.
There are no changes to the code - the only difference is in the layout of the code.

It was brought to my attention that in some text editors the line spacing could be messed up because I used "Tab" to indent rather than spaces. If the editor is set to a large tab size (for example 8 spaces is very common) then some of the lines would be indented by an excessive amount. In this version I've changed the "tabs" to "spaces" so the layout should be the same on all text editors.

I've also made a couple of other minor changes to the layout to comply with the recommendations here: Indenting Common Lisp
Attachments
hq-tone.ny
(4.37 KiB) Downloaded 720 times
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

Irish
Forum Crew
Posts: 550
Joined: Sat Sep 05, 2009 9:25 pm
Operating System: Please select

Re: High Quality (no alias) Tone generator

Post by Irish » Mon Jan 16, 2012 2:14 pm

Steve,

The link in your last post appears to be dead.

I googled it and found it here.

POL
________________________________________FOR INSTANT HELP: (Click on Link below)
* * * * Tips * * * * Tutorials * * * * 1.3 Quick Start Guide * * * * Audacity 1.3 Manual * * * * Audacity wiki * * * *

steve
Site Admin
Posts: 81869
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: High Quality (no alias) Tone generator

Post by steve » Mon Jan 16, 2012 5:26 pm

Thanks POL,
Link updated.
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

steve
Site Admin
Posts: 81869
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: High Quality (no alias) Tone generator

Post by steve » Fri Jun 04, 2021 3:51 pm

An updated version of this plug-in is available on the Audacity wiki: https://wiki.audacityteam.org/wiki/Nyqu ... ns#HQ-Tone
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

Alcross
Posts: 3
Joined: Fri Jul 16, 2021 1:59 pm
Operating System: Windows 10

Re: High Quality (no alias) Tone generator

Post by Alcross » Fri Jul 16, 2021 9:29 pm

Hi Steve....Can you add the ability to HQ-Tone to make audio files from 0.01hz? The option now available starts only from 20hz. And also, can you add the Damped Sinusoidal, Damped Square, H-Bomb Sinusoidal & H-Bomb Square waveforms to the plugin? Please bro. Thanks a million.
steve wrote:
Sun Sep 11, 2011 10:59 pm
hq-tone.nyGenerates the following types of wave:
  • Sine
  • Square
  • Triangle
  • Sawtooth
  • Inverse sawtooth
This is slower than the standard Sine, Square and Sawtooth tone generators, but this plug-in produces tones without aliasing distortion.
The standard Tone generator can produce no-alias square waves, but it is very slow, particularly for lower frequencies.

Highlights:
  • All generated tones have extremely low aliasing distortion.
  • Much faster than the built-in no-alias square generator at low frequencies.
  • The starting phase of the waveform is adjustable
  • When applied to multiple tracks, all tracks have the same phase (regardless of frequency and duration)
  • Square wave is more square at low frequencies than the standard no-alias version.
  • Optimised for best waveform shape, frequency content and speed.
  • Works with Audacity 1.3.4 or later (1.3.12 or later recommended)
  • Very low memory usage on Audacity 1.3.13.
Install in the usual way.
Comments, feedback and bug reports welcome as always.

hq-tone.ny

Latest Version available on the Audacity wiki

steve
Site Admin
Posts: 81869
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: High Quality (no alias) Tone generator

Post by steve » Sat Jul 17, 2021 8:38 am

Alcross wrote:
Fri Jul 16, 2021 9:29 pm
Can you add the ability to HQ-Tone to make audio files from 0.01hz?
Additive synthesis is not a suitable technique for generating sub-sonic frequencies. Better to generate a simple on/off square wave and then apply soft clipping to smooth the polarity changes.

Alcross wrote:
Fri Jul 16, 2021 9:29 pm
Damped Sinusoidal,
A damped sinusoidal wave is just a sine wave at a lower level.

Alcross wrote:
Fri Jul 16, 2021 9:29 pm
H-Bomb Sinusoidal
According to the Internet:
Well, the Square H Bomb is simply, a custom waveform made up of square waves.

Visually it looks like an H, hence the name.

It has potency, hence the bomb nomenclature added to the end.

It is made up of 16 cycles. Since square waves have a duty cycle of 50% by default, this waveform also is on half the time, and off the other half of the time. This means 8 of the 16 cycles will be nothing.

Note the first 4 cycles and the last 4 cycles of the waveform is nothing. There is your 50% off portion of the waveform.

The 8 remaining cycles in the center are as follows:

1 square wave at full amplitude, which acts like a spike.

6 square waves at 1/4 the amplitude, this is the nominal amplitude of the waveform.

1 square wave again at full amplitude, which also acts like a spike
So it seems that it is some sort of sequence of waveforms rather than just a single cyclical waveform, thus outside the scope of this effect.
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

Alcross
Posts: 3
Joined: Fri Jul 16, 2021 1:59 pm
Operating System: Windows 10

Re: High Quality (no alias) Tone generator

Post by Alcross » Tue Jul 20, 2021 2:26 am

Thank you for the reply Steve. That was very helpful.

Post Reply