Parabolic wave and phase modulation and x^y in code comp.
Archive · 200519 old posts
From the original SynthMaker forum (2004–2014), with its members’ names and dates.
lalo ·
Sorry for title length 🙂
www.nusic.org/temps/parabola_learn.rar
this is a little experiment with a parabolic function...
2 questions..
1. how can i change the phase?
2. would be nice to have x^y in code component to do y=x^exponent
where exponent is a inlet of the code component....
anyone with a workaround? how can i go from y=x*x; to Y=x*x*x*x ; ?
i'd can do it in different code components..but i wonder if there's a solution..
oh..obviously is aliased as hell... quite good eh? 😈
..i'll have to implement oversampling and filtering..when i'll understand polyphase filters 😊
lalo
infuzion ·
lalo wrote: anyone with a workaround? how can i go from y=x*x; to Y=x*x*x*x ; ?
looping maybe?
Or change your code to assembely, then use Shif's Pow.
lalo ·
infuzion wrote:
lalo wrote: anyone with a workaround? how can i go from y=x*x; to Y=x*x*x*x ; ?
looping maybe?
Or change your code to assembely, then use Shif's Pow.
i only did some z80 assembly when i was i childy...i have to restart 🙂...arghh
lalo
lalo ·
but can the loop(x) accept a number from an inlet?
i think to remember it doesn't
lalo
sambean ·
It doesn't but you can have a loop with the maximum number of powers you'll use and a counter inside the loop and a conditional test
eg x ^ 5..
counter = 5;
xbase = x
loop(10)
{
x = x * ((counter >= 0)&xbase + (counter < 0)&1)
counter = counter - 1
}
there may be a more efficient way though..
infuzion ·
lalo wrote:
infuzion wrote:
lalo wrote: i only did some z80 assembly when i was i childy...i have to restart 🙂...arghh
I thought the sting output of the Code was supposed to spit out assembly... but I can't seem to get it to work :/
Shifrin ·
lalo wrote: i only did some z80 assembly when i was i childy...i have to restart 🙂...arghh
Me too, tried for a long time to get my head around it and write something decent on my Spectrum +2 😉
infuzion wrote: I thought the sting output of the Code was supposed to spit out assembly... but I can't seem to get it to work :/
It should do, I've used it a few times to inspect the assembler produced via the code component, strange if it's not working now!
Shif.
Tom7777 ·
Interesting stuff lalo 🙂
lalo ·
Tom7777 wrote: Interesting stuff lalo 🙂
thanx man 😊
...is just to teach myself some math basic 😊 ...
i'll do a bunch of aliased-as-hell noise machines for my insane live impro 🙂
lalo
lalo ·
sambean wrote: It doesn't but you can have a loop with the maximum number of powers you'll use and a counter inside the loop and a conditional test
eg x ^ 5..
counter = 5;
xbase = x
loop(10)
{
x = x * ((counter >= 0)&xbase + (counter < 0)&1)
counter = counter - 1
}
there may be a more efficient way though..
good solution sambean 🙂
any idea on how to insert an inlet to change the phase?
about the asm...
wouldn't be good to have an 'asm' tag to use inside the regular code module to insert small assembler snippets...pretty like the 'asm' tag in c++ as far as i remember...
an ideas request thread? 😉
rl ·
lalo wrote: 1. how can i change the phase?
The easiest way is to connect the output of the code module to a Delay. Modulate the phase with the Sample-Delay input.
Shifrin ·
lalo wrote: wouldn't be good to have an 'asm' tag to use inside the regular code module to insert small assembler snippets...pretty like the 'asm' tag in c++ as far as i remember...
That would rock!!!
Shif.
lalo ·
rl wrote:
lalo wrote: 1. how can i change the phase?
The easiest way is to connect the output of the code module to a Delay. Modulate the phase with the Sample-Delay input.
yes..thanx rl...is sure the easiest way...
but i want to figure out how to do it math-wise...
Seems like it might work that way from what I've read of the code you posted! You're sweeping through 'x' to obtain 'y', so it makes sense that if you jump to x+phaseoffset then you'd get the corresponding 'y' value.
Shif.
lalo ·
..and infact it works...
but this thing seems to be pretty instable ( a bug? )
sometimes the sound (if you move the phase slider) become a loud white noise..and it stops..until you move some cable in the schematic so it recompiles..and the sound restart..until it stops again at some point when you re-move the phase slider...
have i to do a bug report?
or is my code so nasty? 😈 😀
www.nusic.org/temps/parabola_phase.rar
infuzion ·
lalo wrote: but this thing seems to be pretty instable ( a bug? )
I get the display flatlining when I move a slider & a crash report when I close SM.
lalo ·
i have to check what's wrong with my code...
infact i am sweeping x from 0 to 1 and from 1 to 0 then calculating the parabolic function...what i'm doing..out of standard practice?
rl ·
Same problem here. I think it's a bug with the Analyzer module (malc, jorge: hint, hint), since it does not crash after deleting the Analyzer.
I too have two or three schematics that crash with recent versions.
Wrote something here? To have a post removed or your name hidden, write to [email protected].