How do I Reverse this Niquist prompt?

I found this prompt that filters upwards, but i’m trying to filter something downwards. Is there any way I could get some help with this one?

(let* ((nyq (/ sound-srate 2.0))
(hpfreq (pwev 100 0.4 100 0.9 10 1 10))
(lpfreq (pwev 500 0.4 500 0.9 nyq 1 nyq)))
(mult (pwlv 1.5 0.4 1.5 0.7 0.7 0.9 1 1 1)
(lp
(lp
(hp
(hp s hpfreq)
hpfreq)
lpfreq)
lpfreq)))


Thank you in advance

Topic moved to Nyquist forum.

That code is a “band-pass filter” (https://en.wikipedia.org/wiki/Band-pass_filter)
The lower frequency limit is defined by “hpfreq” (which I presume is an abbreviation for “high-pass frequency”) and the upper frequency limit is defined by “lpfreq” (presumably “low-pass frequency”).

The frequencies of the filters are control signals, produced using PWLV (see: http://www.cs.cmu.edu/~rbd/doc/nyquist/part8.html#index394). A you see in the manual, the values inside the PWLV command are time/value pairs. So for example, for the high pass frequency:

(pwev 100 0.4 100 0.9 10 1 10)

at time = 0, value = 100
at time = 0.4, value = 100
at time = 0.9, value = 10
at time = 1, value = 10

As you see, during the time period 0 to 1, the frequency falls from 100 to 10.

In Nyquist “effects”, a time period of “1” is the duration of the audio selection.

To make the frequency rise or fall in whatever way you wish you need to set the time/value pairs to suite your requirements.

Example: to make a band-pass filter with a 2 octave band-width, where the centre frequency rises from 40 Hz to 2000 Hz then back down to 40 Hz:

(let* ((nyq (/ *sound-srate* 2.0))
       (hpfreq (pwev 20 0.5 1000 1 20))
       (lpfreq (pwev 80 0.5 4000 1 80)))
  (lp
    (lp
      (hp
        (hp s hpfreq)
        hpfreq)
      lpfreq)
    lpfreq))