M150: Data, Computing and Information - PowerPoint PPT Presentation

1 / 29
About This Presentation
Title:

M150: Data, Computing and Information

Description:

If you want to reduce a picture to numbers, you must divide it into discrete ... The Navier-Stokes equations which relate the movement of air, to the earth's ... – PowerPoint PPT presentation

Number of Views:57
Avg rating:3.0/5.0
Slides: 30
Provided by: nouhadam
Category:

less

Transcript and Presenter's Notes

Title: M150: Data, Computing and Information


1
M150 Data, Computing and Information
Unit Three Crossing the boundary analogue
universe, digital world
2
4- Crossing the boundary
  • Images
  • If you want to reduce a picture to numbers, you
    must divide it into discrete parts (squares) and
    then transform the result into numbers.
  • Take an image.
  • Put a border.
  • Divide it into a grid of equal sized squares.

3
4- Crossing the boundary
  • If the square is entirely grey make it white.
  • If the square is entirely colored (mauve) make it
    black.
  • If the square contains both grey and color and if
    more than the third of the square is mauve then
    it will become black otherwise it will become
    white.

4
4- Crossing the boundary
  • In the resulting image, assign the number 0 if
    the color is white and 1 if the color is black.
  • We obtain a binary image, each mapped square is
    called pixel (picture element), such image
    transformation is called bitmap encoding (each
    number is only
  • either 0 or 1, and computers use bits
  • to store 0s and 1s)
  • A pixel is a short for picture element
  • (square) that we have mapped to 0 or 1.
  • To improve the quality of the image,
  • you must increase the number of
  • the squares (pixels) and make
  • each square smaller

5
4- Crossing the boundary
  • Resolution
  • Depends on the number and the size of the pixels
  • If we go on and on increasing the resolution of
    the picture, making the pixel size smaller and
    smaller, we will move closer and closer to an
    image that appears completely smooth.
  • We can never reach a perfectly smooth image by
    this process to do this one would need
    infinitely small pixels.
  • We can never reach an analogue representation by
    digital means, only approximate to it.

6
4- Crossing the boundary
  • One bit was allocated to each pixel in the image,
    0 or 1, either black or white (no way of handling
    color).
  • Allocating more bits to each pixel will result in
    shades between black and white.
  • 2 bits will result in 11 black, 00 white, 01
    light gray, and 10 dark gray.
  • Three bits per pixel will give us (23) eight
    shades, from black to white four bits per pixel
    gives us (24) 16 shades and so on.
  • A mapping of shades of grey between black and
    white in a black and white bitmap is known as
    grayscale.
  • The range of numbers to which a pixel can be
    mapped is termed the pixel amplitude

7
4- Crossing the boundary
  • Color is an example of an analogue property.
  • We are trying to map infinite number of colors to
    a finite number
  • Colors are represented in a different way.
  • Any color can be made out of a mixture of three
    basic shades Red, Green and Blue (R, G, B). ? RGB
    model
  • Each shade is represented by a byte (8 bits),
    giving values ranging from 0 to 255.
  • As a total we have 256 x 256 x 256 shades of
    color (16,777,216)
  • Red is (255, 0, 0) since it is all Red and 0
    Green and 0 Blue.
  • Green is (0, 255, 0).
  • Blue is (0, 0, 255).
  • White is (255, 255, 255), all the color spectrum.
  • Black is (0, 0, 0), no color what so ever.

8
4- Crossing the boundary
  • When dealing with images, sometimes large amounts
    of memory are required.
  • Two important models
  • RGB model
  • The primary colors are red, green and blue.
  • CMYK model (other model)
  • The primary colors that are reflected off paper
    are not red, green and blue but cyan
    (blue-green), magenta and yellow.
  • The K stands for a special black ink used to add
    crispness.

9
4- Crossing the boundary
  • Interlude diagrams
  • Some types of visual information can be
    represented more economically than in a bitmap
    (less waste of memory).
  • The huge majority of the pixels will just be
    white, the background to the picture. The only
    information all these white pixels give us is the
    simple fact that the background color is white.
  • To reconstruct the diagram we need information
    about what sort of object it is (line, square),
    the size, the position and the color of them
  • Shapes, line thickness, coordinates, all have
    their numerical representations in a computer.

10
4- Crossing the boundary
  • First assign a number to each type of object
    (rectangle, circle, arrow, line and the text).
  • Second record the size and position (Cartesian
    coordinates x, y axes) of each object.
  • Third Identify the color.
  • Finally put all information together and produce
    a final set of numbers
  • A circle is defined by its radius and the
    coordinates of its center.
  • A rectangle by the coordinates of its upper left
    and lower right corners.
  • Lines and arrows by their starting and ending
    points.
  • The text area by the coordinates of its top left
    corner

11
4- Crossing the boundary
  • Vector graphics
  • The way (sort) of encoding of visual information.
  • Opposed to the bitmap approach (raster graphics)
  • Advantages of vector graphics
  • Very compact form of encoding.
  • The resulting image is scalable we can easily
    shrink or stretch the size of it without any loss
    of information.
  • Disadvantages of vector graphics
  • Works with fairly simple images
  • Need complex program to interpret the number and
    display them as diagram
  • Drawing packages the programs that allow us to
    draw and display vector graphics
  • Painting packages the systems for constructing
    and displaying raster graphics (bitmap)

12
4- Crossing the boundary
  • Several formats exist for image digitizing,
    depending on the allowed loss of precision (ex
    bmp, png, jpg, gif, etc)
  • Making image move
  • A Video or a movie, is a series of images that
    slightly differ one from another, passing them
    one after the other at a certain speed will give
    the illusion of movement.
  • A picture would be called a frame.
  • The speed of flipping the frames one after the
    other is called frame rate (fps).
  • Transferring such an enormous amount of digital
    information over a network would be slow.

13
4- Crossing the boundary
  • We have to find some way of reducing the amount
    of storage that moving images need. The vector
    graphics approach will not work for complex
    image, so we must look for a way of compressing
    bitmapped visual information.
  • There are many standards for image and film
    compression.
  • Standards for image compression
  • JPEG (Joint Photographic Experts Group)
  • GIF (Graphics Interchange Format) standards.
  • (Both standards reduce the number of bits used to
    store each pixel)
  • For video, the dominant standard is MPEG (Moving
    Picture Experts Group), which is now used in most
    digital camcorders.

14
4- Crossing the boundary
  • Image and video capture devices
  • Scanner, digital cameras and camcorders are the
    main devices used for transforming images and
    video into digital form inside the computer.
  • Digital still camera and camcorders
  • Widely and cheaply available
  • No film, contains removable memory card
  • Get a compressed digital image (usually JPEG
    format)
  • Camcorder record in MPEG format (store on tape)
  • Both devices works by means of an electronic
    chips called a charge-coupled device (CCD)
  • A CCD is basically an array of tiny cells, that
    respond to light by generating a tiny electric
    charge (the amount of charge depends on the
    intensity and color)

15
4- Crossing the boundary
  • Scanner
  • Making a digital image of the page and then
    passing this image to an OCR system to
    distinguish the various characters.
  • A scanner works by moving a sensing point rapidly
    across the image, in a series of lines.
  • The scanner measures the brightness (luminance)
    and the coloring (chrominance) of a series of
    points along each line.
  • The quality of the resulting bitmap will depend
    on the number of lines the scanner follows across
    the specimen, and the number of measurement
    points along each line.
  • Most scanners come with software that will
    compress the bitmap into a number of formats,
    including JPEG and GIF.

16
4- Crossing the boundary
  • Sound and music
  • Hearing is the second most relied on sense for a
    human being (another analogue feature of the
    world).
  • A sound consists of a waveform (tuning fork
    instrument).
  • Displacement how far an air moves backwards and
    forwards
  • Cycle (wave or period) represent the time
    between adjacent peaks ( or trough)
  • Frequency the number of
  • cycles completed in a fixed time
  • (decide how low or high pitched
  • the note sounds)
  • Amplitude maximum displacement
  • (how loud the sound is)

17
4- Crossing the boundary
  • In order to digitize a sound waveform, we take
    samples of the sound at small time intervals,
    such a process is called sampling
  • The number of times/second we take a sample is
    called the sampling rate.
  • The smaller the interval the better.
  • We can never make a perfect digital
    representation of an analogue quantity.

18
4- Crossing the boundary
  • It is impossible to make a perfect digital coding
    of an analogue picture, because we will always
    lose information between the pixels, so we will
    always lose information between the times we
    sample a waveform.
  • The process of digitizing a sound consists into
    sampling it and then associating a number to each
    sample (quantization).
  • The smaller the interval of taking the samples,
    the more accurate our representation of the
    analogue sound will be.
  • Smaller intervals will mean, more samples and
    therefore more bits to quantize them, which means
    more storage space.
  • Sound waves samples are generally mapped to
    16-bits.
  • Several formats exist for sound digitizing,
    depending on the allowed loss of precision (ex
    mp3, wav, mid, etc).
  • Sound capture devices microphone

19
5- Going back
  • Semantics the meaning attached to words and
    symbols.
  • When we take image, video and sound across the
    boundary (digitized and stored on the computer),
    they are stripped of their meaning. They just
    become numbers, their human associations lost.
  • If their meaning is to be regained, they must be
    transported back from the digital to the human
    world
  • If we need to view an image or replay a sound we
    need some output devices.

20
5- Going back
  • Regaining meaning
  • Machine on which image is stored will have to get
    the image back to us by means of a device that
    can render it into a form meaningful to the human
    eye (output device)
  • The process of sending a digital representation
    back across the boundary, consists of three
    stages
  • Identifying the suitable output device (depends
    on the user for example screen or printer)
  • Arrange the numbers into a form suitable for the
    output device (sometime it is a very complex
    especially in cases where the information has
    been compressed).
  • Interpret the code by the output device (carried
    out by specialized electronics in the output
    devices).

21
5- Going back
  • For the second stage (Arranging the numbers )
  • The digital world can only be manipulated from
    inside by other digital things. In this case, the
    necessary arrangements are made by a special
    class of digital encoding a program.
  • A program is a set of binary words (a word is a
    group of four bytes)
  • Each word of the program has a special
    significance to the machines central processor
    it stands for an instruction.
  • When a computers central processor reads one of
    these words it carries out the instruction that
    the word stands for.
  • The digital representations mean nothing in
    themselves.

22
5- Going back
  • Types of output devices
  • Monitors
  • All computers are supplied complete with a
    monitor which opens a window onto the machines
    digital world.
  • There are two main types of monitor
  • The CRT (cathode ray tube) A CRT monitor looks
    like a television screen, and works in a similar
    way to a TV or a scanner. A beam of electrons is
    fired from a gun at the back of the tube onto a
    glass screen on the front. The beam sweeps across
    this screen in the same raster scanning pattern.
    The front of the tube is coated in a
    phosphorescent material that glows as the
    electron beam hits it.
  • LCD (liquid crystal display) flat (they have no
    electronic gun) works on the principle of passing
    light through a special material. The molecules
    change orientation when an electrical voltage is
    applied to them
  • The CRT monitors have color accuracy.
  • The LCD monitors use less power, takes up little
    space and does not flicker.

23
5- Going back
  • The resolution actually displayed on the screen
    is not decided by the monitor itself, but by the
    program that prepares the digital encodings for
    display.
  • Printers
  • Inkjet, work by firing tiny droplets of liquid
    ink at the paper.
  • Can print in both color and black and white.
  • Color cartridge use color model (CMYK).
  • Cheap but ink cartridges are expensive.
  • Laser, work by firing a laser beam and burning
    powder ink on paper.
  • Produce very high quality.
  • Color lasers are available but expensive.

24
5- Going back
  • Plotters
  • A plotter is a special type of printing device
    mostly used by architects, engineers and map
    makers.
  • Printed output is produced by moving a pen
    across the paper.
  • Suitable for line drawings.
  • In contrast with monitors and printers they
    produce an analogue output directly.
  • Loudspeakers
  • Produce an analogue output (sound).
  • The audio program inside the boundary converts
    the digital encoding of the sound to a series of
    electrical pulses that are sent to the speaker.

25
6- What if? changing the digital world
  • Using appropriate software, computers will help
    you simulate what happens in the real world.
  • We can create digital models of natural phenomena
    and then write programs to manipulate them
  • Simulations help us study problems through models
  • (Example the earths climate).
  • Computer scientists will create a model, a
    simplification including only features directly
    affecting the system being modeled (abstraction).

26
6- What if? changing the digital world
  • The climate model
  • The weather is created by the interaction of
    earths atmosphere with the land, the oceans and
    the energy of the sun.
  • The air pressure, temperature, humidity, wind
    speed, and so on are the key factors.
  • The GCM (General Circulation Model) is an
    atmospheric model.
  • The earths surface is split into a rectangular
    grids.
  • Each rectangle is divided into layers splitting
    the atmosphere into 3-D boxes.
  • Each box contains a sample number of points
    (sampling) where temperature, pressure, humidity,
    wind speed, and other features are recorded
    (quantization).

27
6- What if? changing the digital world
  • The climate model needs to follow certain laws in
    order to be accurate
  • The Navier-Stokes equations which relate the
    movement of air, to the earths rotation,
    friction and pressure.
  • The thermodynamic equation which relates in
    temperature variations to heat from the sun,
    condensation, and from other sources.
  • The laws describe how things change in relation
    to one another over time how air flows, how
    things warm up and cool, how matter clumps
    together. Now, if we write and run a program that
    applies the laws to the model, we can show how
    things will change as time goes on (predicate the
    future)

28
6- What if? changing the digital world
  • Simulated prediction of weather patterns

29
6- What if? changing the digital world
  • Imaginary worlds
  • Human imagination associated with appropriate
    software will allow the creation virtual worlds
    in computer memory.
  • AlphaWorld
  • Does not exist in space (purely digital world)
  • It is a virtual world where a virtual is a term
    used to describe any entity that does not really
    exist, but is simulated by the action of a
    computer.
  • AlphaWorld is open to anyone who has an internet
    connection.
  • I can select or create a digital representative
    of myself, called an avatar, a word now used to
    refer to all sorts of digital being or agent, and
    send that into AlphaWorld.
Write a Comment
User Comments (0)
About PowerShow.com