blob: bf63a5e69c361886e614233bec15b2e6ddd663cd (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
//clc();
clear;
//To calculate braggs angle for first order of reflection
V=5000; //potential difference in V
n=1;
h=1;
k=1;
l=1;
d=0.204*10^-9; //inter planar spacing in m
H=6.625*10^-34; //plancks constant in J
m=9.1*10^-31;
e=1.6*10^-19;
lambda=H/(sqrt(2*m*e*V));
disp(lambda);
a=(n*lambda)/(2*d);
theta=asind(a);
printf("bragg angle in degrees is");
disp(theta);
|