Skip to content

Commit fbd486e

Browse files
authored
Update index.html
Spacing and calculator script
1 parent 6aedea1 commit fbd486e

File tree

1 file changed

+8
-11
lines changed

1 file changed

+8
-11
lines changed

index.html

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1847,7 +1847,6 @@ <h3 itemprop="name" style="margin:7px">Area of a regular Polygon</h3>
18471847
</math>
18481848
</div>
18491849
<br>
1850-
<br>
18511850
<div itemprop="mathExpression">
18521851
<math style="margin:12px" xmlns="http://www.w3.org/1998/Math/MathML">
18531852
<mrow>
@@ -2518,7 +2517,6 @@ <h3 itemprop="name" style="margin:7px">Area of a Circle</h3>
25182517
</section>
25192518
<p style="margin:12px" itemprop="description">The area of both the square and the sum of the quadrants equals 16 right triangles with legs of a quarter, and a half of the square's sides, and its hypotenuse equal to the radius of the circle.</p>
25202519
<br>
2521-
<br>
25222520
<div style="margin:12px" itemprop="mathExpression">
25232521
<math xmlns="http://www.w3.org/1998/Math/MathML">
25242522
<mrow>
@@ -3102,7 +3100,6 @@ <h4>A Rational Alternative: 3.2</h4>
31023100
<p style="margin:12px" itemprop="description">The length of the circumference approaches 6.4 × radius as its thickness approaches 0.
31033101
</p>
31043102
<br>
3105-
<br>
31063103
<div style="margin:12px" itemprop="mathExpression">
31073104
<math xmlns="http://www.w3.org/1998/Math/MathML">
31083105
<mrow>
@@ -3117,7 +3114,6 @@ <h4>A Rational Alternative: 3.2</h4>
31173114
<br>
31183115
<p style="margin:12px" itemprop="description">In calculus terms:</p>
31193116
<br>
3120-
<br>
31213117
<div itemprop="mathExpression" style="margin:12px">
31223118
<math xmlns="http://www.w3.org/1998/Math/MathML">
31233119
<mrow>
@@ -3279,6 +3275,9 @@ <h3 itemprop="name" style="margin:7px">Area of a Circle Segment</h3>
32793275
<br>
32803276
<label for="segment-height">Height:</label>
32813277
<input id="segment-height" type="number" value="1" step="any">
3278+
<br>
3279+
<label for="segment-parent-radius">Radius:</label>
3280+
<input id="segment-parent-radius" type="number" value="1" step="any">
32823281
<script>
32833282
function segmentArea(length, height, angle, radius) {
32843283
return angle * radius ** 2 - (radius - height) * length / 2;
@@ -3287,7 +3286,8 @@ <h3 itemprop="name" style="margin:7px">Area of a Circle Segment</h3>
32873286
function updateSegmentArea() {
32883287
const length = parseFloat(document.getElementById('segment-length').value);
32893288
const height = parseFloat(document.getElementById('segment-height').value);
3290-
3289+
const radius = parseFloat(document.getElementById('segment-parent-radius').value);
3290+
32913291
if (isNaN(length) || isNaN(height) || height === 0) {
32923292
document.getElementById('segment-area').innerText = '';
32933293
return;
@@ -3324,6 +3324,7 @@ <h3 itemprop="name" style="margin:7px">Area of a Circle Segment</h3>
33243324

33253325
document.getElementById('segment-length').addEventListener('input', updateSegmentArea);
33263326
document.getElementById('segment-height').addEventListener('input', updateSegmentArea);
3327+
document.getElementById('segment-parent-radius').addEventListener('input', updateSegmentArea);
33273328
</script>
33283329
<p id="segment-area"></p>
33293330
</div>
@@ -3357,7 +3358,6 @@ <h3 itemprop="name" style="margin:7px">Surface Area of a Cone</h3>
33573358
<br>
33583359
<p style="margin:12px" itemprop="abstract">The surface area of a cone is calculated as a circle slice with a radius equal to the slant height and the angle given by the ratio between the height and the slant height.</p>
33593360
<br>
3360-
<br>
33613361
<div style="margin:12px" itemprop="mathExpression">
33623362
<math xmlns="http://www.w3.org/1998/Math/MathML" >
33633363
<mrow>
@@ -3467,7 +3467,6 @@ <h3 itemprop="name" style="margin:7px">Volume of a Sphere</h3>
34673467
</section>
34683468
<p style="margin:12px" itemprop="abstract">The volume of a sphere equals the cubic value of the square root of its cross-sectional area, just like a cube.</p>
34693469
<br>
3470-
<br>
34713470
<div style="margin:12px" itemprop="mathExpression">
34723471
<math xmlns="http://www.w3.org/1998/Math/MathML">
34733472
<mrow>
@@ -3591,7 +3590,6 @@ <h3 itemprop="name" style="margin:7px">Volume of a Spherical Cap</h3>
35913590
<br>
35923591
<p style="margin:12px" itemprop="abstract">One dimension of the volume of sphere formula can be adjusted to calculate the volume of a spherical cap as a distorted hemisphere.</p>
35933592
<br>
3594-
<br>
35953593
<div style="margin:12px" itemprop="mathExpression">
35963594
<math xmlns="http://www.w3.org/1998/Math/MathML" >
35973595
<mrow>
@@ -4005,7 +4003,6 @@ <h4 itemprop="abstract">The volume of a cone can be calculated by algebraically
40054003
</math>
40064004
</div>
40074005
<br>
4008-
<br>
40094006
<div itemprop="mathExpression">
40104007
<math style="margin:12px" xmlns="http://www.w3.org/1998/Math/MathML" >
40114008
<mrow>
@@ -4125,7 +4122,6 @@ <h3 itemprop="name" style="margin:7px">Volume of a Frustum Cone</h3>
41254122
</math>
41264123
</div>
41274124
<br>
4128-
<br>
41294125
<div itemprop="mathExpression">
41304126
<math style="margin:12px" xmlns="http://www.w3.org/1998/Math/MathML">
41314127
<mrow>
@@ -4654,7 +4650,6 @@ <h3 itemprop="name" style="margin:12px">Volume of a horizontal square Frustum Py
46544650
</math>
46554651
</div>
46564652
<br>
4657-
<br>
46584653
<div style="margin:12px" itemprop="mathExpression">
46594654
<math xmlns="http://www.w3.org/1998/Math/MathML">
46604655
<mrow>
@@ -4844,6 +4839,7 @@ <h3 itemprop="name" style="margin:7px">Volume of a Tetrahedron</h3>
48444839
<br>
48454840
<br>
48464841
<br>
4842+
<br>
48474843
<p itemprop="description">The height of the tetrahedron is also calculable via trigonometry.
48484844
</p>
48494845
<br>
@@ -4938,6 +4934,7 @@ <h3 itemprop="name" style="margin:7px">Volume of a Tetrahedron</h3>
49384934
<br>
49394935
<br>
49404936
<br>
4937+
<br>
49414938
<p>The volume of a pyramid equals base × height × √2 / 4 .
49424939
</p>
49434940
</div>

0 commit comments

Comments
 (0)