glassfile = open('glassfile.txt', "r") from math import pi def openFile(glassfile): for line in glassfile: for i in line: volume = float(i[0]) height = float(i[1]) density = float(i[2]) thickness = float(i[3]) def volumeOfGlassinCubicInches(volume, height, density, thickness): volume * 1.805 = CubicInches return CubicInches def OutsideRadius(volume, height, density, thickness): ((volumeofGlassinCubicInches(CubicInches) - (thickness**2))/(height*pi*thickness)) = InsideRadius InsideRadius + thickness = OutsideRadius return ORadius return IRadius def weightOfPackage(volume, height, density, thickness): ((pi*(OutsideRadius(ORadius)**2)*height)-(pi*(OutsideRadius(IRadius)**2)*height)) = glassVolume density*glassVolume = mass mass * 9.8 = weightGlass weightGlass * 12 = packageWeight return packageWeight def boxArea(volume, height, density, thickness): (OutsideRadius(ORadius)**2) * height = glassArea glassArea * 12 = packageArea return packageArea def boxArrange(volume, heigth, density, thickness): pass openFile(glassfile)