summaryrefslogtreecommitdiff
path: root/1184/CH2/EX2.7.b/Ex2_7b.sce
diff options
context:
space:
mode:
Diffstat (limited to '1184/CH2/EX2.7.b/Ex2_7b.sce')
-rwxr-xr-x1184/CH2/EX2.7.b/Ex2_7b.sce11
1 files changed, 11 insertions, 0 deletions
diff --git a/1184/CH2/EX2.7.b/Ex2_7b.sce b/1184/CH2/EX2.7.b/Ex2_7b.sce
new file mode 100755
index 000000000..f5c5cd672
--- /dev/null
+++ b/1184/CH2/EX2.7.b/Ex2_7b.sce
@@ -0,0 +1,11 @@
+//Example 2-7 b, Page No.36
+
+clear
+clc
+
+pin_mW = 50
+pout_mW = 2
+
+gain_dB= 10*log10(pout_mW/pin_mW)
+
+printf('The gain/attenuation of the amplifier is %.2f',gain_dB)