You are on page 1of 34

Energy-Efficiency through

operations-reduction

Mustafa Mat Deris


Faculty of Computer Science and IT
Universiti Tun Hussein Onn Malaysia
Batu Pahat, Johor
86400, Malaysia

mmustafa@uthm.edu.my
Tel: +607-4533723

23 Mac, 2013
Presentation Outline

 Motivation
 Introduction
 Algorithm for Energy Saving
 Example: Searching Min-Max of Data
 Q&A
Motivation -Some Best Places for Healthy living

New Zealand: Healthy Living Kiwi-style


Home to 4.3 million people, New Zealand
and its awesome landscapes and pollution-
free environment, it’s much easier to
embrace a healthy lifestyle.

Vilcabamba, Ecuador: The Valley of


Longevity
Why can natives of Vilcabamba’s “Valley of
Longevity” live longer, healthier lives? Maybe
it’s the pollution-free environment or the
highly oxygenated air. It could be the
unique combination of minerals in the water
or the abundance of negative ions emanating
from the mountains and fast flowing rivers.
Cont….. - Some Best Places for Healthy living

Bukit tinggi – Padang Indonesia


Surrounding with Maninjau lake
tranquility – highly oxygenated
air

Marang Beach, Terengganu


Malaysia
calm, highly oxygenated
from sea breeze.

Our dream …..!!!!!


Motivation – Attributes for Healthy Living

Pollution-free environment

- Highly oxygenated air


- zero/less CO2 emmision
- water-hygiene

Tranquility environment

- calm
- peacefull

… more
MOTIVATION

Malaysia is highly concerned about environmental


impact for CO2, SO2, NO2 emission from electricity
power generations. Without any mitigation mesures
been taken up, 285.75 million tons CO2 will be released
in 2020 which is 68.86% increase compared to 2000
MOTIVATION

World needs less CO2 emission for healthy living,


thus need ‘green world’

Green world

Computers is none exception for ‘green world’


INTRODUCTION
People Activities
Blogging Social Networking

Use google as internet search engine – requires data centre


INTRODUCTION

Google disclosed that it continuously uses enough


electricity to power 200,000 homes. Every time a person
runs a Google search, watches a YouTube video or
sends a message through Gmail, the company’s data
centers full of computers use electricity. Those data
centers around the world continuously draw almost
260 million watts — about a quarter of the output of a
nuclear power plant.

Source: http://www.marketingpilgrim.com/2011/09/googles-electric-bills-must-be-pretty-darn-
high.html
Introduction

Rapidly Growing
GREEN COMPUTING IS NEEDED TO REDUCE POWER CONSUMPTION
Introduction-Effort

1992: Energy Star, an international standard for energy-


efficient electronic equipment that was created by the
United States Environmental Protection Agency, and
has now been adopted by several other countries.

Energy Star reduces the amount of energy consumed by


a product by automatically switching it into “sleep” mode
when not in use or reducing the amount of power used
by a product when in “standby” mode.
Introduction- Effort
2001 - VIA Technologies, a Taiwanese company that
manufactures motherboard chipsets, CPUs, and other
computer hardware, introduced its initiative for "green
computing".

Focusing on power efficiency throughout the design and


manufacturing process of its products.

2005, the company introduced the VIA C7-M and VIA C7


processors that have a maximum power consumption of
20W at 2.0GHz and an average power consumption of
1W.
4X less carbon during their operation and can be
efficiently embedded in solar-powered devices.
GREEN COMPUTING –APPROACHES/ CATEGORIES

Green Computing

Software &
Product Longivity/ Data Centre Design Development
less carbon -To increase from 160C
Optimization
to 180C or…
-Life-time
-Less CO2 emmision

Power Management Materials Recycling


-where to standby, suspend,
sleep, and full-off states. -reuse the materials
SOFTWARE & DEVELOPMENT OPTIMIZATION - APPROACHES

Software & Development


Optimization

Algorithmic Virtualizing
Efficiency

Resource Allocation Terminal Servers


ALGORITHMIC EFFICIENCY

Power consumption has become a major concern in computer


system design due to the increase CPU clock speed and
processors, that increase power costs as well as thermal .

Recently, there has been considerable research interest in the


design analysis of energy-efficient algorithms that reduce the
energy consumption while minimizing compromise to service.

Basically, there are two techniques to save energy:

- Power Down Mechanisms


- Speed Scaling
ALGORITHMIC EFFICIENCY

- Power down mechanisms

When a system is idle, it can be transitioned into sleep states


(low-power). This technique is well- known and widely used to
save energy.

Normal CPU temps range from 30-40C when idle, under load
maybe 40-55C. The hottest you should allow it to get is 60C.
ALGORITHMIC EFFICIENCY

- Speed scaling

Microprocessors such as AMD and Intel are able to operate at


variable speed. The higher the speed, the higher power
consumption is. Thus, the goal is to save energy by utilizing
the speed of a processor and less response time used.
However, lower speed will save energy but degrade the
performance.
If the processor runs at speed s, then the required power is s3.
[Albers 2010]

Thus, how to set a speed of a processor so as to minimize energy


consumption, while still providing a desired quality of service?
Several approaches have been proposed:

- Scheduling with deadlines


- Minimizing response time
Scheduling with Deadline Algorithm

Yao et. al. 1995. The algorithm proceeds in series of iterations. In


each iteration, a time interval of maximum density is identified and a
corresponding partial schedule is constructed. The density ( total
work to be completed) is ,

1
I 
I
 wi
J i S i
where I = [t,t’] is the length a time interval,
Ji is job I in S, that satisfy [ri,di]  I,
ri is the release time, and di is the deadline time.
wi is a processing volume of Ji

From this, the algorithm schedules the jobs of Si at speed  I using


the earliest deadline first (EDF) policy, where the available unfinished
jobs with earliest deadline is executed first, followed by the second
earliest deadline, and so on. The algorithm with the running time is
O(dn log n)
Issues: Speed Scaling (response time)

Response
Times

CPU
speed

From: Low CPU speed cause Response


high response times Times

To: standard CPU speed with


low response times CPU
speed
Issues: Speed Scaling

From: Low CPU speed cause


Response
Times high response times

CPU
speed

Response
Times

To: standard CPU speed with


low response times CPU
speed
Minimizing Response Time

n
The objective is to minimize g = E +  f i
i 1

where E is energy consumption


fi is the response time (flow time) of job i

This can be improved when the number of operations is less that


can be shown using the following example.
Searching Min and Max elements from a set of data

Popular technique : divide–and-conquer

f(5)

f(2) f(3)

f(1) f(1) f(1) f(2)

f(1) f(1)

f(n) is the total number of comparisons needed for size n


= 2(n-1)
Theorem: Let f be an increasing function that satisfies the
recurrence relation
f(n) = af(n/b) + c

Whenever n is divisible by b, where a ≥ 1, b is an integer greater


than 1, and c is a positive real number. Then

 O(n b ) if a  1
Log a
f(n) = 

O( Log n) if a  1
f(n) ≤ f(bk+1) = C1a k+1 + C2

≤ (C1 a) a Log b n + C2

= (C1 a) n Logb a + C2

where C1 = f(1)+c/(a-1) and C2 = -c/(a-1).


Searching Min and Max elements from a set of data

can be improved when no recursive calls is required for n =2,


i.e., f(n) =1. We call Enhanced divide–and-conquer

[Same approach used by Vasanth Raja, 2010] *

f(5)

f(3)
f(2)

f(1) f(2)

2(n-1) – 2k for n <= 3*2k


f(n) =
n+2k+1 – 2 for n > 3*2k

where k is a positive integer

* http://vasanthexperiments.wordpress.com/tag/divide-and-conquer-min-max-problem-solution/
Enhanced divide–and-conquer algorithm

/* the size of the array a is n */


divide-and-conquer:
if( n =1)
min = max = a[0]
else
if( n =2)
find min_max (a[0] , a[1])
else
divide-and-conquer (a,n/2, min,max)
divide-and-conquer (a+n/2, n-n/2,min,max)
find_min (min1,min2)
find_max(max1,max2)
End.

Enhanced divide–and-conquer algorithm


Example:

a: [1] [2] [3] [4] [5] [6] [7] [8] [9]

22 13 -5 -8 15 60 17 31 47
1,9, 60,-8

1,5, 22,-8 6,9,60,17

1,3,22,-5 4,5, 15,-8 6,7,60,17 8,9,47,31

1,2,22,13 3,3, -5,-5

approach used by Vasanth Raja, 2010*


* http://vasanthexperiments.wordpress.com/tag/divide-and-conquer-min-max-problem-solution/
Proof

Let f(n) be the total number of comparisons needed to find the


minimum and maximum elements of the set with n elements. A
problem of size n, where n is a power of two can be reduced into
two problems of size n/2, using two comparisons, one to compare
the minima of the two sets and the other to compare the maxima
of the two sets. This gives the divide-and-conquer recurrence
relation:

f(n) = f( n / 2 ) + f(n / 2 ) + 2

= 2 f(n / 2 )+ 2
For any positive integer n, the above recurrence relation can be
deduced recursively to be:
k  i k 1
i j  i 
 
k
f(n)   (  f (  (1)   n / 2 k j
))  2  2 j
(1)
   j
i 0  i  j 0   j 0

where k is a positive integer


For the case of n= 2k, equation 1 becomes,
k 1
 2 f (1)  2  2 j
k (2)
j 0

This can be improved when no recursive calls is required for n =2,


where f(n) =1. Therefore equation 2 can be rewritten as;
k 2
2 k 1
f (2)  2  2 j , for k ≥ 2. (3)

j 0
Cont…..

For the case of n ≠ 2k, the range of n should be 2k < n < 2 k+1,
where k is a positive integer. Thus, the equation 2 can be deduced
as;
 2k f (2)  (n  2k 1 ) f (1)  2(n  1)  2k 1, for n  3 * 2k
 (4)
(n  2k 1 ) f (2)  (2k  2  n) f (1)  2k  2  2, for n  3 * 2k

where k = log 2 n  1
and thus,

2(n-1) – 2k for n <= 3*2k


f(n)=
n+2k+1 – 2 for n > 3*2k
Performance Comparisons

Table : Performance comparison between the proposed


approach (m1) and previous approach (m2).
Number of elements varies from 1000 to 7000.

No. of No. of No. of Processing


elements recursive calls comparisons f(n) times (sec)
(n)
m1 m2 m1 m2 m1 m2
1000 511 999 1510 1998 3 6
2000 1023 1999 3022 3998 6 12
3000 1975 2999 4974 5998 11 17
4000 2047 3999 6046 7998 12 24
5000 2951 4999 7950 9998 18 30
6000 3951 5999 9950 11998 23 36
7000 4095 6999 11094 13998 24 41
Performance Comparison

The number of comparisons of


the proposed approach is
16000 21.05% lower than that of the
14000
previous approach, which
subsequently less energy
12000 consumption accordingly.
No of comparisons

10000

8000
proposed model
6000
previous model

4000

2000

0
1000 2000 3000 4000 5000 6000 7000

No of elements

Fig. 1. Number of elements versus Number of


comparisons
Other Causes: The Impact from Radiation and Heat/Thermal

 Cell-phone radiation

scenario

We have to reduce the radiation- How?


Thus, every body is responsible
for the world to become ‘green’
and thus ‘healthy’
Thank you
mmustafa@uthm.edu.my

You might also like