-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathavailability_schedule.py
More file actions
78 lines (73 loc) · 2.42 KB
/
availability_schedule.py
File metadata and controls
78 lines (73 loc) · 2.42 KB
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
70
71
72
73
74
75
76
77
"""availability schedule
NOT USED
"""
from idfhub.idf_autocomplete.idf_helpers_short import(
Scheduletypelimits,
ScheduleDayInterval, ScheduleWeekDaily, ScheduleYear,
)
from idfhub.idf_autocomplete.idf_types_short import(
ScheduletypelimitsType,
ScheduleDayIntervalType, ScheduleWeekDailyType, ScheduleYearType,
)
from src.idfhub.common import idf
DISCRETE = "Discrete"
#---------------------------------------------------------------------------------------------------
# # on crée un schedule d'availability, de type on/off : systems_year_availability
# mais on ne va pas s'en servir, car on va passer par un schedule compact pour les thermostat
#---------------------------------------------------------------------------------------------------
on_off_typelimits = Scheduletypelimits(
idf,
**ScheduletypelimitsType(
Name="on_off",
Lower_Limit_Value=0,
Upper_Limit_Value=1,
Numeric_Type=DISCRETE,
Unit_Type="Availability"
)
)
day_work = ScheduleDayIntervalType(
Name="day_work",
Schedule_Type_Limits_Name="on_off",
Interpolate_to_Timestep="No",
Time_1="07:00",
Value_Until_Time_1=0,
Time_2="17:00",
Value_Until_Time_2=1,
Time_3="24:00",
Value_Until_Time_3=0
)
day_off = ScheduleDayIntervalType(
Name="day_off",
Schedule_Type_Limits_Name="on_off",
Interpolate_to_Timestep="No",
Time_1="24:00",
Value_Until_Time_1=0
)
ScheduleDayInterval(idf, **day_work)
ScheduleDayInterval(idf, **day_off)
systems_week_availability = ScheduleWeekDailyType(
Name="systems_week_availability",
Sunday_ScheduleDay_Name="day_off",
Monday_ScheduleDay_Name="day_work",
Tuesday_ScheduleDay_Name="day_work",
Wednesday_ScheduleDay_Name="day_work",
Thursday_ScheduleDay_Name="day_work",
Friday_ScheduleDay_Name="day_work",
Saturday_ScheduleDay_Name="day_off",
Holiday_ScheduleDay_Name="day_off",
SummerDesignDay_ScheduleDay_Name="day_work",
WinterDesignDay_ScheduleDay_Name="day_work",
CustomDay1_ScheduleDay_Name="day_work",
CustomDay2_ScheduleDay_Name="day_work"
)
ScheduleWeekDaily(idf, **systems_week_availability)
systems_year_availability = ScheduleYearType(
Name="systems_year_availability",
Schedule_Type_Limits_Name="on_off",
ScheduleWeek_Name_1="systems_week_availability",
Start_Day_1=1,
Start_Month_1=1,
End_Day_1=31,
End_Month_1=12
)
ScheduleYear(idf, **systems_year_availability)