blob: 7797115bcc6ff00d9866d16d923a0235af98bc0c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
clc
//Variable declaration
a=3.615
r=1.278
h=1
k=1
l=1
//Calculations
a=(4*r)/sqrt(2)
d=a/(sqrt(h**2+k**2+l**2))
//Result
printf('a =%0.3fAngstroms\n',(a))
printf('d =%0.3fAngstroms\n',(d))
|