Map fixed values for multiple ranges

hi guys
its probably simple, but i’m lost in logic. how to map fixed values for multiranges?

I get my statesNR as value > I want for stateNR from 0 to 3 to output constant/non-proportional value X, from stateNR from 4 to 25 to output constant value Y, from state 10 to 99 to output constant value Z.

thanks in adv, dimi

A little example patch that shows the values you have and want will make it easier for us to help you m8.

something like

fixed values for multiple ranges.v4p (7.4 kB)

I would just make a map value, use all your ranges, than figure out wich one to use. But your mapping will not be that smooth with these large integers. Hope it helps (a bit).

fixed values for multiple ranges.v4p (13.6 kB)

Hi West, thanks
here is my another try
Question 1 - could it be more simple?
Q2- why my default value is not 111, but 222 (e.g. empty range between 5 and 7) ?

fixed values for multiple ranges_v2.v4p (16.6 kB)

guess using Interval (Spreads) is a pretty quick way:

fixed values for multiple ranges_v3.v4p (19.5 kB)

woei thanks. that’s it