From b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b Mon Sep 17 00:00:00 2001 From: priyanka Date: Wed, 24 Jun 2015 15:03:17 +0530 Subject: initial commit / add all books --- 1646/CH3/EX3.6/Ch03Ex6.sce | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100755 1646/CH3/EX3.6/Ch03Ex6.sce (limited to '1646/CH3/EX3.6') diff --git a/1646/CH3/EX3.6/Ch03Ex6.sce b/1646/CH3/EX3.6/Ch03Ex6.sce new file mode 100755 index 000000000..7e00280bf --- /dev/null +++ b/1646/CH3/EX3.6/Ch03Ex6.sce @@ -0,0 +1,15 @@ +// Scilab Code Ex3.6: Page:135 (2011) +clc;clear; +g1 = 4; // Intrinsic probability of first cell +g2 = 2; // Intrinsic probability of second cell +k = 2; // Number of cells +n = 8; // Number of distinguishable particles +n1 = 8; // Number of cells in first compartment +n2 = n - n1; // Number of cells in second compartment +W = factorial(n)*1/factorial(n1)*1/factorial(n2)*(g1)^n1*(g2)^n2; +printf("\nThe thermodynamic probability of the macrostate (8,0) = %5d", W); + +// Result +// The thermodynamic probability of the macrostate (8,0) = 65536 + + -- cgit