summaryrefslogtreecommitdiff
path: root/876/CH3/EX3.9/Ex3_9t.txt
blob: f26b1a85969a6d30d733bb38679249b18b7a79e9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
//caption:Find value of protection resistance
//Ex3.9
clc
clear
close
I=0.01//current through LDR(in A)
R=15//Resistance of LDR(in ohms)
V=9//supply voltage(in V)
Vo=I*R
Vp=V-Vo
R=Vp/I
disp(R,'value of protection resistance(in ohm)=')