[Radiance-general] The Three-Phase Method for Simulating Complex Fenestration with Radiance

Greg Ward gregoryjward at gmail.com
Tue Jul 23 19:25:35 PDT 2013


Oh, oops!  Guess that is the way it works, not the other way around.  If you output into a single file as you were doing, the first 8760*3 values are the first sensor, the next 8760*3 are the next sensor, and so on.  A simple sed script should work for separating them, and you can automate generating the sed script using rcalc.  If you have 20 sensor, you would use:

% cnt 20 | rcalc -e 'a=8761*$1+2;b=8761*($1+1)' -o '${a},${b}w sensor${recno}.txt' > sedscr.txt
% [dctimestep command] | tr \\t \\n | sed -n -f sedscr.txt

For more or fewer sensors, just change the '20' in the first line.  I haven't tried this, but it should work -- assuming you have tr and sed, that is...

-Greg

> From: Leyla Sanati <leylasanati at gmail.com>
> Date: July 23, 2013 6:10:14 PM PDT
> 
> Hi Greg,
> 
> I added the "-o sensor%02d.txt" option to the dctimestep line, and it worked. But it created 8760 files for each time step rather than separating the sensors. Here is what I typed:
> 
> dctimestep -n 8760 -o results/Venetain80/sensor%02d.txt results/photocells_windowglow_W.vmx xml/venetain80.xml results/windows.dmx Milwaukee.smx
> 
> Leyla
> 
> 
> On Tue, Jul 23, 2013 at 7:33 PM, Greg Ward <gregoryjward at gmail.com> wrote:
> The latest version of dctimestep allows an output specification such as "-o sensor%02d.txt" to separate sensor files like you want.
> 
> -Greg
> 
>> From: Leyla Sanati <leylasanati at gmail.com>
>> Date: July 23, 2013 3:58:47 PM PDT
>> 
>> German,
>> 
>> Thank you for your response.
>> I actually tried exporting the results to excel. However, the huge text file needs some time consuming editing before the export.
>> I wonder if we could modify the scripts to pipe each sensor point data into a separate file with one set of R G B values in each line.  
>> This will save me a lot of time. 
>> 
>> Thank you,
>> Leyla
>> 
>> 
>> 
>> On Tue, Jul 23, 2013 at 3:01 PM, Germán Molina Larrain <gmolina1 at uc.cl> wrote:
>> If I understand your question correctly, I guess I would do the rest on a spreadsheet or on a script.
>> 
>> For a spreadsheet, I would do:
>> 
>> rlam 'Results of venetian blind' 'Results of tinted' 'results of untinted' > Results.txt
>> 
>> rlam '!dctimestep -n 8760 results/photocells_windowglow_W.vmx xml/venetain80.xml results/windows.dmx Milwaukee.smx' '!dctimestep -n 8760 results/photocells_windowglow_C.vmx xml/tinted.xml results/clerestories.dmx Milwaukee.smx' '!dctimestep -n 8760 results/photocells_windowglow_C.vmx xml/untinted.xml results/clerestories.dmx Milwaukee.smx' > results/Results.txt
>> 
>> And, you should get, for each timestep, the parameter you are using for controlling the tint on your clerestories, and add that as an extra column.
>> 
>> Then, on excel it is possible to do:
>> 
>> |             A             |            B           |              C            |                D            |          E           |
>> |  Venetian Results  |  Tinted Results  |  Untinted Results  |  Control Parameter  |  Final Results  |
>> 
>> and put a formula to final result saying that, if(Control > theshold; Venetian+Tinted;Venetian+Untinted).
>> 
>> Hope it helps... I am working on something to do this kind of things on a single program, but it is not ready yet.
>> 
>> Regards, 
>> 
>> German   
>> 
>> 
>> 2013/7/23 Leyla Sanati <leylasanati at gmail.com>
>> Dear list,
>> 
>> I am trying to use the three phase method to calculate dynamic daylight performance metrics for a dynamic shading device. Similar to the example 2 in the three phase method tutorial, I have two sets of windows (clerestories and windows). I want to first calculate the annual illuminance levels on a 6 by 8 grid. Then filter the data by occupancy (normal working hours) and calculate the dynamic daylight metrics. 
>> 
>> Since is the shading device in my model is dynamic and has to change based on the incident light, I have two BSDF files for each window (e.g. tinted.xml and untinted.xml).
>> 
>> I have created the vmx, dmx, xml, and smx files. But I am confused on how to write the dctimestep and the rest of the calculations. Bellow is what I have typed so far.  I'd truly appreciate it if you could help me from this point on.
>> 
>> Thank you,
>> 
>> Leyla Sanati
>> 
>> oconv materials/room.mat objects/room.rad objects/windows.rad objects/clerestories.rad objects/ground.rad > model_vmx.oct
>> 
>> rcontrib -f klems_int.cal -bn Nkbins -fo -o results/photocells_%s.vmx -b kbinS -m windowglow_W -b kbinS -m windowglow_C -I+ -ab 12 -ad 50000 -lw 2e-5 model_vmx.oct < data/photocells.pts
>> 
>> oconv materials/room.mat objects/room.rad objects/ground.rad objects/sky_white1.rad > model_dmx.oct
>> 
>> genklemsamp -vd 0 -1 0 objects/windows.rad | rcontrib -c 1000 -e MF:4 -f reinhart.cal -b rbin -bn Nrbins -m sky_glow -faf model_dmx.oct > results/windows.dmx
>> 
>> genklemsamp -vd 0 -1 0 objects/clerestories.rad | rcontrib -c 1000 -e MF:4 -f reinhart.cal -b rbin -bn Nrbins -m sky_glow -faf model_dmx.oct > results/clerestories.dmx
>> 
>> epw2wea USA_WI_Milwaukee_TMY3.epw Milwaukee.wea
>> 
>> gendaymtx -m 4 Milwaukee.wea > Milwaukee.smx
>> 
>> rlam '!dctimestep -n 8760 results/photocells_windowglow_W.vmx xml/venetain80.xml results/windows.dmx Milwaukee.smx' '!dctimestep -n 8760 results/photocells_windowglow_C.vmx xml/tinted.xml results/clerestories.dmx Milwaukee.smx' > results/venetain80_tinted.dat
>> 
>> rlam '!dctimestep -n 8760 results/photocells_windowglow_W.vmx xml/venetain80.xml results/windows.dmx Milwaukee.smx' '!dctimestep -n 8760 results/photocells_windowglow_C.vmx xml/untinted.xml results/clerestories.dmx Milwaukee.smx' > results/venetain80_untinted.dat
>> 
>> 
>> _______________________________________________
>> Radiance-general mailing list
>> Radiance-general at radiance-online.org
>> http://www.radiance-online.org/mailman/listinfo/radiance-general
>> 
>> 
>> 
>> _______________________________________________
>> Radiance-general mailing list
>> Radiance-general at radiance-online.org
>> http://www.radiance-online.org/mailman/listinfo/radiance-general
>> 
>> 
>> _______________________________________________
>> Radiance-general mailing list
>> Radiance-general at radiance-online.org
>> http://www.radiance-online.org/mailman/listinfo/radiance-general
> 
> _______________________________________________
> Radiance-general mailing list
> Radiance-general at radiance-online.org
> http://www.radiance-online.org/mailman/listinfo/radiance-general
> 
> 
> _______________________________________________
> Radiance-general mailing list
> Radiance-general at radiance-online.org
> http://www.radiance-online.org/mailman/listinfo/radiance-general
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.radiance-online.org/pipermail/radiance-general/attachments/20130723/c01e11eb/attachment-0001.html>


More information about the Radiance-general mailing list