practical02_sol

# practical02_sol - Practical Session 2 — Solutions...

This preview shows pages 1–2. Sign up to view the full content.

This preview has intentionally blurred sections. Sign up to view the full version.

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

Unformatted text preview: Practical Session 2 — Solutions Exercises 1. The machine accuracy is between 10- 8 and 10- 7 — it is actually 2- 24 ≈ 5 . 96 × 10- 8 , so to two digits 6 . × 10- 8 . Here’s a suitable code. / * machine_acc.c * Program to determine the machine accuracy, i.e. the smallest number * that can be added to one to give a number different from one. * / #include <stdio.h> int main() { float eps; float x; printf("Test value of eps: "); scanf("%f", &eps); x = 1.0 + eps; if (x == 1.0) printf("1.0+%g = 1.0\n", eps); else printf("1.0+%g != 1.0\n", eps); return 0; } 2. (a) You need to solve x 2 + K a x- K a = 0 , where K a = 1 . 76 × 10- 5 . The solution required is the positive root, which is about 4 . 2 × 10- 3 , so the percentage ionisation is about 0.42%. (b) The pH is about 2.4. (c) You need to solve x 2 = K a , which gives x ≈ 4 . 195 × 10- 3 M , compared with 4 . 186 × 10- 3 M in (a), so they differ by about 0.2%....
View Full Document

## This note was uploaded on 09/29/2009 for the course COSC 1002 taught by Professor Wheatland during the Three '09 term at University of Sydney.

### Page1 / 2

practical02_sol - Practical Session 2 — Solutions...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online