# 0.15 Lab 10a - image processing (part 1)  (Page 2/5)

 Page 2 / 5

image(B);

colormap(gray(256));

axis('image');

The image command works for both type uint8 and double images. The colormap command specifies the range of displayed gray levels, assigning black to 0 and white to 255.It is important to note that if any pixel values are outside the range 0 to 255 (after processing), they will be clipped to 0 or 255 respectivelyin the displayed image. It is also important to note that a floating point pixel value will berounded down ("floored") to an integer before it is displayed. Therefore the maximum number of gray levels that will be displayed onthe monitor is 255, even if the image values take on a continuous range.

Now we will practice some simple operations on the yacht.tif image. Make a horizontally flipped version of the image by reversing theorder of each column. Similarly, create a vertically flipped image. Print your results.

Now, create a "negative" of the image by subtracting each pixel from 255 (here's an example of where conversion to double is necessary.) Print the result.

Finally, multiply each pixel of the original image by $1.5$ , and print the result.

## Inlab report

1. Hand in two flipped images.
2. Hand in the negative image.
3. Hand in the image multiplied by factor of 1.5. What effect did this have?

## Histogram of an image

The histogram of a digital image shows how its pixel intensities are distributed. The pixel intensities vary along the horizontal axis,and the number of pixels at each intensity is plotted vertically, usually as a bar graph.A typical histogram of an 8-bit image is shown in [link] .

Write a simple Matlab function Hist(A) which will plot the histogram of image matrix $A$ . You may use Matlab's hist function, however that function requires a vector as input.An example of using hist to plot a histogram of a matrix would be

x=reshape(A,1,M*N);

hist(x,0:255);

where $A$ is an image, and $M$ and $N$ are the number of rows and columns in $A$ . The reshape command is creating a row vector out of the image matrix, and the hist command plots a histogram with bins centered at $\left[0:255\right]$ .

Download the image file house.tif , and read it into Matlab.Test your Hist function on the image. Label the axes of the histogram and give it a title.

Hand in your labeled histogram. Comment on the distribution of the pixel intensities.

## Pointwise transformations

A pointwise transformation is a function that maps pixels from one intensity to another.An example is shown in [link] . The horizontal axis shows all possible intensitiesof the original image, and the vertical axis shows the intensities of the transformed image. This particular transformation maps the"darker" pixels in the range $\left[0,{T}_{1}\right]$ to a level of zero (black), and similarly maps the "lighter" pixels in $\left[{T}_{2},255\right]$ to white. Then the pixels in the range $\left[{T}_{1},{T}_{2}\right]$ are "stretched out" to use the full scale of $\left[0,255\right]$ . This can have the effect of increasing the contrast in an image.

Pointwise transformations will obviously affect the pixel distribution, hence they will change the shape of the histogram.If a pixel transformation can be described by a one-to-one function, $y=f\left(x\right)$ , then it can be shown that the input and output histograms are approximately related by the following:

what does nano mean?
nano basically means 10^(-9). nanometer is a unit to measure length.
Bharti
do you think it's worthwhile in the long term to study the effects and possibilities of nanotechnology on viral treatment?
absolutely yes
Daniel
how to know photocatalytic properties of tio2 nanoparticles...what to do now
it is a goid question and i want to know the answer as well
Maciej
Abigail
for teaching engĺish at school how nano technology help us
Anassong
Do somebody tell me a best nano engineering book for beginners?
what is fullerene does it is used to make bukky balls
are you nano engineer ?
s.
fullerene is a bucky ball aka Carbon 60 molecule. It was name by the architect Fuller. He design the geodesic dome. it resembles a soccer ball.
Tarell
what is the actual application of fullerenes nowadays?
Damian
That is a great question Damian. best way to answer that question is to Google it. there are hundreds of applications for buck minister fullerenes, from medical to aerospace. you can also find plenty of research papers that will give you great detail on the potential applications of fullerenes.
Tarell
what is the Synthesis, properties,and applications of carbon nano chemistry
Mostly, they use nano carbon for electronics and for materials to be strengthened.
Virgil
is Bucky paper clear?
CYNTHIA
so some one know about replacing silicon atom with phosphorous in semiconductors device?
Yeah, it is a pain to say the least. You basically have to heat the substarte up to around 1000 degrees celcius then pass phosphene gas over top of it, which is explosive and toxic by the way, under very low pressure.
Harper
Do you know which machine is used to that process?
s.
how to fabricate graphene ink ?
for screen printed electrodes ?
SUYASH
What is lattice structure?
of graphene you mean?
Ebrahim
or in general
Ebrahim
in general
s.
Graphene has a hexagonal structure
tahir
On having this app for quite a bit time, Haven't realised there's a chat room in it.
Cied
what is biological synthesis of nanoparticles
what's the easiest and fastest way to the synthesize AgNP?
China
Cied
types of nano material
I start with an easy one. carbon nanotubes woven into a long filament like a string
Porter
many many of nanotubes
Porter
what is the k.e before it land
Yasmin
what is the function of carbon nanotubes?
Cesar
I'm interested in nanotube
Uday
what is nanomaterials​ and their applications of sensors.
what is nano technology
what is system testing?
preparation of nanomaterial
how to synthesize TiO2 nanoparticles by chemical methods
Zubear
what's the program
Jordan
?
Jordan
what chemical
Jordan
how did you get the value of 2000N.What calculations are needed to arrive at it
Privacy Information Security Software Version 1.1a
Good
Got questions? Join the online conversation and get instant answers!