1 # Lumen 2 # 3 # A basic light level calculation program 4 # 5 # Created as part of a tutorial for assisting Engineers 6 # to learn programming with Python 7 # 8 # Copyright (c) 2006 to Ted Bell ted dot bell at lineone dot net 9 # Distributed free and without warranty of any kind 10 # 11 12 13 # Begin by estimating the number of fittings required. 14 15 e = input("Enter the light level required in Lux ") 16 l = input("Enter the length of the room ") 17 w = input("Enter the width of the room ") 18 a = l*w 19 f = input("Enter the bare lamp lumens per fitting ") 20 uf = 0.85 # we can amend this to generate a number at a later stage. 21 n = (e*a)/(f*uf) 22 print round(n) 23 24 25 # Now calculate the actual light level. 26 27 N = input("Enter actual number of luminaires to be used ") 28 # we can use capital n here as Python treats n and N as two values. 29 llf = input("Enter light loss factor ") 30 # we can revisit this at a later stage and break it down into parts. 31 E = (N*f*uf*llf)/a 32 # Again we can use capital E here to distinguish it. 33 print E
Attached FilesTo refer to attachments on a page, use attachment:filename, as shown below in the list of files. Do NOT use the URL of the [get] link, since this is subject to change and can break easily.
You are not allowed to attach a file to this page.