20_pdfsam_2 - The w.d width specifiers are optional If they...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: The w.d width specifiers are optional. If they are left out, default values are used. Examples: >> fprintf(’The temperature is %f degrees F \n’, temp) The temperature is 78.000000 degrees F >> fprintf(’The temperature is %4.1f degrees F \n’, temp) The temperature is 78.0 degrees F It should be noted that fprintf only displays the real part of a complex number, which is an important data type to be discussed later in the course. 2.6 Accuracy and Precision Physical measurements cannot be assumed to be exact. Errors are likely to be present regardless of the precautions used when making the measurement. Quantities determined by analytical means are not always exact either. Often assumptions are made to arrive at an analytical expression that is then used to calculate a numerical value. The use of significant digits provides a method of expressing results and measurements that conveys how “good” these numbers are....
View Full Document

This note was uploaded on 03/07/2010 for the course ENG 101 taught by Professor Chang during the Summer '09 term at 東京国際大学.

Ask a homework question - tutors are online