CIS541 - PowerPoint PPT Presentation

1 / 7
About This Presentation
Title:

CIS541

Description:

CIS541 Lab1 Analysis Roger Crawfis ... CIS 541 Numerical Methods Author: Roger Crawfis Last modified by: Roger Crawfis Created Date: 3/29/2002 6:56:30 PM – PowerPoint PPT presentation

Number of Views:51
Avg rating:3.0/5.0
Slides: 8
Provided by: RogerC89
Learn more at: https://cse.osu.edu
Category:

less

Transcript and Presenter's Notes

Title: CIS541


1
CIS541 Lab1 Analysis
  • Roger Crawfis

2
Computers Do As Theyre Told
  • Garbage in Garbage out
  • Most of lifes problems emanate from an
    underlying communication problem.
  • No different with computers
  • You thought you told the computer to do one
    thing. It did another.
  • You thought the input or intended use of your
    system was A. It was given B.

3
Lab1 Results
  • Results were identical to digits shown for Taylor
    series and sin(x). Results for different step
    sizes.

100K 1M 10M 100M
Reimann(sin) -1.0449 10-5 6.9785 10-5 3.7607710-4 -4.194310-3
Value of x at the end of the for loop 0.0998974 0.1007008 0.104126 -0.1
???
4
Lab1 Results
  • Why was the value of x equal to 0.1 at the end
    of the loop?
  • 32-bit floating point accuracy
  • x -0.1 0.00000001 ? -0.1
  • The value of sin(-0.1) -0.09983342, why wasnt
    the result equal to this value as well?

5
Forcing Floating-Point Arithmetic
  • Do you believe the other numbers generated by
    your program?
  • What is the difference between these two
    statements?
  • Sum x // one term of the Taylor Series
  • Sum x(1-xx( 1 / (321) ) )
  • // two terms of the Taylor Series

Absolutely nothing!!!
6
Lab1 Lessons Learned
  • More work is not necessarily better.
  • Do not trust the answers blindly. See if they
    make sense.
  • Computer precision is limited.
  • Round-off errors actually do happen.
  • Sleep is for weenies ?!

7
Lessons Learned
  • Computers have limited capabilities!!!
Write a Comment
User Comments (0)
About PowerShow.com