Sunday, June 3, 2012

(05312012) Computation Model: Pressure vs Depth



One of the goal of this project is to provide a computational model that describes the behavior of our apparatus. In this program I have set up the theoretical depth needed to achieve in order to acquire a pressure of 2 atmosphere.The development is relatively simple as I just implement the equation P = P0 + ρgh into the coding.
 


Figure 1: Pressure versus Depth







// Comment
from pylab import *
import re

x = arange(0,10.3,.01)
y = 1+(9810*x/101325)

plot(x,y)

xlabel('Depth (m)')
ylabel('Pressure (atm)')

"""
title(r'$Pressure Depth$')
"""

title(r'$Pressure(h)$')
"""
k = re.sub(r"(\w)([A-Z])", r"\1 \2", "WordWordWord")
title(r'$re.sub(r"(\w)([A-Z])", r"\1 \2", "WordWordWord")$')
"""



show()

No comments:

Post a Comment