-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
179 lines (153 loc) · 5.53 KB
/
index.html
File metadata and controls
179 lines (153 loc) · 5.53 KB
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>GeoScope</title>
<style>
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family: 'Arial', sans-serif;
background-color: #f0f4f8;
color: #333;
line-height: 1.6;
}
.container {
max-width: 960px;
margin: 20px auto;
padding: 20px;
background-color: white;
box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
border-radius: 8px;
}
header {
text-align: center;
padding: 20px;
background-color: #b6c8e8;
color: #fff;
border-radius: 8px 8px 8px 8px;
}
header h1 {
font-size: 2em;
margin-bottom: 10px;
color: black;
}
header p {
font-size: 1.2em;
font-weight: 300;
color:black
}
section {
margin: 20px 0;
}
section h2 {
font-size: 2em;
margin-bottom: 15px;
color: #4C638C;
}
section p {
margin-bottom: 15px;
color: #666;
font-size: 1.1em;
}
.highlights {
display: flex;
flex-wrap: wrap;
gap: 20px;
}
.highlight {
flex: 1;
min-width: 280px;
padding: 15px;
background-color: #e6edf7;
border-left: 5px solid #4C638C;
border-radius: 5px;
}
.highlight h3 {
color: #333;
font-size: 1.5em;
margin-bottom: 10px;
}
.highlight p {
color: #555;
}
pre {
background-color: #282c34;
color: #ffffff;
padding: 20px;
border-radius: 5px;
overflow-x: auto;
font-size: 0.9em;
}
code {
font-family: 'Courier New', Courier, monospace;
}
footer {
text-align: center;
padding: 10px;
background-color: #4C638C;
color: white;
font-size: 0.9em;
margin-top: 30px;
border-radius: 0 0 8px 8px;
}
footer a {
color: #b6c8e8;
text-decoration: none;
}
footer a:hover {
text-decoration: underline;
}
</style>
</head>
<body>
<div class="container">
<header>
<h1>GeoScope</h1>
<p>By Aadiraj Anil, Ayushman Kalita, Mehul Saini</p>
</header>
<section>
<h2>Overview</h2>
<p>Wavelength detection plays a key role in identifying the composition and purity of materials. This project uses a sensor to measure wavelength values from objects and detect the closest material match, calculating the purity percentage. It is an innovative approach that showcases real-world applications of physics, technology, and electronics.</p>
</section>
<section class="highlights">
<div class="highlight">
<h3>Purpose</h3>
<p>This project helps identify different materials based on their reflective properties and wavelength data, allowing a closer look into purity estimation and material identification in a cost-effective and efficient manner.</p>
</div>
<div class="highlight">
<h3>Technology</h3>
<p>Using sensors that capture light reflection, we process the wavelengths detected and match them against known material properties. The core of the project involves an <b>HW067 16 diode wavelength sensor</b> and a set of calculations based on the difference in reflected wavelengths.</p>
</div>
<div class="highlight">
<h3>Future Scope</h3>
<p>The project has potential applications in industries like recycling, manufacturing, and material sciences where quick and accurate material identification is required.</p>
</div>
</section>
<section>
<h2>Code Snippet</h2>
<p>Below is the core function for material detection and purity calculation. The wavelength values from the sensor are compared to predefined material data to find the closest match, with the purity calculated based on the closeness of the values.</p>
<pre><code class="language-cpp">
for (int i = 0; i < sizeof(materials) / sizeof(materials[0]); i++) {
int rDiff = r - materials[i].rWavelength;
int gDiff = g - materials[i].gWavelength;
int bDiff = b - materials[i].bWavelength;
int distance = rDiff * rDiff + gDiff * gDiff + bDiff * bDiff;
int maxDistance = 255 * 255 * 3;
float normalizedDistance = sqrt(minDistance) / sqrt(maxDistance);
purity = max(0, 100 - int(normalizedDistance * 100));
return closestMaterial;
}
}
</code></pre>
</section>
<footer>
<p>Created by Team Pragmatic Engineers | <a href="https://trajectory-aerospace.squarespace.com/">Learn More</a> | Mekathalon 2024</p>
</footer>
</div>
</body>
</html>