Yes you can do it numerically but it is not as safe.
Concepts needed, crank handle, meshed gears, parallel belts, crossed belts, and winch drum.
Where two gears mesh the rotation direction reverses.
Where a belt connects two pulleys there is no change of rotation, unless the belt is crossed.
There are two ways to solve this puzzle.
1. Draw more direction arrows as you work along the gears and belts of the mechanism.
2. Count using tokens such as “clock” and “anti”, flipping the token for every reversal.
Use = for a parallel belt, x is a crossed belt. c is clockwise, a is anticlockwise.
The sequence here is “ ca = acaca x cacac x aca ”
So output is opposite direction to input. The box opens.