#Electric Drives:concepts and applications by V.subrahmanyam
#Example:5.1
import math
theta1=60;#Temperature rise of motor in degree
theta2=40.0;#Temperature rise of motor in degree
e=0.5;#exponential value
I1=110.0;#current in A
I2=125;#current in A
t1=4;#Time in hour
t2=8;#Time in hour
theta=theta1/theta2;
tough=-(1/math.log(0.5));
thetam1=theta2/e;
thetam2=thetam1*(I2/I1)**2;
x=t1/(theta1*tough);
a=math.e**-x;
y=t2/(theta1*tough);
b=math.e**-y;
thetam=I2*((1-a)/(1-(a*b)));
print thetam," is The final temperature in deg"
#Electric Drives:concepts and applications by V.subrahmanyam
#Publisher:Tata McGraw-Hill
#Edition:Second
#Ex5_2
import math
T=100.0;#Temperature rise of motor in degree
t1=2;#Time in hour
t2=1.5;#Time in hour
Alpha=0.5;#Angle in rad
e=math.e**(-t1/t2);
thetam=100.0/(1-e);
t=thetam/T;
x=math.sqrt((t*(Alpha+1))-Alpha);
print x," is The permissible overloading "
#Electric Drives:concepts and applications by V.subrahmanyam
#Publisher:Tata McGraw-Hill
#Edition:Second
#Ex5_3
import math
Alpha=0.4;#Angle in rad
T1=100;#Temperature rise of motor in degree
T2=150.0;#Temperature rise of motor in degree
P=125.0;#Power in KW
t1=15;#Time in hour
t2=30.0;#Time in hour
x=-t1/T1;
a=math.e**x;
y=-t2/T2;
b=math.e**y;
p=math.sqrt(((Alpha+1)*(1-(a*b)))/(1-a)-Alpha);
print p,"is The permissible overloading of the motor "