Research Article

A Dynamic Programming Solution for Energy-Optimal Video Playback on Mobile Devices

Algorithm 2

FSA-split (frequency selection algorithm for the th iteration).
()Temporary variables: , , and ;
()Input parameter from the previous iteration ():
();
()for   to   do
()for   to   do
()  , , and ;
()end for
()end for
()for   to   do
()  for   to   do
()   if   and   then
()   if    then
()    Calculate , and using (2), (3), and (4), respectively, by replacing
     with ;
()   else
()    Calculate , and using (2), (3), and (4), respectively, by replacing with 0;
()   end if
()   ;
()   ;
()   ;
()   end if
()  end for
() end for
() for   to   do
()  for   to   do
()   for   to   do
()    if  then
()     Calculate the value of from (2) by replacing with ;
()      is calculated from (3) by replacing with ;
()      is calculated from (4), and is updated using this value of ;
()    end if
()   end for
()  end for
()  ;
()  ;
()  ;
()  ;
() end for
() ;
() ;
() while    do
()  ;
()  ;
()  ;
() end while