-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgatesbasicOperations.html
More file actions
299 lines (267 loc) · 13 KB
/
Copy pathgatesbasicOperations.html
File metadata and controls
299 lines (267 loc) · 13 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
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta content="width=device-width, initial-scale=1.0" name="viewport">
<title>Digital Logic: AND Gates - Ritesh Thapa</title>
<meta name="description" content="The basic operation of AND logic gates in digital circuits. Learn functional expressions, circuit diagrams, truth tables, and verification procedures.">
<meta name="keywords" content="digital logic, AND gates, truth table, breadboard, electronics, Ritesh Thapa">
<script async src="https://www.googletagmanager.com/gtag/js?id=G-T3Q2Q1XTSN"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'G-T3Q2Q1XTSN');
</script>
<link href="https://fonts.googleapis.com/css?family=Poppins:300,300i,400,400i,500,500i,600,600i,700,700i|Playfair+Display:400,400i,500,500i,600,600i,700,700i,900,900i" rel="stylesheet">
<link href="assets/vendor/bootstrap/css/bootstrap.min.css" rel="stylesheet">
<link href="assets/vendor/bootstrap-icons/bootstrap-icons.css" rel="stylesheet">
<link href="assets/vendor/boxicons/css/boxicons.min.css" rel="stylesheet">
<link href="assets/vendor/glightbox/css/glightbox.min.css" rel="stylesheet">
<link href="assets/vendor/swiper/swiper-bundle.min.css" rel="stylesheet">
<link href="https://unpkg.com/aos@2.3.1/dist/aos.css" rel="stylesheet">
<link href="assets/css/style.css" rel="stylesheet">
<style>
/* Inlining the mobile nav override since it's in index.html */
.mobile-nav-toggle { display: none; font-size: 28px; cursor: pointer; color: #fff; line-height: 1; transition: color 0.3s; z-index: 9999; }
@media (max-width: 991px) {
.mobile-nav-toggle { display: block; }
#navbar ul { display: none; flex-direction: column; position: fixed; top: 0; right: -100%; width: 260px; height: 100vh; background: #0f172a; padding: 60px 20px 20px; gap: 0; box-shadow: -4px 0 20px rgba(0,0,0,0.4); transition: right 0.35s ease; z-index: 9998; overflow-y: auto; }
#navbar.navbar-mobile ul { display: flex; right: 0; }
#navbar.navbar-mobile ul li { border-bottom: 1px solid rgba(255,255,255,0.08); }
#navbar.navbar-mobile ul li a { display: block; padding: 14px 10px; font-size: 15px; color: rgba(255,255,255,0.85); letter-spacing: 0.5px; transition: color 0.2s, padding-left 0.2s; }
#navbar.navbar-mobile ul li a:hover, #navbar.navbar-mobile ul li a.active { color: #0ea5e9; padding-left: 18px; }
.mobile-nav-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 996; backdrop-filter: blur(2px); }
.mobile-nav-overlay.active { display: block; }
#navbar.navbar-mobile ~ .mobile-nav-toggle::before { content: none; }
}
/* Blog specific styles */
.blog-header {
padding: 120px 0 60px;
text-align: center;
}
.blog-header h1 {
font-size: 42px;
font-weight: 800;
margin-bottom: 20px;
background: var(--gradient);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
}
.blog-content {
background: var(--dark-card);
border-radius: 16px;
padding: 40px;
margin-bottom: 60px;
box-shadow: 0 10px 30px rgba(0,0,0,0.5);
border: 1px solid rgba(255,255,255,0.05);
}
.blog-content h2 {
font-size: 28px;
color: var(--primary);
margin-top: 40px;
margin-bottom: 20px;
}
.blog-content h3 {
font-size: 22px;
color: #e2e8f0;
margin-top: 30px;
margin-bottom: 15px;
}
.blog-content p, .blog-content li {
font-size: 16px;
line-height: 1.8;
color: var(--text-muted);
margin-bottom: 20px;
}
.blog-content img {
width: 100%;
border-radius: 12px;
margin: 30px 0;
border: 1px solid rgba(255,255,255,0.1);
}
/* Buttons in Dark Theme */
.btn-outline-primary, .btn-outline-secondary, .btn-outline-success {
border-radius: 8px;
margin: 5px;
transition: all 0.3s;
}
.btn-outline-primary:hover, .btn-outline-secondary:hover, .btn-outline-success:hover {
box-shadow: 0 0 15px rgba(14, 165, 233, 0.4);
}
</style>
</head>
<body>
<div class="cursor-dot"></div>
<div class="cursor-outline"></div>
<div class="mobile-nav-overlay" id="mobileNavOverlay"></div>
<!-- ======= Header ======= -->
<header id="header" class="fixed-top">
<div class="container d-flex align-items-center justify-content-between">
<h1 class="logo"><a href="index.html">RITESH</a></h1>
<nav id="navbar" class="navbar">
<ul>
<li><a class="nav-link" href="index.html#hero">Home</a></li>
<li><a class="nav-link" href="index.html#about">About</a></li>
<li><a class="nav-link" href="index.html#skills">Skills</a></li>
<li><a class="nav-link" href="index.html#portfolio">My projects</a></li>
<li><a class="nav-link active" href="index.html#journal">Blog</a></li>
<li><a class="nav-link" href="index.html#contact">Contact</a></li>
</ul>
<i class="bi bi-list mobile-nav-toggle" id="mobileNavToggle"></i>
</nav>
</div>
</header>
<main id="main">
<section class="blog-header">
<div class="container" data-aos="fade-up">
<h1>Digital Logic Operations:<br>AND Gates</h1>
<p style="font-size: 18px; color: var(--text-muted);">Verifying the basic operations of logic gates in digital circuits.</p>
</div>
</section>
<section class="container" data-aos="fade-up" data-aos-delay="200">
<div class="row justify-content-center">
<div class="col-lg-10">
<div class="blog-content">
<img src="assets/img/logicGates.png" alt="Logic Gates Header" style="max-height: 400px; object-fit: contain; background: #fff; padding: 20px;">
<h2>Introduction to AND Gates</h2>
<p>An AND gate is a digital logic gate with two or more inputs and one output that performs logical conjunction. It is one of the fundamental building blocks of digital electronics.</p>
<h2>Functional Expression</h2>
<p>The functional expression of AND gates is denoted by a dot (.).<br>
If A and B are the two inputs of the AND gate, then the output of the given function is <strong>Z = A.B</strong>,</p>
<ul>
<li><strong>Z</strong> is the output of the AND gate</li>
<li><strong>A</strong> and <strong>B</strong> are the inputs to the AND gate</li>
</ul>
<h2>Circuit Diagram</h2>
<p>The standard symbol and circuit diagram for a 2-input AND gate:</p>
<img src="assets/img/and.png" alt="AND Gate Circuit Diagram" style="max-height: 200px; object-fit: contain; width: auto; display: block; background: #fff; padding: 15px;">
<h2>Truth Table</h2>
<p>The truth table clearly shows that the output is high (1) only when both inputs are high (1).</p>
<img src="assets/img/truthtable.png" alt="AND Gate Truth Table" style="max-height: 250px; object-fit: contain; width: auto; display: block; background: #fff; padding: 15px;">
<h2>Verification Procedure</h2>
<p>The procedure to verify the basic operation of logic AND gates using a breadboard is as follows:</p>
<ol style="color: var(--text-muted); line-height: 1.8; margin-bottom: 20px; padding-left: 20px;">
<li>Take all required apparatus (Breadboard, IC 7408, LED, Resistor, Jumper wires, Power Supply).</li>
<li>Give power supply to the breadboard.</li>
<li>Connect the jumper wires to create a positive and negative path on the breadboard.</li>
<li>Give pin number 7 a ground (connect to negative path) and pin 14 a high (connect to positive path) for the integrated circuit (IC 7408).</li>
<li>Take pin 1 and 2 as inputs and pin 3 as the output of the IC.</li>
<li>Connect one leg of the resistor to the output path and the other leg to any free point on the breadboard.</li>
<li>Connect the positive leg of the LED to the path of the output leg of the resistor and the negative leg to the negative path of the breadboard.</li>
</ol>
<h2>Result</h2>
<p>After completing the procedure, the LED will glow depending on the inputs. If either of the inputs is connected to the negative path (0) on the breadboard, the LED will be off. If both inputs are connected to the positive path (1), the LED will turn on, verifying the logical conjunction.</p>
<div style="margin-top: 60px; padding-top: 30px; border-top: 1px solid rgba(255,255,255,0.1);">
<h3 style="margin-top: 0;">Explore Other Logic Operations</h3>
<div class="d-flex flex-wrap gap-2 mt-3">
<a href="orGate.html" class="btn btn-outline-primary">OR GATES</a>
<a href="gatesbasicOperations.html" class="btn btn-primary">AND GATES</a>
<a href="notGate.html" class="btn btn-outline-success">NOT GATES</a>
</div>
</div>
</div>
</div>
</div>
</section>
</main>
<!-- ======= Footer ======= -->
<div id="footer" class="text-center">
<div class="container">
<div class="socials-media text-center">
<ul class="list-unstyled">
<li><a href="https://www.facebook.com/ritesh.thapa.96155"><i class="bi bi-facebook"></i></a></li>
<li><a href="https://www.instagram.com/invites/contact/?i=5lt8p3n73zbr&utm_content=1u9pxss"><i class="bi bi-instagram"></i></a></li>
<li><a href="https://www.linkedin.com/in/ritesh-thapa-b85942178"><i class="bi bi-linkedin"></i></a></li>
</ul>
</div>
<div class="credits">
Designed by <a href="https://reteshthapa.com.np/">Ritesh Thapa</a>
</div>
</div>
</div>
<a href="#" class="back-to-top d-flex align-items-center justify-content-center"><i class="bi bi-arrow-up-short"></i></a>
<!-- Vendor JS Files -->
<script src="assets/vendor/bootstrap/js/bootstrap.bundle.min.js"></script>
<script src="assets/vendor/glightbox/js/glightbox.min.js"></script>
<script src="assets/vendor/isotope-layout/isotope.pkgd.min.js"></script>
<script src="assets/vendor/swiper/swiper-bundle.min.js"></script>
<script src="assets/vendor/php-email-form/validate.js"></script>
<script src="https://unpkg.com/aos@2.3.1/dist/aos.js"></script>
<script src="assets/js/main.js"></script>
<!-- ======= Mobile Nav Toggle Script ======= -->
<script>
(function () {
const toggle = document.getElementById('mobileNavToggle');
const navbar = document.getElementById('navbar');
const overlay = document.getElementById('mobileNavOverlay');
if(toggle && navbar && overlay) {
function openMenu() {
navbar.classList.add('navbar-mobile');
overlay.classList.add('active');
toggle.classList.remove('bi-list');
toggle.classList.add('bi-x');
document.body.style.overflow = 'hidden';
}
function closeMenu() {
navbar.classList.remove('navbar-mobile');
overlay.classList.remove('active');
toggle.classList.remove('bi-x');
toggle.classList.add('bi-list');
document.body.style.overflow = '';
}
toggle.addEventListener('click', function (e) {
e.stopPropagation();
if (navbar.classList.contains('navbar-mobile')) {
closeMenu();
} else {
openMenu();
}
});
overlay.addEventListener('click', closeMenu);
navbar.querySelectorAll('a').forEach(function (link) {
link.addEventListener('click', function () {
if (navbar.classList.contains('navbar-mobile')) {
closeMenu();
}
});
});
}
})();
</script>
<!-- Custom Cursor & AOS Init -->
<script>
document.addEventListener("DOMContentLoaded", function() {
AOS.init({
duration: 800,
easing: 'ease-in-out',
once: true,
mirror: false
});
const cursorDot = document.querySelector(".cursor-dot");
const cursorOutline = document.querySelector(".cursor-outline");
if (cursorDot && cursorOutline) {
window.addEventListener("mousemove", function(e) {
const posX = e.clientX;
const posY = e.clientY;
cursorDot.style.left = `${posX}px`;
cursorDot.style.top = `${posY}px`;
cursorOutline.animate({
left: `${posX}px`,
top: `${posY}px`
}, { duration: 500, fill: "forwards" });
});
const interactables = document.querySelectorAll('a, button');
interactables.forEach(el => {
el.addEventListener('mouseenter', () => {
cursorOutline.classList.add('cursor-hover');
});
el.addEventListener('mouseleave', () => {
cursorOutline.classList.remove('cursor-hover');
});
});
}
});
</script>
</body>
</html>