<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/264935</link>
    <title>MATLAB Central Newsreader - MATLAB code needed based on the given equations.</title>
    <description>Feed for thread: MATLAB code needed based on the given equations.</description>
    <language>en-us</language>
    <copyright>&amp;copy;1994-2012 by MathWorks, Inc.</copyright>
    <webmaster>webmaster@mathworks.com</webmaster>
    <generator>MATLAB Central Newsreader</generator>
    <docs>http://blogs.law.harvard.edu/tech/rss</docs>
    <ttl>60</ttl>
    <image>
      <title>MathWorks</title>
      <url>http://www.mathworks.com/images/membrane_icon.gif</url>
    </image>
    <item>
      <pubDate>Wed, 04 Nov 2009 08:49:02 -0500</pubDate>
      <title>MATLAB code needed based on the given equations.</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/264935#691962</link>
      <author>Prabhakaran </author>
      <description>Concept&lt;br&gt;
As a rule of thumb, if the background of overlay text is dark, then the overlay text tends to be bright. On the contrary, the overlay text tends to be dark if the background of overlay text is bright. Therefore, there exists a transient color between overlay text and its adjacent background.&lt;br&gt;
Using the above idea i want transition map to be generated which contains only transient colors pixel.&lt;br&gt;
Code is needed based on this requirement.&lt;br&gt;
Since the change of intensity at the boundary of overlay text may be small in the low contrast image, to effectively determine whether a pixel is within a transition region, the modified saturation is first introduced as a weight value based on the fact that overlay text is in the form of overlay graphics. The modified saturation is defined as follows:&lt;br&gt;
&lt;br&gt;
S(x, y) =1-(3/(R+G+B)[min(R,G,B)]) ---------------&amp;gt; 1&lt;br&gt;
~S(x, y) = S(x, y)/max(S(x, y))&lt;br&gt;
Max(S(x, y)) =2*(0.5-I(x, y)), if ~I(x, y)&amp;gt;0.5 ---------&amp;gt; 2&lt;br&gt;
Max(S(x, y)) =I(x, y)), Otherwise. -------------------&amp;gt; 2&lt;br&gt;
&lt;br&gt;
S(x, y) and Max(S(x, y)) denote the saturation value and the maximum saturation value at the corresponding intensity level, respectively ~I(x, y). Denotes the intensity at the (x, y), which is normalized to [0,1] . Based on the conical HSI color model, the maximum value of saturation is normalized in accordance with ~I(x, y) compared to 0.5 in (2). The transition can thus be defined by combination of the change of intensity and the modified saturation as follows:&lt;br&gt;
&lt;br&gt;
DL(x, y) = (1+dSL(x, y)) * |I(x-1, y) - I(x, y)|&lt;br&gt;
DH(x, y) = (1+dSH(x, y)) * |I(x, y) - I(x+1, y)|&lt;br&gt;
Where dSL(x, y) = |~S(x-1, y)-~S(x, y)| and&lt;br&gt;
dSH(x, y)= |~S(x, y)-~S(x+1,y)| ------------&amp;gt; 3&lt;br&gt;
&lt;br&gt;
Since the weight dSH(x, y)) and dSL(x, y)) can be zero by the achromatic overlay text and background, we add 1 to the weight in (3). If a pixel satisfies the logarithmical change constraint given in (4), three consecutive pixels centered by the current pixel are detected as the transition pixels and the transition map is generated&lt;br&gt;
&lt;br&gt;
T(x, y) = 1, if DH &amp;gt; DL+TH&lt;br&gt;
T(x, y) = 0, Otherwise. -------&amp;gt; 4&lt;br&gt;
&lt;br&gt;
The thresholding value TH is empirically set to 80 in consideration of the logarithmical change.</description>
    </item>
  </channel>
</rss>

