飽和水蒸気圧 | : | [Pa] | |
飽和水蒸気量 | : | [g/m3] | |
指定湿度における水分量 | : | [g/m3] | |
指定湿度、指定ガス量における水分量 | : | [mg] |
\(飽和水蒸気圧 e(T) [Pa] = 6.1078 \times 10^\frac{7.5T}{T+237.3}\)
\(飽和水蒸気量 aT [g/m^3] = \frac{217 \times e(T)}{T + 273.15}\)
\(T: 温度(℃)\)
<p><label>温度 :</label><input type="Input" id="temperature" value="25"><label> ℃</label></p>
<p><label>湿度 :</label><input type="Input" id="relative_humidity" value="30"><label> %</label></p>
<p><label>気体量 :</label><input type="Input" id="gas_amount" value="1"><label> L </label><button onclick="buttonclick()">Click</button></p>
<table>
<tbody><tr><td>飽和水蒸気圧</td><td>:</td><td><span id="saturated_pressure_out"></span></td><td>[Pa]</td></tr>
<tr><td>飽和水蒸気量</td><td>:</td><td><span id="saturated_amount_out"></span></td><td>[g/m<sup>3</sup>]</td></tr>
<tr><td><span id="humidity_out1">指定湿度</span>における水分量</td><td>:</td><td><span id="watwer_athumidity_out"></span></td><td>[g/m<sup>3</sup>]</td></tr>
<tr><td><span id="humidity_out2">指定湿度</span>、<span id="gas_amount_out">指定ガス量</span>における水分量</td><td>:</td><td><span id="water_athumidity_gas_out"></span></td><td>[mg]</td></tr>
</table>
<script>
function buttonclick(){
let temperature = Number(document.getElementById("temperature").value);
let relative_humidity = Number(document.getElementById("relative_humidity").value);
let gas_amount = Number(document.getElementById("gas_amount").value);
let saturated_pressure_out= document.getElementById("saturated_pressure_out");
let saturated_amount_out = document.getElementById("saturated_amount_out");
let watwer_athumidity_out = document.getElementById("watwer_athumidity_out");
let water_athumidity_gas_out = document.getElementById("water_athumidity_gas_out");
let humidity_out1 = document.getElementById("humidity_out1");
let humidity_out2 = document.getElementById("humidity_out2");
let gas_amount_out = document.getElementById("gas_amount_out");
let eT = 6.1078 * 10**((7.5*temperature)/(temperature+237.3));
let aT = 217 *(eT/(temperature + 273.15))
let water_athumid = aT * relative_humidity / 100
let water_ingas = water_athumid * gas_amount
humidity_out1.innerHTML = relative_humidity + " %";
humidity_out2.innerHTML = relative_humidity + " %";
gas_amount_out.innerHTML = gas_amount + " L";
saturated_pressure_out.innerHTML = Math.round(eT*100)/100;
saturated_amount_out.innerHTML = Math.round(aT*100)/100;
watwer_athumidity_out.innerHTML = Math.round(water_athumid*100)/100
water_athumidity_gas_out.innerHTML = Math.round(water_ingas*100)/100
}
</script>
コメント