# Converting Kelvin to cxy

Hi there

I try to convert different color temperatures into cie xy values for use in lamptab.
The script below is meant to convert degrees Kelving to cxy values, for use in the lamp.tab file like this :
/2800K/ 0.4519 0.4086 1.0
/2150K/ 0.5108 0.4150 1.0
The result is a bit strange, since the lower the kelvin value, the more white my resulting lampcolor gets.

Any suggestions?

-Iebele

#!/bin/csh

if ( \$#argv < 1 ) then
echo "Usage \$0 KELVIN "
echo "Convert degrees Kelvin to spectral values and cie-xy "
endif

echo "cct \$1" > .Kelvin.tmp
echo ""
echo "spectral values of \$1 K source:"
mgfilt c,cspec .Kelvin.tmp
echo ""
echo "cie xy values of \$1 K source:"
mgfilt c,cxy .Kelvin.tmp
echo ""

Hi Iebele,

Actually, white would be "cxy 0.3333 0.3333", so the values you are getting are actually becoming redder as the temperature decreases, as expected.

There is nothing wrong with this method for computing CIE (x,y) from CCT -- it's probably best. You can check against the other approximation, which is a table-based lookup in src/cal/cal/blackbody.cal. Just load this file into icalc or rcalc and evaluate the cct_x(kelvin) and cct_y(kelvin) with the same argument.

Best,
-Greg

ยทยทยท

From: iebele <[email protected]>
Date: November 5, 2007 1:40:42 AM MST

Hi there

I try to convert different color temperatures into cie xy values for use in lamptab.
The script below is meant to convert degrees Kelving to cxy values, for use in the lamp.tab file like this :
/2800K/ 0.4519 0.4086 1.0
/2150K/ 0.5108 0.4150 1.0
The result is a bit strange, since the lower the kelvin value, the more white my resulting lampcolor gets.

Any suggestions?

-Iebele

#!/bin/csh

if ( \$#argv < 1 ) then
echo "Usage \$0 KELVIN "
echo "Convert degrees Kelvin to spectral values and cie-xy "
endif

echo "cct \$1" > .Kelvin.tmp
echo ""
echo "spectral values of \$1 K source:"
mgfilt c,cspec .Kelvin.tmp
echo ""
echo "cie xy values of \$1 K source:"
mgfilt c,cxy .Kelvin.tmp
echo ""