-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathwaterboss_calculator.py
69 lines (65 loc) · 3.76 KB
/
waterboss_calculator.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
# Запрос показателей:
print('ВВЕДИТЕ ОБЩИЕ УСЛОВИЯ')
turbidity = int(input('Какая сейчас вода? \n 1 - прозрачная, 2 - мутная: '))
water_drink = int(input('Какая нужна вода? \n 1 - питьевая, 2 - техническая: '))
water_points = int(input('Кол-во точек водоразбора: '))
water_type = int(input('Тип воды? \n 1 - водопроводная, 2 - из скважины: '))
print()
print('ВВЕДИТЕ РЕЗУЛЬТАТ АНАЛИЗА ВОДЫ')
pH = float(input('Водород: '))
TDS = float(input('Минерализация: '))
TDH = float(input('Жесткость: '))
Fe = float(input('Железо: '))
N = float(input('Нитраты: '))
O = float(input('Органика: '))
Mn = float(input('Марганец: '))
F = float(input('Фториды: '))
P = float(input('Сероводород: '))
S = float(input('Сульфиды: '))
# Система водоподготовки:
prefilter = ''
waterboss = []
postfilter = ''
dwm = 'Не требуется'
# Функция проверки соответствия систем:
def waterboss_check():
if (water_points <= 4 and 6 <= pH <= 9 and 200 <= TDS <= 1000 and TDH <= 10 and Fe <= 3 and N <= 10 and O <= 3 and Mn <= 0.2 and F <= 1 and P <= 0.003 and S <= 0.003):
waterboss.append('WaterBoss 400')
if (water_points <= 5 and 6 <= pH <= 9 and 200 <= TDS <= 1000 and TDH <= 20 and Fe <= 10 and N <= 10 and O <= 3 and 0.2 <= Mn <= 0.5 and F <= 1 and P <= 0.003 and S <= 0.003):
waterboss.append('WaterBoss 700')
if (water_points <= 5 and 6 <= pH <= 9 and 200 <= TDS <= 1000 and TDH <= 20 and Fe <= 10 and N <= 10 and O <= 3 and 0.2 <= Mn <= 0.5 and F <= 1 and P <= 0.003 and S <= 0.003):
waterboss.append('WaterBoss 800')
if (water_points <= 6 and 6 <= pH <= 9 and 200 <= TDS <= 1000 and TDH <= 25 and Fe <= 10 and N <= 10 and O <= 3 and 0.2 <= Mn <= 0.5 and F <= 1 and P <= 0.003 and S <= 0.003):
waterboss.append('WaterBoss 900')
if (water_points <= 6 and 6 <= pH <= 9 and 200 <= TDS <= 1000 and TDH <= 25 and Fe <= 10 and N <= 10 and O <= 3 and 0.2 <= Mn <= 0.5 and F <= 1 and P <= 0.003 and S <= 0.003):
waterboss.append('Aquaphor 1000')
if (water_points <= 5 and 6 <= pH <= 9 and 200 <= TDS <= 1000 and TDH <= 20 and Fe <= 10 and N <= 10 and O <= 3 and 0.2 <= Mn <= 0.5 and F <= 1 and P <= 0.003 and S <= 0.003):
waterboss.append('Aquaphor Pro 180')
if (water_points <= 7 and 6 <= pH <= 9 and 200 <= TDS <= 1000 and TDH <= 28 and Fe <= 10 and N <= 10 and O <= 3 and 0.2 <= Mn <= 0.5 and F <= 1 and P <= 0.003 and S <= 0.003):
waterboss.append('Aquaphor ProPlus 380')
if (water_points <= 4 and 6 <= pH <= 9 and 200 <= TDS <= 1000 and TDH <= 10 and Fe <= 3 and N <= 10 and O <= 3 and Mn <= 0.2 and F <= 1 and P > 0.003 and S > 0.003):
waterboss.append('WaterBoss 400 P')
if (water_points <= 7 and 6 <= pH <= 9 and 200 <= TDS <= 1000 and TDH <= 28 and Fe <= 10 and N <= 10 and O <= 3 and 0.2 <= Mn <= 0.5 and F <= 1 and P > 0.003 and S > 0.003):
waterboss.append('Aquaphor ProPlus 380 P')
else:
pass
# Подбор оборудования:
if turbidity != 2:
waterboss_check()
if water_drink == 1:
dwm = 'DWM 101S Морион'
if water_type == 1:
prefilter = 'Полипропиленовый картридж'
else:
prefilter = 'Угольный картридж'
# Результат:
if waterboss != []:
print(f'''
СИСТЕМА ВОДООЧИСТКИ.
Предфильтрация: Гросс 20 + {prefilter};
Очистка: {' или '.join(waterboss)};
Постфильтрация: {postfilter};
Дополнительно: {dwm}.
''')
else:
print('Не удалось подобрать оборудование под ваши показатели.')