// 건축법 시행령 34조 (직통계단의 설치) 1항
Check(EDBA_34_1){
KS
}
KS{
Floor myFloor{
isObjectProperty(Floor.isEscape) = TRUE
}
Space mySpace{
getObjectProperty(Space.usage)="PerformanceHall"
OR getObjectProperty(Space.usage)="AssemblyHall"
OR getObjectProperty(Space.usage)="Auditorium"
OR getObjectProperty(Space.usage)="ExhibitionHall"
}
Door myDoor{
isDirectlyAccessible(Door, Ground)=TRUE
}
Stair myStair{
isObjectProperty(Stair.isDirect)=TRUE
isAccessible(Stair,myFloor)=TRUE
OR isAccessible(Stair,Ground)=TRUE
}
Ramp myRamp{
isAccessible(Ramp,myFloor)=TRUE
OR isAccessible(Ramp,Ground)=TRUE
}
Floor myFloor2{
isObjectProperty(Floor.isEscape)=FALSE
OR hasObject(Floor, myDoor)=FALSE
}
Zone myZone{
isDirectlyAccessible(myStair, Zone)=FALSE
}
IF
getFloorNumber(mySpace)>0
getFloorArea(mySpace)<=300 m2
isFireResistantStructure(MainStructuralPart)=TRUE
OR isObjectProperty(MainStructuralPart.Material.nonCombustibility)=TRUE
THEN IF getBuildingStoriesCount()>=16
getBuildingUsage()="MultiUnitHouse"
THEN ED= 40
ELSE THEN ED=50
END IF
ELSE IF
getBuildingUsage() = "Factory"
isExist(ExtinguishingSystem)=TRUE
isObjectProperty(ExtinguishingSystem.isAutomatic)=TRUE
getResult(REFB_8_2)=TRUE
THEN IF getBuildingUsage() = "UnmannedFactory"
THEN ED=100
ELSE THEN ED=75
END IF
ELSE THEN ED=30
END IF
(hasObject(myFloor,myStair)=TRUE
hasObject(myZone, myStair)=TRUE
getObjectDistance(Room,myStair, 1)<=ED)
OR
(hasObject(myFloor,myRamp)=TRUE
hasObject(myZone, myRamp)=TRUE
getObjectDistance(Room,myRamp, 1)<=ED)
}
|
max_route_length = 30
def Check():
evac_storey_exist = False
stories = SELECT('storey')
for storey in stories:
if storey.SELECT('is evacuation storey').BOOL() == True:
evac_storey_exist = True
break
if evac_storey_exist == False:
ERROR('피난층이 존재하지 않습니다.')
return
for storey in stories:
if storey.SELECT('is evacuation storey').BOOL() == True:
continue
stairs = storey.SELECT('direct stair')
if stairs.COUNT() == 0:
storey.ERROR(storey.SELECT('name').STRING() + '에 직통계단이 존재하지 않습니다.')
continue
for space in storey.SELECT('space'):
route_length = -1
for route in space.SELECT('escape route', stairs):
length = route.SELECT('length').UNIT('m').NUMBER()
if length > 0:
if route_length < 0:
route_length = length
else:
route_length = min([route_length, length])
if route_length < 0:
space.ERROR(space.SELECT('name').STRING() + '부터 직통계단까지 갈 수 없다.')
elif route_length > max_route_length:
space.ERROR(space.SELECT('name').STRING() + '부터 직통계단까지의 거리가 멀다 : ' + str(route_length))
else:
space.SUCCESS(space.SELECT('name').STRING() + ' : ' + str(route_length))
|