, P8 = 15.503875968992244
, P6 = 725.503875968992
P7 = 16.83501683501683
, P5 = 828.8350168350166
, V1 = 446.28596771931444
, V4 = 221.7457214540226
, V5 = 224.54024626529184
, P6 = -49589.487176042894
, V2 = -13120051.355446983
, V3 = 331.04302919113536
, K = 13119944.852664057
, P8 = 15.527950310559003
, P6 = 727.5279503105588
P7 = 16.86340640809443
, P5 = 830.8634064080941
, V1 = 446.2836951912896
, V4 = 221.74114772317725
, V5 = 224.54254746811236
, P6 = -49588.4922170614
, V2 = -13119788.115924312
, V3 = 331.0415264238935
, K = 13119681.616945356
, P8 = 15.552099533437008
, P6 = 729.5520995334367
P7 = 16.891891891891888
, P5 = 832.8918918918915
, V1 = 446.28142254423733
, V4 = 221.73657368171834
, V5 = 224.544848862519
, P6 = -49587.4972587996
, V2 = -13119524.876592051
, V3 = 331.04002365091685
, K = 13119418.381417263
, P8 = 15.576323987538936
, P6 = 731.5763239875386
P7 = 16.920473773265645
, P5 = 834.9204737732653
, V1 = 446.2791497776103
, V4 = 221.7319993285289
, V5 = 224.5471504490814
, P6 = -49586.50230102914
, V2 = -13119261.637389787
, V3 = 331.0385208718604
, K = 13119155.146019364
, P8 = 15.600624024960993
, P6 = 733.6006240249607
Bajardi:Ergashev Zuhriddin
Hisoblash dasturi
//---------------------------------------------------------------------------
import math as m
Pn = 100
e = 0.01
p = 1000
g = 10
def Step1(h1g, h1):
P7 = Pn * (h1g/(h1g-h1))
return P7
def Step2(p, g, h1, P7):
P5 = P7 + (p * g * h1)
return P5
def Step3(k1, P1, P5):
V1 = k1 * m.sqrt(abs(P1-P5))
return V1
def Step4(k4, P4, P5):
V4 = k4 * m.sqrt(abs(P5-P4))
return V4
def Step5(V1, V4):
V5 = V1 - V4
return V5
def Step6(V5, k5, P5):
P6 = P5 - m.pow(V5/k5, 2)
return P6
def Step7(k2, P6, P1):
V2 = k2 * m.sqrt(abs(P6-P1))
return V2
def Step8(k3, P3, P6):
V3 = k3 * m.sqrt(abs(P6-P3))
return V3
def Step9(V5, V2, V3):
return V5 - V2 - V3
def Step10(Pn, H2g, H2):
P8 = Pn * (H2g / (H2g - H2))
return P8
def Step11(P8, p, g, H2):
P6 = P8 + (p * g * H2)
return P6
def GetResult(P1, P2, P3, P4, P5, P6, H1g, H2g, H1, H2, K1, K2, K3, K4, K5):
result = dict()
for i in range(0, 10):
step1P7 = Step1(H1g, H1)
step2P5 = Step2(p, g, H1, step1P7)
step3V1 = Step3(K1, P1, step2P5)
step4V4 = Step4(K4, P4, step2P5)
step5V5 = Step5(step3V1, step4V4)
step6P6 = Step6(step5V5, K5, step2P5)
step7V2 = Step7(step6P6, K2, P1)
step8V3 = Step8(K3, P3, step6P6)
step9 = Step9(step5V5, step7V2, step8V3)
step10P8 = Step10(Pn, H2g, H2)
step11P6 = Step11(step10P8, p, g, H2)
print(f"P7 = {step1P7}\n, P5 = {step2P5}\n, V1 = {step3V1}\n, V4 = {step4V4}\n, V5 = {step5}\n, P6 = {step6P6}\n, V2 = {step7V2}\n, V3 = {step8V3}\n, K = {step9}\n, P8 = {step10P8}\n, P6 = {step11P6}")
print("\n")
H1 += E + 0.01
H2 += E + 0.01
v = ["P1", "P2", "P3", "P4", "P5", "H1g", "H2g", "H1", "H2", "K1", "K2", "K3", "K4", "K5"]
params = []
for i in v:
print(i, end="=")
params.append(float(input()))
GetResult(params[0], params[1], params[2], params[3], params[4], params[5], params[6], params[7], params[8], params[9], params[10], params[11], params[12], params[13], params[14])
Do'stlaringiz bilan baham: |