html
html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
<!--New update
1)Alignment of input boxes
2)Fixed digit
3)Input name
4)BP problem solve-->
<!DOCTYPE html>
<html>
<head>
<title>Heat Balance Sheet</title>
<h1>Heat Balance Sheet</h1>
<p> - Made by @Lalit_sp</p>
<h2>-Input-</h2>
<h5>*All input mandatory</h5>
</head>
<body>
Duration of trial :
<input type="number" id="dot" placeholder="(min)" oninput="dot"><br />
Mass of fuel consumed :
<input type="number" id="mof" placeholder="(ltr)" oninput="mof"><br />
CV of fuel :
<input type="number" id="cvof" placeholder="(kJ/kg)" oninput="cvof"><br />
Sp. gravity of fuel :
<input type="number" id="sgof" placeholder="" oninput="sgof"><br />
<button onclick="show_qs()">Qs</button><br />
Speed of engine :
<input type="number" id="rpm" placeholder="(rpm)" oninput="rpm"><br />
Diameter of break drum :
Enter to Rename, Shift+Enter to Preview
css
css
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
h1 {
Text-align:center;
text-shadow: 5px 10px 2px #93968f, -3px 6px 5px #58d1e3;
}
h2 {
Text-align:center;
}
p {
Text-align:right;
Margin-top:3px;
}
h5 {
Text-align:right;
color: red;
}
input {
float:right;
}
Enter to Rename, Shift+Enter to Preview
js
js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
function show_bp(){
var d = document.getElementById("dobd").value;
var n = document.getElementById("rpm").value;
var w = document.getElementById("bl").value;
var s = document.getElementById("sbr").value;
document.getElementById("ans2").innerHTML = ("1.Heat equivalent to BP = " + ((2 * 3.14 * (w-s) * n * (d/2))/1000) +" kJ/min");
}
function show_qs(){
var t = document.getElementById("dot").value;
var mf = document.getElementById("mof").value;
var cv = document.getElementById("cvof").value;
var sp = document.getElementById("sgof").value;
document.getElementById("ans1").innerHTML =("* Heat Supplied = " + ((mf*sp/t)*cv).toFixed(2) + " kJ/min");
}
function show_hw(){
var mw = document.getElementById("mow").value;
var dtw = document.getElementById("dtw").value;
var cpw = 4.187;
document.getElementById("ans3").innerHTML =("2.Heat Rejected to cooling water = " + (mw * cpw * dtw).toFixed(2) + " kJ/min");
}
function show_heg(){
var au = document.getElementById("au").value;
var cpeg = document.getElementById("cpeg").value;
var teg = document.getElementById("teg").value;
var cv = document.getElementById("cvof").value;
Enter to Rename, Shift+Enter to Preview
BROWSER
Console
Run