From c15505ca05196eb1197ddaec4b39890421d651ee Mon Sep 17 00:00:00 2001 From: Paul Wolok Date: Tue, 2 Dec 2025 08:40:19 +0100 Subject: [PATCH] =?UTF-8?q?Es=20as=20elemente=20drehung=20f=C3=BCr=20singl?= =?UTF-8?q?e=20objekte=20gemacht?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- cfg/shapes.cfg | 2 +- lib/plant2dxf.py | 141 +++++++++++++++++++++++++---------------------- 2 files changed, 77 insertions(+), 66 deletions(-) diff --git a/cfg/shapes.cfg b/cfg/shapes.cfg index 220b78f..40b4b65 100644 --- a/cfg/shapes.cfg +++ b/cfg/shapes.cfg @@ -33,7 +33,7 @@ winkel_boegen = 3 winkel_motor = 3 winkel_umlenk = 3 winkel_as = 3 -winkel_es = -3 +winkel_es = 3 [Omniflo] OFgeradesivas = 821106002 Tefgeradesivas = 1 diff --git a/lib/plant2dxf.py b/lib/plant2dxf.py index 3e9ab34..9b2a17d 100644 --- a/lib/plant2dxf.py +++ b/lib/plant2dxf.py @@ -165,7 +165,10 @@ def dreh_block(block_name: str, to_doc, winkel) : return dreh_block_name block_zwischen = to_doc.blocks.new(name=block_name + f"zwischenschrit_{winkel}", base_point=(0,0,0)) block = to_doc.blocks.new(name=dreh_block_name, base_point=(0,0,0)) - rotation_matrix = Matrix44.axis_rotate(Y_AXIS, winkel) + if block_name == "200000146_ES-Element_90_rechts" or block_name =="400102632_ES-Element_90_links" or block_name =="200000241_AS-Element_90_rechts" or block_name =="200000217_AS-Element_90_links": + rotation_matrix = Matrix44.axis_rotate(X_AXIS, winkel) + else: + rotation_matrix = Matrix44.axis_rotate(Y_AXIS, winkel) block_zwischen.add_blockref(block_name,(0,0,0)) for e in block_zwischen: @@ -1618,37 +1621,38 @@ def erstellung_gefaelle_block_verbunenden_am_einen(msp,x, y, doc, lib_doc, upper esoffset = float(config.get("ILS 2.0 Gefällestrecke", "esoffset")) winkel_as = float(config.get("Ils 2.0 core winkel", "winkel_as")) winkel_es = float(config.get("Ils 2.0 core winkel", "winkel_es")) + asoffset_y = asoffset * math.cos(math.radians(winkel_as)) + asoffset_z = asoffset * math.sin(math.radians(winkel_as)) + esoffset_y = esoffset * math.cos(math.radians(winkel_as)) + esoffset_z = esoffset * math.sin(math.radians(winkel_as)) + if (( hight == "higher" and drehung0 == "GUZS" )or (vario_richtung == "Auf"and verbungden_höher == False and drehung0 == "GUZS")or (vario_richtung == "Ab" and verbungden_höher == True and drehung0 == "GUZS")or (vario_richtung == "Horizontal" and drehung0 == "GUZS" and (mit_horizontal_verbunden == "unten_drehung_0_or_-90" or mit_horizontal_verbunden == "oben_drehung_-180_or_-270"))): block_as = "200000241_AS-Element_90_rechts" import_block(block_as,lib_doc,doc) - # block_as = dreh_block(block_as,doc,math.radians(winkel_as)) - # asoffset_y = asoffset * math.cos(math.radians(winkel_as)) - # asoffset_z = asoffset * math.sin(math.radians(winkel_as)) - if vario_richtung == "Auf": + block_as = dreh_block(block_as,doc,math.radians(winkel_as)) + + + if vario_richtung == "Auf" or vario_richtung =="Horizontal": start = (x , y + dy ,upper_hoehe_gefaehlle) - ende = (x , y - dy + asoffset ,lower_hoehe_gefaehlle) - block_vario.add_blockref(block_as,(ende[0]-x ,ende[1]-asoffset -y,ende[2] -hoehe_gefaehlle ),dxfattribs={"rotation": 180}) + ende = (x , y - dy + asoffset_y ,lower_hoehe_gefaehlle - asoffset_z) + block_vario.add_blockref(block_as,(ende[0]-x ,ende[1]-asoffset_y -y,ende[2] -hoehe_gefaehlle + asoffset_z),dxfattribs={"rotation": 180}) return start, ende elif vario_richtung == "Ab": - start = (x , y + dy - asoffset,upper_hoehe_gefaehlle ) + start = (x , y + dy - asoffset_y,upper_hoehe_gefaehlle - asoffset_z) ende = (x , y - dy ,lower_hoehe_gefaehlle) - block_vario.add_blockref(block_as,(start[0]-x ,start[1]+asoffset -y,start[2] -hoehe_gefaehlle )) + block_vario.add_blockref(block_as,(start[0]-x ,start[1]+asoffset_y -y,start[2] -hoehe_gefaehlle + asoffset_z)) return start,ende - elif vario_richtung =="Horizontal": - start = (x , y + dy ,upper_hoehe_gefaehlle) - ende = (x , y - dy + asoffset ,lower_hoehe_gefaehlle ) - block_vario.add_blockref(block_as,(ende[0]-x ,ende[1]-asoffset -y,ende[2] -hoehe_gefaehlle ),dxfattribs={"rotation": 180}) - return start, ende + if laenge > asoffset: - start[1] = start[1] - asoffset - start[2] = start[2] + start[1] = start[1] - asoffset_y + start[2] = start[2] - asoffset_z line = Line.new(dxfattribs={"start": start, "end": ende}) line.dxf.layer = "6-SP" copy= line.copy() copy.translate(-x,-y,-hoehe_gefaehlle) gefaelle_block.add_entity(copy) - gefaelle_block.add_blockref(block_as,(start[0]-x ,start[1]+asoffset -y,start[2] -hoehe_gefaehlle )) + gefaelle_block.add_blockref(block_as,(start[0]-x ,start[1]+asoffset_y -y,start[2] -hoehe_gefaehlle + asoffset_z)) return False else: msp.add_blockref(block_as,(x,y,upper_hoehe_gefaehlle)) @@ -1658,28 +1662,22 @@ def erstellung_gefaelle_block_verbunenden_am_einen(msp,x, y, doc, lib_doc, upper (vario_richtung == "Ab" and verbungden_höher == False and drehung0 == "GUZS")or (vario_richtung == "Horizontal" and drehung0 == "GUZS" and (mit_horizontal_verbunden == "oben_drehung_0_or_-90" or mit_horizontal_verbunden == "unten_drehung_-180_or_-270"))): block_es = "200000146_ES-Element_90_rechts" import_block(block_es,lib_doc,doc) - # block_es = dreh_block(block_es,doc,math.radians(winkel_es)) - # esoffset_y = asoffset * math.cos(math.radians(winkel_es)) - # esoffset_z = asoffset * math.sin(math.radians(winkel_es)) - if vario_richtung == "Auf": - start = (x , y + dy-esoffset,upper_hoehe_gefaehlle ) + block_es = dreh_block(block_es,doc,math.radians(winkel_es)) + + if vario_richtung == "Auf" or vario_richtung =="Horizontal": + start = (x , y + dy-esoffset_y,upper_hoehe_gefaehlle + esoffset_z) ende = (x , y - dy ,lower_hoehe_gefaehlle) - block_vario.add_blockref(block_es, (start[0]-x ,start[1]+esoffset-y ,start[2] -hoehe_gefaehlle ),dxfattribs={"rotation": 180}) + block_vario.add_blockref(block_es, (start[0]-x ,start[1]+esoffset_y-y ,start[2] -hoehe_gefaehlle -esoffset_z ),dxfattribs={"rotation": 180}) return start, ende elif vario_richtung == "Ab": - start = (x , y + dy,upper_hoehe_gefaehlle) - ende = (x , y - dy + esoffset,lower_hoehe_gefaehlle ) - block_vario.add_blockref(block_es, (ende[0]-x ,ende[1]-esoffset-y ,ende[2] -hoehe_gefaehlle )) + start = (x , y + dy,upper_hoehe_gefaehlle ) + ende = (x , y - dy + esoffset_y,lower_hoehe_gefaehlle +esoffset_z) + block_vario.add_blockref(block_es, (ende[0]-x ,ende[1]-esoffset_y-y ,ende[2] -hoehe_gefaehlle -esoffset_z)) return start, ende - elif vario_richtung =="Horizontal": - start = (x , y + dy-esoffset_y,upper_hoehe_gefaehlle ) - ende = (x , y - dy ,lower_hoehe_gefaehlle) - block_vario.add_blockref(block_es, (start[0]-x ,start[1]+esoffset-y ,start[2] -hoehe_gefaehlle ),dxfattribs={"rotation": 180}) - return start, ende if laenge > esoffset: - ende[1] = ende[1] + esoffset - ende[2] = ende[2] + ende[1] = ende[1] + esoffset_y + ende[2] = ende[2] + esoffset_z line = Line.new(dxfattribs={"start": start, "end": ende}) line.dxf.layer = "6-SP" copy= line.copy() @@ -1687,7 +1685,7 @@ def erstellung_gefaelle_block_verbunenden_am_einen(msp,x, y, doc, lib_doc, upper copy.translate(-x,-y,-hoehe_gefaehlle) gefaelle_block.add_entity(copy) - gefaelle_block.add_blockref(block_es, (ende[0]-x ,ende[1]-esoffset_y-y ,ende[2] -hoehe_gefaehlle - esoffset_z/2)) + gefaelle_block.add_blockref(block_es, (ende[0]-x ,ende[1]-esoffset_y-y ,ende[2] -hoehe_gefaehlle - esoffset_z)) return False else: msp.add_blockref(block_es,(x,y,lower_hoehe_gefaehlle)) @@ -1698,32 +1696,27 @@ def erstellung_gefaelle_block_verbunenden_am_einen(msp,x, y, doc, lib_doc, upper block_as = "200000241_AS-Element_90_rechts" block_as = "200000217_AS-Element_90_links" import_block(block_as,lib_doc,doc) - if vario_richtung == "Auf": + if vario_richtung == "Auf" or vario_richtung =="Horizontal": start = (x , y + dy ,upper_hoehe_gefaehlle) - ende = (x , y - dy + asoffset,lower_hoehe_gefaehlle) + ende = (x , y - dy + asoffset_y,lower_hoehe_gefaehlle - asoffset_z) - block_vario.add_blockref(block_as,(ende[0]-x ,ende[1]-asoffset -y,ende[2] - hoehe_gefaehlle)) + block_vario.add_blockref(block_as,(ende[0]-x ,ende[1]-asoffset_y -y,ende[2] - hoehe_gefaehlle + asoffset_z)) return start, ende elif vario_richtung == "Ab": - start = (x , y + dy - asoffset,upper_hoehe_gefaehlle) + start = (x , y + dy - asoffset_y,upper_hoehe_gefaehlle -asoffset_z) ende = (x , y - dy ,lower_hoehe_gefaehlle) - block_vario.add_blockref(block_as,(start[0]-x ,start[1]+asoffset -y,start[2] - hoehe_gefaehlle),dxfattribs={"rotation": 180}) - return start, ende - elif vario_richtung =="Horizontal": - start = (x , y + dy ,upper_hoehe_gefaehlle) - ende = (x , y - dy + asoffset,lower_hoehe_gefaehlle) - - block_vario.add_blockref(block_as,(ende[0]-x ,ende[1]-asoffset -y,ende[2] - hoehe_gefaehlle)) + block_vario.add_blockref(block_as,(start[0]-x ,start[1]+asoffset_y -y,start[2] - hoehe_gefaehlle + asoffset_z),dxfattribs={"rotation": 180}) return start, ende if laenge > asoffset: - start[1] = start[1] - asoffset + start[1] = start[1] - asoffset_y + start[2] = start[2] - asoffset_z line = Line.new(dxfattribs={"start": start, "end": ende}) line.dxf.layer = "6-SP" copy= line.copy() copy.translate(-x ,-y,-hoehe_gefaehlle) gefaelle_block.add_entity(copy) - gefaelle_block.add_blockref(block_as,(start[0]-x ,start[1]+asoffset -y,start[2] - hoehe_gefaehlle),dxfattribs={"rotation": 180}) + gefaelle_block.add_blockref(block_as,(start[0]-x ,start[1]+asoffset_y -y,start[2] - hoehe_gefaehlle + asoffset_z),dxfattribs={"rotation": 180}) return False else: msp.add_blockref(block_as,(x,y,upper_hoehe_gefaehlle),dxfattribs={"rotation": 180}) @@ -1734,29 +1727,26 @@ def erstellung_gefaelle_block_verbunenden_am_einen(msp,x, y, doc, lib_doc, upper block_es = "400102632_ES-Element_90_links" import_block(block_es,lib_doc,doc) - if vario_richtung == "Auf": - start = (x , y + dy-esoffset ,upper_hoehe_gefaehlle) + if vario_richtung == "Auf" or vario_richtung =="Horizontal": + start = (x , y + dy-esoffset_y ,upper_hoehe_gefaehlle + esoffset_z) ende = (x , y - dy,lower_hoehe_gefaehlle) - block_vario.add_blockref(block_es, (start[0]-x ,start[1]+esoffset -y,start[2] - hoehe_gefaehlle)) + block_vario.add_blockref(block_es, (start[0]-x ,start[1]+esoffset_y -y,start[2] - hoehe_gefaehlle - esoffset_z)) return start, ende elif vario_richtung == "Ab": start = (x , y + dy ,upper_hoehe_gefaehlle) - ende = (x , y - dy + esoffset,lower_hoehe_gefaehlle) - block_vario.add_blockref(block_es, (ende[0]-x ,ende[1]-esoffset -y,ende[2] - hoehe_gefaehlle),dxfattribs={"rotation": 180}) + ende = (x , y - dy + esoffset_y,lower_hoehe_gefaehlle + esoffset_z) + block_vario.add_blockref(block_es, (ende[0]-x ,ende[1]-esoffset_y -y,ende[2] - hoehe_gefaehlle -esoffset_z),dxfattribs={"rotation": 180}) return start,ende - elif vario_richtung =="Horizontal": - start = (x , y + dy-esoffset ,upper_hoehe_gefaehlle) - ende = (x , y - dy,lower_hoehe_gefaehlle) - block_vario.add_blockref(block_es, (start[0]-x ,start[1]+esoffset -y,start[2] - hoehe_gefaehlle)) - return start, ende + if laenge > esoffset: - ende[1] = ende[1] + esoffset + ende[1] = ende[1] + esoffset_y + ende[2] = ende[2] + esoffset_z line = Line.new(dxfattribs={"start": start, "end": ende}) line.dxf.layer = "6-SP" copy= line.copy() copy.translate(-x ,-y,-hoehe_gefaehlle) gefaelle_block.add_entity(copy) - gefaelle_block.add_blockref(block_es, (ende[0]-x ,ende[1]-esoffset -y,ende[2] - hoehe_gefaehlle),dxfattribs={"rotation": 180}) + gefaelle_block.add_blockref(block_es, (ende[0]-x ,ende[1]-esoffset_y -y,ende[2] - hoehe_gefaehlle -esoffset_z),dxfattribs={"rotation": 180}) return False else: msp.add_blockref(block_es,(x,y,lower_hoehe_gefaehlle),dxfattribs={"rotation": 180}) @@ -1767,6 +1757,12 @@ def gefaellegerade_erstellung(x, y, doc, lib_doc, upper_hoehe_gefaehlle, lower_h asoffset = float(config.get("ILS 2.0 Gefällestrecke", "asoffset")) esoffset = float(config.get("ILS 2.0 Gefällestrecke", "esoffset")) + winkel_as = float(config.get("Ils 2.0 core winkel", "winkel_as")) + winkel_es = float(config.get("Ils 2.0 core winkel", "winkel_es")) + asoffset_y = asoffset * math.cos(math.radians(winkel_as)) + asoffset_z = asoffset * math.sin(math.radians(winkel_as)) + esoffset_y = esoffset * math.cos(math.radians(winkel_as)) + esoffset_z = esoffset * math.sin(math.radians(winkel_as)) if upper_hoehe_gefaehlle < lower_hoehe_gefaehlle: middle_hoehe = upper_hoehe_gefaehlle upper_hoehe_gefaehlle = lower_hoehe_gefaehlle @@ -1778,6 +1774,7 @@ def gefaellegerade_erstellung(x, y, doc, lib_doc, upper_hoehe_gefaehlle, lower_h (voerder_richtung == "Ab"and ((am_kreisel == 1 and erster_kreisel_höher == True)or (am_kreisel== 2 and erster_kreisel_höher == False)) and drehung0 == "GUZS" and drehung1== "GUZS")): block_es = "200000146_ES-Element_90_rechts" import_block(block_es,lib_doc,doc) + block_es = dreh_block(block_es,doc,math.radians(winkel_es)) # block_es = dreh_block(block_es,doc,math.radians(3)) # esoffset_y = esoffset * math.cos(math.radians(3)) # esoffset_z = esoffset * math.sin(math.radians(3)) @@ -1787,17 +1784,17 @@ def gefaellegerade_erstellung(x, y, doc, lib_doc, upper_hoehe_gefaehlle, lower_h halbe_laenge = laenge / 2 dy = halbe_laenge * math.cos(0) if voerder_richtung == "Auf": - start = (x , y+ dy - esoffset,upper_hoehe_gefaehlle) + start = (x , y+ dy - esoffset_y,upper_hoehe_gefaehlle) ende = (x , y1 ,z1) - block_vario.add_blockref(block_es, (start[0]-x ,start[1]+esoffset-y ,start[2] -hoehe_gefaehlle),dxfattribs={"rotation": 180}) + block_vario.add_blockref(block_es, (start[0]-x ,start[1]+esoffset_y-y ,start[2] -hoehe_gefaehlle),dxfattribs={"rotation": 180}) return start,ende elif(voerder_richtung == "Ab"): start = (x , y1 ,z1) - ende = (x , y - dy + esoffset,lower_hoehe_gefaehlle) - block_vario.add_blockref(block_es, (ende[0]-x ,ende[1]-esoffset-y ,ende[2] -hoehe_gefaehlle)) + ende = (x , y - dy + esoffset_y,lower_hoehe_gefaehlle) + block_vario.add_blockref(block_es, (ende[0]-x ,ende[1]-esoffset_y-y ,ende[2] -hoehe_gefaehlle)) return start, ende start = (x , y + dy,upper_hoehe_gefaehlle) - ende = (x , y - dy + esoffset,lower_hoehe_gefaehlle) + ende = (x , y - dy + esoffset_y,lower_hoehe_gefaehlle) line = Line.new(dxfattribs={"start": start, "end": ende}) line.dxf.layer = "6-SP" copy= line.copy() @@ -1811,7 +1808,7 @@ def gefaellegerade_erstellung(x, y, doc, lib_doc, upper_hoehe_gefaehlle, lower_h halbe_laenge = laenge / 2 block_as = "200000241_AS-Element_90_rechts" import_block(block_as,lib_doc,doc) - block_as = dreh_block(block_es,doc,math.radians(3)) + block_as = dreh_block(block_as,doc,math.radians(winkel_as)) dy = halbe_laenge * math.cos(0) if voerder_richtung == "Auf": @@ -1841,6 +1838,7 @@ def gefaellegerade_erstellung(x, y, doc, lib_doc, upper_hoehe_gefaehlle, lower_h block_es = "400102632_ES-Element_90_links" import_block(block_es,lib_doc,doc) + block_es = dreh_block(block_es,doc,math.radians(winkel_es)) if am_kreisel == None: block = doc.blocks.new(name=blockname, base_point=(0,0,0)) halbe_laenge = laenge / 2 @@ -1874,6 +1872,7 @@ def gefaellegerade_erstellung(x, y, doc, lib_doc, upper_hoehe_gefaehlle, lower_h block_as = "200000241_AS-Element_90_rechts" import_block(block_as,lib_doc,doc) + block_as = dreh_block(block_as,doc,math.radians(winkel_as)) if am_kreisel == None: block = doc.blocks.new(name=blockname, base_point=(0,0,0)) halbe_laenge = laenge / 2 @@ -1909,6 +1908,7 @@ def gefaellegerade_erstellung(x, y, doc, lib_doc, upper_hoehe_gefaehlle, lower_h halbe_laenge = laenge / 2 block_es = "400102632_ES-Element_90_links" import_block(block_es,lib_doc,doc) + block_es = dreh_block(block_es,doc,math.radians(winkel_es)) dy = halbe_laenge * math.cos(0) if voerder_richtung == "Auf": start = (x , y + dy - esoffset,upper_hoehe_gefaehlle) @@ -1936,6 +1936,7 @@ def gefaellegerade_erstellung(x, y, doc, lib_doc, upper_hoehe_gefaehlle, lower_h (am_kreisel!= None and drehung0 == "UZS" and drehung1 == "UZS"))): block_as = "200000217_AS-Element_90_links" import_block(block_as,lib_doc,doc) + block_as = dreh_block(block_as,doc,math.radians(winkel_as)) if am_kreisel == None: block = doc.blocks.new(name=blockname, base_point=(0,0,0)) halbe_laenge = laenge / 2 @@ -1967,6 +1968,7 @@ def gefaellegerade_erstellung(x, y, doc, lib_doc, upper_hoehe_gefaehlle, lower_h (voerder_richtung == "Ab" and((am_kreisel == 1 and erster_kreisel_höher == True)or (am_kreisel == 2 and erster_kreisel_höher == False))and (drehung0 == "UZS" and drehung1 == "GUZS"))): block_es = "200000146_ES-Element_90_rechts" import_block(block_es,lib_doc,doc) + block_es = dreh_block(block_es,doc,math.radians(winkel_es)) if am_kreisel == None: block = doc.blocks.new(name=blockname, base_point=(0,0,0)) halbe_laenge = laenge / 2 @@ -1998,6 +2000,7 @@ def gefaellegerade_erstellung(x, y, doc, lib_doc, upper_hoehe_gefaehlle, lower_h (voerder_richtung == "Ab" and((am_kreisel == 1 and erster_kreisel_höher == False)or (am_kreisel == 2 and erster_kreisel_höher == True))and (drehung0 == "UZS" and drehung1 == "GUZS"))): block_as = "200000217_AS-Element_90_links" import_block(block_as,lib_doc,doc) + block_as = dreh_block(block_as,doc,math.radians(winkel_as)) if am_kreisel == None: block = doc.blocks.new(name=blockname, base_point=(0,0,0)) halbe_laenge = laenge / 2 @@ -2031,6 +2034,8 @@ def gefaellegerade_erstellung(x, y, doc, lib_doc, upper_hoehe_gefaehlle, lower_h import_block(block_as,lib_doc,doc) block_es = "200000146_ES-Element_90_rechts" import_block(block_es,lib_doc,doc) + block_as = dreh_block(block_as,doc,math.radians(winkel_as)) + block_es = dreh_block(block_es,doc,math.radians(winkel_es)) if hight_position != None: block = doc.blocks.new(name=blockname, base_point=(0,0,0)) halbe_laenge = laenge / 2 @@ -2072,6 +2077,8 @@ def gefaellegerade_erstellung(x, y, doc, lib_doc, upper_hoehe_gefaehlle, lower_h import_block(block_as,lib_doc,doc) block_es = "400102632_ES-Element_90_links" import_block(block_es,lib_doc,doc) + block_as = dreh_block(block_as,doc,math.radians(winkel_as)) + block_es = dreh_block(block_es,doc,math.radians(winkel_es)) if hight_position != None: block = doc.blocks.new(name=blockname, base_point=(0,0,0)) halbe_laenge = laenge / 2 @@ -2107,6 +2114,8 @@ def gefaellegerade_erstellung(x, y, doc, lib_doc, upper_hoehe_gefaehlle, lower_h import_block(block_as,lib_doc,doc) block_es = "400102632_ES-Element_90_links" import_block(block_es,lib_doc,doc) + block_as = dreh_block(block_as,doc,math.radians(winkel_as)) + block_es = dreh_block(block_es,doc,math.radians(winkel_es)) if hight_position !=None: block = doc.blocks.new(name=blockname, base_point=(0,0,0)) halbe_laenge = laenge / 2 @@ -2145,6 +2154,8 @@ def gefaellegerade_erstellung(x, y, doc, lib_doc, upper_hoehe_gefaehlle, lower_h import_block(block_as,lib_doc,doc) block_es = "200000146_ES-Element_90_rechts" import_block(block_es,lib_doc,doc) + block_as = dreh_block(block_as,doc,math.radians(winkel_as)) + block_es = dreh_block(block_es,doc,math.radians(winkel_es)) if hight_position != None: block = doc.blocks.new(name=blockname, base_point=(0,0,0)) halbe_laenge = laenge / 2