I would like to show an element in the following four periods every hour:
hh:05 till hh:09
hh:35 till hh:39
hh:25 till hh:29
hh:55 till hh:59

The first two can be covered with this formula:
$abs(#Dm#-22)>=13&&abs(#Dm#-22)<18? 100 : 20$
The second two with this formula:
$abs(#Dm#-42)>=13&&abs(#Dm#-42)<18? 100 : 20$

Now I would like to combine these statements for the single element as follows:
First formula OR second formula

I thought of solving it this way:
$abs(#Dm#-22)>=13&&abs(#Dm#-22)<18||abs(#Dm#-42)>=13&&abs(#Dm#-42)<18? 100 : 20$

This does not work though. Can anybody tell me where my mistake is and put me on the right track?

bummer @pierre no that won’t work. You cannot chain conditionals beyond 2 conditions. You can say:
If this AND that, then… or If this OR that, then… But you cannot execute any deeper logical combinations.

You can NEST conditionals but only on EQUALS.
If this=A then X, elseif that=B then Y, else if ThatOtherThing=C then Z, otherwise NOTHING.

However, (and I don’t know your scenario) you can repeat an appearance in a cycle. You stated a showing at 5, 25, 35, and 55 seconds. Let’s ignore the absence at 15 and 45 for a moment and say instead that you want your object to appear every 10 seconds on the 5’s for 4 seconds each…
hh:05 till hh:09
hh:15 till hh:19
hh:25 till hh:29
hh:35 till hh:39
hh:45 till hh:49
hh:55 till hh:59

If you can live with that case then consider FLOOR()ing one-tenth of a second x 10. That would count 0-to-9 every ten seconds: 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 and so on. Now, you can pick out the 5-to-9 periods each 10 seconds in the minute 6 times: