sine wave gain- does my patch sound wrong to you?

May 21, 2012 at 12:45pm

sine wave gain- does my patch sound wrong to you?

Hi,

i am trying to raise the level of a 1000Hz sine wave using the line object. However as the gain goes up i can hear another frequency as well as the 1kHz, am i imagining this, or am i going about this incorrectly?

J

– Pasted Max Patch, click to expand. –
#63711
May 21, 2012 at 3:14pm

In your patch any (non-time) values to line~ above 1.0 will result in clipping, so going from 20 to 450 as the message to line~ currently does, is going to produce a serious amount of clipping distortion to the sine wave, which I imagine is ‘the other frequency’ that you are hearing. Try [0, 1.0 10000] instead…

#229776
May 21, 2012 at 3:25pm

#229777
May 21, 2012 at 3:29pm

thanks spectro- i realise my previous values were too extrme!
I’m actually trying to raise the gain of the sine wave by 6dB over a set time- I’ve messed around with the values to get this, but I cant help feeling there’s a better way to do this?!?

– Pasted Max Patch, click to expand. –
#229778
May 21, 2012 at 4:59pm

atodb can give you numerical gain values which you can provide to line (but not line~), so I’ve modified your patch to that end…

– Pasted Max Patch, click to expand. –
#229779
May 21, 2012 at 5:12pm

thanks for modification spectro! I want the level to keep varying, so it goes up by 6 dB, then down by 6 dB etc. I have tried to add this to your modification but it doesnt go beyond the first 2 values.. any suggestions please?

– Pasted Max Patch, click to expand. –
#229780
May 21, 2012 at 5:42pm

One way to alternate b/w two values using line.

As you insist on setting the fader to an arbitrary level via the preset object, the level meter connected to it will not give an accurate reading of the gain the line is setting, so I bypassed that and connected it directly to the *~ object which is the one actually controlling the gain of the sine wave.

– Pasted Max Patch, click to expand. –
#229781
May 21, 2012 at 7:03pm

thats great- thanks. just to explain my random fader position; The aim of this patch is for people to try and keep the meter at the arrow, I will be varying the time it takes for the 6dB changes to happen and will measure how accurate people are as the speed of level change increases. To that ends I need the fader to control the meter- so have tweaked the patch- does it look o.k. to you?

– Pasted Max Patch, click to expand. –
#229782
May 22, 2012 at 7:43am

Ok. I don’t have time to check your patch right now (sorry) but I can at least understand why you chose to do it that way…

#229783

You must be logged in to reply to this topic.