上面的压缩性是使用公式计算的图(一样维基百科的文章),我包括代码复制的结果。:
T = 2:1:30;P = 0:10:1000;S = 35;i = 1:长度为j = 1 (T):长度(P)洞穴(i, j) = sw_dens (S, T (i), P (j));dens15 (i, j) = sw_dens (15 T (i), P (j));dens0 (i, j) = sw_dens (0, T (i), P (j));结束结束spvo = 1. /洞穴;spvo15 = 1. / dens15;spvo0 = 1. / dens0;i = 1:长度为j = 1 (T):长度(P) -1% Ev2 (i, j) = - (1. / spvo (i, j)) * (spvo (i, j + 1) -spvo (i, j)。/ (P (j + 1) - P (j)); Ev35(i,j)=(1-spvo(i,j+1)/spvo(i,j))/(P(j+1)-P(j)); Ev15(i,j)=(1-spvo15(i,j+1)/spvo15(i,j))/(P(j+1)-P(j)); Ev0(i,j)=(1-spvo0(i,j+1)/spvo0(i,j))/(P(j+1)-P(j)); end end figure(1);clf for j=[1,20,100] line(T,Ev35(:,j),'Color','k','LineWidth',2); line(T,Ev15(:,j),'Color','b','LineWidth',2); line(T,Ev0(:,j),'Color','r','LineWidth',2);axtt end text(T(20),Ev35(20,1),['P=',num2str(P(2)),'dbar']) text(T(20),Ev35(20,20)*.99,['P=',num2str(P(21)),'dbar']) text(T(20),Ev35(20,100)*.98,['P=',num2str(P(101)),'dbar']) text(T(15),Ev0(15,1),['P=',num2str(P(2)),'dbar'],'Color','r') text(T(15),Ev0(15,20)*.99,['P=',num2str(P(21)),'dbar'],'Color','r') text(T(15),Ev0(15,100)*.99,['P=',num2str(P(101)),'dbar'],'Color','r') xlabel('Temperature (degC) ') ylabel('Compressibility (1/dbar) ') legend('35 PSU','15 PSU','0 PSU') text(7,5e-6,'美元c_w = - {1 \ / V} ({dV \ / dp})美元”、“翻译”、“乳胶”、“字形大小的,20日FontWeight”、“大胆”)