blob: 71feff981a2648f7e4b8f1613f19d3d06db3a64a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
clear
//Given
q=1*10**-6// charges C
a=2*10**-2// seperation distance m
E=10**5 // electric field N
//Calculation
p=q*a // finding potential
W=2*p*E// total work done
//Result
printf("\n Work done in the rotation is %0.3f *10**-3 J", W*10**3)
|