Alcohol and water contract during mixing, so there is no formula for diluting alcohol, only tables for reference.
This app has an internal table and considers the contraction of alcohol and water in the calculations.
The calculations are possible in all directions. You can set the desired drinking strength as well as the amount of water or the desired amount of the diluted mixture.