#importing modules
import math
from __future__ import division
#Variable declaration
C = 2 #capacitance(micro-farad)
V = 1000 #voltage applied(V)
epsilon_r = 100 #permitivity
#Calculation
C = C*10**-6 #capacitance(farad)
W = (C*V**2)/2 #energy stored in capacitor(J)
C0 = C/epsilon_r #capacitance removing the dielectric
W0 = C0*(V**2)/2 #energy stored without dielectric(J)
E = 1-W0 #energy stored in dielectric(J)
#Result
print "energy stored in capacitor is",W,"J"
print "energy stored in the dielectric is",E,"J"
#importing modules
import math
from __future__ import division
#Variable declaration
epsilon_r = 4.94
n_2 = 2.69 #square of index of refraction
alpha_i = 0 #at optical frequencies
#Calculation
#(epsilon_r-1)/(epsilon_r+2) = N*(alpha_e+alpha_i)/(3*epsilon0)
X = (epsilon_r-1)/(epsilon_r+2)
#epsilon_r = n**2. therefore (n**2-1)/(n**2+2) = N*alpha_e/(3*epsilon0)
Y = (n_2-1)/(n_2+2)
#N*(alpha_e+alpha_i)/N*alpha_e = X/Y
#let alpha = alpha_i/alpha_e
alphai_e = (X/Y)-1 #ratio between electronic ionic and electronic polarizability
alphai_e = math.ceil(alphai_e*10**4)/10**4 #rounding off to 4 decimals
alphae_i = 1/alphai_e #ratio between electronic and ionic polarizability
alphae_i = math.ceil(alphae_i*10**3)/10**3 #rounding off to 3 decimals
#Result
print "ratio between electronic ionic and electronic polarizability is",alphai_e
print "ratio between electronic and ionic polarizability is",alphae_i
#importing modules
import math
from __future__ import division
#Variable declaration
epsilon_r = 2.56
tan_delta = 0.7*10**-4
f = 1 #frequency(MHz)
A = 8 #area(cm**2)
d = 0.08 #diameter(mm)
epsilon0 = 8.85*10**-12
#Calculation
A = A*10**-4 #area(m**2)
d = d*10**-3 #diameter(m)
epsilon_rdash = epsilon_r*tan_delta
omega = 2*math.pi*10**6
Rp = d/(omega*epsilon0*epsilon_rdash*A) #parallel loss resistance(ohm)
Rp = Rp*10**-6 #parallel loss resistance(Mega ohm)
Rp = math.ceil(Rp*10**3)/10**3 #rounding off to 3 decimals
Cp = A*epsilon0*epsilon_r/d #capacitance(farad)
#Result
print "parallel loss resistance is",Rp,"ohm"
print "capacitance in Farad is",Cp,"Farad"
#importing modules
import math
from __future__ import division
#Variable declaration
N = 3*10**28 #density(atoms/m**3)
alpha_e = 10**-40 #electronic polarizability(Farad-m**2)
epsilon0 = 8.854*10**-12
#Calculation
epsilon_r = 1+(N*alpha_e/epsilon0) #dielectric constant of material
epsilon_r = math.ceil(epsilon_r*10**3)/10**3 #rounding off to 3 decimals
#Result
print "dielectric constant of material is",epsilon_r
#importing modules
import math
from __future__ import division
#Variable declaration
epsilon0 = 8.854*10**-12
epsilon_r = 1.0000684 #dielectric constant
N = 2.7*10**25 #density(atoms/m**3)
#Calculation
alpha_e = epsilon0*(epsilon_r-1)/N #electronic polarizability(Fm**2)
#Result
print "electronic polarizability is",round(alpha_e/1e-41,3),"*10^-41 Fm**2"
#importing modules
import math
from __future__ import division
#Variable declaration
epsilon0 = 8.85*10**-12
V = 100 #potential(V)
A = 100 #area(cm**2)
d = 1 #plate seperation(cm)
#Calculation
A = A*10**-4 #area(m**2)
d = d*10**-2 #plate seperation(m)
C = epsilon0*A/d #capacitance(farad)
Q = C*V #charge on plates
#Result
print "capacitance of capacitor is",C,"F"
print "charge on plates in coulomb is",Q,"coulomb"
#importing modules
import math
from __future__ import division
#Variable declaration
N = 6.02*10**26 #avagadro number
d = 2050 #density(kg/m**3)
AW = 32 #atomic weight of sulphur
epsilon_r = 3.75 #relative dielectric constant
epsilon0 = 8.55*10**-12
#Calculation
n = N*d/AW #number of atoms(per m**3)
alpha_e = ((epsilon_r-1)/(epsilon_r+2))*3*epsilon0/n #electronic polarizability(Fm**2)
#Result
print "electronic polarizability is",round(alpha_e/1e-40,3),"*10^-40 Fm**2"
#importing modules
import math
from __future__ import division
#Variable declaration
Q = 2*10**-10 #charge(coulomb)
d = 4 #plate seperation(mm)
epsilon_r = 3.5 #dielectric constant
A = 650 #area(mm**2)
epsilon0 = 8.85*10**-12
#Calculation
d = d*10**-3 #plate seperation(m)
A = A*10**-6 #area(m**2)
V = Q*d/(epsilon0*epsilon_r*A) #voltage across capacitors(V)
V = math.ceil(V*10**3)/10**3 #rounding off to 3 decimals
#Result
print "resultant voltage across capacitors is",V,"V"
#importing modules
import math
from __future__ import division
#Variable declaration
V = 10 #potential(V)
d = 2*10**-3 #plate seperation(m)
epsilon_r = 6
epsilon0 = 8.85*10**-12
#Calculation
E = V/d #electric field(V/m)
D = epsilon0*epsilon_r*E #dielectric displacement(C/m**2)
#Result
print "dielectric displacement is",D,"Cm^-2"