Sample Solution

MMTE-007 Solved Assignment 2024 CS

SOFT COMPUTING AND ITS APPLICATIONS

(Valid from 1st January, 2024 to 31st December, 2024)

  1. a) Two sensors based upon their detection levels and gain settings are compared. The following of gain setting and sensor detection levels with a standard item being monitored provides typical membership values to represent the detection levels for each of the sensors.
Gain Setting
Sensor 1
detection levels
Sensor 1 detection levels| Sensor 1 | | :—: | | detection levels |
Sensor 2
detection levels
Sensor 2 detection levels| Sensor 2 | | :—: | | detection levels |
0 0 0
20 0.5 0.35
40 0.65 0.5
60 0.85 0.75
80 1 0.90
100 1 1
Gain Setting “Sensor 1 detection levels” “Sensor 2 detection levels” 0 0 0 20 0.5 0.35 40 0.65 0.5 60 0.85 0.75 80 1 0.90 100 1 1| Gain Setting | Sensor 1 <br> detection levels | Sensor 2 <br> detection levels | | :—: | :—: | :—: | | 0 | 0 | 0 | | 20 | 0.5 | 0.35 | | 40 | 0.65 | 0.5 | | 60 | 0.85 | 0.75 | | 80 | 1 | 0.90 | | 100 | 1 | 1 |
The universe of discourse is x = { 0 , 20 , 40 , 60 , 80 , 100 } x = { 0 , 20 , 40 , 60 , 80 , 100 } x={0,20,40,60,80,100}x=\{0,20,40,60,80,100\}x={0,20,40,60,80,100}. Find the membership function for the two sensors. Also, verify De-morgon’s laws for these membership functions.
b) Consider a subset of natural numbers from 1 to 30 , as the universe of discourse, U U UUU. Define the fuzzy sets "small" and "medium" by enumeration.
2. a) Construct the α α alpha\alphaα-cut at α = 0.4 α = 0.4 alpha=0.4\alpha=0.4α=0.4 for the fuzzy sets defined in Q. 1(b).
b) Apply the "very" hedge on the fuzzy sets defined in Q. 1(b) to get the new modified fuzzy sets. Show the modified fuzzy sets through numeration.
3. Let A and B are two fuzzy sets and x U x U xinU\mathrm{x} \in \mathrm{U}xU, if μ A ( x ) = 0.4 μ A ( x ) = 0.4 mu_(A)(x)=0.4\mu_{\mathrm{A}}(\mathrm{x})=0.4μA(x)=0.4 and μ B ( x ) = 0.8 μ B ( x ) = 0.8 mu_(B)(x)=0.8\mu_{\mathrm{B}}(\mathrm{x})=0.8μB(x)=0.8 then find out the following membership values:
i) μ A ( x ) μ A ( x ) quadmu_(A)(x)\quad \mu_{\mathrm{A} \mathcal{}}(\mathrm{x})μA(x),
ii) μ A B ( x ) μ A B ( x ) mu_(A nn B)(x)\mu_{A \cap B}(x)μAB(x),
iii) μ A B ( x ) μ A ¯ B ¯ ( x ) mu_( bar(A)uu bar(B))(x)\mu_{\overline{\mathrm{A}} \cup \overline{\mathrm{B}}}(\mathrm{x})μAB(x),
iv) μ A B ( x ) μ A ¯ B ¯ ( x ) mu_( bar(A)nn bar(B))(x)\mu_{\overline{\mathrm{A}} \cap \overline{\mathrm{B}}}(\mathrm{x})μAB(x),
v) μ A B ( x ) μ A ¯ B ¯ ¯ ( x ) mu_( bar(A) bar(bar(B)))(x)\mu_{\overline{\mathrm{A}} \overline{\overline{\mathrm{B}}}}(\mathrm{x})μAB(x),
vi) μ A B ( x ) μ A ¯ B ¯ ¯ ( x ) mu_( bar(A) bar(bar(B)))(x)\mu_{\overline{\mathrm{A}} \overline{\overline{\mathrm{B}}}}(\mathrm{x})μAB(x),
  1. Consider a dataset of six points given in the following table, each of which has two features f 1 f 1 f_(1)f_1f1 and f 2 f 2 f_(2)f_2f2. Assuming the values of the parameters c c ccc and m m mmm as 2 and the initial cluster centers v 1 = ( 5 , 5 ) v 1 = ( 5 , 5 ) v_(1)=(5,5)\mathrm{v}_1=(5,5)v1=(5,5) and v 2 = ( 10 , 10 ) v 2 = ( 10 , 10 ) v_(2)=(10,10)\mathrm{v}_2=(10,10)v2=(10,10), apply FCm algorithm to find the new cluster center after one iteration.
f 1 f 1 f_(1)\mathrm{f}_1f1 f 2 f 2 f_(2)\mathrm{f}_2f2
x 1 x 1 x_(1)\mathrm{x}_1x1 3 11
x 2 x 2 x_(2)\mathrm{x}_2x2 3 10
f_(1) f_(2) x_(1) 3 11 x_(2) 3 10| | $\mathrm{f}_1$ | $\mathrm{f}_2$ | | :— | :— | :— | | $\mathrm{x}_1$ | 3 | 11 | | $\mathrm{x}_2$ | 3 | 10 |
x 3 x 3 x_(3)x_3x3 8 12
x 4 x 4 x_(4)x_4x4 10 6
x 5 x 5 x_(5)x_5x5 13 6
x 6 x 6 x_(6)x_6x6 13 5
x_(3) 8 12 x_(4) 10 6 x_(5) 13 6 x_(6) 13 5| $x_3$ | 8 | 12 | | :— | :— | :— | | $x_4$ | 10 | 6 | | $x_5$ | 13 | 6 | | $x_6$ | 13 | 5 |
  1. a) Define Error Correction Learning with examples.
    b) Write the types of Neural Memory Models. Also, give one example of each.
  2. Consider the set of pattern vectors P. Obtain the connectivity matrix (CM) for the patterns in P P PPP (four patterns).
p = [ 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 0 0 0 0 0 0 1 1 0 1 0 1 0 1 0 1 0 ] p = 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 0 0 0 0 0 0 1 1 0 1 0 1 0 1 0 1 0 p=[[1,1,1,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,1,1,1],[1,1,1,0,0,0,0,0,0,1],[1,0,1,0,1,0,1,0,1,0]]\mathrm{p}=\left[\begin{array}{llllllllll} 1 & 1 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 1 & 1 & 1 \\ 1 & 1 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 1 \\ 1 & 0 & 1 & 0 & 1 & 0 & 1 & 0 & 1 & 0 \end{array}\right]p=[1110000000000000011111100000011010101010]
  1. a) Define Kohonen networks with examples.
    b) Describe the Function Approximation in MLP. Also, explain Generalization of MLP.
  2. a) Find the length and order of the following schema:
    i) S 1 = ( 1 00 1 ) S 1 = 1 00 1 S_(1)=(1^(****)00**1^(****))\mathrm{S}_1=\left(1^{* *} 00 * 1^{* *}\right)S1=(1001)
    ii) S 2 = ( 00 1 ) S 2 = 00 1 S_(2)=(^(**)00^(**)1^(****))\mathrm{S}_2=\left({ }^* 00{ }^* 1^{* *}\right)S2=(001)
    iii) S 3 = ( 1 ) S 3 = 1 S_(3)=(******1^(******))\mathrm{S}_3=\left(* * * 1^{* * *}\right)S3=(1)
    b) Let an activation function be defined as
ϕ ( v ) = 1 1 + e zv , a > 0 ϕ ( v ) = 1 1 + e zv , a > 0 phi(v)=(1)/(1+e^(-zv)),a > 0\phi(\mathrm{v})=\frac{1}{1+\mathrm{e}^{-\mathrm{zv}}}, \mathrm{a}>0ϕ(v)=11+ezv,a>0
Show that d ϕ d v = a ϕ ( v ) [ 1 ϕ ( v ) ] d ϕ d v = a ϕ ( v ) [ 1 ϕ ( v ) ] (d phi)/(dv)=a phi(v)[1-phi(v)]\frac{d \phi}{d v}=a \phi(v)[1-\phi(v)]dϕdv=aϕ(v)[1ϕ(v)]. What is the value of ϕ ( v ) ϕ ( v ) phi(v)\phi(v)ϕ(v) at the origin? Also, find the value of ϕ ( v ) ϕ ( v ) phi(v)\phi(\mathrm{v})ϕ(v) as v v vvv approaches + + +oo+\infty+ and -oo-\infty.
9. a) Consider the following travelling salesman problem involving 9 cities.
Parent 1 G J H F E D B I C
Parent 2 D C H J I G E F B
Parent 1 G J H F E D B I C Parent 2 D C H J I G E F B| Parent 1 | G | J | H | F | E | D | B | I | C | | :— | :— | :— | :— | :— | :— | :— | :— | :— | :— | | Parent 2 | D | C | H | J | I | G | E | F | B |
Determine the children solution using.
i) Order crossover #1, assuming 4 th 4 th 4^(“th “)4^{\text {th }}4th and 7 th 7 th 7^(“th “)7^{\text {th }}7th sites as the crossover sites.
ii) Order crossover #2, assuming 3 rd , 5 th 3 rd , 5 th 3^(“rd “),5^(“th “)3^{\text {rd }}, 5^{\text {th }}3rd ,5th and 7 th 7 th 7^(“th “)7^{\text {th }}7th as the key positions.
b) Consider the following single layer perception as shown in the following figure.
original image
and the activation function of each unit is defined as Φ ( v ) = { 1 , if v 0 0 , otherwise. Φ ( v ) = 1 , if v 0 0 , otherwise. Phi(v)={[1″,”” if “v >= 0],[0″,”” otherwise. “]:}\Phi(\mathrm{v})=\left\{\begin{array}{l}1, \text { if } \mathrm{v} \geq 0 \\ 0, \text { otherwise. }\end{array}\right.Φ(v)={1, if v00, otherwise.
Calculate the output y y yyy of the unit for each of the following input patterns:
Patterns P 1 P 1 P_(1)P_1P1 P 2 P 2 P_(2)P_2P2 P 3 P 3 P_(3)P_3P3 P 4 P 4 P_(4)P_4P4
x 1 x 1 x_(1)x_1x1 1 0 1 1
x 2 x 2 x_(2)x_2x2 0 1 0 1
x 3 x 3 x_(3)x_3x3 0 1 1 1
Patterns P_(1) P_(2) P_(3) P_(4) x_(1) 1 0 1 1 x_(2) 0 1 0 1 x_(3) 0 1 1 1| Patterns | $P_1$ | $P_2$ | $P_3$ | $P_4$ | | :— | :— | :— | :— | :— | | $x_1$ | 1 | 0 | 1 | 1 | | $x_2$ | 0 | 1 | 0 | 1 | | $x_3$ | 0 | 1 | 1 | 1 |
Also, find the modified weights after one iteration.
  1. Which of the following statements are true or false? Give a short proof or a counter example in support of your answers.
    a) There is chance of occurrence of the premature convergence in Roulett-wheel selection shceme used in GA.
    b) Gradient based optimization methods are used when the objective function is not smooth and one needs efficient local optimization.
    c) The α α alpha\alphaα-cut of a fuzzy set A in uu\cup is defined as A α 0 = { x U μ A ( x ) α 0 } A α 0 = x U μ A ( x ) α 0 Aalpha_(0)={xin U∣mu_(A)(x) <= alpha_(0)}\mathrm{A} \alpha_0=\left\{\mathrm{x} \in U \mid \mu_{\mathrm{A}}(\mathrm{x}) \leq \alpha_0\right\}Aα0={xUμA(x)α0}
    d) A single perception with preprocessing is neither an auto associative network nor a multiple layer neural network.
    e) If W ( k 0 ) = W ( k 0 + 1 ) = W ( k 0 + 2 ) W k 0 = W k 0 + 1 = W k 0 + 2 W(k_(0))=W(k_(0)+1)=W(k_(0)+2)\mathrm{W}\left(\mathrm{k}_0\right)=\mathrm{W}\left(\mathrm{k}_0+1\right)=\mathrm{W}\left(\mathrm{k}_0+2\right)W(k0)=W(k0+1)=W(k0+2), then perception is non-linear separable.

Expert Answer

Question:-1(a)

Two sensors based upon their detection levels and gain settings are compared. The following of gain setting and sensor detection levels with a standard item being monitored provides typical membership values to represent the detection levels for each of the sensors.

Gain Setting
Sensor 1
detection levels
Sensor 1 detection levels| Sensor 1 | | :—: | | detection levels |
Sensor 2
detection levels
Sensor 2 detection levels| Sensor 2 | | :—: | | detection levels |
0 0 0
20 0.5 0.35
40 0.65 0.5
60 0.85 0.75
80 1 0.90
100 1 1
Gain Setting “Sensor 1 detection levels” “Sensor 2 detection levels” 0 0 0 20 0.5 0.35 40 0.65 0.5 60 0.85 0.75 80 1 0.90 100 1 1| Gain Setting | Sensor 1 <br> detection levels | Sensor 2 <br> detection levels | | :—: | :—: | :—: | | 0 | 0 | 0 | | 20 | 0.5 | 0.35 | | 40 | 0.65 | 0.5 | | 60 | 0.85 | 0.75 | | 80 | 1 | 0.90 | | 100 | 1 | 1 |
The universe of discourse is x = { 0 , 20 , 40 , 60 , 80 , 100 } x = { 0 , 20 , 40 , 60 , 80 , 100 } x={0,20,40,60,80,100}x=\{0,20,40,60,80,100\}x={0,20,40,60,80,100}. Find the membership function for the two sensors. Also, verify De-morgon’s laws for these membership functions.

Answer:

Step 1: Define the Membership Functions

We are given the detection levels for two sensors at different gain settings. The gain settings are represented as the universe of discourse x = { 0 , 20 , 40 , 60 , 80 , 100 } x = { 0 , 20 , 40 , 60 , 80 , 100 } x={0,20,40,60,80,100}x = \{0, 20, 40, 60, 80, 100\}x={0,20,40,60,80,100}, and for each gain setting, we have membership values representing the detection levels for each sensor.
Let’s define the membership functions for Sensor 1 and Sensor 2.

Membership Function for Sensor 1, μ S1 ( x ) μ S1 ( x ) mu_(“S1”)(x)\mu_{\text{S1}}(x)μS1(x)

The detection levels for Sensor 1 at different gain settings are:
μ S1 ( 0 ) = 0 , μ S1 ( 20 ) = 0.5 , μ S1 ( 40 ) = 0.65 , μ S1 ( 60 ) = 0.85 , μ S1 ( 80 ) = 1 , μ S1 ( 100 ) = 1. μ S1 ( 0 ) = 0 , μ S1 ( 20 ) = 0.5 , μ S1 ( 40 ) = 0.65 , μ S1 ( 60 ) = 0.85 , μ S1 ( 80 ) = 1 , μ S1 ( 100 ) = 1. {:[mu_(“S1″)(0)=0″,”],[mu_(“S1″)(20)=0.5″,”],[mu_(“S1″)(40)=0.65″,”],[mu_(“S1″)(60)=0.85″,”],[mu_(“S1″)(80)=1″,”],[mu_(“S1”)(100)=1.]:}\begin{aligned} \mu_{\text{S1}}(0) &= 0, \\ \mu_{\text{S1}}(20) &= 0.5, \\ \mu_{\text{S1}}(40) &= 0.65, \\ \mu_{\text{S1}}(60) &= 0.85, \\ \mu_{\text{S1}}(80) &= 1, \\ \mu_{\text{S1}}(100) &= 1. \end{aligned}μS1(0)=0,μS1(20)=0.5,μS1(40)=0.65,μS1(60)=0.85,μS1(80)=1,μS1(100)=1.
Thus, the membership function for Sensor 1 is:
μ S1 ( x ) = { ( 0 , 0 ) , ( 20 , 0.5 ) , ( 40 , 0.65 ) , ( 60 , 0.85 ) , ( 80 , 1 ) , ( 100 , 1 ) } μ S1 ( x ) = { ( 0 , 0 ) , ( 20 , 0.5 ) , ( 40 , 0.65 ) , ( 60 , 0.85 ) , ( 80 , 1 ) , ( 100 , 1 ) } mu_(“S1”)(x)={(0,0),(20,0.5),(40,0.65),(60,0.85),(80,1),(100,1)}\mu_{\text{S1}}(x) = \{(0, 0), (20, 0.5), (40, 0.65), (60, 0.85), (80, 1), (100, 1)\}μS1(x)={(0,0),(20,0.5),(40,0.65),(60,0.85),(80,1),(100,1)}

Membership Function for Sensor 2, μ S2 ( x ) μ S2 ( x ) mu_(“S2”)(x)\mu_{\text{S2}}(x)μS2(x)

The detection levels for Sensor 2 at different gain settings are:
μ S2 ( 0 ) = 0 , μ S2 ( 20 ) = 0.35 , μ S2 ( 40 ) = 0.5 , μ S2 ( 60 ) = 0.75 , μ S2 ( 80 ) = 0.90 , μ S2 ( 100 ) = 1. μ S2 ( 0 ) = 0 , μ S2 ( 20 ) = 0.35 , μ S2 ( 40 ) = 0.5 , μ S2 ( 60 ) = 0.75 , μ S2 ( 80 ) = 0.90 , μ S2 ( 100 ) = 1. {:[mu_(“S2″)(0)=0″,”],[mu_(“S2″)(20)=0.35″,”],[mu_(“S2″)(40)=0.5″,”],[mu_(“S2″)(60)=0.75″,”],[mu_(“S2″)(80)=0.90″,”],[mu_(“S2”)(100)=1.]:}\begin{aligned} \mu_{\text{S2}}(0) &= 0, \\ \mu_{\text{S2}}(20) &= 0.35, \\ \mu_{\text{S2}}(40) &= 0.5, \\ \mu_{\text{S2}}(60) &= 0.75, \\ \mu_{\text{S2}}(80) &= 0.90, \\ \mu_{\text{S2}}(100) &= 1. \end{aligned}μS2(0)=0,μS2(20)=0.35,μS2(40)=0.5,μS2(60)=0.75,μS2(80)=0.90,μS2(100)=1.
Thus, the membership function for Sensor 2 is:
μ S2 ( x ) = { ( 0 , 0 ) , ( 20 , 0.35 ) , ( 40 , 0.5 ) , ( 60 , 0.75 ) , ( 80 , 0.90 ) , ( 100 , 1 ) } μ S2 ( x ) = { ( 0 , 0 ) , ( 20 , 0.35 ) , ( 40 , 0.5 ) , ( 60 , 0.75 ) , ( 80 , 0.90 ) , ( 100 , 1 ) } mu_(“S2”)(x)={(0,0),(20,0.35),(40,0.5),(60,0.75),(80,0.90),(100,1)}\mu_{\text{S2}}(x) = \{(0, 0), (20, 0.35), (40, 0.5), (60, 0.75), (80, 0.90), (100, 1)\}μS2(x)={(0,0),(20,0.35),(40,0.5),(60,0.75),(80,0.90),(100,1)}

Step 2: Verify De Morgan’s Laws

De Morgan’s laws for fuzzy sets are similar to De Morgan’s laws in classical set theory. For two fuzzy sets A A AAA and B B BBB with membership functions μ A ( x ) μ A ( x ) mu _(A)(x)\mu_A(x)μA(x) and μ B ( x ) μ B ( x ) mu _(B)(x)\mu_B(x)μB(x), De Morgan’s laws are stated as:
  1. First Law:
    μ ¬ ( A B ) ( x ) = μ ¬ A ( x ) μ ¬ B ( x ) μ ¬ ( A B ) ( x ) = μ ¬ A ( x ) μ ¬ B ( x ) mu_(not(A uu B))(x)=mu_(not A)(x)nnmu_(not B)(x)\mu_{\neg(A \cup B)}(x) = \mu_{\neg A}(x) \cap \mu_{\neg B}(x)μ¬(AB)(x)=μ¬A(x)μ¬B(x)
    This means:
    μ ¬ ( A B ) ( x ) = min ( 1 μ A ( x ) , 1 μ B ( x ) ) μ ¬ ( A B ) ( x ) = min ( 1 μ A ( x ) , 1 μ B ( x ) ) mu_(not(A uu B))(x)=min(1-mu _(A)(x),1-mu _(B)(x))\mu_{\neg(A \cup B)}(x) = \min(1 – \mu_A(x), 1 – \mu_B(x))μ¬(AB)(x)=min(1μA(x),1μB(x))
  2. Second Law:
    μ ¬ ( A B ) ( x ) = μ ¬ A ( x ) μ ¬ B ( x ) μ ¬ ( A B ) ( x ) = μ ¬ A ( x ) μ ¬ B ( x ) mu_(not(A nn B))(x)=mu_(not A)(x)uumu_(not B)(x)\mu_{\neg(A \cap B)}(x) = \mu_{\neg A}(x) \cup \mu_{\neg B}(x)μ¬(AB)(x)=μ¬A(x)μ¬B(x)
    This means:
    μ ¬ ( A B ) ( x ) = max ( 1 μ A ( x ) , 1 μ B ( x ) ) μ ¬ ( A B ) ( x ) = max ( 1 μ A ( x ) , 1 μ B ( x ) ) mu_(not(A nn B))(x)=max(1-mu _(A)(x),1-mu _(B)(x))\mu_{\neg(A \cap B)}(x) = \max(1 – \mu_A(x), 1 – \mu_B(x))μ¬(AB)(x)=max(1μA(x),1μB(x))
Let’s verify these laws using the membership functions for Sensor 1 and Sensor 2.

First Law: μ ¬ ( S 1 S 2 ) ( x ) = μ ¬ S 1 ( x ) μ ¬ S 2 ( x ) μ ¬ ( S 1 S 2 ) ( x ) = μ ¬ S 1 ( x ) μ ¬ S 2 ( x ) mu_(not(S1uu S2))(x)=mu_(not S1)(x)nnmu_(not S2)(x)\mu_{\neg(S1 \cup S2)}(x) = \mu_{\neg S1}(x) \cap \mu_{\neg S2}(x)μ¬(S1S2)(x)=μ¬S1(x)μ¬S2(x)

  1. Compute μ S 1 S 2 ( x ) μ S 1 S 2 ( x ) mu_(S1uu S2)(x)\mu_{S1 \cup S2}(x)μS1S2(x):
    The union of two fuzzy sets is the maximum of the membership values:
    μ S 1 S 2 ( x ) = max ( μ S1 ( x ) , μ S2 ( x ) ) μ S 1 S 2 ( x ) = max ( μ S1 ( x ) , μ S2 ( x ) ) mu_(S1uu S2)(x)=max(mu_(“S1”)(x),mu_(“S2”)(x))\mu_{S1 \cup S2}(x) = \max(\mu_{\text{S1}}(x), \mu_{\text{S2}}(x))μS1S2(x)=max(μS1(x),μS2(x))
    For each value of x x xxx:
    μ S 1 S 2 ( 0 ) = max ( 0 , 0 ) = 0 , μ S 1 S 2 ( 20 ) = max ( 0.5 , 0.35 ) = 0.5 , μ S 1 S 2 ( 40 ) = max ( 0.65 , 0.5 ) = 0.65 , μ S 1 S 2 ( 60 ) = max ( 0.85 , 0.75 ) = 0.85 , μ S 1 S 2 ( 80 ) = max ( 1 , 0.90 ) = 1 , μ S 1 S 2 ( 100 ) = max ( 1 , 1 ) = 1. μ S 1 S 2 ( 0 ) = max ( 0 , 0 ) = 0 , μ S 1 S 2 ( 20 ) = max ( 0.5 , 0.35 ) = 0.5 , μ S 1 S 2 ( 40 ) = max ( 0.65 , 0.5 ) = 0.65 , μ S 1 S 2 ( 60 ) = max ( 0.85 , 0.75 ) = 0.85 , μ S 1 S 2 ( 80 ) = max ( 1 , 0.90 ) = 1 , μ S 1 S 2 ( 100 ) = max ( 1 , 1 ) = 1. {:[mu_(S1uu S2)(0)=max(0″,”0)=0″,”],[mu_(S1uu S2)(20)=max(0.5″,”0.35)=0.5″,”],[mu_(S1uu S2)(40)=max(0.65″,”0.5)=0.65″,”],[mu_(S1uu S2)(60)=max(0.85″,”0.75)=0.85″,”],[mu_(S1uu S2)(80)=max(1″,”0.90)=1″,”],[mu_(S1uu S2)(100)=max(1″,”1)=1.]:}\begin{aligned} \mu_{S1 \cup S2}(0) &= \max(0, 0) = 0, \\ \mu_{S1 \cup S2}(20) &= \max(0.5, 0.35) = 0.5, \\ \mu_{S1 \cup S2}(40) &= \max(0.65, 0.5) = 0.65, \\ \mu_{S1 \cup S2}(60) &= \max(0.85, 0.75) = 0.85, \\ \mu_{S1 \cup S2}(80) &= \max(1, 0.90) = 1, \\ \mu_{S1 \cup S2}(100) &= \max(1, 1) = 1. \end{aligned}μS1S2(0)=max(0,0)=0,μS1S2(20)=max(0.5,0.35)=0.5,μS1S2(40)=max(0.65,0.5)=0.65,μS1S2(60)=max(0.85,0.75)=0.85,μS1S2(80)=max(1,0.90)=1,μS1S2(100)=max(1,1)=1.
  2. Compute μ ¬ ( S 1 S 2 ) ( x ) μ ¬ ( S 1 S 2 ) ( x ) mu_(not(S1uu S2))(x)\mu_{\neg(S1 \cup S2)}(x)μ¬(S1S2)(x):
    The complement of a fuzzy set is 1 μ ( x ) 1 μ ( x ) 1-mu(x)1 – \mu(x)1μ(x):
    μ ¬ ( S 1 S 2 ) ( x ) = 1 μ S 1 S 2 ( x ) μ ¬ ( S 1 S 2 ) ( x ) = 1 μ S 1 S 2 ( x ) mu_(not(S1uu S2))(x)=1-mu_(S1uu S2)(x)\mu_{\neg(S1 \cup S2)}(x) = 1 – \mu_{S1 \cup S2}(x)μ¬(S1S2)(x)=1μS1S2(x)
    For each value of x x xxx:
    μ ¬ ( S 1 S 2 ) ( 0 ) = 1 0 = 1 , μ ¬ ( S 1 S 2 ) ( 20 ) = 1 0.5 = 0.5 , μ ¬ ( S 1 S 2 ) ( 40 ) = 1 0.65 = 0.35 , μ ¬ ( S 1 S 2 ) ( 60 ) = 1 0.85 = 0.15 , μ ¬ ( S 1 S 2 ) ( 80 ) = 1 1 = 0 , μ ¬ ( S 1 S 2 ) ( 100 ) = 1 1 = 0. μ ¬ ( S 1 S 2 ) ( 0 ) = 1 0 = 1 , μ ¬ ( S 1 S 2 ) ( 20 ) = 1 0.5 = 0.5 , μ ¬ ( S 1 S 2 ) ( 40 ) = 1 0.65 = 0.35 , μ ¬ ( S 1 S 2 ) ( 60 ) = 1 0.85 = 0.15 , μ ¬ ( S 1 S 2 ) ( 80 ) = 1 1 = 0 , μ ¬ ( S 1 S 2 ) ( 100 ) = 1 1 = 0. {:[mu_(not(S1uu S2))(0)=1-0=1″,”],[mu_(not(S1uu S2))(20)=1-0.5=0.5″,”],[mu_(not(S1uu S2))(40)=1-0.65=0.35″,”],[mu_(not(S1uu S2))(60)=1-0.85=0.15″,”],[mu_(not(S1uu S2))(80)=1-1=0″,”],[mu_(not(S1uu S2))(100)=1-1=0.]:}\begin{aligned} \mu_{\neg(S1 \cup S2)}(0) &= 1 – 0 = 1, \\ \mu_{\neg(S1 \cup S2)}(20) &= 1 – 0.5 = 0.5, \\ \mu_{\neg(S1 \cup S2)}(40) &= 1 – 0.65 = 0.35, \\ \mu_{\neg(S1 \cup S2)}(60) &= 1 – 0.85 = 0.15, \\ \mu_{\neg(S1 \cup S2)}(80) &= 1 – 1 = 0, \\ \mu_{\neg(S1 \cup S2)}(100) &= 1 – 1 = 0. \end{aligned}μ¬(S1S2)(0)=10=1,μ¬(S1S2)(20)=10.5=0.5,μ¬(S1S2)(40)=10.65=0.35,μ¬(S1S2)(60)=10.85=0.15,μ¬(S1S2)(80)=11=0,μ¬(S1S2)(100)=11=0.
  3. Compute μ ¬ S 1 ( x ) μ ¬ S 2 ( x ) μ ¬ S 1 ( x ) μ ¬ S 2 ( x ) mu_(not S1)(x)nnmu_(not S2)(x)\mu_{\neg S1}(x) \cap \mu_{\neg S2}(x)μ¬S1(x)μ¬S2(x):
    The complement of Sensor 1 and Sensor 2 is:
    μ ¬ S 1 ( x ) = 1 μ S1 ( x ) , μ ¬ S 2 ( x ) = 1 μ S2 ( x ) μ ¬ S 1 ( x ) = 1 μ S1 ( x ) , μ ¬ S 2 ( x ) = 1 μ S2 ( x ) mu_(not S1)(x)=1-mu_(“S1”)(x),quadmu_(not S2)(x)=1-mu_(“S2”)(x)\mu_{\neg S1}(x) = 1 – \mu_{\text{S1}}(x), \quad \mu_{\neg S2}(x) = 1 – \mu_{\text{S2}}(x)μ¬S1(x)=1μS1(x),μ¬S2(x)=1μS2(x)
    For each value of x x xxx:
    μ ¬ S 1 ( 0 ) = 1 0 = 1 , μ ¬ S 2 ( 0 ) = 1 0 = 1 , μ ¬ S 1 ( 20 ) = 1 0.5 = 0.5 , μ ¬ S 2 ( 20 ) = 1 0.35 = 0.65 , μ ¬ S 1 ( 40 ) = 1 0.65 = 0.35 , μ ¬ S 2 ( 40 ) = 1 0.5 = 0.5 , μ ¬ S 1 ( 60 ) = 1 0.85 = 0.15 , μ ¬ S 2 ( 60 ) = 1 0.75 = 0.25 , μ ¬ S 1 ( 80 ) = 1 1 = 0 , μ ¬ S 2 ( 80 ) = 1 0.90 = 0.1 , μ ¬ S 1 ( 100 ) = 1 1 = 0 , μ ¬ S 2 ( 100 ) = 1 1 = 0. μ ¬ S 1 ( 0 ) = 1 0 = 1 , μ ¬ S 2 ( 0 ) = 1 0 = 1 , μ ¬ S 1 ( 20 ) = 1 0.5 = 0.5 , μ ¬ S 2 ( 20 ) = 1 0.35 = 0.65 , μ ¬ S 1 ( 40 ) = 1 0.65 = 0.35 , μ ¬ S 2 ( 40 ) = 1 0.5 = 0.5 , μ ¬ S 1 ( 60 ) = 1 0.85 = 0.15 , μ ¬ S 2 ( 60 ) = 1 0.75 = 0.25 , μ ¬ S 1 ( 80 ) = 1 1 = 0 , μ ¬ S 2 ( 80 ) = 1 0.90 = 0.1 , μ ¬ S 1 ( 100 ) = 1 1 = 0 , μ ¬ S 2 ( 100 ) = 1 1 = 0. {:[mu_(not S1)(0)=1-0=1″,”quadmu_(not S2)(0)=1-0=1″,”],[mu_(not S1)(20)=1-0.5=0.5″,”quadmu_(not S2)(20)=1-0.35=0.65″,”],[mu_(not S1)(40)=1-0.65=0.35″,”quadmu_(not S2)(40)=1-0.5=0.5″,”],[mu_(not S1)(60)=1-0.85=0.15″,”quadmu_(not S2)(60)=1-0.75=0.25″,”],[mu_(not S1)(80)=1-1=0″,”quadmu_(not S2)(80)=1-0.90=0.1″,”],[mu_(not S1)(100)=1-1=0″,”quadmu_(not S2)(100)=1-1=0.]:}\begin{aligned} \mu_{\neg S1}(0) &= 1 – 0 = 1, \quad &\mu_{\neg S2}(0) &= 1 – 0 = 1, \\ \mu_{\neg S1}(20) &= 1 – 0.5 = 0.5, \quad &\mu_{\neg S2}(20) &= 1 – 0.35 = 0.65, \\ \mu_{\neg S1}(40) &= 1 – 0.65 = 0.35, \quad &\mu_{\neg S2}(40) &= 1 – 0.5 = 0.5, \\ \mu_{\neg S1}(60) &= 1 – 0.85 = 0.15, \quad &\mu_{\neg S2}(60) &= 1 – 0.75 = 0.25, \\ \mu_{\neg S1}(80) &= 1 – 1 = 0, \quad &\mu_{\neg S2}(80) &= 1 – 0.90 = 0.1, \\ \mu_{\neg S1}(100) &= 1 – 1 = 0, \quad &\mu_{\neg S2}(100) &= 1 – 1 = 0. \end{aligned}μ¬S1(0)=10=1,μ¬S2(0)=10=1,μ¬S1(20)=10.5=0.5,μ¬S2(20)=10.35=0.65,μ¬S1(40)=10.65=0.35,μ¬S2(40)=10.5=0.5,μ¬S1(60)=10.85=0.15,μ¬S2(60)=10.75=0.25,μ¬S1(80)=11=0,μ¬S2(80)=10.90=0.1,μ¬S1(100)=11=0,μ¬S2(100)=11=0.
Now, compute the intersection (minimum):
μ ¬ S 1 ( 0 ) μ ¬ S 2 ( 0 ) = min ( 1 , 1 ) = 1 , μ ¬ S 1 ( 20 ) μ ¬ S 2 ( 20 ) = min ( 0.5 , 0.65 ) = 0.5 , μ ¬ S 1 ( 40 ) μ ¬ S 2 ( 40 ) = min ( 0.35 , 0.5 ) = 0.35 , μ ¬ S 1 ( 60 ) μ ¬ S 2 ( 60 ) = min ( 0.15 , 0.25 ) = 0.15 , μ ¬ S 1 ( 80 ) μ ¬ S 2 ( 80 ) = min ( 0 , 0.1 ) = 0 , μ ¬ S 1 ( 100 ) μ ¬ S 2 ( 100 ) = min ( 0 , 0 ) = 0. μ ¬ S 1 ( 0 ) μ ¬ S 2 ( 0 ) = min ( 1 , 1 ) = 1 , μ ¬ S 1 ( 20 ) μ ¬ S 2 ( 20 ) = min ( 0.5 , 0.65 ) = 0.5 , μ ¬ S 1 ( 40 ) μ ¬ S 2 ( 40 ) = min ( 0.35 , 0.5 ) = 0.35 , μ ¬ S 1 ( 60 ) μ ¬ S 2 ( 60 ) = min ( 0.15 , 0.25 ) = 0.15 , μ ¬ S 1 ( 80 ) μ ¬ S 2 ( 80 ) = min ( 0 , 0.1 ) = 0 , μ ¬ S 1 ( 100 ) μ ¬ S 2 ( 100 ) = min ( 0 , 0 ) = 0. {:[mu_(not S1)(0)nnmu_(not S2)(0)=min(1″,”1)=1″,”],[mu_(not S1)(20)nnmu_(not S2)(20)=min(0.5″,”0.65)=0.5″,”],[mu_(not S1)(40)nnmu_(not S2)(40)=min(0.35″,”0.5)=0.35″,”],[mu_(not S1)(60)nnmu_(not S2)(60)=min(0.15″,”0.25)=0.15″,”],[mu_(not S1)(80)nnmu_(not S2)(80)=min(0″,”0.1)=0″,”],[mu_(not S1)(100)nnmu_(not S2)(100)=min(0″,”0)=0.]:}\begin{aligned} \mu_{\neg S1}(0) \cap \mu_{\neg S2}(0) &= \min(1, 1) = 1, \\ \mu_{\neg S1}(20) \cap \mu_{\neg S2}(20) &= \min(0.5, 0.65) = 0.5, \\ \mu_{\neg S1}(40) \cap \mu_{\neg S2}(40) &= \min(0.35, 0.5) = 0.35, \\ \mu_{\neg S1}(60) \cap \mu_{\neg S2}(60) &= \min(0.15, 0.25) = 0.15, \\ \mu_{\neg S1}(80) \cap \mu_{\neg S2}(80) &= \min(0, 0.1) = 0, \\ \mu_{\neg S1}(100) \cap \mu_{\neg S2}(100) &= \min(0, 0) = 0. \end{aligned}μ¬S1(0)μ¬S2(0)=min(1,1)=1,μ¬S1(20)μ¬S2(20)=min(0.5,0.65)=0.5,μ¬S1(40)μ¬S2(40)=min(0.35,0.5)=0.35,μ¬S1(60)μ¬S2(60)=min(0.15,0.25)=0.15,μ¬S1(80)μ¬S2(80)=min(0,0.1)=0,μ¬S1(100)μ¬S2(100)=min(0,0)=0.
  1. Compare Results for the First Law:
    We can see that the results match for all values of x x xxx, so the first De Morgan law holds:
    μ ¬ ( S 1 S 2 ) ( x ) = μ ¬ S 1 ( x ) μ ¬ S 2 ( x ) μ ¬ ( S 1 S 2 ) ( x ) = μ ¬ S 1 ( x ) μ ¬ S 2 ( x ) mu_(not(S1uu S2))(x)=mu_(not S1)(x)nnmu_(not S2)(x)\mu_{\neg(S1 \cup S2)}(x) = \mu_{\neg S1}(x) \cap \mu_{\neg S2}(x)μ¬(S1S2)(x)=μ¬S1(x)μ¬S2(x)

Second Law: μ ¬ ( S 1 S 2 ) ( x ) = μ ¬ S 1 ( x ) μ ¬ S 2 ( x ) μ ¬ ( S 1 S 2 ) ( x ) = μ ¬ S 1 ( x ) μ ¬ S 2 ( x ) mu_(not(S1nn S2))(x)=mu_(not S1)(x)uumu_(not S2)(x)\mu_{\neg(S1 \cap S2)}(x) = \mu_{\neg S1}(x) \cup \mu_{\neg S2}(x)μ¬(S1S2)(x)=μ¬S1(x)μ¬S2(x)

  1. Compute μ S 1 S 2 ( x ) μ S 1 S 2 ( x ) mu_(S1nn S2)(x)\mu_{S1 \cap S2}(x)μS1S2(x):
    The intersection of two fuzzy sets is the minimum of the membership values:
    μ S 1 S 2 ( x ) = min ( μ S1 ( x ) , μ S2 ( x ) ) μ S 1 S 2 ( x ) = min ( μ S1 ( x ) , μ S2 ( x ) ) mu_(S1nn S2)(x)=min(mu_(“S1”)(x),mu_(“S2”)(x))\mu_{S1 \cap S2}(x) = \min(\mu_{\text{S1}}(x), \mu_{\text{S2}}(x))μS1S2(x)=min(μS1(x),μS2(x))
    For each value of x x xxx:
    μ S 1 S 2 ( 0 ) = min ( 0 , 0 ) = 0 , μ S 1 S 2 ( 20 ) = min ( 0.5 , 0.35 ) = 0.35 , μ S 1 S 2 ( 40 ) = min ( 0.65 , 0.5 ) = 0.5 , μ S 1 S 2 ( 60 ) = min ( 0.85 , 0.75 ) = 0.75 , μ S 1 S 2 ( 80 ) = min ( 1 , 0.90 ) = 0.90 , μ S 1 S 2 ( 100 ) = min ( 1 , 1 ) = 1. μ S 1 S 2 ( 0 ) = min ( 0 , 0 ) = 0 , μ S 1 S 2 ( 20 ) = min ( 0.5 , 0.35 ) = 0.35 , μ S 1 S 2 ( 40 ) = min ( 0.65 , 0.5 ) = 0.5 , μ S 1 S 2 ( 60 ) = min ( 0.85 , 0.75 ) = 0.75 , μ S 1 S 2 ( 80 ) = min ( 1 , 0.90 ) = 0.90 , μ S 1 S 2 ( 100 ) = min ( 1 , 1 ) = 1. {:[mu_(S1nn S2)(0)=min(0″,”0)=0″,”],[mu_(S1nn S2)(20)=min(0.5″,”0.35)=0.35″,”],[mu_(S1nn S2)(40)=min(0.65″,”0.5)=0.5″,”],[mu_(S1nn S2)(60)=min(0.85″,”0.75)=0.75″,”],[mu_(S1nn S2)(80)=min(1″,”0.90)=0.90″,”],[mu_(S1nn S2)(100)=min(1″,”1)=1.]:}\begin{aligned} \mu_{S1 \cap S2}(0) &= \min(0, 0) = 0, \\ \mu_{S1 \cap S2}(20) &= \min(0.5, 0.35) = 0.35, \\ \mu_{S1 \cap S2}(40) &= \min(0.65, 0.5) = 0.5, \\ \mu_{S1 \cap S2}(60) &= \min(0.85, 0.75) = 0.75, \\ \mu_{S1 \cap S2}(80) &= \min(1, 0.90) = 0.90, \\ \mu_{S1 \cap S2}(100) &= \min(1, 1) = 1. \end{aligned}μS1S2(0)=min(0,0)=0,μS1S2(20)=min(0.5,0.35)=0.35,μS1S2(40)=min(0.65,0.5)=0.5,μS1S2(60)=min(0.85,0.75)=0.75,μS1S2(80)=min(1,0.90)=0.90,μS1S2(100)=min(1,1)=1.
  2. Compute μ ¬ ( S 1 S 2 ) ( x ) μ ¬ ( S 1 S 2 ) ( x ) mu_(not(S1nn S2))(x)\mu_{\neg(S1 \cap S2)}(x)μ¬(S1S2)(x):
    The complement of S 1 S 2 S 1 S 2 S1nn S2S1 \cap S2S1S2 is:
    μ ¬ ( S 1 S 2 ) ( x ) = 1 μ S 1 S 2 ( x ) μ ¬ ( S 1 S 2 ) ( x ) = 1 μ S 1 S 2 ( x ) mu_(not(S1nn S2))(x)=1-mu_(S1nn S2)(x)\mu_{\neg(S1 \cap S2)}(x) = 1 – \mu_{S1 \cap S2}(x)μ¬(S1S2)(x)=1μS1S2(x)
    For each value of x x xxx:
    μ ¬ ( S 1 S 2 ) ( 0 ) = 1 0 = 1 , μ ¬ ( S 1 S 2 ) ( 20 ) = 1 0.35 = 0.65 , μ ¬ ( S 1 S 2 ) ( 40 ) = 1 0.5 = 0.5 , μ ¬ ( S 1 S 2 ) ( 60 ) = 1 0.75 = 0.25 , μ ¬ ( S 1 S 2 ) ( 80 ) = 1 0.90 = 0.10 , μ ¬ ( S 1 S 2 ) ( 100 ) = 1 1 = 0. μ ¬ ( S 1 S 2 ) ( 0 ) = 1 0 = 1 , μ ¬ ( S 1 S 2 ) ( 20 ) = 1 0.35 = 0.65 , μ ¬ ( S 1 S 2 ) ( 40 ) = 1 0.5 = 0.5 , μ ¬ ( S 1 S 2 ) ( 60 ) = 1 0.75 = 0.25 , μ ¬ ( S 1 S 2 ) ( 80 ) = 1 0.90 = 0.10 , μ ¬ ( S 1 S 2 ) ( 100 ) = 1 1 = 0. {:[mu_(not(S1nn S2))(0)=1-0=1″,”],[mu_(not(S1nn S2))(20)=1-0.35=0.65″,”],[mu_(not(S1nn S2))(40)=1-0.5=0.5″,”],[mu_(not(S1nn S2))(60)=1-0.75=0.25″,”],[mu_(not(S1nn S2))(80)=1-0.90=0.10″,”],[mu_(not(S1nn S2))(100)=1-1=0.]:}\begin{aligned} \mu_{\neg(S1 \cap S2)}(0) &= 1 – 0 = 1, \\ \mu_{\neg(S1 \cap S2)}(20) &= 1 – 0.35 = 0.65, \\ \mu_{\neg(S1 \cap S2)}(40) &= 1 – 0.5 = 0.5, \\ \mu_{\neg(S1 \cap S2)}(60) &= 1 – 0.75 = 0.25, \\ \mu_{\neg(S1 \cap S2)}(80) &= 1 – 0.90 = 0.10, \\ \mu_{\neg(S1 \cap S2)}(100) &= 1 – 1 = 0. \end{aligned}μ¬(S1S2)(0)=10=1,μ¬(S1S2)(20)=10.35=0.65,μ¬(S1S2)(40)=10.5=0.5,μ¬(S1S2)(60)=10.75=0.25,μ¬(S1S2)(80)=10.90=0.10,μ¬(S1S2)(100)=11=0.
  3. Compute μ ¬ S 1 ( x ) μ ¬ S 2 ( x ) μ ¬ S 1 ( x ) μ ¬ S 2 ( x ) mu_(not S1)(x)uumu_(not S2)(x)\mu_{\neg S1}(x) \cup \mu_{\neg S2}(x)μ¬S1(x)μ¬S2(x):
    The union (maximum) is:
    μ ¬ S 1 ( x ) μ ¬ S 2 ( x ) = max ( 1 μ S1 ( x ) , 1 μ S2 ( x ) ) μ ¬ S 1 ( x ) μ ¬ S 2 ( x ) = max ( 1 μ S1 ( x ) , 1 μ S2 ( x ) ) mu_(not S1)(x)uumu_(not S2)(x)=max(1-mu_(“S1”)(x),1-mu_(“S2”)(x))\mu_{\neg S1}(x) \cup \mu_{\neg S2}(x) = \max(1 – \mu_{\text{S1}}(x), 1 – \mu_{\text{S2}}(x))μ¬S1(x)μ¬S2(x)=max(1μS1(x),1μS2(x))
    For each value of x x xxx:
    μ ¬ S 1 ( 0 ) μ ¬ S 2 ( 0 ) = max ( 1 , 1 ) = 1 , μ ¬ S 1 ( 20 ) μ ¬ S 2 ( 20 ) = max ( 0.5 , 0.65 ) = 0.65 , μ ¬ S 1 ( 40 ) μ ¬ S 2 ( 40 ) = max ( 0.35 , 0.5 ) = 0.5 , μ ¬ S 1 ( 60 ) μ ¬ S 2 ( 60 ) = max ( 0.15 , 0.25 ) = 0.25 , μ ¬ S 1 ( 80 ) μ ¬ S 2 ( 80 ) = max ( 0 , 0.1 ) = 0.1 , μ ¬ S 1 ( 100 ) μ ¬ S 2 ( 100 ) = max ( 0 , 0 ) = 0. μ ¬ S 1 ( 0 ) μ ¬ S 2 ( 0 ) = max ( 1 , 1 ) = 1 , μ ¬ S 1 ( 20 ) μ ¬ S 2 ( 20 ) = max ( 0.5 , 0.65 ) = 0.65 , μ ¬ S 1 ( 40 ) μ ¬ S 2 ( 40 ) = max ( 0.35 , 0.5 ) = 0.5 , μ ¬ S 1 ( 60 ) μ ¬ S 2 ( 60 ) = max ( 0.15 , 0.25 ) = 0.25 , μ ¬ S 1 ( 80 ) μ ¬ S 2 ( 80 ) = max ( 0 , 0.1 ) = 0.1 , μ ¬ S 1 ( 100 ) μ ¬ S 2 ( 100 ) = max ( 0 , 0 ) = 0. {:[mu_(not S1)(0)uumu_(not S2)(0)=max(1″,”1)=1″,”],[mu_(not S1)(20)uumu_(not S2)(20)=max(0.5″,”0.65)=0.65″,”],[mu_(not S1)(40)uumu_(not S2)(40)=max(0.35″,”0.5)=0.5″,”],[mu_(not S1)(60)uumu_(not S2)(60)=max(0.15″,”0.25)=0.25″,”],[mu_(not S1)(80)uumu_(not S2)(80)=max(0″,”0.1)=0.1″,”],[mu_(not S1)(100)uumu_(not S2)(100)=max(0″,”0)=0.]:}\begin{aligned} \mu_{\neg S1}(0) \cup \mu_{\neg S2}(0) &= \max(1, 1) = 1, \\ \mu_{\neg S1}(20) \cup \mu_{\neg S2}(20) &= \max(0.5, 0.65) = 0.65, \\ \mu_{\neg S1}(40) \cup \mu_{\neg S2}(40) &= \max(0.35, 0.5) = 0.5, \\ \mu_{\neg S1}(60) \cup \mu_{\neg S2}(60) &= \max(0.15, 0.25) = 0.25, \\ \mu_{\neg S1}(80) \cup \mu_{\neg S2}(80) &= \max(0, 0.1) = 0.1, \\ \mu_{\neg S1}(100) \cup \mu_{\neg S2}(100) &= \max(0, 0) = 0. \end{aligned}μ¬S1(0)μ¬S2(0)=max(1,1)=1,μ¬S1(20)μ¬S2(20)=max(0.5,0.65)=0.65,μ¬S1(40)μ¬S2(40)=max(0.35,0.5)=0.5,μ¬S1(60)μ¬S2(60)=max(0.15,0.25)=0.25,μ¬S1(80)μ¬S2(80)=max(0,0.1)=0.1,μ¬S1(100)μ¬S2(100)=max(0,0)=0.
  4. Compare Results for the Second Law:
    We can see that the results match for all values of x x xxx, so the second De Morgan law holds:
    μ ¬ ( S 1 S 2 ) ( x ) = μ ¬ S 1 ( x ) μ ¬ S 2 ( x ) μ ¬ ( S 1 S 2 ) ( x ) = μ ¬ S 1 ( x ) μ ¬ S 2 ( x ) mu_(not(S1nn S2))(x)=mu_(not S1)(x)uumu_(not S2)(x)\mu_{\neg(S1 \cap S2)}(x) = \mu_{\neg S1}(x) \cup \mu_{\neg S2}(x)μ¬(S1S2)(x)=μ¬S1(x)μ¬S2(x)

Final Answer:

The membership functions for the two sensors are:
  • For Sensor 1:
    μ S1 ( x ) = { ( 0 , 0 ) , ( 20 , 0.5 ) , ( 40 , 0.65 ) , ( 60 , 0.85 ) , ( 80 , 1 ) , ( 100 , 1 ) } μ S1 ( x ) = { ( 0 , 0 ) , ( 20 , 0.5 ) , ( 40 , 0.65 ) , ( 60 , 0.85 ) , ( 80 , 1 ) , ( 100 , 1 ) } mu_(“S1”)(x)={(0,0),(20,0.5),(40,0.65),(60,0.85),(80,1),(100,1)}\mu_{\text{S1}}(x) = \{(0, 0), (20, 0.5), (40, 0.65), (60, 0.85), (80, 1), (100, 1)\}μS1(x)={(0,0),(20,0.5),(40,0.65),(60,0.85),(80,1),(100,1)}
  • For Sensor 2:
    μ S2 ( x ) = { ( 0 , 0 ) , ( 20 , 0.35 ) , ( 40 , 0.5 ) , ( 60 , 0.75 ) , ( 80 , 0.90 ) , ( 100 , 1 ) } μ S2 ( x ) = { ( 0 , 0 ) , ( 20 , 0.35 ) , ( 40 , 0.5 ) , ( 60 , 0.75 ) , ( 80 , 0.90 ) , ( 100 , 1 ) } mu_(“S2”)(x)={(0,0),(20,0.35),(40,0.5),(60,0.75),(80,0.90),(100,1)}\mu_{\text{S2}}(x) = \{(0, 0), (20, 0.35), (40, 0.5), (60, 0.75), (80, 0.90), (100, 1)\}μS2(x)={(0,0),(20,0.35),(40,0.5),(60,0.75),(80,0.90),(100,1)}
We have also verified that both De Morgan’s laws hold for these membership functions.




Question:-1(b)

Consider a subset of natural numbers from 1 to 30, as the universe of discourse, U U UUU. Define the fuzzy sets "small" and "medium" by enumeration.

Answer:

We are given a universe of discourse U U UUU, which is the set of natural numbers from 1 to 30:
U = { 1 , 2 , 3 , , 30 } U = { 1 , 2 , 3 , , 30 } U={1,2,3,dots,30}U = \{1, 2, 3, \dots, 30\}U={1,2,3,,30}
We are tasked with defining two fuzzy sets: "small" and "medium". A fuzzy set is characterized by a membership function that assigns each element in the universe a membership value between 0 and 1, indicating the degree to which that element belongs to the set.

Define the Fuzzy Set "Small"

The fuzzy set "small" should intuitively have higher membership values for smaller numbers and lower values as the numbers increase. A possible definition could be:
  • For numbers near 1, the membership value is close to 1.
  • For numbers near 30, the membership value is close to 0.
One possible membership function for "small" could be defined as:
μ small ( x ) = { 1 if 1 x 10 20 x 10 if 11 x 20 0 if 21 x 30 μ small ( x ) = 1 if 1 x 10 20 x 10 if 11 x 20 0 if 21 x 30 mu_(“small”)(x)={[1,”if “1 <= x <= 10],[(20-x)/(10),”if “11 <= x <= 20],[0,”if “21 <= x <= 30]:}\mu_{\text{small}}(x) = \begin{cases} 1 & \text{if } 1 \leq x \leq 10 \\ \frac{20 – x}{10} & \text{if } 11 \leq x \leq 20 \\ 0 & \text{if } 21 \leq x \leq 30 \end{cases}μsmall(x)={1if 1x1020x10if 11x200if 21x30
Thus, by enumeration, the fuzzy set "small" is:
μ small ( x ) = { ( 1 , 1 ) , ( 2 , 1 ) , ( 3 , 1 ) , ( 4 , 1 ) , ( 5 , 1 ) , ( 6 , 1 ) , ( 7 , 1 ) , ( 8 , 1 ) , ( 9 , 1 ) , ( 10 , 1 ) , ( 11 , 0.9 ) , ( 12 , 0.8 ) , ( 13 , 0.7 ) , ( 14 , 0.6 ) , ( 15 , 0.5 ) , ( 16 , 0.4 ) , ( 17 , 0.3 ) , ( 18 , 0.2 ) , ( 19 , 0.1 ) , ( 20 , 0 ) , ( 21 , 0 ) , , ( 30 , 0 ) } μ small ( x ) = { ( 1 , 1 ) , ( 2 , 1 ) , ( 3 , 1 ) , ( 4 , 1 ) , ( 5 , 1 ) , ( 6 , 1 ) , ( 7 , 1 ) , ( 8 , 1 ) , ( 9 , 1 ) , ( 10 , 1 ) , ( 11 , 0.9 ) , ( 12 , 0.8 ) , ( 13 , 0.7 ) , ( 14 , 0.6 ) , ( 15 , 0.5 ) , ( 16 , 0.4 ) , ( 17 , 0.3 ) , ( 18 , 0.2 ) , ( 19 , 0.1 ) , ( 20 , 0 ) , ( 21 , 0 ) , , ( 30 , 0 ) } mu_(“small”)(x)={(1,1),(2,1),(3,1),(4,1),(5,1),(6,1),(7,1),(8,1),(9,1),(10,1),(11,0.9),(12,0.8),(13,0.7),(14,0.6),(15,0.5),(16,0.4),(17,0.3),(18,0.2),(19,0.1),(20,0),(21,0),dots,(30,0)}\mu_{\text{small}}(x) = \{ (1, 1), (2, 1), (3, 1), (4, 1), (5, 1), (6, 1), (7, 1), (8, 1), (9, 1), (10, 1), (11, 0.9), (12, 0.8), (13, 0.7), (14, 0.6), (15, 0.5), (16, 0.4), (17, 0.3), (18, 0.2), (19, 0.1), (20, 0), (21, 0), \dots, (30, 0) \}μsmall(x)={(1,1),(2,1),(3,1),(4,1),(5,1),(6,1),(7,1),(8,1),(9,1),(10,1),(11,0.9),(12,0.8),(13,0.7),(14,0.6),(15,0.5),(16,0.4),(17,0.3),(18,0.2),(19,0.1),(20,0),(21,0),,(30,0)}

Define the Fuzzy Set "Medium"

The fuzzy set "medium" should intuitively have higher membership values for numbers in the middle range (e.g., around 15) and lower membership values for smaller and larger numbers.
One possible membership function for "medium" could be defined as:
  • The membership value is 0 for numbers below 5 and above 25.
  • The membership value increases from 0 to 1 as numbers go from 5 to 15.
  • The membership value decreases from 1 to 0 as numbers go from 15 to 25.
Mathematically, we can define the membership function for "medium" as:
μ medium ( x ) = { 0 if x 5 or x 25 x 5 10 if 6 x 15 25 x 10 if 16 x 24 μ medium ( x ) = 0 if x 5 or x 25 x 5 10 if 6 x 15 25 x 10 if 16 x 24 mu_(“medium”)(x)={[0,”if “x <= 5” or “x >= 25],[(x-5)/(10),”if “6 <= x <= 15],[(25-x)/(10),”if “16 <= x <= 24]:}\mu_{\text{medium}}(x) = \begin{cases} 0 & \text{if } x \leq 5 \text{ or } x \geq 25 \\ \frac{x – 5}{10} & \text{if } 6 \leq x \leq 15 \\ \frac{25 – x}{10} & \text{if } 16 \leq x \leq 24 \end{cases}μmedium(x)={0if x5 or x25x510if 6x1525x10if 16x24
Thus, by enumeration, the fuzzy set "medium" is:
μ medium ( x ) = { ( 1 , 0 ) , ( 2 , 0 ) , ( 3 , 0 ) , ( 4 , 0 ) , ( 5 , 0 ) , ( 6 , 0.1 ) , ( 7 , 0.2 ) , ( 8 , 0.3 ) , ( 9 , 0.4 ) , ( 10 , 0.5 ) , ( 11 , 0.6 ) , ( 12 , 0.7 ) , ( 13 , 0.8 ) , ( 14 , 0.9 ) , ( 15 , 1 ) , ( 16 , 0.9 ) , ( 17 , 0.8 ) , ( 18 , 0.7 ) , ( 19 , 0.6 ) , ( 20 , 0.5 ) , ( 21 , 0.4 ) , ( 22 , 0.3 ) , ( 23 , 0.2 ) , ( 24 , 0.1 ) , ( 25 , 0 ) , ( 26 , 0 ) , , ( 30 , 0 ) } μ medium ( x ) = { ( 1 , 0 ) , ( 2 , 0 ) , ( 3 , 0 ) , ( 4 , 0 ) , ( 5 , 0 ) , ( 6 , 0.1 ) , ( 7 , 0.2 ) , ( 8 , 0.3 ) , ( 9 , 0.4 ) , ( 10 , 0.5 ) , ( 11 , 0.6 ) , ( 12 , 0.7 ) , ( 13 , 0.8 ) , ( 14 , 0.9 ) , ( 15 , 1 ) , ( 16 , 0.9 ) , ( 17 , 0.8 ) , ( 18 , 0.7 ) , ( 19 , 0.6 ) , ( 20 , 0.5 ) , ( 21 , 0.4 ) , ( 22 , 0.3 ) , ( 23 , 0.2 ) , ( 24 , 0.1 ) , ( 25 , 0 ) , ( 26 , 0 ) , , ( 30 , 0 ) } mu_(“medium”)(x)={(1,0),(2,0),(3,0),(4,0),(5,0),(6,0.1),(7,0.2),(8,0.3),(9,0.4),(10,0.5),(11,0.6),(12,0.7),(13,0.8),(14,0.9),(15,1),(16,0.9),(17,0.8),(18,0.7),(19,0.6),(20,0.5),(21,0.4),(22,0.3),(23,0.2),(24,0.1),(25,0),(26,0),dots,(30,0)}\mu_{\text{medium}}(x) = \{ (1, 0), (2, 0), (3, 0), (4, 0), (5, 0), (6, 0.1), (7, 0.2), (8, 0.3), (9, 0.4), (10, 0.5), (11, 0.6), (12, 0.7), (13, 0.8), (14, 0.9), (15, 1), (16, 0.9), (17, 0.8), (18, 0.7), (19, 0.6), (20, 0.5), (21, 0.4), (22, 0.3), (23, 0.2), (24, 0.1), (25, 0), (26, 0), \dots, (30, 0) \}μmedium(x)={(1,0),(2,0),(3,0),(4,0),(5,0),(6,0.1),(7,0.2),(8,0.3),(9,0.4),(10,0.5),(11,0.6),(12,0.7),(13,0.8),(14,0.9),(15,1),(16,0.9),(17,0.8),(18,0.7),(19,0.6),(20,0.5),(21,0.4),(22,0.3),(23,0.2),(24,0.1),(25,0),(26,0),,(30,0)}

Final Answer

  • Fuzzy set "small": Membership values decrease as x x xxx increases.
μ small ( x ) = { ( 1 , 1 ) , ( 2 , 1 ) , ( 3 , 1 ) , , ( 10 , 1 ) , ( 11 , 0.9 ) , , ( 19 , 0.1 ) , ( 20 , 0 ) , ( 21 , 0 ) , , ( 30 , 0 ) } μ small ( x ) = { ( 1 , 1 ) , ( 2 , 1 ) , ( 3 , 1 ) , , ( 10 , 1 ) , ( 11 , 0.9 ) , , ( 19 , 0.1 ) , ( 20 , 0 ) , ( 21 , 0 ) , , ( 30 , 0 ) } mu_(“small”)(x)={(1,1),(2,1),(3,1),dots,(10,1),(11,0.9),dots,(19,0.1),(20,0),(21,0),dots,(30,0)}\mu_{\text{small}}(x) = \{(1, 1), (2, 1), (3, 1), \dots, (10, 1), (11, 0.9), \dots, (19, 0.1), (20, 0), (21, 0), \dots, (30, 0)\}μsmall(x)={(1,1),(2,1),(3,1),,(10,1),(11,0.9),,(19,0.1),(20,0),(21,0),,(30,0)}
  • Fuzzy set "medium": Membership values peak around 15 and decrease towards the edges.
μ medium ( x ) = { ( 1 , 0 ) , ( 2 , 0 ) , ( 3 , 0 ) , , ( 6 , 0.1 ) , ( 10 , 0.5 ) , ( 15 , 1 ) , ( 20 , 0.5 ) , ( 25 , 0 ) , , ( 30 , 0 ) } μ medium ( x ) = { ( 1 , 0 ) , ( 2 , 0 ) , ( 3 , 0 ) , , ( 6 , 0.1 ) , ( 10 , 0.5 ) , ( 15 , 1 ) , ( 20 , 0.5 ) , ( 25 , 0 ) , , ( 30 , 0 ) } mu_(“medium”)(x)={(1,0),(2,0),(3,0),dots,(6,0.1),(10,0.5),(15,1),(20,0.5),(25,0),dots,(30,0)}\mu_{\text{medium}}(x) = \{(1, 0), (2, 0), (3, 0), \dots, (6, 0.1), (10, 0.5), (15, 1), (20, 0.5), (25, 0), \dots, (30, 0)\}μmedium(x)={(1,0),(2,0),(3,0),,(6,0.1),(10,0.5),(15,1),(20,0.5),(25,0),,(30,0)}




Question:-2(a)

Construct the α α alpha\alphaα-cut at α = 0.4 α = 0.4 alpha=0.4\alpha=0.4α=0.4 for the fuzzy sets defined in Q. 1(b).

Answer:

To construct the α α alpha\alphaα-cut for the fuzzy sets "small" and "medium" at α = 0.4 α = 0.4 alpha=0.4\alpha = 0.4α=0.4, we need to identify all the elements in the universe of discourse U = { 1 , 2 , , 30 } U = { 1 , 2 , , 30 } U={1,2,dots,30}U = \{1, 2, \dots, 30\}U={1,2,,30} where the membership values are greater than or equal to 0.4.

Recap of the Membership Functions

Fuzzy Set "Small" Membership Function:

μ small ( x ) = { ( 1 , 1 ) , ( 2 , 1 ) , ( 3 , 1 ) , ( 4 , 1 ) , ( 5 , 1 ) , ( 6 , 1 ) , ( 7 , 1 ) , ( 8 , 1 ) , ( 9 , 1 ) , ( 10 , 1 ) , ( 11 , 0.9 ) , ( 12 , 0.8 ) , ( 13 , 0.7 ) , ( 14 , 0.6 ) , ( 15 , 0.5 ) , ( 16 , 0.4 ) , ( 17 , 0.3 ) , ( 18 , 0.2 ) , ( 19 , 0.1 ) , ( 20 , 0 ) , ( 21 , 0 ) , , ( 30 , 0 ) } μ small ( x ) = { ( 1 , 1 ) , ( 2 , 1 ) , ( 3 , 1 ) , ( 4 , 1 ) , ( 5 , 1 ) , ( 6 , 1 ) , ( 7 , 1 ) , ( 8 , 1 ) , ( 9 , 1 ) , ( 10 , 1 ) , ( 11 , 0.9 ) , ( 12 , 0.8 ) , ( 13 , 0.7 ) , ( 14 , 0.6 ) , ( 15 , 0.5 ) , ( 16 , 0.4 ) , ( 17 , 0.3 ) , ( 18 , 0.2 ) , ( 19 , 0.1 ) , ( 20 , 0 ) , ( 21 , 0 ) , , ( 30 , 0 ) } mu_(“small”)(x)={(1,1),(2,1),(3,1),(4,1),(5,1),(6,1),(7,1),(8,1),(9,1),(10,1),(11,0.9),(12,0.8),(13,0.7),(14,0.6),(15,0.5),(16,0.4),(17,0.3),(18,0.2),(19,0.1),(20,0),(21,0),dots,(30,0)}\mu_{\text{small}}(x) = \{(1, 1), (2, 1), (3, 1), (4, 1), (5, 1), (6, 1), (7, 1), (8, 1), (9, 1), (10, 1), (11, 0.9), (12, 0.8), (13, 0.7), (14, 0.6), (15, 0.5), (16, 0.4), (17, 0.3), (18, 0.2), (19, 0.1), (20, 0), (21, 0), \dots, (30, 0)\}μsmall(x)={(1,1),(2,1),(3,1),(4,1),(5,1),(6,1),(7,1),(8,1),(9,1),(10,1),(11,0.9),(12,0.8),(13,0.7),(14,0.6),(15,0.5),(16,0.4),(17,0.3),(18,0.2),(19,0.1),(20,0),(21,0),,(30,0)}

Fuzzy Set "Medium" Membership Function:

μ medium ( x ) = { ( 1 , 0 ) , ( 2 , 0 ) , ( 3 , 0 ) , ( 4 , 0 ) , ( 5 , 0 ) , ( 6 , 0.1 ) , ( 7 , 0.2 ) , ( 8 , 0.3 ) , ( 9 , 0.4 ) , ( 10 , 0.5 ) , ( 11 , 0.6 ) , ( 12 , 0.7 ) , ( 13 , 0.8 ) , ( 14 , 0.9 ) , ( 15 , 1 ) , ( 16 , 0.9 ) , ( 17 , 0.8 ) , ( 18 , 0.7 ) , ( 19 , 0.6 ) , ( 20 , 0.5 ) , ( 21 , 0.4 ) , ( 22 , 0.3 ) , ( 23 , 0.2 ) , ( 24 , 0.1 ) , ( 25 , 0 ) , ( 26 , 0 ) , , ( 30 , 0 ) } μ medium ( x ) = { ( 1 , 0 ) , ( 2 , 0 ) , ( 3 , 0 ) , ( 4 , 0 ) , ( 5 , 0 ) , ( 6 , 0.1 ) , ( 7 , 0.2 ) , ( 8 , 0.3 ) , ( 9 , 0.4 ) , ( 10 , 0.5 ) , ( 11 , 0.6 ) , ( 12 , 0.7 ) , ( 13 , 0.8 ) , ( 14 , 0.9 ) , ( 15 , 1 ) , ( 16 , 0.9 ) , ( 17 , 0.8 ) , ( 18 , 0.7 ) , ( 19 , 0.6 ) , ( 20 , 0.5 ) , ( 21 , 0.4 ) , ( 22 , 0.3 ) , ( 23 , 0.2 ) , ( 24 , 0.1 ) , ( 25 , 0 ) , ( 26 , 0 ) , , ( 30 , 0 ) } mu_(“medium”)(x)={(1,0),(2,0),(3,0),(4,0),(5,0),(6,0.1),(7,0.2),(8,0.3),(9,0.4),(10,0.5),(11,0.6),(12,0.7),(13,0.8),(14,0.9),(15,1),(16,0.9),(17,0.8),(18,0.7),(19,0.6),(20,0.5),(21,0.4),(22,0.3),(23,0.2),(24,0.1),(25,0),(26,0),dots,(30,0)}\mu_{\text{medium}}(x) = \{(1, 0), (2, 0), (3, 0), (4, 0), (5, 0), (6, 0.1), (7, 0.2), (8, 0.3), (9, 0.4), (10, 0.5), (11, 0.6), (12, 0.7), (13, 0.8), (14, 0.9), (15, 1), (16, 0.9), (17, 0.8), (18, 0.7), (19, 0.6), (20, 0.5), (21, 0.4), (22, 0.3), (23, 0.2), (24, 0.1), (25, 0), (26, 0), \dots, (30, 0)\}μmedium(x)={(1,0),(2,0),(3,0),(4,0),(5,0),(6,0.1),(7,0.2),(8,0.3),(9,0.4),(10,0.5),(11,0.6),(12,0.7),(13,0.8),(14,0.9),(15,1),(16,0.9),(17,0.8),(18,0.7),(19,0.6),(20,0.5),(21,0.4),(22,0.3),(23,0.2),(24,0.1),(25,0),(26,0),,(30,0)}

Definition of α α alpha\alphaα-cut

The α α alpha\alphaα-cut of a fuzzy set is the crisp set of all elements in the universe of discourse whose membership values are greater than or equal to α α alpha\alphaα.
A α = { x U μ A ( x ) α } A α = { x U μ A ( x ) α } A_(alpha)={x in U∣mu _(A)(x) >= alpha}A_{\alpha} = \{ x \in U \mid \mu_A(x) \geq \alpha \}Aα={xUμA(x)α}
For α = 0.4 α = 0.4 alpha=0.4\alpha = 0.4α=0.4, we need to find all the elements x x xxx such that their membership values in the fuzzy sets "small" and "medium" are greater than or equal to 0.4.

1. α α alpha\alphaα-cut for the Fuzzy Set "Small" at α = 0.4 α = 0.4 alpha=0.4\alpha = 0.4α=0.4

Looking at the fuzzy set "small", we select all the values of x x xxx where μ small ( x ) 0.4 μ small ( x ) 0.4 mu_(“small”)(x) >= 0.4\mu_{\text{small}}(x) \geq 0.4μsmall(x)0.4:
μ small ( x ) = { ( 1 , 1 ) , ( 2 , 1 ) , ( 3 , 1 ) , ( 4 , 1 ) , ( 5 , 1 ) , ( 6 , 1 ) , ( 7 , 1 ) , ( 8 , 1 ) , ( 9 , 1 ) , ( 10 , 1 ) , ( 11 , 0.9 ) , ( 12 , 0.8 ) , ( 13 , 0.7 ) , ( 14 , 0.6 ) , ( 15 , 0.5 ) , ( 16 , 0.4 ) } μ small ( x ) = { ( 1 , 1 ) , ( 2 , 1 ) , ( 3 , 1 ) , ( 4 , 1 ) , ( 5 , 1 ) , ( 6 , 1 ) , ( 7 , 1 ) , ( 8 , 1 ) , ( 9 , 1 ) , ( 10 , 1 ) , ( 11 , 0.9 ) , ( 12 , 0.8 ) , ( 13 , 0.7 ) , ( 14 , 0.6 ) , ( 15 , 0.5 ) , ( 16 , 0.4 ) } mu_(“small”)(x)={(1,1),(2,1),(3,1),(4,1),(5,1),(6,1),(7,1),(8,1),(9,1),(10,1),(11,0.9),(12,0.8),(13,0.7),(14,0.6),(15,0.5),(16,0.4)}\mu_{\text{small}}(x) = \{(1, 1), (2, 1), (3, 1), (4, 1), (5, 1), (6, 1), (7, 1), (8, 1), (9, 1), (10, 1), (11, 0.9), (12, 0.8), (13, 0.7), (14, 0.6), (15, 0.5), (16, 0.4)\}μsmall(x)={(1,1),(2,1),(3,1),(4,1),(5,1),(6,1),(7,1),(8,1),(9,1),(10,1),(11,0.9),(12,0.8),(13,0.7),(14,0.6),(15,0.5),(16,0.4)}
So, the α = 0.4 α = 0.4 alpha=0.4\alpha = 0.4α=0.4 cut for the fuzzy set "small" is:
A 0.4 small = { 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 11 , 12 , 13 , 14 , 15 , 16 } A 0.4 small = { 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 11 , 12 , 13 , 14 , 15 , 16 } A_(0.4)^(“small”)={1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16}A_{0.4}^{\text{small}} = \{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16\}A0.4small={1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16}

2. α α alpha\alphaα-cut for the Fuzzy Set "Medium" at α = 0.4 α = 0.4 alpha=0.4\alpha = 0.4α=0.4

Looking at the fuzzy set "medium", we select all the values of x x xxx where μ medium ( x ) 0.4 μ medium ( x ) 0.4 mu_(“medium”)(x) >= 0.4\mu_{\text{medium}}(x) \geq 0.4μmedium(x)0.4:
μ medium ( x ) = { ( 9 , 0.4 ) , ( 10 , 0.5 ) , ( 11 , 0.6 ) , ( 12 , 0.7 ) , ( 13 , 0.8 ) , ( 14 , 0.9 ) , ( 15 , 1 ) , ( 16 , 0.9 ) , ( 17 , 0.8 ) , ( 18 , 0.7 ) , ( 19 , 0.6 ) , ( 20 , 0.5 ) , ( 21 , 0.4 ) } μ medium ( x ) = { ( 9 , 0.4 ) , ( 10 , 0.5 ) , ( 11 , 0.6 ) , ( 12 , 0.7 ) , ( 13 , 0.8 ) , ( 14 , 0.9 ) , ( 15 , 1 ) , ( 16 , 0.9 ) , ( 17 , 0.8 ) , ( 18 , 0.7 ) , ( 19 , 0.6 ) , ( 20 , 0.5 ) , ( 21 , 0.4 ) } mu_(“medium”)(x)={(9,0.4),(10,0.5),(11,0.6),(12,0.7),(13,0.8),(14,0.9),(15,1),(16,0.9),(17,0.8),(18,0.7),(19,0.6),(20,0.5),(21,0.4)}\mu_{\text{medium}}(x) = \{(9, 0.4), (10, 0.5), (11, 0.6), (12, 0.7), (13, 0.8), (14, 0.9), (15, 1), (16, 0.9), (17, 0.8), (18, 0.7), (19, 0.6), (20, 0.5), (21, 0.4)\}μmedium(x)={(9,0.4),(10,0.5),(11,0.6),(12,0.7),(13,0.8),(14,0.9),(15,1),(16,0.9),(17,0.8),(18,0.7),(19,0.6),(20,0.5),(21,0.4)}
So, the α = 0.4 α = 0.4 alpha=0.4\alpha = 0.4α=0.4 cut for the fuzzy set "medium" is:
A 0.4 medium = { 9 , 10 , 11 , 12 , 13 , 14 , 15 , 16 , 17 , 18 , 19 , 20 , 21 } A 0.4 medium = { 9 , 10 , 11 , 12 , 13 , 14 , 15 , 16 , 17 , 18 , 19 , 20 , 21 } A_(0.4)^(“medium”)={9,10,11,12,13,14,15,16,17,18,19,20,21}A_{0.4}^{\text{medium}} = \{9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21\}A0.4medium={9,10,11,12,13,14,15,16,17,18,19,20,21}

Final Answer

  • The α = 0.4 α = 0.4 alpha=0.4\alpha = 0.4α=0.4-cut for the fuzzy set "small" is:
    A 0.4 small = { 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 11 , 12 , 13 , 14 , 15 , 16 } A 0.4 small = { 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 11 , 12 , 13 , 14 , 15 , 16 } A_(0.4)^(“small”)={1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16}A_{0.4}^{\text{small}} = \{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16\}A0.4small={1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16}
  • The α = 0.4 α = 0.4 alpha=0.4\alpha = 0.4α=0.4-cut for the fuzzy set "medium" is:
    A 0.4 medium = { 9 , 10 , 11 , 12 , 13 , 14 , 15 , 16 , 17 , 18 , 19 , 20 , 21 } A 0.4 medium = { 9 , 10 , 11 , 12 , 13 , 14 , 15 , 16 , 17 , 18 , 19 , 20 , 21 } A_(0.4)^(“medium”)={9,10,11,12,13,14,15,16,17,18,19,20,21}A_{0.4}^{\text{medium}} = \{9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21\}A0.4medium={9,10,11,12,13,14,15,16,17,18,19,20,21}




Question:-2(b)

Apply the "very" hedge on the fuzzy sets defined in Q. 1(b) to get the new modified fuzzy sets. Show the modified fuzzy sets through numeration.

Answer:

In fuzzy logic, a hedge is a linguistic modifier that affects the membership values of a fuzzy set. The hedge "very" typically squares the membership values of a fuzzy set, making the set more restrictive (i.e., it reduces the membership values of elements that are not fully in the set).
For a fuzzy set A A AAA with membership function μ A ( x ) μ A ( x ) mu _(A)(x)\mu_A(x)μA(x), the modified fuzzy set under the "very" hedge has a membership function defined as:
μ very A ( x ) = ( μ A ( x ) ) 2 μ very A ( x ) = ( μ A ( x ) ) 2 mu_(“very “A)(x)=(mu _(A)(x))^(2)\mu_{\text{very } A}(x) = (\mu_A(x))^2μvery A(x)=(μA(x))2
We will apply this hedge to the fuzzy sets "small" and "medium" from the previous question.

Recap of the Membership Functions

Fuzzy Set "Small" Membership Function:

μ small ( x ) = { ( 1 , 1 ) , ( 2 , 1 ) , ( 3 , 1 ) , ( 4 , 1 ) , ( 5 , 1 ) , ( 6 , 1 ) , ( 7 , 1 ) , ( 8 , 1 ) , ( 9 , 1 ) , ( 10 , 1 ) , ( 11 , 0.9 ) , ( 12 , 0.8 ) , ( 13 , 0.7 ) , ( 14 , 0.6 ) , ( 15 , 0.5 ) , ( 16 , 0.4 ) , ( 17 , 0.3 ) , ( 18 , 0.2 ) , ( 19 , 0.1 ) , ( 20 , 0 ) , ( 21 , 0 ) , , ( 30 , 0 ) } μ small ( x ) = { ( 1 , 1 ) , ( 2 , 1 ) , ( 3 , 1 ) , ( 4 , 1 ) , ( 5 , 1 ) , ( 6 , 1 ) , ( 7 , 1 ) , ( 8 , 1 ) , ( 9 , 1 ) , ( 10 , 1 ) , ( 11 , 0.9 ) , ( 12 , 0.8 ) , ( 13 , 0.7 ) , ( 14 , 0.6 ) , ( 15 , 0.5 ) , ( 16 , 0.4 ) , ( 17 , 0.3 ) , ( 18 , 0.2 ) , ( 19 , 0.1 ) , ( 20 , 0 ) , ( 21 , 0 ) , , ( 30 , 0 ) } mu_(“small”)(x)={(1,1),(2,1),(3,1),(4,1),(5,1),(6,1),(7,1),(8,1),(9,1),(10,1),(11,0.9),(12,0.8),(13,0.7),(14,0.6),(15,0.5),(16,0.4),(17,0.3),(18,0.2),(19,0.1),(20,0),(21,0),dots,(30,0)}\mu_{\text{small}}(x) = \{(1, 1), (2, 1), (3, 1), (4, 1), (5, 1), (6, 1), (7, 1), (8, 1), (9, 1), (10, 1), (11, 0.9), (12, 0.8), (13, 0.7), (14, 0.6), (15, 0.5), (16, 0.4), (17, 0.3), (18, 0.2), (19, 0.1), (20, 0), (21, 0), \dots, (30, 0)\}μsmall(x)={(1,1),(2,1),(3,1),(4,1),(5,1),(6,1),(7,1),(8,1),(9,1),(10,1),(11,0.9),(12,0.8),(13,0.7),(14,0.6),(15,0.5),(16,0.4),(17,0.3),(18,0.2),(19,0.1),(20,0),(21,0),,(30,0)}

Fuzzy Set "Medium" Membership Function:

μ medium ( x ) = { ( 1 , 0 ) , ( 2 , 0 ) , ( 3 , 0 ) , ( 4 , 0 ) , ( 5 , 0 ) , ( 6 , 0.1 ) , ( 7 , 0.2 ) , ( 8 , 0.3 ) , ( 9 , 0.4 ) , ( 10 , 0.5 ) , ( 11 , 0.6 ) , ( 12 , 0.7 ) , ( 13 , 0.8 ) , ( 14 , 0.9 ) , ( 15 , 1 ) , ( 16 , 0.9 ) , ( 17 , 0.8 ) , ( 18 , 0.7 ) , ( 19 , 0.6 ) , ( 20 , 0.5 ) , ( 21 , 0.4 ) , ( 22 , 0.3 ) , ( 23 , 0.2 ) , ( 24 , 0.1 ) , ( 25 , 0 ) , ( 26 , 0 ) , , ( 30 , 0 ) } μ medium ( x ) = { ( 1 , 0 ) , ( 2 , 0 ) , ( 3 , 0 ) , ( 4 , 0 ) , ( 5 , 0 ) , ( 6 , 0.1 ) , ( 7 , 0.2 ) , ( 8 , 0.3 ) , ( 9 , 0.4 ) , ( 10 , 0.5 ) , ( 11 , 0.6 ) , ( 12 , 0.7 ) , ( 13 , 0.8 ) , ( 14 , 0.9 ) , ( 15 , 1 ) , ( 16 , 0.9 ) , ( 17 , 0.8 ) , ( 18 , 0.7 ) , ( 19 , 0.6 ) , ( 20 , 0.5 ) , ( 21 , 0.4 ) , ( 22 , 0.3 ) , ( 23 , 0.2 ) , ( 24 , 0.1 ) , ( 25 , 0 ) , ( 26 , 0 ) , , ( 30 , 0 ) } mu_(“medium”)(x)={(1,0),(2,0),(3,0),(4,0),(5,0),(6,0.1),(7,0.2),(8,0.3),(9,0.4),(10,0.5),(11,0.6),(12,0.7),(13,0.8),(14,0.9),(15,1),(16,0.9),(17,0.8),(18,0.7),(19,0.6),(20,0.5),(21,0.4),(22,0.3),(23,0.2),(24,0.1),(25,0),(26,0),dots,(30,0)}\mu_{\text{medium}}(x) = \{(1, 0), (2, 0), (3, 0), (4, 0), (5, 0), (6, 0.1), (7, 0.2), (8, 0.3), (9, 0.4), (10, 0.5), (11, 0.6), (12, 0.7), (13, 0.8), (14, 0.9), (15, 1), (16, 0.9), (17, 0.8), (18, 0.7), (19, 0.6), (20, 0.5), (21, 0.4), (22, 0.3), (23, 0.2), (24, 0.1), (25, 0), (26, 0), \dots, (30, 0)\}μmedium(x)={(1,0),(2,0),(3,0),(4,0),(5,0),(6,0.1),(7,0.2),(8,0.3),(9,0.4),(10,0.5),(11,0.6),(12,0.7),(13,0.8),(14,0.9),(15,1),(16,0.9),(17,0.8),(18,0.7),(19,0.6),(20,0.5),(21,0.4),(22,0.3),(23,0.2),(24,0.1),(25,0),(26,0),,(30,0)}

Applying the "Very" Hedge

We will now apply the "very" hedge, squaring each membership value.

1. Modified Fuzzy Set "Small" (Applying the "Very" Hedge)

For the fuzzy set "small", we square each membership value:
μ very small ( x ) = ( μ small ( x ) ) 2 μ very small ( x ) = μ small ( x ) 2 mu_(“very small”)(x)=(mu_(“small”)(x))^(2)\mu_{\text{very small}}(x) = \left( \mu_{\text{small}}(x) \right)^2μvery small(x)=(μsmall(x))2
Thus, the new membership values for the fuzzy set "very small" are:
μ very small ( x ) = { ( 1 , 1 ) , ( 2 , 1 ) , ( 3 , 1 ) , ( 4 , 1 ) , ( 5 , 1 ) , ( 6 , 1 ) , ( 7 , 1 ) , ( 8 , 1 ) , ( 9 , 1 ) , ( 10 , 1 ) , ( 11 , 0.81 ) , ( 12 , 0.64 ) , ( 13 , 0.49 ) , ( 14 , 0.36 ) , ( 15 , 0.25 ) , ( 16 , 0.16 ) , ( 17 , 0.09 ) , ( 18 , 0.04 ) , ( 19 , 0.01 ) , ( 20 , 0 ) , ( 21 , 0 ) , , ( 30 , 0 ) } μ very small ( x ) = { ( 1 , 1 ) , ( 2 , 1 ) , ( 3 , 1 ) , ( 4 , 1 ) , ( 5 , 1 ) , ( 6 , 1 ) , ( 7 , 1 ) , ( 8 , 1 ) , ( 9 , 1 ) , ( 10 , 1 ) , ( 11 , 0.81 ) , ( 12 , 0.64 ) , ( 13 , 0.49 ) , ( 14 , 0.36 ) , ( 15 , 0.25 ) , ( 16 , 0.16 ) , ( 17 , 0.09 ) , ( 18 , 0.04 ) , ( 19 , 0.01 ) , ( 20 , 0 ) , ( 21 , 0 ) , , ( 30 , 0 ) } mu_(“very small”)(x)={(1,1),(2,1),(3,1),(4,1),(5,1),(6,1),(7,1),(8,1),(9,1),(10,1),(11,0.81),(12,0.64),(13,0.49),(14,0.36),(15,0.25),(16,0.16),(17,0.09),(18,0.04),(19,0.01),(20,0),(21,0),dots,(30,0)}\mu_{\text{very small}}(x) = \{(1, 1), (2, 1), (3, 1), (4, 1), (5, 1), (6, 1), (7, 1), (8, 1), (9, 1), (10, 1), (11, 0.81), (12, 0.64), (13, 0.49), (14, 0.36), (15, 0.25), (16, 0.16), (17, 0.09), (18, 0.04), (19, 0.01), (20, 0), (21, 0), \dots, (30, 0)\}μvery small(x)={(1,1),(2,1),(3,1),(4,1),(5,1),(6,1),(7,1),(8,1),(9,1),(10,1),(11,0.81),(12,0.64),(13,0.49),(14,0.36),(15,0.25),(16,0.16),(17,0.09),(18,0.04),(19,0.01),(20,0),(21,0),,(30,0)}

2. Modified Fuzzy Set "Medium" (Applying the "Very" Hedge)

For the fuzzy set "medium", we square each membership value:
μ very medium ( x ) = ( μ medium ( x ) ) 2 μ very medium ( x ) = μ medium ( x ) 2 mu_(“very medium”)(x)=(mu_(“medium”)(x))^(2)\mu_{\text{very medium}}(x) = \left( \mu_{\text{medium}}(x) \right)^2μvery medium(x)=(μmedium(x))2
Thus, the new membership values for the fuzzy set "very medium" are:
μ very medium ( x ) = { ( 1 , 0 ) , ( 2 , 0 ) , ( 3 , 0 ) , ( 4 , 0 ) , ( 5 , 0 ) , ( 6 , 0.01 ) , ( 7 , 0.04 ) , ( 8 , 0.09 ) , ( 9 , 0.16 ) , ( 10 , 0.25 ) , ( 11 , 0.36 ) , ( 12 , 0.49 ) , ( 13 , 0.64 ) , ( 14 , 0.81 ) , ( 15 , 1 ) , ( 16 , 0.81 ) , ( 17 , 0.64 ) , ( 18 , 0.49 ) , ( 19 , 0.36 ) , ( 20 , 0.25 ) , ( 21 , 0.16 ) , ( 22 , 0.09 ) , ( 23 , 0.04 ) , ( 24 , 0.01 ) , ( 25 , 0 ) , ( 26 , 0 ) , , ( 30 , 0 ) } μ very medium ( x ) = { ( 1 , 0 ) , ( 2 , 0 ) , ( 3 , 0 ) , ( 4 , 0 ) , ( 5 , 0 ) , ( 6 , 0.01 ) , ( 7 , 0.04 ) , ( 8 , 0.09 ) , ( 9 , 0.16 ) , ( 10 , 0.25 ) , ( 11 , 0.36 ) , ( 12 , 0.49 ) , ( 13 , 0.64 ) , ( 14 , 0.81 ) , ( 15 , 1 ) , ( 16 , 0.81 ) , ( 17 , 0.64 ) , ( 18 , 0.49 ) , ( 19 , 0.36 ) , ( 20 , 0.25 ) , ( 21 , 0.16 ) , ( 22 , 0.09 ) , ( 23 , 0.04 ) , ( 24 , 0.01 ) , ( 25 , 0 ) , ( 26 , 0 ) , , ( 30 , 0 ) } mu_(“very medium”)(x)={(1,0),(2,0),(3,0),(4,0),(5,0),(6,0.01),(7,0.04),(8,0.09),(9,0.16),(10,0.25),(11,0.36),(12,0.49),(13,0.64),(14,0.81),(15,1),(16,0.81),(17,0.64),(18,0.49),(19,0.36),(20,0.25),(21,0.16),(22,0.09),(23,0.04),(24,0.01),(25,0),(26,0),dots,(30,0)}\mu_{\text{very medium}}(x) = \{(1, 0), (2, 0), (3, 0), (4, 0), (5, 0), (6, 0.01), (7, 0.04), (8, 0.09), (9, 0.16), (10, 0.25), (11, 0.36), (12, 0.49), (13, 0.64), (14, 0.81), (15, 1), (16, 0.81), (17, 0.64), (18, 0.49), (19, 0.36), (20, 0.25), (21, 0.16), (22, 0.09), (23, 0.04), (24, 0.01), (25, 0), (26, 0), \dots, (30, 0)\}μvery medium(x)={(1,0),(2,0),(3,0),(4,0),(5,0),(6,0.01),(7,0.04),(8,0.09),(9,0.16),(10,0.25),(11,0.36),(12,0.49),(13,0.64),(14,0.81),(15,1),(16,0.81),(17,0.64),(18,0.49),(19,0.36),(20,0.25),(21,0.16),(22,0.09),(23,0.04),(24,0.01),(25,0),(26,0),,(30,0)}

Final Answer: Modified Fuzzy Sets with the "Very" Hedge

  • Modified fuzzy set "very small":
    μ very small ( x ) = { ( 1 , 1 ) , ( 2 , 1 ) , ( 3 , 1 ) , ( 4 , 1 ) , ( 5 , 1 ) , ( 6 , 1 ) , ( 7 , 1 ) , ( 8 , 1 ) , ( 9 , 1 ) , ( 10 , 1 ) , ( 11 , 0.81 ) , ( 12 , 0.64 ) , ( 13 , 0.49 ) , ( 14 , 0.36 ) , ( 15 , 0.25 ) , ( 16 , 0.16 ) , ( 17 , 0.09 ) , ( 18 , 0.04 ) , ( 19 , 0.01 ) , ( 20 , 0 ) , ( 21 , 0 ) , , ( 30 , 0 ) } μ very small ( x ) = { ( 1 , 1 ) , ( 2 , 1 ) , ( 3 , 1 ) , ( 4 , 1 ) , ( 5 , 1 ) , ( 6 , 1 ) , ( 7 , 1 ) , ( 8 , 1 ) , ( 9 , 1 ) , ( 10 , 1 ) , ( 11 , 0.81 ) , ( 12 , 0.64 ) , ( 13 , 0.49 ) , ( 14 , 0.36 ) , ( 15 , 0.25 ) , ( 16 , 0.16 ) , ( 17 , 0.09 ) , ( 18 , 0.04 ) , ( 19 , 0.01 ) , ( 20 , 0 ) , ( 21 , 0 ) , , ( 30 , 0 ) } mu_(“very small”)(x)={(1,1),(2,1),(3,1),(4,1),(5,1),(6,1),(7,1),(8,1),(9,1),(10,1),(11,0.81),(12,0.64),(13,0.49),(14,0.36),(15,0.25),(16,0.16),(17,0.09),(18,0.04),(19,0.01),(20,0),(21,0),dots,(30,0)}\mu_{\text{very small}}(x) = \{(1, 1), (2, 1), (3, 1), (4, 1), (5, 1), (6, 1), (7, 1), (8, 1), (9, 1), (10, 1), (11, 0.81), (12, 0.64), (13, 0.49), (14, 0.36), (15, 0.25), (16, 0.16), (17, 0.09), (18, 0.04), (19, 0.01), (20, 0), (21, 0), \dots, (30, 0)\}μvery small(x)={(1,1),(2,1),(3,1),(4,1),(5,1),(6,1),(7,1),(8,1),(9,1),(10,1),(11,0.81),(12,0.64),(13,0.49),(14,0.36),(15,0.25),(16,0.16),(17,0.09),(18,0.04),(19,0.01),(20,0),(21,0),,(30,0)}
  • Modified fuzzy set "very medium":
    μ very medium ( x ) = { ( 1 , 0 ) , ( 2 , 0 ) , ( 3 , 0 ) , ( 4 , 0 ) , ( 5 , 0 ) , ( 6 , 0.01 ) , ( 7 , 0.04 ) , ( 8 , 0.09 ) , ( 9 , 0.16 ) , ( 10 , 0.25 ) , ( 11 , 0.36 ) , ( 12 , 0.49 ) , ( 13 , 0.64 ) , ( 14 , 0.81 ) , ( 15 , 1 ) , ( 16 , 0.81 ) , ( 17 , 0.64 ) , ( 18 , 0.49 ) , ( 19 , 0.36 ) , ( 20 , 0.25 ) , ( 21 , 0.16 ) , ( 22 , 0.09 ) , ( 23 , 0.04 ) , ( 24 , 0.01 ) , ( 25 , 0 ) , ( 26 , 0 ) , , ( 30 , 0 ) } μ very medium ( x ) = { ( 1 , 0 ) , ( 2 , 0 ) , ( 3 , 0 ) , ( 4 , 0 ) , ( 5 , 0 ) , ( 6 , 0.01 ) , ( 7 , 0.04 ) , ( 8 , 0.09 ) , ( 9 , 0.16 ) , ( 10 , 0.25 ) , ( 11 , 0.36 ) , ( 12 , 0.49 ) , ( 13 , 0.64 ) , ( 14 , 0.81 ) , ( 15 , 1 ) , ( 16 , 0.81 ) , ( 17 , 0.64 ) , ( 18 , 0.49 ) , ( 19 , 0.36 ) , ( 20 , 0.25 ) , ( 21 , 0.16 ) , ( 22 , 0.09 ) , ( 23 , 0.04 ) , ( 24 , 0.01 ) , ( 25 , 0 ) , ( 26 , 0 ) , , ( 30 , 0 ) } mu_(“very medium”)(x)={(1,0),(2,0),(3,0),(4,0),(5,0),(6,0.01),(7,0.04),(8,0.09),(9,0.16),(10,0.25),(11,0.36),(12,0.49),(13,0.64),(14,0.81),(15,1),(16,0.81),(17,0.64),(18,0.49),(19,0.36),(20,0.25),(21,0.16),(22,0.09),(23,0.04),(24,0.01),(25,0),(26,0),dots,(30,0)}\mu_{\text{very medium}}(x) = \{(1, 0), (2, 0), (3, 0), (4, 0), (5, 0), (6, 0.01), (7, 0.04), (8, 0.09), (9, 0.16), (10, 0.25), (11, 0.36), (12, 0.49), (13, 0.64), (14, 0.81), (15, 1), (16, 0.81), (17, 0.64), (18, 0.49), (19, 0.36), (20, 0.25), (21, 0.16), (22, 0.09), (23, 0.04), (24, 0.01), (25, 0), (26, 0), \dots, (30, 0)\}μvery medium(x)={(1,0),(2,0),(3,0),(4,0),(5,0),(6,0.01),(7,0.04),(8,0.09),(9,0.16),(10,0.25),(11,0.36),(12,0.49),(13,0.64),(14,0.81),(15,1),(16,0.81),(17,0.64),(18,0.49),(19,0.36),(20,0.25),(21,0.16),(22,0.09),(23,0.04),(24,0.01),(25,0),(26,0),,(30,0)}




Question:-3

Let A and B be two fuzzy sets and x U x U xinU\mathrm{x} \in \mathrm{U}xU, if μ A ( x ) = 0.4 μ A ( x ) = 0.4 mu_(A)(x)=0.4\mu_{\mathrm{A}}(\mathrm{x})=0.4μA(x)=0.4 and μ B ( x ) = 0.8 μ B ( x ) = 0.8 mu_(B)(x)=0.8\mu_{\mathrm{B}}(\mathrm{x})=0.8μB(x)=0.8, then find out the following membership values:

i) μ A ( x ) μ A ( x ) quadmu_(A)(x)\quad \mu_{\mathrm{A} \mathcal{}}(\mathrm{x})μA(x),
ii) μ A B ( x ) μ A B ( x ) mu_(A nn B)(x)\mu_{A \cap B}(x)μAB(x),
iii) μ A B ( x ) μ A ¯ B ¯ ( x ) mu_( bar(A)uu bar(B))(x)\mu_{\overline{\mathrm{A}} \cup \overline{\mathrm{B}}}(\mathrm{x})μAB(x),
iv) μ A B ( x ) μ A ¯ B ¯ ( x ) mu_( bar(A)nn bar(B))(x)\mu_{\overline{\mathrm{A}} \cap \overline{\mathrm{B}}}(\mathrm{x})μAB(x),
v) μ A B ( x ) μ A ¯ B ¯ ¯ ( x ) mu_( bar(A) bar(bar(B)))(x)\mu_{\overline{\mathrm{A}} \overline{\overline{\mathrm{B}}}}(\mathrm{x})μAB(x),
vi) μ A B ( x ) μ A ¯ B ¯ ¯ ( x ) mu_( bar(A) bar(bar(B)))(x)\mu_{\overline{\mathrm{A}} \overline{\overline{\mathrm{B}}}}(\mathrm{x})μAB(x).

Answer:

Given two fuzzy sets A A AAA and B B BBB, with membership functions:
μ A ( x ) = 0.4 , μ B ( x ) = 0.8 μ A ( x ) = 0.4 , μ B ( x ) = 0.8 mu _(A)(x)=0.4,quadmu _(B)(x)=0.8\mu_A(x) = 0.4, \quad \mu_B(x) = 0.8μA(x)=0.4,μB(x)=0.8
We are tasked with calculating several membership values based on these values.

i) μ A ( x ) μ A ( x ) mu_(A)(x)\mu_{\mathrm{A} \mathcal{}}(x)μA(x)

This appears to be asking for the membership value of the complement of set A A AAA. The complement of a fuzzy set A A AAA is given by:
μ A ( x ) = 1 μ A ( x ) μ A ¯ ( x ) = 1 μ A ( x ) mu_( bar(A))(x)=1-mu _(A)(x)\mu_{\overline{A}}(x) = 1 – \mu_A(x)μA(x)=1μA(x)
Substitute μ A ( x ) = 0.4 μ A ( x ) = 0.4 mu _(A)(x)=0.4\mu_A(x) = 0.4μA(x)=0.4:
μ A ( x ) = 1 0.4 = 0.6 μ A ¯ ( x ) = 1 0.4 = 0.6 mu_( bar(A))(x)=1-0.4=0.6\mu_{\overline{A}}(x) = 1 – 0.4 = 0.6μA(x)=10.4=0.6

ii) μ A B ( x ) μ A B ( x ) mu_(A nn B)(x)\mu_{A \cap B}(x)μAB(x)

The intersection ( nn\cap) of two fuzzy sets A A AAA and B B BBB is defined as the minimum of the membership values:
μ A B ( x ) = min ( μ A ( x ) , μ B ( x ) ) μ A B ( x ) = min ( μ A ( x ) , μ B ( x ) ) mu_(A nn B)(x)=min(mu _(A)(x),mu _(B)(x))\mu_{A \cap B}(x) = \min(\mu_A(x), \mu_B(x))μAB(x)=min(μA(x),μB(x))
Substitute the given values:
μ A B ( x ) = min ( 0.4 , 0.8 ) = 0.4 μ A B ( x ) = min ( 0.4 , 0.8 ) = 0.4 mu_(A nn B)(x)=min(0.4,0.8)=0.4\mu_{A \cap B}(x) = \min(0.4, 0.8) = 0.4μAB(x)=min(0.4,0.8)=0.4

iii) μ A B ( x ) μ A ¯ B ¯ ( x ) mu_( bar(A)uu bar(B))(x)\mu_{\overline{\mathrm{A}} \cup \overline{\mathrm{B}}}(x)μAB(x)

The union ( uu\cup) of two fuzzy sets is the maximum of the membership values. We need to first compute the complement of A A AAA and B B BBB, and then take their union:
μ A ( x ) = 1 μ A ( x ) = 0.6 , μ B ( x ) = 1 μ B ( x ) = 0.2 μ A ¯ ( x ) = 1 μ A ( x ) = 0.6 , μ B ¯ ( x ) = 1 μ B ( x ) = 0.2 mu_( bar(A))(x)=1-mu _(A)(x)=0.6,quadmu_( bar(B))(x)=1-mu _(B)(x)=0.2\mu_{\overline{A}}(x) = 1 – \mu_A(x) = 0.6, \quad \mu_{\overline{B}}(x) = 1 – \mu_B(x) = 0.2μA(x)=1μA(x)=0.6,μB(x)=1μB(x)=0.2
Now, compute the union:
μ A B ( x ) = max ( μ A ( x ) , μ B ( x ) ) = max ( 0.6 , 0.2 ) = 0.6 μ A ¯ B ¯ ( x ) = max ( μ A ¯ ( x ) , μ B ¯ ( x ) ) = max ( 0.6 , 0.2 ) = 0.6 mu_( bar(A)uu bar(B))(x)=max(mu_( bar(A))(x),mu_( bar(B))(x))=max(0.6,0.2)=0.6\mu_{\overline{A} \cup \overline{B}}(x) = \max(\mu_{\overline{A}}(x), \mu_{\overline{B}}(x)) = \max(0.6, 0.2) = 0.6μAB(x)=max(μA(x),μB(x))=max(0.6,0.2)=0.6

iv) μ A B ( x ) μ A ¯ B ¯ ( x ) mu_( bar(A)nn bar(B))(x)\mu_{\overline{\mathrm{A}} \cap \overline{\mathrm{B}}}(x)μAB(x)

The intersection ( nn\cap) of the complements of A A AAA and B B BBB is the minimum of the membership values:
μ A B ( x ) = min ( μ A ( x ) , μ B ( x ) ) = min ( 0.6 , 0.2 ) = 0.2 μ A ¯ B ¯ ( x ) = min ( μ A ¯ ( x ) , μ B ¯ ( x ) ) = min ( 0.6 , 0.2 ) = 0.2 mu_( bar(A)nn bar(B))(x)=min(mu_( bar(A))(x),mu_( bar(B))(x))=min(0.6,0.2)=0.2\mu_{\overline{A} \cap \overline{B}}(x) = \min(\mu_{\overline{A}}(x), \mu_{\overline{B}}(x)) = \min(0.6, 0.2) = 0.2μAB(x)=min(μA(x),μB(x))=min(0.6,0.2)=0.2

v) μ A B ( x ) μ A ¯ B ¯ ¯ ( x ) mu_( bar(A) bar(bar(B)))(x)\mu_{\overline{A} \overline{\overline{B}}}(x)μAB(x)

This expression seems to involve the complement of the complement of B B BBB, which simplifies as follows:
B = B B ¯ ¯ = B bar(bar(B))=B\overline{\overline{B}} = BB=B
So, the expression becomes μ A B ( x ) μ A ¯ B ( x ) mu_( bar(A)B)(x)\mu_{\overline{A} B}(x)μAB(x), which implies the intersection of A A ¯ bar(A)\overline{A}A and B B BBB:
μ A B ( x ) = min ( μ A ( x ) , μ B ( x ) ) = min ( 0.6 , 0.8 ) = 0.6 μ A ¯ B ( x ) = min ( μ A ¯ ( x ) , μ B ( x ) ) = min ( 0.6 , 0.8 ) = 0.6 mu_( bar(A)nn B)(x)=min(mu_( bar(A))(x),mu _(B)(x))=min(0.6,0.8)=0.6\mu_{\overline{A} \cap B}(x) = \min(\mu_{\overline{A}}(x), \mu_B(x)) = \min(0.6, 0.8) = 0.6μAB(x)=min(μA(x),μB(x))=min(0.6,0.8)=0.6

vi) μ A B ( x ) μ A ¯ B ¯ ¯ ( x ) mu_( bar(A) bar(bar(B)))(x)\mu_{\overline{A} \overline{\overline{B}}}(x)μAB(x)

This is identical to part (v) because B = B B ¯ ¯ = B bar(bar(B))=B\overline{\overline{B}} = BB=B, so the result is the same:
μ A B ( x ) = 0.6 μ A ¯ B ( x ) = 0.6 mu_( bar(A)nn B)(x)=0.6\mu_{\overline{A} \cap B}(x) = 0.6μAB(x)=0.6

Final Answer:

  1. μ A ( x ) = 0.6 μ A ¯ ( x ) = 0.6 mu_( bar(A))(x)=0.6\mu_{\overline{A}}(x) = 0.6μA(x)=0.6
  2. μ A B ( x ) = 0.4 μ A B ( x ) = 0.4 mu_(A nn B)(x)=0.4\mu_{A \cap B}(x) = 0.4μAB(x)=0.4
  3. μ A B ( x ) = 0.6 μ A ¯ B ¯ ( x ) = 0.6 mu_( bar(A)uu bar(B))(x)=0.6\mu_{\overline{A} \cup \overline{B}}(x) = 0.6μAB(x)=0.6
  4. μ A B ( x ) = 0.2 μ A ¯ B ¯ ( x ) = 0.2 mu_( bar(A)nn bar(B))(x)=0.2\mu_{\overline{A} \cap \overline{B}}(x) = 0.2μAB(x)=0.2
  5. μ A B ( x ) = 0.6 μ A ¯ B ( x ) = 0.6 mu_( bar(A)nn B)(x)=0.6\mu_{\overline{A} \cap B}(x) = 0.6μAB(x)=0.6
  6. μ A B ( x ) = 0.6 μ A ¯ B ( x ) = 0.6 mu_( bar(A)nn B)(x)=0.6\mu_{\overline{A} \cap B}(x) = 0.6μAB(x)=0.6 (same as v).




Question:-4

Consider a dataset of six points given in the following table, each of which has two features f 1 f 1 f_(1)f_1f1 and f 2 f 2 f_(2)f_2f2. Assuming the values of the parameters c c ccc and m m mmm as 2 and the initial cluster centers v 1 = ( 5 , 5 ) v 1 = ( 5 , 5 ) v_(1)=(5,5)\mathrm{v}_1=(5,5)v1=(5,5) and v 2 = ( 10 , 10 ) v 2 = ( 10 , 10 ) v_(2)=(10,10)\mathrm{v}_2=(10,10)v2=(10,10), apply FCm algorithm to find the new cluster center after one iteration.

f 1 f 2 x 1 3 11 x 2 3 10 x 3 8 12 x 4 10 6 x 5 13 6 x 6 13 5 f 1 f 2 x 1 3 11 x 2 3 10 x 3 8 12 x 4 10 6 x 5 13 6 x 6 13 5 {:[{:[,f_(1),f_(2)],[x_(1),3,11],[x_(2),3,10]:}],[{:[x_(3),8,12],[x_(4),10,6],[x_(5),13,6],[x_(6),13,5]:}]:}\begin{aligned} &\begin{array}{|l|l|l|} \hline & \mathrm{f}_1 & \mathrm{f}_2 \\ \hline \mathrm{x}_1 & 3 & 11 \\ \hline \mathrm{x}_2 & 3 & 10 \\ \hline \end{array}\\ &\begin{array}{|l|l|l|} \hline x_3 & 8 & 12 \\ \hline x_4 & 10 & 6 \\ \hline x_5 & 13 & 6 \\ \hline x_6 & 13 & 5 \\ \hline \end{array} \end{aligned}f1f2x1311x2310x3812x4106x5136x6135

Answer:

The Fuzzy C-Means (FCM) algorithm is a clustering method where each data point can belong to multiple clusters with varying degrees of membership. The objective is to update cluster centers iteratively based on the membership values of the points to the clusters.

Step-by-Step Process to Apply FCM Algorithm:

Given Information:

  • Two initial cluster centers:
    v 1 = ( 5 , 5 ) , v 2 = ( 10 , 10 ) v 1 = ( 5 , 5 ) , v 2 = ( 10 , 10 ) v_(1)=(5,5),quadv_(2)=(10,10)v_1 = (5, 5), \quad v_2 = (10, 10)v1=(5,5),v2=(10,10)
  • Parameter c = 2 c = 2 c=2c = 2c=2 (number of clusters),
  • Fuzziness parameter m = 2 m = 2 m=2m = 2m=2,
  • Dataset of six points with two features:
    x 1 = ( 3 , 11 ) , x 2 = ( 3 , 10 ) , x 3 = ( 8 , 12 ) , x 4 = ( 10 , 6 ) , x 5 = ( 13 , 6 ) , x 6 = ( 13 , 5 ) x 1 = ( 3 , 11 ) , x 2 = ( 3 , 10 ) , x 3 = ( 8 , 12 ) , x 4 = ( 10 , 6 ) , x 5 = ( 13 , 6 ) , x 6 = ( 13 , 5 ) {:[x_(1)=(3″,”11)”,”quadx_(2)=(3″,”10)”,”quadx_(3)=(8″,”12)”,”],[x_(4)=(10″,”6)”,”quadx_(5)=(13″,”6)”,”quadx_(6)=(13″,”5)]:}\begin{aligned} &\mathbf{x}_1 = (3, 11), \quad \mathbf{x}_2 = (3, 10), \quad \mathbf{x}_3 = (8, 12), \\ &\mathbf{x}_4 = (10, 6), \quad \mathbf{x}_5 = (13, 6), \quad \mathbf{x}_6 = (13, 5) \end{aligned}x1=(3,11),x2=(3,10),x3=(8,12),x4=(10,6),x5=(13,6),x6=(13,5)

Step 1: Calculate the Distance between Each Data Point and the Cluster Centers

The Euclidean distance formula between two points ( x 1 , y 1 ) ( x 1 , y 1 ) (x_(1),y_(1))(x_1, y_1)(x1,y1) and ( x 2 , y 2 ) ( x 2 , y 2 ) (x_(2),y_(2))(x_2, y_2)(x2,y2) is given by:
d ( x , v ) = ( x 1 x 2 ) 2 + ( y 1 y 2 ) 2 d ( x , v ) = ( x 1 x 2 ) 2 + ( y 1 y 2 ) 2 d(x,v)=sqrt((x_(1)-x_(2))^(2)+(y_(1)-y_(2))^(2))d(\mathbf{x}, \mathbf{v}) = \sqrt{(x_1 – x_2)^2 + (y_1 – y_2)^2}d(x,v)=(x1x2)2+(y1y2)2

Distance from points to v 1 = ( 5 , 5 ) v 1 = ( 5 , 5 ) v_(1)=(5,5)v_1 = (5, 5)v1=(5,5):

d ( x 1 , v 1 ) = ( 3 5 ) 2 + ( 11 5 ) 2 = 4 + 36 = 40 = 6.32 , d ( x 2 , v 1 ) = ( 3 5 ) 2 + ( 10 5 ) 2 = 4 + 25 = 29 = 5.39 , d ( x 3 , v 1 ) = ( 8 5 ) 2 + ( 12 5 ) 2 = 9 + 49 = 58 = 7.62 , d ( x 4 , v 1 ) = ( 10 5 ) 2 + ( 6 5 ) 2 = 25 + 1 = 26 = 5.10 , d ( x 5 , v 1 ) = ( 13 5 ) 2 + ( 6 5 ) 2 = 64 + 1 = 65 = 8.06 , d ( x 6 , v 1 ) = ( 13 5 ) 2 + ( 5 5 ) 2 = 64 = 8.00 . d ( x 1 , v 1 ) = ( 3 5 ) 2 + ( 11 5 ) 2 = 4 + 36 = 40 = 6.32 , d ( x 2 , v 1 ) = ( 3 5 ) 2 + ( 10 5 ) 2 = 4 + 25 = 29 = 5.39 , d ( x 3 , v 1 ) = ( 8 5 ) 2 + ( 12 5 ) 2 = 9 + 49 = 58 = 7.62 , d ( x 4 , v 1 ) = ( 10 5 ) 2 + ( 6 5 ) 2 = 25 + 1 = 26 = 5.10 , d ( x 5 , v 1 ) = ( 13 5 ) 2 + ( 6 5 ) 2 = 64 + 1 = 65 = 8.06 , d ( x 6 , v 1 ) = ( 13 5 ) 2 + ( 5 5 ) 2 = 64 = 8.00 . {:[d(x_(1)”,”v_(1))=sqrt((3-5)^(2)+(11-5)^(2))=sqrt(4+36)=sqrt40=6.32″,”],[d(x_(2)”,”v_(1))=sqrt((3-5)^(2)+(10-5)^(2))=sqrt(4+25)=sqrt29=5.39″,”],[d(x_(3)”,”v_(1))=sqrt((8-5)^(2)+(12-5)^(2))=sqrt(9+49)=sqrt58=7.62″,”],[d(x_(4)”,”v_(1))=sqrt((10-5)^(2)+(6-5)^(2))=sqrt(25+1)=sqrt26=5.10″,”],[d(x_(5)”,”v_(1))=sqrt((13-5)^(2)+(6-5)^(2))=sqrt(64+1)=sqrt65=8.06″,”],[d(x_(6)”,”v_(1))=sqrt((13-5)^(2)+(5-5)^(2))=sqrt64=8.00.]:}\begin{aligned} d(\mathbf{x}_1, v_1) &= \sqrt{(3 – 5)^2 + (11 – 5)^2} = \sqrt{4 + 36} = \sqrt{40} = 6.32, \\ d(\mathbf{x}_2, v_1) &= \sqrt{(3 – 5)^2 + (10 – 5)^2} = \sqrt{4 + 25} = \sqrt{29} = 5.39, \\ d(\mathbf{x}_3, v_1) &= \sqrt{(8 – 5)^2 + (12 – 5)^2} = \sqrt{9 + 49} = \sqrt{58} = 7.62, \\ d(\mathbf{x}_4, v_1) &= \sqrt{(10 – 5)^2 + (6 – 5)^2} = \sqrt{25 + 1} = \sqrt{26} = 5.10, \\ d(\mathbf{x}_5, v_1) &= \sqrt{(13 – 5)^2 + (6 – 5)^2} = \sqrt{64 + 1} = \sqrt{65} = 8.06, \\ d(\mathbf{x}_6, v_1) &= \sqrt{(13 – 5)^2 + (5 – 5)^2} = \sqrt{64} = 8.00. \end{aligned}d(x1,v1)=(35)2+(115)2=4+36=40=6.32,d(x2,v1)=(35)2+(105)2=4+25=29=5.39,d(x3,v1)=(85)2+(125)2=9+49=58=7.62,d(x4,v1)=(105)2+(65)2=25+1=26=5.10,d(x5,v1)=(135)2+(65)2=64+1=65=8.06,d(x6,v1)=(135)2+(55)2=64=8.00.

Distance from points to v 2 = ( 10 , 10 ) v 2 = ( 10 , 10 ) v_(2)=(10,10)v_2 = (10, 10)v2=(10,10):

d ( x 1 , v 2 ) = ( 3 10 ) 2 + ( 11 10 ) 2 = 49 + 1 = 50 = 7.07 , d ( x 2 , v 2 ) = ( 3 10 ) 2 + ( 10 10 ) 2 = 49 = 7.00 , d ( x 3 , v 2 ) = ( 8 10 ) 2 + ( 12 10 ) 2 = 4 + 4 = 8 = 2.83 , d ( x 4 , v 2 ) = ( 10 10 ) 2 + ( 6 10 ) 2 = 0 + 16 = 4.00 , d ( x 5 , v 2 ) = ( 13 10 ) 2 + ( 6 10 ) 2 = 9 + 16 = 25 = 5.00 , d ( x 6 , v 2 ) = ( 13 10 ) 2 + ( 5 10 ) 2 = 9 + 25 = 34 = 5.83 . d ( x 1 , v 2 ) = ( 3 10 ) 2 + ( 11 10 ) 2 = 49 + 1 = 50 = 7.07 , d ( x 2 , v 2 ) = ( 3 10 ) 2 + ( 10 10 ) 2 = 49 = 7.00 , d ( x 3 , v 2 ) = ( 8 10 ) 2 + ( 12 10 ) 2 = 4 + 4 = 8 = 2.83 , d ( x 4 , v 2 ) = ( 10 10 ) 2 + ( 6 10 ) 2 = 0 + 16 = 4.00 , d ( x 5 , v 2 ) = ( 13 10 ) 2 + ( 6 10 ) 2 = 9 + 16 = 25 = 5.00 , d ( x 6 , v 2 ) = ( 13 10 ) 2 + ( 5 10 ) 2 = 9 + 25 = 34 = 5.83 . {:[d(x_(1)”,”v_(2))=sqrt((3-10)^(2)+(11-10)^(2))=sqrt(49+1)=sqrt50=7.07″,”],[d(x_(2)”,”v_(2))=sqrt((3-10)^(2)+(10-10)^(2))=sqrt49=7.00″,”],[d(x_(3)”,”v_(2))=sqrt((8-10)^(2)+(12-10)^(2))=sqrt(4+4)=sqrt8=2.83″,”],[d(x_(4)”,”v_(2))=sqrt((10-10)^(2)+(6-10)^(2))=sqrt(0+16)=4.00″,”],[d(x_(5)”,”v_(2))=sqrt((13-10)^(2)+(6-10)^(2))=sqrt(9+16)=sqrt25=5.00″,”],[d(x_(6)”,”v_(2))=sqrt((13-10)^(2)+(5-10)^(2))=sqrt(9+25)=sqrt34=5.83.]:}\begin{aligned} d(\mathbf{x}_1, v_2) &= \sqrt{(3 – 10)^2 + (11 – 10)^2} = \sqrt{49 + 1} = \sqrt{50} = 7.07, \\ d(\mathbf{x}_2, v_2) &= \sqrt{(3 – 10)^2 + (10 – 10)^2} = \sqrt{49} = 7.00, \\ d(\mathbf{x}_3, v_2) &= \sqrt{(8 – 10)^2 + (12 – 10)^2} = \sqrt{4 + 4} = \sqrt{8} = 2.83, \\ d(\mathbf{x}_4, v_2) &= \sqrt{(10 – 10)^2 + (6 – 10)^2} = \sqrt{0 + 16} = 4.00, \\ d(\mathbf{x}_5, v_2) &= \sqrt{(13 – 10)^2 + (6 – 10)^2} = \sqrt{9 + 16} = \sqrt{25} = 5.00, \\ d(\mathbf{x}_6, v_2) &= \sqrt{(13 – 10)^2 + (5 – 10)^2} = \sqrt{9 + 25} = \sqrt{34} = 5.83. \end{aligned}d(x1,v2)=(310)2+(1110)2=49+1=50=7.07,d(x2,v2)=(310)2+(1010)2=49=7.00,d(x3,v2)=(810)2+(1210)2=4+4=8=2.83,d(x4,v2)=(1010)2+(610)2=0+16=4.00,d(x5,v2)=(1310)2+(610)2=9+16=25=5.00,d(x6,v2)=(1310)2+(510)2=9+25=34=5.83.

Step 2: Calculate Membership Values

For each point x i x i x_(i)\mathbf{x}_ixi and each cluster v 1 v 1 v_(1)v_1v1 and v 2 v 2 v_(2)v_2v2, we calculate the membership values using the formula:
μ i j = 1 k = 1 c ( d ( x i , v j ) d ( x i , v k ) ) 2 m 1 μ i j = 1 k = 1 c d ( x i , v j ) d ( x i , v k ) 2 m 1 mu_(ij)=(1)/(sum_(k=1)^(c)((d(x_(i),v_(j)))/(d(x_(i),v_(k))))^((2)/(m-1)))\mu_{ij} = \frac{1}{\sum_{k=1}^{c} \left( \frac{d(\mathbf{x}_i, v_j)}{d(\mathbf{x}_i, v_k)} \right)^{\frac{2}{m-1}} }μij=1k=1c(d(xi,vj)d(xi,vk))2m1
where:
  • μ i j μ i j mu_(ij)\mu_{ij}μij is the membership of point x i x i x_(i)\mathbf{x}_ixi in cluster j j jjj,
  • m = 2 m = 2 m=2m = 2m=2 (the fuzziness parameter),
  • d ( x i , v j ) d ( x i , v j ) d(x_(i),v_(j))d(\mathbf{x}_i, v_j)d(xi,vj) is the distance between point x i x i x_(i)\mathbf{x}_ixi and cluster center v j v j v_(j)v_jvj,
  • c = 2 c = 2 c=2c = 2c=2 (the number of clusters).
We can compute this for each point for both clusters:

Membership Values for x 1 = ( 3 , 11 ) x 1 = ( 3 , 11 ) x_(1)=(3,11)\mathbf{x}_1 = (3, 11)x1=(3,11):

μ 1 , 1 = 1 ( 6.32 6.32 ) 2 + ( 6.32 7.07 ) 2 = 1 1 + 0.798 = 0.556 μ 1 , 1 = 1 6.32 6.32 2 + 6.32 7.07 2 = 1 1 + 0.798 = 0.556 mu_(1,1)=(1)/(((6.32)/(6.32))^(2)+((6.32)/(7.07))^(2))=(1)/(1+0.798)=0.556\mu_{1,1} = \frac{1}{\left( \frac{6.32}{6.32} \right)^2 + \left( \frac{6.32}{7.07} \right)^2 } = \frac{1}{1 + 0.798} = 0.556μ1,1=1(6.326.32)2+(6.327.07)2=11+0.798=0.556
μ 1 , 2 = 1 μ 1 , 1 = 0.444 μ 1 , 2 = 1 μ 1 , 1 = 0.444 mu_(1,2)=1-mu_(1,1)=0.444\mu_{1,2} = 1 – \mu_{1,1} = 0.444μ1,2=1μ1,1=0.444

Membership Values for x 2 = ( 3 , 10 ) x 2 = ( 3 , 10 ) x_(2)=(3,10)\mathbf{x}_2 = (3, 10)x2=(3,10):

μ 2 , 1 = 1 ( 5.39 5.39 ) 2 + ( 5.39 7.00 ) 2 = 1 1 + 0.594 = 0.627 μ 2 , 1 = 1 5.39 5.39 2 + 5.39 7.00 2 = 1 1 + 0.594 = 0.627 mu_(2,1)=(1)/(((5.39)/(5.39))^(2)+((5.39)/(7.00))^(2))=(1)/(1+0.594)=0.627\mu_{2,1} = \frac{1}{\left( \frac{5.39}{5.39} \right)^2 + \left( \frac{5.39}{7.00} \right)^2 } = \frac{1}{1 + 0.594} = 0.627μ2,1=1(5.395.39)2+(5.397.00)2=11+0.594=0.627
μ 2 , 2 = 1 μ 2 , 1 = 0.373 μ 2 , 2 = 1 μ 2 , 1 = 0.373 mu_(2,2)=1-mu_(2,1)=0.373\mu_{2,2} = 1 – \mu_{2,1} = 0.373μ2,2=1μ2,1=0.373

Membership Values for x 3 = ( 8 , 12 ) x 3 = ( 8 , 12 ) x_(3)=(8,12)\mathbf{x}_3 = (8, 12)x3=(8,12):

μ 3 , 1 = 1 ( 7.62 7.62 ) 2 + ( 7.62 2.83 ) 2 = 1 1 + 7.24 = 0.121 μ 3 , 1 = 1 7.62 7.62 2 + 7.62 2.83 2 = 1 1 + 7.24 = 0.121 mu_(3,1)=(1)/(((7.62)/(7.62))^(2)+((7.62)/(2.83))^(2))=(1)/(1+7.24)=0.121\mu_{3,1} = \frac{1}{\left( \frac{7.62}{7.62} \right)^2 + \left( \frac{7.62}{2.83} \right)^2 } = \frac{1}{1 + 7.24} = 0.121μ3,1=1(7.627.62)2+(7.622.83)2=11+7.24=0.121
μ 3 , 2 = 1 μ 3 , 1 = 0.879 μ 3 , 2 = 1 μ 3 , 1 = 0.879 mu_(3,2)=1-mu_(3,1)=0.879\mu_{3,2} = 1 – \mu_{3,1} = 0.879μ3,2=1μ3,1=0.879

Membership Values for x 4 = ( 10 , 6 ) x 4 = ( 10 , 6 ) x_(4)=(10,6)\mathbf{x}_4 = (10, 6)x4=(10,6):

μ 4 , 1 = 1 ( 5.10 5.10 ) 2 + ( 5.10 4.00 ) 2 = 1 1 + 1.625 = 0.381 μ 4 , 1 = 1 5.10 5.10 2 + 5.10 4.00 2 = 1 1 + 1.625 = 0.381 mu_(4,1)=(1)/(((5.10)/(5.10))^(2)+((5.10)/(4.00))^(2))=(1)/(1+1.625)=0.381\mu_{4,1} = \frac{1}{\left( \frac{5.10}{5.10} \right)^2 + \left( \frac{5.10}{4.00} \right)^2 } = \frac{1}{1 + 1.625} = 0.381μ4,1=1(5.105.10)2+(5.104.00)2=11+1.625=0.381
μ 4 , 2 = 1 μ 4 , 1 = 0.619 μ 4 , 2 = 1 μ 4 , 1 = 0.619 mu_(4,2)=1-mu_(4,1)=0.619\mu_{4,2} = 1 – \mu_{4,1} = 0.619μ4,2=1μ4,1=0.619

Membership Values for x 5 = ( 13 , 6 ) x 5 = ( 13 , 6 ) x_(5)=(13,6)\mathbf{x}_5 = (13, 6)x5=(13,6):

μ 5 , 1 = 1 ( 8.06 8.06 ) 2 + ( 8.06 5.00 ) 2 = 1 1 + 2.60 = 0.278 μ 5 , 1 = 1 8.06 8.06 2 + 8.06 5.00 2 = 1 1 + 2.60 = 0.278 mu_(5,1)=(1)/(((8.06)/(8.06))^(2)+((8.06)/(5.00))^(2))=(1)/(1+2.60)=0.278\mu_{5,1} = \frac{1}{\left( \frac{8.06}{8.06} \right)^2 + \left( \frac{8.06}{5.00} \right)^2 } = \frac{1}{1 + 2.60} = 0.278μ5,1=1(8.068.06)2+(8.065.00)2=11+2.60=0.278
μ 5 , 2 = 1 μ 5 , 1 = 0.722 μ 5 , 2 = 1 μ 5 , 1 = 0.722 mu_(5,2)=1-mu_(5,1)=0.722\mu_{5,2} = 1 – \mu_{5,1} = 0.722μ5,2=1μ5,1=0.722

Membership Values for x 6 = ( 13 , 5 ) x 6 = ( 13 , 5 ) x_(6)=(13,5)\mathbf{x}_6 = (13, 5)x6=(13,5):

μ 6 , 1 = 1 ( 8.00 8.00 ) 2 + ( 8.00 5.83 ) 2 = 1 1 + 1.88 = 0.347 μ 6 , 1 = 1 8.00 8.00 2 + 8.00 5.83 2 = 1 1 + 1.88 = 0.347 mu_(6,1)=(1)/(((8.00)/(8.00))^(2)+((8.00)/(5.83))^(2))=(1)/(1+1.88)=0.347\mu_{6,1} = \frac{1}{\left( \frac{8.00}{8.00} \right)^2 + \left( \frac{8.00}{5.83} \right)^2 } = \frac{1}{1 + 1.88} = 0.347μ6,1=1(8.008.00)2+(8.005.83)2=11+1.88=0.347
μ 6 , 2 = 1 μ 6 , 1 = 0.653 μ 6 , 2 = 1 μ 6 , 1 = 0.653 mu_(6,2)=1-mu_(6,1)=0.653\mu_{6,2} = 1 – \mu_{6,1} = 0.653μ6,2=1μ6,1=0.653

Step 3: Update the Cluster Centers

The new cluster centers are computed using the following formula for each cluster center v j v j v_(j)v_jvj:
v j = i = 1 n μ i j m x i i = 1 n μ i j m v j = i = 1 n μ i j m x i i = 1 n μ i j m v_(j)=(sum_(i=1)^(n)mu_(ij)^(m)x_(i))/(sum_(i=1)^(n)mu_(ij)^(m))v_j = \frac{\sum_{i=1}^{n} \mu_{ij}^m \mathbf{x}_i}{\sum_{i=1}^{n} \mu_{ij}^m}vj=i=1nμijmxii=1nμijm
For cluster center v 1 v 1 v_(1)v_1v1:
  • Numerator:
    i = 1 n μ i , 1 m x i = 0.556 2 x 1 + 0.627 2 x 2 + 0.121 2 x 3 + 0.381 2 x 4 + 0.278 2 x 5 + 0.347 2 x 6 i = 1 n μ i , 1 m x i = 0.556 2 x 1 + 0.627 2 x 2 + 0.121 2 x 3 + 0.381 2 x 4 + 0.278 2 x 5 + 0.347 2 x 6 sum_(i=1)^(n)mu_(i,1)^(m)x_(i)=0.556^(2)x_(1)+0.627^(2)x_(2)+0.121^(2)x_(3)+0.381^(2)x_(4)+0.278^(2)x_(5)+0.347^(2)x_(6)\sum_{i=1}^{n} \mu_{i,1}^m \mathbf{x}_i = 0.556^2 \mathbf{x}_1 + 0.627^2 \mathbf{x}_2 + 0.121^2 \mathbf{x}_3 + 0.381^2 \mathbf{x}_4 + 0.278^2 \mathbf{x}_5 + 0.347^2 \mathbf{x}_6i=1nμi,1mxi=0.5562x1+0.6272x2+0.1212x3+0.3812x4+0.2782x5+0.3472x6
    = 0.309 ( 3 , 11 ) + 0.393 ( 3 , 10 ) + 0.015 ( 8 , 12 ) + 0.145 ( 10 , 6 ) + 0.077 ( 13 , 6 ) + 0.120 ( 13 , 5 ) = 0.309 ( 3 , 11 ) + 0.393 ( 3 , 10 ) + 0.015 ( 8 , 12 ) + 0.145 ( 10 , 6 ) + 0.077 ( 13 , 6 ) + 0.120 ( 13 , 5 ) =0.309*(3,11)+0.393*(3,10)+0.015*(8,12)+0.145*(10,6)+0.077*(13,6)+0.120*(13,5)= 0.309 \cdot (3, 11) + 0.393 \cdot (3, 10) + 0.015 \cdot (8, 12) + 0.145 \cdot (10, 6) + 0.077 \cdot (13, 6) + 0.120 \cdot (13, 5)=0.309(3,11)+0.393(3,10)+0.015(8,12)+0.145(10,6)+0.077(13,6)+0.120(13,5)
    = ( 0.927 , 3.399 ) + ( 1.179 , 3.930 ) + ( 0.118 , 0.180 ) + ( 1.450 , 0.870 ) + ( 1.001 , 0.462 ) + ( 1.560 , 0.600 ) = ( 0.927 , 3.399 ) + ( 1.179 , 3.930 ) + ( 0.118 , 0.180 ) + ( 1.450 , 0.870 ) + ( 1.001 , 0.462 ) + ( 1.560 , 0.600 ) =(0.927,3.399)+(1.179,3.930)+(0.118,0.180)+(1.450,0.870)+(1.001,0.462)+(1.560,0.600)= (0.927, 3.399) + (1.179, 3.930) + (0.118, 0.180) + (1.450, 0.870) + (1.001, 0.462) + (1.560, 0.600)=(0.927,3.399)+(1.179,3.930)+(0.118,0.180)+(1.450,0.870)+(1.001,0.462)+(1.560,0.600)
    = ( 6.235 , 9.441 ) = ( 6.235 , 9.441 ) =(6.235,9.441)= (6.235, 9.441)=(6.235,9.441)
  • Denominator:
    i = 1 n μ i , 1 m = 0.556 2 + 0.627 2 + 0.121 2 + 0.381 2 + 0.278 2 + 0.347 2 i = 1 n μ i , 1 m = 0.556 2 + 0.627 2 + 0.121 2 + 0.381 2 + 0.278 2 + 0.347 2 sum_(i=1)^(n)mu_(i,1)^(m)=0.556^(2)+0.627^(2)+0.121^(2)+0.381^(2)+0.278^(2)+0.347^(2)\sum_{i=1}^{n} \mu_{i,1}^m = 0.556^2 + 0.627^2 + 0.121^2 + 0.381^2 + 0.278^2 + 0.347^2i=1nμi,1m=0.5562+0.6272+0.1212+0.3812+0.2782+0.3472
    = 0.309 + 0.393 + 0.015 + 0.145 + 0.077 + 0.120 = 1.059 = 0.309 + 0.393 + 0.015 + 0.145 + 0.077 + 0.120 = 1.059 =0.309+0.393+0.015+0.145+0.077+0.120=1.059= 0.309 + 0.393 + 0.015 + 0.145 + 0.077 + 0.120 = 1.059=0.309+0.393+0.015+0.145+0.077+0.120=1.059
So, the new cluster center for v 1 v 1 v_(1)v_1v1 is:
v 1 = ( 6.235 , 9.441 ) 1.059 = ( 5.89 , 8.91 ) v 1 = ( 6.235 , 9.441 ) 1.059 = ( 5.89 , 8.91 ) v_(1)=((6.235,9.441))/(1.059)=(5.89,8.91)v_1 = \frac{(6.235, 9.441)}{1.059} = (5.89, 8.91)v1=(6.235,9.441)1.059=(5.89,8.91)
For cluster center v 2 v 2 v_(2)v_2v2:
  • Numerator:
    i = 1 n μ i , 2 m x i = 0.444 2 x 1 + 0.373 2 x 2 + 0.879 2 x 3 + 0.619 2 x 4 + 0.722 2 x 5 + 0.653 2 x 6 i = 1 n μ i , 2 m x i = 0.444 2 x 1 + 0.373 2 x 2 + 0.879 2 x 3 + 0.619 2 x 4 + 0.722 2 x 5 + 0.653 2 x 6 sum_(i=1)^(n)mu_(i,2)^(m)x_(i)=0.444^(2)x_(1)+0.373^(2)x_(2)+0.879^(2)x_(3)+0.619^(2)x_(4)+0.722^(2)x_(5)+0.653^(2)x_(6)\sum_{i=1}^{n} \mu_{i,2}^m \mathbf{x}_i = 0.444^2 \mathbf{x}_1 + 0.373^2 \mathbf{x}_2 + 0.879^2 \mathbf{x}_3 + 0.619^2 \mathbf{x}_4 + 0.722^2 \mathbf{x}_5 + 0.653^2 \mathbf{x}_6i=1nμi,2mxi=0.4442x1+0.3732x2+0.8792x3+0.6192x4+0.7222x5+0.6532x6
    = 0.197 ( 3 , 11 ) + 0.139 ( 3 , 10 ) + 0.773 ( 8 , 12 ) + 0.383 ( 10 , 6 ) + 0.521 ( 13 , 6 ) + 0.426 ( 13 , 5 ) = 0.197 ( 3 , 11 ) + 0.139 ( 3 , 10 ) + 0.773 ( 8 , 12 ) + 0.383 ( 10 , 6 ) + 0.521 ( 13 , 6 ) + 0.426 ( 13 , 5 ) =0.197*(3,11)+0.139*(3,10)+0.773*(8,12)+0.383*(10,6)+0.521*(13,6)+0.426*(13,5)= 0.197 \cdot (3, 11) + 0.139 \cdot (3, 10) + 0.773 \cdot (8, 12) + 0.383 \cdot (10, 6) + 0.521 \cdot (13, 6) + 0.426 \cdot (13, 5)=0.197(3,11)+0.139(3,10)+0.773(8,12)+0.383(10,6)+0.521(13,6)+0.426(13,5)
    = ( 0.591 , 2.167 ) + ( 0.417 , 1.386 ) + ( 6.184 , 9.276 ) + ( 3.830 , 2.298 ) + ( 6.773 , 3.126 ) + ( 5.538 , 2.130 ) = ( 0.591 , 2.167 ) + ( 0.417 , 1.386 ) + ( 6.184 , 9.276 ) + ( 3.830 , 2.298 ) + ( 6.773 , 3.126 ) + ( 5.538 , 2.130 ) =(0.591,2.167)+(0.417,1.386)+(6.184,9.276)+(3.830,2.298)+(6.773,3.126)+(5.538,2.130)= (0.591, 2.167) + (0.417, 1.386) + (6.184, 9.276) + (3.830, 2.298) + (6.773, 3.126) + (5.538, 2.130)=(0.591,2.167)+(0.417,1.386)+(6.184,9.276)+(3.830,2.298)+(6.773,3.126)+(5.538,2.130)
    = ( 23.333 , 20.383 ) = ( 23.333 , 20.383 ) =(23.333,20.383)= (23.333, 20.383)=(23.333,20.383)
  • Denominator:
    i = 1 n μ i , 2 m = 0.444 2 + 0.373 2 + 0.879 2 + 0.619 2 + 0.722 2 + 0.653 2 i = 1 n μ i , 2 m = 0.444 2 + 0.373 2 + 0.879 2 + 0.619 2 + 0.722 2 + 0.653 2 sum_(i=1)^(n)mu_(i,2)^(m)=0.444^(2)+0.373^(2)+0.879^(2)+0.619^(2)+0.722^(2)+0.653^(2)\sum_{i=1}^{n} \mu_{i,2}^m = 0.444^2 + 0.373^2 + 0.879^2 + 0.619^2 + 0.722^2 + 0.653^2i=1nμi,2m=0.4442+0.3732+0.8792+0.6192+0.7222+0.6532
    = 0.197 + 0.139 + 0.773 + 0.383 + 0.521 + 0.426 = 2.439 = 0.197 + 0.139 + 0.773 + 0.383 + 0.521 + 0.426 = 2.439 =0.197+0.139+0.773+0.383+0.521+0.426=2.439= 0.197 + 0.139 + 0.773 + 0.383 + 0.521 + 0.426 = 2.439=0.197+0.139+0.773+0.383+0.521+0.426=2.439
So, the new cluster center for v 2 v 2 v_(2)v_2v2 is:
v 2 = ( 23.333 , 20.383 ) 2.439 = ( 9.57 , 8.36 ) v 2 = ( 23.333 , 20.383 ) 2.439 = ( 9.57 , 8.36 ) v_(2)=((23.333,20.383))/(2.439)=(9.57,8.36)v_2 = \frac{(23.333, 20.383)}{2.439} = (9.57, 8.36)v2=(23.333,20.383)2.439=(9.57,8.36)

Final Answer: New Cluster Centers

After one iteration, the new cluster centers are:
v 1 = ( 5.89 , 8.91 ) , v 2 = ( 9.57 , 8.36 ) v 1 = ( 5.89 , 8.91 ) , v 2 = ( 9.57 , 8.36 ) v_(1)=(5.89,8.91),quadv_(2)=(9.57,8.36)v_1 = (5.89, 8.91), \quad v_2 = (9.57, 8.36)v1=(5.89,8.91),v2=(9.57,8.36)




Question:-5(a)

Define Error Correction Learning with examples.

Answer:

Error Correction Learning is a learning process in machine learning and neural networks where the model adjusts its parameters (such as weights) based on the difference between the actual output and the desired (or target) output. The main goal is to minimize the error, typically defined as the difference between the predicted output and the actual output, over a series of learning iterations.

Key Concept:

In Error Correction Learning, the model tries to correct its errors by adjusting its internal parameters using the error signal. The error signal is calculated as the difference between the desired output and the actual output. This process is iterative, meaning that the model repeatedly adjusts its parameters to reduce the error and eventually learn the correct mapping from inputs to outputs.

General Steps:

  1. Initial Prediction: The model makes an initial prediction using its current parameters (e.g., weights in a neural network).
  2. Compute Error: The error is computed by comparing the actual prediction to the desired (target) output: Error = Target Output Actual Output Error = Target Output Actual Output “Error”=”Target Output”-“Actual Output”\text{Error} = \text{Target Output} – \text{Actual Output}Error=Target OutputActual Output
  3. Parameter Adjustment: The model adjusts its parameters to reduce this error. This is typically done using a learning rule, such as gradient descent, where the parameters are updated proportionally to the error: New Parameter = Old Parameter + Learning Rate × Error × Input New Parameter = Old Parameter + Learning Rate × Error × Input “New Parameter”=”Old Parameter”+”Learning Rate”xx”Error”xx”Input”\text{New Parameter} = \text{Old Parameter} + \text{Learning Rate} \times \text{Error} \times \text{Input}New Parameter=Old Parameter+Learning Rate×Error×Input
  4. Repeat: The process is repeated until the error is minimized (ideally close to zero) or until a stopping criterion (e.g., number of iterations) is reached.

Types of Error Correction Learning Algorithms:

  • Perceptron Learning Rule: One of the simplest forms of error correction learning, used in a single-layer neural network called a perceptron. The weights are adjusted based on the error between the predicted class and the true class.
  • Delta Rule (Widrow-Hoff Rule): Used in gradient descent for adjusting weights in a linear neuron or perceptron to minimize the squared error between the actual output and target output.
  • Backpropagation: Used in multi-layer neural networks, where error correction is applied at each layer of the network using the gradient of the error with respect to the parameters (weights). This is the basis for modern deep learning.

Example 1: Perceptron Learning Algorithm (Error Correction in Binary Classification)

Consider a simple perceptron model used for binary classification where:
  • Inputs: x = [ x 1 , x 2 ] x = [ x 1 , x 2 ] x=[x_(1),x_(2)]\mathbf{x} = [x_1, x_2]x=[x1,x2]
  • Weights: w = [ w 1 , w 2 ] w = [ w 1 , w 2 ] w=[w_(1),w_(2)]\mathbf{w} = [w_1, w_2]w=[w1,w2]
  • Bias: b b bbb
The output y y yyy of the perceptron is given by the sign of the weighted sum of inputs:
y = sign ( w 1 x 1 + w 2 x 2 + b ) y = sign ( w 1 x 1 + w 2 x 2 + b ) y=”sign”(w_(1)x_(1)+w_(2)x_(2)+b)y = \text{sign}(w_1 x_1 + w_2 x_2 + b)y=sign(w1x1+w2x2+b)
Let’s assume the task is to classify points as either belonging to class +1 or -1. If the perceptron makes a mistake, the weights and bias are updated as:
w i w i + η ( t y ) x i (for each weight w i ) w i w i + η ( t y ) x i (for each weight w i ) w_(i)larrw_(i)+eta(t-y)x_(i)quad(for each weight (w_(i))”)”w_i \leftarrow w_i + \eta (t – y) x_i \quad \text{(for each weight \( w_i \))}wiwi+η(ty)xi(for each weight wi)
b b + η ( t y ) b b + η ( t y ) b larr b+eta(t-y)b \leftarrow b + \eta (t – y)bb+η(ty)
Where:
  • η η eta\etaη is the learning rate,
  • t t ttt is the target output (either +1 or -1),
  • y y yyy is the actual output.

Example with data:

Suppose we are classifying the following points:
x 1 x 1 x_(1)x_1x1 x 2 x 2 x_(2)x_2x2 Target t t ttt
1 1 +1
-1 -1 -1
  1. Initial weights and bias: w 1 = 0 , w 2 = 0 , b = 0 w 1 = 0 , w 2 = 0 , b = 0 w_(1)=0,w_(2)=0,b=0w_1 = 0, w_2 = 0, b = 0w1=0,w2=0,b=0.
  2. First input: x = [ 1 , 1 ] x = [ 1 , 1 ] x=[1,1]\mathbf{x} = [1, 1]x=[1,1], target t = + 1 t = + 1 t=+1t = +1t=+1.
    • The weighted sum is 0 0 000 (since weights are zero), so the predicted output y = 0 y = 0 y=0y = 0y=0.
    • Update rule: w 1 0 + η ( 1 0 ) 1 = η w 1 0 + η ( 1 0 ) 1 = η w_(1)larr0+eta(1-0)1=etaw_1 \leftarrow 0 + \eta(1 – 0)1 = \etaw10+η(10)1=η, and similarly for w 2 w 2 w_(2)w_2w2.
    • So, w 1 = η w 1 = η w_(1)=etaw_1 = \etaw1=η, w 2 = η w 2 = η w_(2)=etaw_2 = \etaw2=η, b = η b = η b=etab = \etab=η.
  3. Second input: x = [ 1 , 1 ] x = [ 1 , 1 ] x=[-1,-1]\mathbf{x} = [-1, -1]x=[1,1], target t = 1 t = 1 t=-1t = -1t=1.
    • The weighted sum is η ( 1 ) + η ( 1 ) + η = η η ( 1 ) + η ( 1 ) + η = η eta(-1)+eta(-1)+eta=-eta\eta(-1) + \eta(-1) + \eta = -\etaη(1)+η(1)+η=η.
    • Predicted output y = 1 y = 1 y=-1y = -1y=1, which is correct. No weight update is necessary.
The weights are adjusted after each incorrect prediction, correcting the error step-by-step.

Example 2: Backpropagation in a Neural Network

In modern deep learning, backpropagation is an error correction learning method used to train multi-layer neural networks. Consider a simple feedforward neural network with:
  • One input layer,
  • One hidden layer,
  • One output layer.
  1. Forward Pass: The input data is passed through the network to produce an output.
  2. Compute Error: The error is computed using a loss function, such as mean squared error (MSE): E = 1 2 ( t y ) 2 E = 1 2 ( t y ) 2 E=(1)/(2)(t-y)^(2)E = \frac{1}{2}(t – y)^2E=12(ty)2where t t ttt is the target output, and y y yyy is the predicted output.
  3. Backpropagation: The error is propagated backward through the network. The weights in each layer are adjusted based on the gradient of the error with respect to each weight: w w η E w w w η E w w larr w-eta(del E)/(del w)w \leftarrow w – \eta \frac{\partial E}{\partial w}wwηEw
  4. Update Weights: The weights are updated, and the process is repeated for each training example.

Example in Context:

Let’s assume you have a neural network that classifies handwritten digits. During training, if the network predicts a digit incorrectly (e.g., predicts "3" when the correct label is "8"), the backpropagation algorithm adjusts the network’s weights to reduce the error in future predictions. Over time, the model corrects its errors and becomes more accurate in classifying digits.

Conclusion:

Error Correction Learning is a fundamental concept used to update parameters in machine learning models, enabling them to reduce prediction errors iteratively. It forms the basis for algorithms such as perceptron learning, delta rule, and backpropagation in neural networks.




Question:-5(b)

Write the types of Neural Memory Models. Also, give one example of each.

Answer:

Neural memory models are neural networks designed to mimic memory functions in computational systems. These models store, retrieve, and process information in ways similar to how memory works in biological systems. Below are the main types of Neural Memory Models, along with an example of each:

1. Associative Memory Models

These models are designed to store patterns and recall them when a similar or noisy pattern is presented. They "associate" an input with a stored pattern, even if the input is incomplete or noisy.

Example: Hopfield Network

  • Hopfield Network is a type of recurrent neural network that stores patterns as stable states. When an input pattern is presented, the network iteratively updates until it converges to one of the stored patterns, even if the input is noisy or incomplete.
    Application: Pattern recognition, error correction, or auto-association tasks.

2. Content-Addressable Memory (CAM)

These models allow for data retrieval based on the content of the data itself rather than an explicit memory address, making them a type of associative memory that searches for stored patterns matching the input.

Example: Bidirectional Associative Memory (BAM)

  • BAM is a recurrent associative memory model capable of storing a set of pattern pairs, where one pattern can be used to recall its associated counterpart. It works bidirectionally: both forward and backward (i.e., pattern A A AAA retrieves pattern B B BBB and vice versa).
    Application: Paired pattern recognition (e.g., recalling a person’s face given their name or vice versa).

3. Recurrent Neural Networks (RNNs)

RNNs are neural networks with connections that form directed cycles, giving them the ability to maintain a "memory" of previous inputs through internal state loops. This makes RNNs particularly effective for tasks involving sequences or time-series data.

Example: Long Short-Term Memory (LSTM)

  • LSTM is a special kind of RNN capable of learning long-term dependencies. It uses memory cells to store information over time and has mechanisms (gates) to control the flow of information, solving the vanishing gradient problem common in traditional RNNs.
    Application: Time-series prediction, natural language processing (NLP), and speech recognition (e.g., predicting the next word in a sentence).

4. Self-Organizing Maps (SOMs)

SOMs are unsupervised learning models that project high-dimensional data into lower-dimensional spaces while preserving topological relationships. They store information by organizing neurons based on the similarity between input data.

Example: Kohonen Self-Organizing Map (SOM)

  • Kohonen SOM is a neural network that organizes and clusters data based on similarity. The map consists of a grid of neurons that adapt to input data, and nearby neurons in the grid represent similar input data.
    Application: Data clustering, visualization of high-dimensional data, such as customer segmentation or feature extraction.

5. Memory Networks

Memory networks are models that include an external memory component, allowing the network to store information in an explicit memory bank and retrieve it as needed. These models are commonly used in tasks that require both reasoning and the ability to handle large amounts of information.

Example: Neural Turing Machine (NTM)

  • NTM is a neural network model that includes an external memory matrix, enabling it to read from and write to the memory bank. The model learns to use this memory through backpropagation and is capable of complex tasks like copying or sorting sequences.
    Application: Reasoning tasks, algorithmic tasks like sorting or copying sequences, and solving problems that require both memory and computation.

6. Transformer-based Models

These models use attention mechanisms to handle long-range dependencies in data sequences by focusing on relevant parts of the input data, enabling parallel processing. They are particularly efficient for sequence-to-sequence tasks without needing a recurrent structure.

Example: BERT (Bidirectional Encoder Representations from Transformers)

  • BERT is a transformer-based model that uses attention mechanisms to learn contextual relationships between words in a text. It captures information from both directions (left and right context) in a sentence, enabling more accurate language understanding.
    Application: Natural language understanding, question-answering systems, and text classification.

Summary of Types and Examples:

  1. Associative Memory Models: Hopfield Network (Pattern recognition).
  2. Content-Addressable Memory (CAM): Bidirectional Associative Memory (BAM) (Pattern pair recognition).
  3. Recurrent Neural Networks (RNNs): LSTM (Time-series prediction, NLP).
  4. Self-Organizing Maps (SOMs): Kohonen SOM (Data clustering, visualization).
  5. Memory Networks: Neural Turing Machine (NTM) (Complex tasks with memory).
  6. Transformer-based Models: BERT (NLP tasks, text classification).
These neural memory models are fundamental in various applications, including pattern recognition, language processing, and reasoning tasks.




Question:-6

Consider the set of pattern vectors P. Obtain the connectivity matrix (CM) for the patterns in P P PPP (four patterns).

p = [ 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 0 0 0 0 0 0 1 1 0 1 0 1 0 1 0 1 0 ] p = 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 0 0 0 0 0 0 1 1 0 1 0 1 0 1 0 1 0 p=[[1,1,1,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,1,1,1],[1,1,1,0,0,0,0,0,0,1],[1,0,1,0,1,0,1,0,1,0]]\mathrm{p}=\left[\begin{array}{llllllllll} 1 & 1 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 1 & 1 & 1 \\ 1 & 1 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 1 \\ 1 & 0 & 1 & 0 & 1 & 0 & 1 & 0 & 1 & 0 \end{array}\right]p=[1110000000000000011111100000011010101010]

Answer:

The Connectivity Matrix (CM), also known as the weight matrix in the context of associative memory (such as Hopfield Networks), represents the strength of connections between neurons (pattern elements). For a given set of pattern vectors, the connectivity matrix is symmetric, with each element of the matrix representing the degree of interaction between two neurons.

Steps to Calculate the Connectivity Matrix (CM):

  1. Given Pattern Set P P PPP:
    We are given four pattern vectors p 1 , p 2 , p 3 , p 4 p 1 , p 2 , p 3 , p 4 p_(1),p_(2),p_(3),p_(4)\mathbf{p}_1, \mathbf{p}_2, \mathbf{p}_3, \mathbf{p}_4p1,p2,p3,p4, each consisting of 10 elements:
    p 1 = [ 1 , 1 , 1 , 0 , 0 , 0 , 0 , 0 , 0 , 0 ] p 1 = [ 1 , 1 , 1 , 0 , 0 , 0 , 0 , 0 , 0 , 0 ] p_(1)=[1,1,1,0,0,0,0,0,0,0]\mathbf{p}_1 = [1, 1, 1, 0, 0, 0, 0, 0, 0, 0]p1=[1,1,1,0,0,0,0,0,0,0]
    p 2 = [ 0 , 0 , 0 , 0 , 0 , 0 , 0 , 1 , 1 , 1 ] p 2 = [ 0 , 0 , 0 , 0 , 0 , 0 , 0 , 1 , 1 , 1 ] p_(2)=[0,0,0,0,0,0,0,1,1,1]\mathbf{p}_2 = [0, 0, 0, 0, 0, 0, 0, 1, 1, 1]p2=[0,0,0,0,0,0,0,1,1,1]
    p 3 = [ 1 , 1 , 1 , 0 , 0 , 0 , 0 , 0 , 0 , 1 ] p 3 = [ 1 , 1 , 1 , 0 , 0 , 0 , 0 , 0 , 0 , 1 ] p_(3)=[1,1,1,0,0,0,0,0,0,1]\mathbf{p}_3 = [1, 1, 1, 0, 0, 0, 0, 0, 0, 1]p3=[1,1,1,0,0,0,0,0,0,1]
    p 4 = [ 1 , 0 , 1 , 0 , 1 , 0 , 1 , 0 , 1 , 0 ] p 4 = [ 1 , 0 , 1 , 0 , 1 , 0 , 1 , 0 , 1 , 0 ] p_(4)=[1,0,1,0,1,0,1,0,1,0]\mathbf{p}_4 = [1, 0, 1, 0, 1, 0, 1, 0, 1, 0]p4=[1,0,1,0,1,0,1,0,1,0]
  2. Connectivity Matrix Formula:
    The connectivity matrix W W WWW for a set of N N NNN patterns, where each pattern has n n nnn elements, is calculated as:
    W = k = 1 N p k T p k W = k = 1 N p k T p k W=sum_(k=1)^(N)p_(k)^(T)p_(k)W = \sum_{k=1}^{N} \mathbf{p}_k^T \mathbf{p}_kW=k=1NpkTpk
    where p k T p k p k T p k p_(k)^(T)p_(k)\mathbf{p}_k^T \mathbf{p}_kpkTpk is the outer product of pattern p k p k p_(k)\mathbf{p}_kpk with itself.
    The matrix will have dimensions 10 × 10 10 × 10 10 xx1010 \times 1010×10, since each pattern vector has 10 elements.
  3. Outer Product Calculation:
    For each pattern vector p k p k p_(k)\mathbf{p}_kpk, compute the outer product p k T p k p k T p k p_(k)^(T)p_(k)\mathbf{p}_k^T \mathbf{p}_kpkTpk, which results in a 10 × 10 10 × 10 10 xx1010 \times 1010×10 matrix. The final weight matrix W W WWW is the sum of these outer products for all four patterns.

Step-by-Step Outer Product Calculations

For p 1 = [ 1 , 1 , 1 , 0 , 0 , 0 , 0 , 0 , 0 , 0 ] p 1 = [ 1 , 1 , 1 , 0 , 0 , 0 , 0 , 0 , 0 , 0 ] p_(1)=[1,1,1,0,0,0,0,0,0,0]\mathbf{p}_1 = [1, 1, 1, 0, 0, 0, 0, 0, 0, 0]p1=[1,1,1,0,0,0,0,0,0,0]:

p 1 T p 1 = [ 1 1 1 0 0 0 0 0 0 0 1 1 1 0 0 0 0 0 0 0 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ] p 1 T p 1 = 1 1 1 0 0 0 0 0 0 0 1 1 1 0 0 0 0 0 0 0 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 p_(1)^(T)p_(1)=[[1,1,1,0,0,0,0,0,0,0],[1,1,1,0,0,0,0,0,0,0],[1,1,1,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0]]\mathbf{p}_1^T \mathbf{p}_1 = \begin{bmatrix} 1 & 1 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 1 & 1 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 1 & 1 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \end{bmatrix}p1Tp1=[1110000000111000000011100000000000000000000000000000000000000000000000000000000000000000000000000000]

For p 2 = [ 0 , 0 , 0 , 0 , 0 , 0 , 0 , 1 , 1 , 1 ] p 2 = [ 0 , 0 , 0 , 0 , 0 , 0 , 0 , 1 , 1 , 1 ] p_(2)=[0,0,0,0,0,0,0,1,1,1]\mathbf{p}_2 = [0, 0, 0, 0, 0, 0, 0, 1, 1, 1]p2=[0,0,0,0,0,0,0,1,1,1]:

p 2 T p 2 = [ 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 0 0 0 0 0 0 0 1 1 1 0 0 0 0 0 0 0 1 1 1 ] p 2 T p 2 = 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 0 0 0 0 0 0 0 1 1 1 0 0 0 0 0 0 0 1 1 1 p_(2)^(T)p_(2)=[[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,1,1,1],[0,0,0,0,0,0,0,1,1,1],[0,0,0,0,0,0,0,1,1,1]]\mathbf{p}_2^T \mathbf{p}_2 = \begin{bmatrix} 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 1 & 1 & 1 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 1 & 1 & 1 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 1 & 1 & 1 \end{bmatrix}p2Tp2=[0000000000000000000000000000000000000000000000000000000000000000000000000000011100000001110000000111]

For p 3 = [ 1 , 1 , 1 , 0 , 0 , 0 , 0 , 0 , 0 , 1 ] p 3 = [ 1 , 1 , 1 , 0 , 0 , 0 , 0 , 0 , 0 , 1 ] p_(3)=[1,1,1,0,0,0,0,0,0,1]\mathbf{p}_3 = [1, 1, 1, 0, 0, 0, 0, 0, 0, 1]p3=[1,1,1,0,0,0,0,0,0,1]:

p 3 T p 3 = [ 1 1 1 0 0 0 0 0 0 1 1 1 1 0 0 0 0 0 0 1 1 1 1 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 0 0 0 0 0 0 1 ] p 3 T p 3 = 1 1 1 0 0 0 0 0 0 1 1 1 1 0 0 0 0 0 0 1 1 1 1 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 0 0 0 0 0 0 1 p_(3)^(T)p_(3)=[[1,1,1,0,0,0,0,0,0,1],[1,1,1,0,0,0,0,0,0,1],[1,1,1,0,0,0,0,0,0,1],[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0],[1,1,1,0,0,0,0,0,0,1]]\mathbf{p}_3^T \mathbf{p}_3 = \begin{bmatrix} 1 & 1 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 1 \\ 1 & 1 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 1 \\ 1 & 1 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 1 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 1 & 1 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 1 \end{bmatrix}p3Tp3=[1110000001111000000111100000010000000000000000000000000000000000000000000000000000000000001110000001]

For p 4 = [ 1 , 0 , 1 , 0 , 1 , 0 , 1 , 0 , 1 , 0 ] p 4 = [ 1 , 0 , 1 , 0 , 1 , 0 , 1 , 0 , 1 , 0 ] p_(4)=[1,0,1,0,1,0,1,0,1,0]\mathbf{p}_4 = [1, 0, 1, 0, 1, 0, 1, 0, 1, 0]p4=[1,0,1,0,1,0,1,0,1,0]:

p 4 T p 4 = [ 1 0 1 0 1 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 1 0 1 0 1 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 1 0 1 0 1 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 1 0 1 0 1 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 1 0 1 0 1 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 ] p 4 T p 4 = 1 0 1 0 1 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 1 0 1 0 1 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 1 0 1 0 1 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 1 0 1 0 1 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 1 0 1 0 1 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 p_(4)^(T)p_(4)=[[1,0,1,0,1,0,1,0,1,0],[0,0,0,0,0,0,0,0,0,0],[1,0,1,0,1,0,1,0,1,0],[0,0,0,0,0,0,0,0,0,0],[1,0,1,0,1,0,1,0,1,0],[0,0,0,0,0,0,0,0,0,0],[1,0,1,0,1,0,1,0,1,0],[0,0,0,0,0,0,0,0,0,0],[1,0,1,0,1,0,1,0,1,0],[0,0,0,0,0,0,0,0,0,0]]\mathbf{p}_4^T \mathbf{p}_4 = \begin{bmatrix} 1 & 0 & 1 & 0 & 1 & 0 & 1 & 0 & 1 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 1 & 0 & 1 & 0 & 1 & 0 & 1 & 0 & 1 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 1 & 0 & 1 & 0 & 1 & 0 & 1 & 0 & 1 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 1 & 0 & 1 & 0 & 1 & 0 & 1 & 0 & 1 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 1 & 0 & 1 & 0 & 1 & 0 & 1 & 0 & 1 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \end{bmatrix}p4Tp4=[1010101010000000000010101010100000000000101010101000000000001010101010000000000010101010100000000000]

Step 4: Sum of the Outer Products

Now, sum the outer products to get the final connectivity matrix W W WWW:
W = p 1 T p 1 + p 2 T p 2 + p 3 T p 3 + p 4 T p 4 W = p 1 T p 1 + p 2 T p 2 + p 3 T p 3 + p 4 T p 4 W=p_(1)^(T)p_(1)+p_(2)^(T)p_(2)+p_(3)^(T)p_(3)+p_(4)^(T)p_(4)W = \mathbf{p}_1^T \mathbf{p}_1 + \mathbf{p}_2^T \mathbf{p}_2 + \mathbf{p}_3^T \mathbf{p}_3 + \mathbf{p}_4^T \mathbf{p}_4W=p1Tp1+p2Tp2+p3Tp3+p4Tp4
Summing all the matrices element-wise, we get:
W = [ 4 2 4 0 2 0 2 0 2 1 2 2 2 0 0 0 0 0 0 1 4 2 4 0 2 0 2 0 2 1 0 0 0 0 0 0 0 0 0 0 2 0 2 0 2 0 2 0 2 0 0 0 0 0 0 0 0 0 0 0 2 0 2 0 2 0 2 0 2 0 0 0 0 0 0 0 0 2 2 2 2 0 2 0 2 0 2 2 2 2 1 1 1 0 0 0 0 2 2 3 ] W = 4 2 4 0 2 0 2 0 2 1 2 2 2 0 0 0 0 0 0 1 4 2 4 0 2 0 2 0 2 1 0 0 0 0 0 0 0 0 0 0 2 0 2 0 2 0 2 0 2 0 0 0 0 0 0 0 0 0 0 0 2 0 2 0 2 0 2 0 2 0 0 0 0 0 0 0 0 2 2 2 2 0 2 0 2 0 2 2 2 2 1 1 1 0 0 0 0 2 2 3 W=[[4,2,4,0,2,0,2,0,2,1],[2,2,2,0,0,0,0,0,0,1],[4,2,4,0,2,0,2,0,2,1],[0,0,0,0,0,0,0,0,0,0],[2,0,2,0,2,0,2,0,2,0],[0,0,0,0,0,0,0,0,0,0],[2,0,2,0,2,0,2,0,2,0],[0,0,0,0,0,0,0,2,2,2],[2,0,2,0,2,0,2,2,2,2],[1,1,1,0,0,0,0,2,2,3]]W = \begin{bmatrix} 4 & 2 & 4 & 0 & 2 & 0 & 2 & 0 & 2 & 1 \\ 2 & 2 & 2 & 0 & 0 & 0 & 0 & 0 & 0 & 1 \\ 4 & 2 & 4 & 0 & 2 & 0 & 2 & 0 & 2 & 1 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 2 & 0 & 2 & 0 & 2 & 0 & 2 & 0 & 2 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 2 & 0 & 2 & 0 & 2 & 0 & 2 & 0 & 2 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 2 & 2 & 2 \\ 2 & 0 & 2 & 0 & 2 & 0 & 2 & 2 & 2 & 2 \\ 1 & 1 & 1 & 0 & 0 & 0 & 0 & 2 & 2 & 3 \end{bmatrix}W=[4240202021222000000142402020210000000000202020202000000000002020202020000000022220202022221110000223]

Final Answer: Connectivity Matrix W W WWW

The Connectivity Matrix (CM) is:
W = [ 4 2 4 0 2 0 2 0 2 1 2 2 2 0 0 0 0 0 0 1 4 2 4 0 2 0 2 0 2 1 0 0 0 0 0 0 0 0 0 0 2 0 2 0 2 0 2 0 2 0 0 0 0 0 0 0 0 0 0 0 2 0 2 0 2 0 2 0 2 0 0 0 0 0 0 0 0 2 2 2 2 0 2 0 2 0 2 2 2 2 1 1 1 0 0 0 0 2 2 3 ] W = 4 2 4 0 2 0 2 0 2 1 2 2 2 0 0 0 0 0 0 1 4 2 4 0 2 0 2 0 2 1 0 0 0 0 0 0 0 0 0 0 2 0 2 0 2 0 2 0 2 0 0 0 0 0 0 0 0 0 0 0 2 0 2 0 2 0 2 0 2 0 0 0 0 0 0 0 0 2 2 2 2 0 2 0 2 0 2 2 2 2 1 1 1 0 0 0 0 2 2 3 W=[[4,2,4,0,2,0,2,0,2,1],[2,2,2,0,0,0,0,0,0,1],[4,2,4,0,2,0,2,0,2,1],[0,0,0,0,0,0,0,0,0,0],[2,0,2,0,2,0,2,0,2,0],[0,0,0,0,0,0,0,0,0,0],[2,0,2,0,2,0,2,0,2,0],[0,0,0,0,0,0,0,2,2,2],[2,0,2,0,2,0,2,2,2,2],[1,1,1,0,0,0,0,2,2,3]]W = \begin{bmatrix} 4 & 2 & 4 & 0 & 2 & 0 & 2 & 0 & 2 & 1 \\ 2 & 2 & 2 & 0 & 0 & 0 & 0 & 0 & 0 & 1 \\ 4 & 2 & 4 & 0 & 2 & 0 & 2 & 0 & 2 & 1 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 2 & 0 & 2 & 0 & 2 & 0 & 2 & 0 & 2 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 2 & 0 & 2 & 0 & 2 & 0 & 2 & 0 & 2 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 2 & 2 & 2 \\ 2 & 0 & 2 & 0 & 2 & 0 & 2 & 2 & 2 & 2 \\ 1 & 1 & 1 & 0 & 0 & 0 & 0 & 2 & 2 & 3 \end{bmatrix}W=[4240202021222000000142402020210000000000202020202000000000002020202020000000022220202022221110000223]




Question:-7(a)

Define Kohonen networks with examples.

Answer:

Kohonen Networks, also known as Self-Organizing Maps (SOMs), are a type of unsupervised neural network used for clustering and visualizing high-dimensional data by projecting it into a lower-dimensional space, typically a two-dimensional grid. These networks are named after Teuvo Kohonen, who introduced this technique.

Key Characteristics of Kohonen Networks:

  • Unsupervised Learning: SOMs do not require labeled data. They automatically group similar data points together based on patterns in the input data.
  • Topological Preservation: The network attempts to maintain the relative distance of data points in the input space, meaning similar data points in the input will map to nearby nodes in the output map.
  • Dimensionality Reduction: High-dimensional input data is mapped onto a low-dimensional grid, often 2D, making it easier to visualize complex data patterns.

Structure of Kohonen Networks:

A Kohonen Network consists of:
  1. Input Layer: The input vector representing the features of the data.
  2. Output Layer (Map Units): A grid of neurons (or nodes), usually arranged in a 2D lattice. Each neuron in this grid has a weight vector of the same dimension as the input vector.
  3. Weight Vectors: Each node in the output layer is associated with a weight vector that is iteratively adjusted during the learning process to represent the input data.

Working of Kohonen Networks (SOM):

  1. Initialization: The weights of the neurons are initialized, typically with small random values.
  2. Input Vector Presentation: An input vector from the dataset is presented to the network.
  3. Best Matching Unit (BMU): The Euclidean distance between the input vector and each neuron’s weight vector is calculated. The neuron whose weight vector is closest to the input vector is called the Best Matching Unit (BMU).
    BMU = arg min j x w j BMU = arg min j x w j “BMU”=arg min _(j)||x-w_(j)||\text{BMU} = \arg \min_j \|\mathbf{x} – \mathbf{w}_j\|BMU=argminjxwj
    where x x x\mathbf{x}x is the input vector, and w j w j w_(j)\mathbf{w}_jwj is the weight vector of neuron j j jjj.
  4. Weight Update: The BMU and its neighboring neurons have their weights updated to become more similar to the input vector. The amount of update depends on the learning rate and the neighborhood function, which shrinks over time.
    w j ( t + 1 ) = w j ( t ) + η ( t ) h ( j , t ) ( x ( t ) w j ( t ) ) w j ( t + 1 ) = w j ( t ) + η ( t ) h ( j , t ) ( x ( t ) w j ( t ) ) w_(j)(t+1)=w_(j)(t)+eta(t)*h(j,t)*(x(t)-w_(j)(t))\mathbf{w}_j(t+1) = \mathbf{w}_j(t) + \eta(t) \cdot h(j,t) \cdot (\mathbf{x}(t) – \mathbf{w}_j(t))wj(t+1)=wj(t)+η(t)h(j,t)(x(t)wj(t))
    where:
    • w j ( t + 1 ) w j ( t + 1 ) w_(j)(t+1)\mathbf{w}_j(t+1)wj(t+1) is the updated weight vector,
    • η ( t ) η ( t ) eta(t)\eta(t)η(t) is the learning rate,
    • h ( j , t ) h ( j , t ) h(j,t)h(j,t)h(j,t) is the neighborhood function,
    • x ( t ) x ( t ) x(t)\mathbf{x}(t)x(t) is the input vector.
  5. Iteration: The process is repeated for multiple iterations and for all input vectors until the weights stabilize, and the network becomes "self-organized."

Example of Kohonen Network:

Dataset:

Consider a simple dataset of two-dimensional points:
Data Point Feature 1 (X) Feature 2 (Y)
A 0.1 0.6
B 0.8 0.7
C 0.4 0.3
D 0.9 0.2
We want to cluster this data using a Kohonen network with a 2 × 2 2 × 2 2xx22 \times 22×2 grid of neurons.

Steps:

  1. Initialization: Assume the weights of the neurons in the 2 × 2 2 × 2 2xx22 \times 22×2 grid are initialized as random 2D vectors:
    Weights of neurons: w 1 = ( 0.2 , 0.4 ) , w 2 = ( 0.6 , 0.1 ) , w 3 = ( 0.7 , 0.9 ) , w 4 = ( 0.5 , 0.5 ) Weights of neurons: w 1 = ( 0.2 , 0.4 ) , w 2 = ( 0.6 , 0.1 ) , w 3 = ( 0.7 , 0.9 ) , w 4 = ( 0.5 , 0.5 ) “Weights of neurons: “w_(1)=(0.2,0.4),w_(2)=(0.6,0.1),w_(3)=(0.7,0.9),w_(4)=(0.5,0.5)\text{Weights of neurons: } \mathbf{w}_1 = (0.2, 0.4), \mathbf{w}_2 = (0.6, 0.1), \mathbf{w}_3 = (0.7, 0.9), \mathbf{w}_4 = (0.5, 0.5)Weights of neurons: w1=(0.2,0.4),w2=(0.6,0.1),w3=(0.7,0.9),w4=(0.5,0.5)
  2. Input Vector Presentation: Present the first data point x A = ( 0.1 , 0.6 ) x A = ( 0.1 , 0.6 ) x_(A)=(0.1,0.6)\mathbf{x}_A = (0.1, 0.6)xA=(0.1,0.6).
  3. BMU Selection: Calculate the Euclidean distance between the input point x A x A x_(A)\mathbf{x}_AxA and each neuron’s weight:
    d ( x A , w 1 ) = ( 0.1 0.2 ) 2 + ( 0.6 0.4 ) 2 = 0.224 d ( x A , w 1 ) = ( 0.1 0.2 ) 2 + ( 0.6 0.4 ) 2 = 0.224 d(x_(A),w_(1))=sqrt((0.1-0.2)^(2)+(0.6-0.4)^(2))=0.224d(\mathbf{x}_A, \mathbf{w}_1) = \sqrt{(0.1 – 0.2)^2 + (0.6 – 0.4)^2} = 0.224d(xA,w1)=(0.10.2)2+(0.60.4)2=0.224
    d ( x A , w 2 ) = ( 0.1 0.6 ) 2 + ( 0.6 0.1 ) 2 = 0.707 d ( x A , w 2 ) = ( 0.1 0.6 ) 2 + ( 0.6 0.1 ) 2 = 0.707 d(x_(A),w_(2))=sqrt((0.1-0.6)^(2)+(0.6-0.1)^(2))=0.707d(\mathbf{x}_A, \mathbf{w}_2) = \sqrt{(0.1 – 0.6)^2 + (0.6 – 0.1)^2} = 0.707d(xA,w2)=(0.10.6)2+(0.60.1)2=0.707
    d ( x A , w 3 ) = ( 0.1 0.7 ) 2 + ( 0.6 0.9 ) 2 = 0.678 d ( x A , w 3 ) = ( 0.1 0.7 ) 2 + ( 0.6 0.9 ) 2 = 0.678 d(x_(A),w_(3))=sqrt((0.1-0.7)^(2)+(0.6-0.9)^(2))=0.678d(\mathbf{x}_A, \mathbf{w}_3) = \sqrt{(0.1 – 0.7)^2 + (0.6 – 0.9)^2} = 0.678d(xA,w3)=(0.10.7)2+(0.60.9)2=0.678
    d ( x A , w 4 ) = ( 0.1 0.5 ) 2 + ( 0.6 0.5 ) 2 = 0.412 d ( x A , w 4 ) = ( 0.1 0.5 ) 2 + ( 0.6 0.5 ) 2 = 0.412 d(x_(A),w_(4))=sqrt((0.1-0.5)^(2)+(0.6-0.5)^(2))=0.412d(\mathbf{x}_A, \mathbf{w}_4) = \sqrt{(0.1 – 0.5)^2 + (0.6 – 0.5)^2} = 0.412d(xA,w4)=(0.10.5)2+(0.60.5)2=0.412
    The neuron with the smallest distance is neuron 1, so it is the BMU.
  4. Update Weights: Update the weight of neuron 1 (the BMU) and its neighboring neurons. Assuming a learning rate η = 0.5 η = 0.5 eta=0.5\eta = 0.5η=0.5 and that neuron 4 is within the neighborhood, the updated weights are:
    w 1 = ( 0.2 , 0.4 ) + 0.5 ( ( 0.1 , 0.6 ) ( 0.2 , 0.4 ) ) = ( 0.15 , 0.5 ) w 1 = ( 0.2 , 0.4 ) + 0.5 ( ( 0.1 , 0.6 ) ( 0.2 , 0.4 ) ) = ( 0.15 , 0.5 ) w_(1)=(0.2,0.4)+0.5*((0.1,0.6)-(0.2,0.4))=(0.15,0.5)\mathbf{w}_1 = (0.2, 0.4) + 0.5 \cdot ((0.1, 0.6) – (0.2, 0.4)) = (0.15, 0.5)w1=(0.2,0.4)+0.5((0.1,0.6)(0.2,0.4))=(0.15,0.5)
    w 4 = ( 0.5 , 0.5 ) + 0.5 ( ( 0.1 , 0.6 ) ( 0.5 , 0.5 ) ) = ( 0.3 , 0.55 ) w 4 = ( 0.5 , 0.5 ) + 0.5 ( ( 0.1 , 0.6 ) ( 0.5 , 0.5 ) ) = ( 0.3 , 0.55 ) w_(4)=(0.5,0.5)+0.5*((0.1,0.6)-(0.5,0.5))=(0.3,0.55)\mathbf{w}_4 = (0.5, 0.5) + 0.5 \cdot ((0.1, 0.6) – (0.5, 0.5)) = (0.3, 0.55)w4=(0.5,0.5)+0.5((0.1,0.6)(0.5,0.5))=(0.3,0.55)
  5. Repeat: The process is repeated for all input vectors until the weights converge.

Output:

After several iterations, the neurons will represent clusters of the input data. The data points that are closer in feature space will be mapped to nearby neurons in the 2D grid.

Applications of Kohonen Networks:

  1. Data Clustering: SOMs are widely used to cluster high-dimensional data into groups where similar data points are grouped together in the map. For example, clustering customer profiles based on purchasing behavior.
  2. Dimensionality Reduction: Kohonen networks can be used to reduce the dimensionality of data while preserving topological relationships. For example, reducing 100-dimensional data into a 2D map for visualization.
  3. Pattern Recognition: Kohonen networks can be applied to recognize patterns in input data, such as in speech recognition and image classification.
  4. Visualization: They are also used for visualizing complex relationships in high-dimensional datasets. For instance, visualizing a large number of genes in a 2D map based on gene expression data.

Conclusion:

Kohonen Networks (Self-Organizing Maps) are powerful tools for unsupervised learning that help cluster and visualize high-dimensional data by mapping it to a lower-dimensional grid. They are used in various fields like data mining, pattern recognition, and feature extraction due to their ability to preserve topological relationships and uncover hidden patterns in the data.




Question:-7(b)

Describe the Function Approximation in MLP. Also, explain Generalization of MLP.

Answer:

Function Approximation in Multi-Layer Perceptron (MLP)

A Multi-Layer Perceptron (MLP) is a type of feedforward neural network that can approximate complex, non-linear functions. In function approximation, the goal is to learn a mapping from input data (features) to output data (target values), based on a set of training examples. MLPs are capable of approximating both continuous and discrete functions by adjusting their weights and biases through training.

Key Components of Function Approximation in MLP:

  1. Layers:
    • Input Layer: Receives input data (features) x = [ x 1 , x 2 , , x n ] x = [ x 1 , x 2 , , x n ] x=[x_(1),x_(2),dots,x_(n)]\mathbf{x} = [x_1, x_2, \dots, x_n]x=[x1,x2,,xn].
    • Hidden Layers: One or more layers that process the inputs using weights, biases, and activation functions. These layers extract and learn complex patterns in the data.
    • Output Layer: Produces the final approximation of the function. The number of neurons in this layer corresponds to the number of outputs (e.g., a single neuron for scalar output or multiple neurons for vector outputs).
  2. Activation Functions:
    • Activation functions introduce non-linearity into the model, which allows MLPs to approximate complex functions. Common activation functions include sigmoid, ReLU (Rectified Linear Unit), and tanh.
  3. Training Process:
    • Feedforward: During the forward pass, the input data is propagated through the network layer by layer, using the weights and biases of the neurons to compute outputs.
    • Loss Function: The difference between the actual output (from the MLP) and the desired output (target) is calculated using a loss function, such as mean squared error (MSE) for regression tasks or cross-entropy for classification.
    • Backpropagation and Weight Update: The error is propagated back through the network, and the weights are updated using an optimization algorithm like gradient descent to minimize the error.
  4. Universal Approximation Theorem:
    The Universal Approximation Theorem states that an MLP with at least one hidden layer containing a sufficient number of neurons can approximate any continuous function to any desired accuracy, provided that an appropriate activation function (e.g., sigmoid or tanh) is used. This theorem emphasizes that MLPs are powerful tools for function approximation, capable of learning complex, non-linear mappings from inputs to outputs.

Example of Function Approximation in MLP:

Suppose we want to approximate the function f ( x ) = x 2 + 2 x + 1 f ( x ) = x 2 + 2 x + 1 f(x)=x^(2)+2x+1f(x) = x^2 + 2x + 1f(x)=x2+2x+1. Given a dataset of input-output pairs ( x , f ( x ) ) ( x , f ( x ) ) (x,f(x))(x, f(x))(x,f(x)), an MLP can be trained to learn this quadratic function. The MLP would adjust its weights and biases to minimize the error between the predicted and actual outputs. After training, the MLP can generalize and predict the output for unseen inputs, effectively approximating the function f ( x ) f ( x ) f(x)f(x)f(x).

Generalization of Multi-Layer Perceptron (MLP)

Generalization refers to the MLP’s ability to correctly predict or classify unseen data after being trained on a given dataset. In other words, a well-generalized MLP can apply what it has learned during training to new, previously unseen inputs and produce accurate predictions.

Key Concepts of Generalization:

  1. Training vs. Testing:
    • During training, the MLP adjusts its weights based on the given training data to minimize the error between predicted and actual outputs.
    • Generalization is evaluated on test data, which the MLP has never seen during training. If the model performs well on this unseen test data, it is said to generalize well.
  2. Overfitting:
    • Overfitting occurs when the MLP performs very well on the training data but poorly on the test data. This happens because the network has learned the noise and specific details in the training data rather than capturing the underlying pattern.
    • Overfitting can be recognized when the training error continues to decrease, but the test error starts to increase. It indicates that the model has become too complex, memorizing the training data rather than generalizing from it.
  3. Underfitting:
    • Underfitting occurs when the MLP is too simple (e.g., having too few neurons or layers) to capture the underlying patterns in the data. The model performs poorly on both the training and test datasets because it fails to learn the function properly.

Techniques to Improve Generalization:

  1. Regularization:
    • Regularization techniques like L2 regularization (weight decay) or L1 regularization (lasso) add a penalty term to the loss function to constrain the weights and prevent the model from becoming too complex.
    • The loss function is modified to include the regularization term: Loss = MSE + λ w i 2 Loss = MSE + λ w i 2 “Loss”=”MSE”+lambda sumw_(i)^(2)\text{Loss} = \text{MSE} + \lambda \sum w_i^2Loss=MSE+λwi2where λ λ lambda\lambdaλ is the regularization coefficient, and w i w i w_(i)w_iwi are the weights.
  2. Dropout:
    • Dropout is a regularization technique where, during each training iteration, random neurons are "dropped" (i.e., temporarily ignored) from the network. This prevents the network from becoming too reliant on specific neurons and encourages the model to learn more robust features.
  3. Early Stopping:
    • Early stopping involves monitoring the performance of the MLP on a validation dataset during training. If the validation error starts to increase while the training error continues to decrease, training is stopped to avoid overfitting.
  4. Cross-Validation:
    • K-fold cross-validation is used to ensure that the MLP generalizes well. The dataset is split into k k kkk subsets, and the model is trained on k 1 k 1 k-1k-1k1 subsets and tested on the remaining subset. This process is repeated k k kkk times, with a different subset used as the test set each time. The final result is averaged over all folds, providing a more robust measure of generalization.

Example of Generalization in MLP:

Consider an MLP trained to classify handwritten digits (e.g., the MNIST dataset). After training the network on thousands of labeled digit images, the MLP’s generalization ability is tested on a separate test set containing different handwritten digits that the network has never seen before. If the MLP can correctly classify these unseen digits with high accuracy, it has generalized well.

Conclusion:

  • Function Approximation in an MLP refers to the network’s ability to learn a mapping from inputs to outputs by adjusting its weights based on training data. MLPs, through their non-linear activation functions and multiple layers, can approximate complex functions.
  • Generalization is the ability of the MLP to perform well on unseen data after training. Good generalization means that the MLP has learned the underlying patterns in the data and not just memorized the training examples. Techniques like regularization, dropout, and early stopping help to improve generalization and prevent overfitting.




Question:-8(a)

Find the length and order of the following schema:

i) S 1 = ( 1 00 1 ) S 1 = 1 00 1 S_(1)=(1^(****)00**1^(****))\mathrm{S}_1=\left(1^{* *} 00 * 1^{* *}\right)S1=(1001)
ii) S 2 = ( 00 1 ) S 2 = 00 1 S_(2)=(^(**)00^(**)1^(****))\mathrm{S}_2=\left({ }^* 00{ }^* 1^{* *}\right)S2=(001)
iii) S 3 = ( 1 ) S 3 = 1 S_(3)=(******1^(******))\mathrm{S}_3=\left(* * * 1^{* * *}\right)S3=(1)

Answer:

In the context of schema theory, we define the length and order of a schema as follows:
  • Length: The length of a schema is the distance between the first and the last fixed positions (positions that are either 0 0 000 or 1 1 111) in the string.
  • Order: The order of a schema is the number of fixed positions (positions that are either 0 0 000 or 1 1 111) in the string.
Now, let’s calculate the length and order for the given schemas.

i) Schema S 1 = ( 1 00 1 ) S 1 = 1 00 1 S_(1)=(1^(****)00**1^(****))\mathrm{S}_1 = \left(1^{**} 00 * 1^{**}\right)S1=(1001)

Order:

  • The fixed positions are:
    • Position 1: 1 1 111,
    • Positions 5 and 6: 00 00 000000,
    • Position 8: 1 1 111.
  • Therefore, the fixed positions are 1, 5, 6, and 8.
  • The number of fixed positions is 4.
Thus, the order of S 1 S 1 S_(1)\mathrm{S}_1S1 is:
Order of S 1 = 4 Order of S 1 = 4 “Order of “S_(1)=4\text{Order of } \mathrm{S}_1 = 4Order of S1=4

Length:

  • The first fixed position is at position 1 (the first 1 1 111).
  • The last fixed position is at position 8 (the last 1 1 111).
  • The distance between these positions is 8 1 = 7 8 1 = 7 8-1=78 – 1 = 781=7.
Thus, the length of S 1 S 1 S_(1)\mathrm{S}_1S1 is:
Length of S 1 = 7 Length of S 1 = 7 “Length of “S_(1)=7\text{Length of } \mathrm{S}_1 = 7Length of S1=7

ii) Schema S 2 = ( 00 1 ) S 2 = 00 1 S_(2)=(^(**)00^(**)1^(****))\mathrm{S}_2 = \left({ }^* 00 { }^* 1^{**}\right)S2=(001)

Order:

  • The fixed positions are:
    • Positions 2 and 3: 00 00 000000,
    • Position 6: 1 1 111.
  • Therefore, the fixed positions are 2, 3, and 6.
  • The number of fixed positions is 3.
Thus, the order of S 2 S 2 S_(2)\mathrm{S}_2S2 is:
Order of S 2 = 3 Order of S 2 = 3 “Order of “S_(2)=3\text{Order of } \mathrm{S}_2 = 3Order of S2=3

Length:

  • The first fixed position is at position 2 (the first 0 0 000).
  • The last fixed position is at position 6 (the 1 1 111).
  • The distance between these positions is 6 2 = 4 6 2 = 4 6-2=46 – 2 = 462=4.
Thus, the length of S 2 S 2 S_(2)\mathrm{S}_2S2 is:
Length of S 2 = 4 Length of S 2 = 4 “Length of “S_(2)=4\text{Length of } \mathrm{S}_2 = 4Length of S2=4

iii) Schema S 3 = ( 1 ) S 3 = 1 S_(3)=(******1^(******))\mathrm{S}_3 = \left(* * * 1^{***}\right)S3=(1)

Order:

  • The fixed position is:
    • Position 4: 1 1 111.
  • There is only one fixed position, which is position 4.
Thus, the order of S 3 S 3 S_(3)\mathrm{S}_3S3 is:
Order of S 3 = 1 Order of S 3 = 1 “Order of “S_(3)=1\text{Order of } \mathrm{S}_3 = 1Order of S3=1

Length:

  • Since there is only one fixed position (at position 4), the length of the schema is 0, because the distance between the first and last fixed positions is 0.
Thus, the length of S 3 S 3 S_(3)\mathrm{S}_3S3 is:
Length of S 3 = 0 Length of S 3 = 0 “Length of “S_(3)=0\text{Length of } \mathrm{S}_3 = 0Length of S3=0

Final Answer:

  • S 1 = ( 1 00 1 ) S 1 = 1 00 1 S_(1)=(1^(****)00**1^(****))\mathrm{S}_1 = \left(1^{**} 00 * 1^{**}\right)S1=(1001):
    • Order: 4
    • Length: 7
  • S 2 = ( 00 1 ) S 2 = 00 1 S_(2)=(^(**)00^(**)1^(****))\mathrm{S}_2 = \left({ }^* 00 { }^* 1^{**}\right)S2=(001):
    • Order: 3
    • Length: 4
  • S 3 = ( 1 ) S 3 = 1 S_(3)=(******1^(******))\mathrm{S}_3 = \left(* * * 1^{***}\right)S3=(1):
    • Order: 1
    • Length: 0




Question:-8(b)

Let an activation function be defined as

ϕ ( v ) = 1 1 + e zv , a > 0 ϕ ( v ) = 1 1 + e zv , a > 0 phi(v)=(1)/(1+e^(-zv)),a > 0\phi(\mathrm{v})=\frac{1}{1+\mathrm{e}^{-\mathrm{zv}}}, \mathrm{a}>0ϕ(v)=11+ezv,a>0
Show that d ϕ d v = a ϕ ( v ) [ 1 ϕ ( v ) ] d ϕ d v = a ϕ ( v ) [ 1 ϕ ( v ) ] (d phi)/(dv)=a phi(v)[1-phi(v)]\frac{d \phi}{d v}=a \phi(v)[1-\phi(v)]dϕdv=aϕ(v)[1ϕ(v)]. What is the value of ϕ ( v ) ϕ ( v ) phi(v)\phi(v)ϕ(v) at the origin? Also, find the value of ϕ ( v ) ϕ ( v ) phi(v)\phi(\mathrm{v})ϕ(v) as v v vvv approaches + + +oo+\infty+ and -oo-\infty.

Answer:

We are given the activation function:
ϕ ( v ) = 1 1 + e a v , a > 0 ϕ ( v ) = 1 1 + e a v , a > 0 phi(v)=(1)/(1+e^(-av)),quad a > 0\phi(v) = \frac{1}{1 + e^{-av}}, \quad a > 0ϕ(v)=11+eav,a>0
where a a aaa is a positive constant, and we need to:
  1. Show that d ϕ d v = a ϕ ( v ) [ 1 ϕ ( v ) ] d ϕ d v = a ϕ ( v ) [ 1 ϕ ( v ) ] (d phi)/(dv)=a phi(v)[1-phi(v)]\frac{d \phi}{d v} = a \phi(v) [1 – \phi(v)]dϕdv=aϕ(v)[1ϕ(v)],
  2. Find the value of ϕ ( v ) ϕ ( v ) phi(v)\phi(v)ϕ(v) at the origin ( v = 0 v = 0 v=0v = 0v=0),
  3. Find the value of ϕ ( v ) ϕ ( v ) phi(v)\phi(v)ϕ(v) as v v vvv approaches + + +oo+\infty+ and -oo-\infty.

1. Differentiating ϕ ( v ) ϕ ( v ) phi(v)\phi(v)ϕ(v) with respect to v v vvv

The given activation function is:
ϕ ( v ) = 1 1 + e a v . ϕ ( v ) = 1 1 + e a v . phi(v)=(1)/(1+e^(-av)).\phi(v) = \frac{1}{1 + e^{-av}}.ϕ(v)=11+eav.
Let’s differentiate ϕ ( v ) ϕ ( v ) phi(v)\phi(v)ϕ(v) with respect to v v vvv:
d ϕ d v = d d v ( 1 1 + e a v ) . d ϕ d v = d d v 1 1 + e a v . (d phi)/(dv)=(d)/(dv)((1)/(1+e^(-av))).\frac{d \phi}{d v} = \frac{d}{dv} \left( \frac{1}{1 + e^{-av}} \right).dϕdv=ddv(11+eav).
Using the chain rule, let’s first differentiate the denominator. The denominator is 1 + e a v 1 + e a v 1+e^(-av)1 + e^{-av}1+eav, so the derivative of this term with respect to v v vvv is:
d d v ( 1 + e a v ) = a e a v . d d v 1 + e a v = a e a v . (d)/(dv)(1+e^(-av))=-ae^(-av).\frac{d}{dv} \left( 1 + e^{-av} \right) = -a e^{-av}.ddv(1+eav)=aeav.
Now, applying the quotient rule for differentiation:
d ϕ d v = 0 ( 1 + e a v ) ( 1 ) ( a e a v ) ( 1 + e a v ) 2 = a e a v ( 1 + e a v ) 2 . d ϕ d v = 0 ( 1 + e a v ) ( 1 ) ( a e a v ) ( 1 + e a v ) 2 = a e a v ( 1 + e a v ) 2 . (d phi)/(dv)=(0*(1+e^(-av))-(1)*(-ae^(-av)))/((1+e^(-av))^(2))=(ae^(-av))/((1+e^(-av))^(2)).\frac{d \phi}{d v} = \frac{0 \cdot (1 + e^{-av}) – (1) \cdot (-a e^{-av})}{(1 + e^{-av})^2} = \frac{a e^{-av}}{(1 + e^{-av})^2}.dϕdv=0(1+eav)(1)(aeav)(1+eav)2=aeav(1+eav)2.
Since ϕ ( v ) = 1 1 + e a v ϕ ( v ) = 1 1 + e a v phi(v)=(1)/(1+e^(-av))\phi(v) = \frac{1}{1 + e^{-av}}ϕ(v)=11+eav, we can express e a v e a v e^(-av)e^{-av}eav as:
e a v = 1 ϕ ( v ) ϕ ( v ) . e a v = 1 ϕ ( v ) ϕ ( v ) . e^(-av)=(1-phi(v))/(phi(v)).e^{-av} = \frac{1 – \phi(v)}{\phi(v)}.eav=1ϕ(v)ϕ(v).
Substitute this expression for e a v e a v e^(-av)e^{-av}eav into the derivative:
d ϕ d v = a 1 ϕ ( v ) ϕ ( v ) ( 1 + 1 ϕ ( v ) ϕ ( v ) ) 2 = a ϕ ( v ) [ 1 ϕ ( v ) ] . d ϕ d v = a 1 ϕ ( v ) ϕ ( v ) ( 1 + 1 ϕ ( v ) ϕ ( v ) ) 2 = a ϕ ( v ) [ 1 ϕ ( v ) ] . (d phi)/(dv)=(a(1-phi(v))/(phi(v)))/((1+(1-phi(v))/(phi(v)))^(2))=a phi(v)[1-phi(v)].\frac{d \phi}{d v} = \frac{a \frac{1 – \phi(v)}{\phi(v)}}{(1 + \frac{1 – \phi(v)}{\phi(v)})^2} = a \phi(v) [1 – \phi(v)].dϕdv=a1ϕ(v)ϕ(v)(1+1ϕ(v)ϕ(v))2=aϕ(v)[1ϕ(v)].
Thus, we have shown that:
d ϕ d v = a ϕ ( v ) [ 1 ϕ ( v ) ] . d ϕ d v = a ϕ ( v ) [ 1 ϕ ( v ) ] . (d phi)/(dv)=a phi(v)[1-phi(v)].\frac{d \phi}{d v} = a \phi(v) [1 – \phi(v)].dϕdv=aϕ(v)[1ϕ(v)].

2. Value of ϕ ( v ) ϕ ( v ) phi(v)\phi(v)ϕ(v) at the origin ( v = 0 v = 0 v=0v = 0v=0)

Substitute v = 0 v = 0 v=0v = 0v=0 into the expression for ϕ ( v ) ϕ ( v ) phi(v)\phi(v)ϕ(v):
ϕ ( 0 ) = 1 1 + e a 0 = 1 1 + 1 = 1 2 . ϕ ( 0 ) = 1 1 + e a 0 = 1 1 + 1 = 1 2 . phi(0)=(1)/(1+e^(-a*0))=(1)/(1+1)=(1)/(2).\phi(0) = \frac{1}{1 + e^{-a \cdot 0}} = \frac{1}{1 + 1} = \frac{1}{2}.ϕ(0)=11+ea0=11+1=12.
Thus, the value of ϕ ( v ) ϕ ( v ) phi(v)\phi(v)ϕ(v) at the origin is:
ϕ ( 0 ) = 1 2 . ϕ ( 0 ) = 1 2 . phi(0)=(1)/(2).\phi(0) = \frac{1}{2}.ϕ(0)=12.

3. Value of ϕ ( v ) ϕ ( v ) phi(v)\phi(v)ϕ(v) as v v vvv approaches + + +oo+\infty+ and -oo-\infty

As v + v + v rarr+oov \to +\inftyv+:

When v v vvv approaches + + +oo+\infty+, e a v e a v e^(-av)e^{-av}eav approaches 0 because e a v e a v e^(-av)e^{-av}eav decays exponentially. So, we have:
ϕ ( v ) = 1 1 + e a v as v + . ϕ ( v ) = 1 1 + e a v as v + . phi(v)=(1)/(1+e^(-av))quad”as”quad v rarr+oo.\phi(v) = \frac{1}{1 + e^{-av}} \quad \text{as} \quad v \to +\infty.ϕ(v)=11+eavasv+.
As e a v 0 e a v 0 e^(-av)rarr0e^{-av} \to 0eav0, we get:
ϕ ( v ) 1 1 + 0 = 1. ϕ ( v ) 1 1 + 0 = 1. phi(v)rarr(1)/(1+0)=1.\phi(v) \to \frac{1}{1 + 0} = 1.ϕ(v)11+0=1.
Thus, as v + v + v rarr+oov \to +\inftyv+, the value of ϕ ( v ) ϕ ( v ) phi(v)\phi(v)ϕ(v) approaches:
lim v + ϕ ( v ) = 1. lim v + ϕ ( v ) = 1. lim_(v rarr+oo)phi(v)=1.\lim_{v \to +\infty} \phi(v) = 1.limv+ϕ(v)=1.

As v v v rarr-oov \to -\inftyv:

When v v vvv approaches -oo-\infty, e a v e a v e^(-av)e^{-av}eav grows exponentially large because e a v e a v e^(-av)rarr ooe^{-av} \to \inftyeav. So, we have:
ϕ ( v ) = 1 1 + e a v as v . ϕ ( v ) = 1 1 + e a v as v . phi(v)=(1)/(1+e^(-av))quad”as”quad v rarr-oo.\phi(v) = \frac{1}{1 + e^{-av}} \quad \text{as} \quad v \to -\infty.ϕ(v)=11+eavasv.
As e a v e a v e^(-av)rarr ooe^{-av} \to \inftyeav, we get:
ϕ ( v ) 1 1 + = 0. ϕ ( v ) 1 1 + = 0. phi(v)rarr(1)/(1+oo)=0.\phi(v) \to \frac{1}{1 + \infty} = 0.ϕ(v)11+=0.
Thus, as v v v rarr-oov \to -\inftyv, the value of ϕ ( v ) ϕ ( v ) phi(v)\phi(v)ϕ(v) approaches:
lim v ϕ ( v ) = 0. lim v ϕ ( v ) = 0. lim_(v rarr-oo)phi(v)=0.\lim_{v \to -\infty} \phi(v) = 0.limvϕ(v)=0.

Final Results:

  1. We have shown that:
    d ϕ d v = a ϕ ( v ) [ 1 ϕ ( v ) ] . d ϕ d v = a ϕ ( v ) [ 1 ϕ ( v ) ] . (d phi)/(dv)=a phi(v)[1-phi(v)].\frac{d \phi}{d v} = a \phi(v) [1 – \phi(v)].dϕdv=aϕ(v)[1ϕ(v)].
  2. The value of ϕ ( v ) ϕ ( v ) phi(v)\phi(v)ϕ(v) at the origin is:
    ϕ ( 0 ) = 1 2 . ϕ ( 0 ) = 1 2 . phi(0)=(1)/(2).\phi(0) = \frac{1}{2}.ϕ(0)=12.
  3. The value of ϕ ( v ) ϕ ( v ) phi(v)\phi(v)ϕ(v) as v + v + v rarr+oov \to +\inftyv+ is:
    lim v + ϕ ( v ) = 1. lim v + ϕ ( v ) = 1. lim_(v rarr+oo)phi(v)=1.\lim_{v \to +\infty} \phi(v) = 1.limv+ϕ(v)=1.
  4. The value of ϕ ( v ) ϕ ( v ) phi(v)\phi(v)ϕ(v) as v v v rarr-oov \to -\inftyv is:
    lim v ϕ ( v ) = 0. lim v ϕ ( v ) = 0. lim_(v rarr-oo)phi(v)=0.\lim_{v \to -\infty} \phi(v) = 0.limvϕ(v)=0.




Question:-9(a)

Consider the following travelling salesman problem involving 9 cities.

P a r e n t 1 G J H F E D B I C P a r e n t 2 D C H J I G E F B P a r e n t 1 G J H F E D B I C P a r e n t 2 D C H J I G E F B {:[Parent1,G,J,H,F,E,D,B,I,C],[Parent2,D,C,H,J,I,G,E,F,B]:}\begin{array}{|l|l|l|l|l|l|l|l|l|l|} \hline Parent 1 & G & J & H & F & E & D & B & I & C \\ \hline Parent 2 & D & C & H & J & I & G & E & F & B \\ \hline \end{array}Parent1GJHFEDBICParent2DCHJIGEFB
Determine the children solution using:
i) Order crossover #1, assuming 4 th 4 th 4^(“th “)4^{\text {th }}4th and 7 th 7 th 7^(“th “)7^{\text {th }}7th sites as the crossover sites.
ii) Order crossover #2, assuming 3 rd , 5 th 3 rd , 5 th 3^(“rd “),5^(“th “)3^{\text {rd }}, 5^{\text {th }}3rd ,5th and 7 th 7 th 7^(“th “)7^{\text {th }}7th as the key positions.

Answer:

i) Order Crossover #1

In Order Crossover #1 (OX1), we generate two child solutions from two parent solutions by selecting a subset of the tour (sequence of cities) from each parent and preserving the relative order of the remaining cities.
Given:
  • Parent 1: G , J , H , F , E , D , B , I , C G , J , H , F , E , D , B , I , C G,J,H,F,E,D,B,I,CG, J, H, F, E, D, B, I, CG,J,H,F,E,D,B,I,C
  • Parent 2: D , C , H , J , I , G , E , F , B D , C , H , J , I , G , E , F , B D,C,H,J,I,G,E,F,BD, C, H, J, I, G, E, F, BD,C,H,J,I,G,E,F,B
  • Crossover points are at the 4th and 7th sites.

Steps for OX1:

  1. Copy the segment between the crossover points from Parent 1 to Child 1 and from Parent 2 to Child 2:
    • Child 1: Copy cities from positions 4 to 7 in Parent 1, i.e., [ F , E , D , B ] [ F , E , D , B ] [F,E,D,B][F, E, D, B][F,E,D,B].
    • Child 2: Copy cities from positions 4 to 7 in Parent 2, i.e., [ J , I , G , E ] [ J , I , G , E ] [J,I,G,E][J, I, G, E][J,I,G,E].
  2. Preserve the relative order of the remaining cities from the other parent:
    • Start from the end of the crossover segment and continue circularly to fill the remaining positions.
    • For Child 1, we need to place the cities D , C , H , J , I , G D , C , H , J , I , G D,C,H,J,I,GD, C, H, J, I, GD,C,H,J,I,G (in that order from Parent 2) in the empty spots, skipping those already in Child 1.
    • For Child 2, we need to place the cities G , J , H , F , E , D , B , I , C G , J , H , F , E , D , B , I , C G,J,H,F,E,D,B,I,CG, J, H, F, E, D, B, I, CG,J,H,F,E,D,B,I,C (in that order from Parent 1), skipping those already in Child 2.

Construction of Child 1:

  • Initial segment from Parent 1: [ F , E , D , B ] [ F , E , D , B ] [F,E,D,B][F, E, D, B][F,E,D,B].
  • Now, add the remaining cities from Parent 2 [ D , C , H , J , I , G ] [ D , C , H , J , I , G ] [D,C,H,J,I,G][D, C, H, J, I, G][D,C,H,J,I,G], skipping the ones already in Child 1 [ D , E , F , B ] [ D , E , F , B ] [D,E,F,B][D, E, F, B][D,E,F,B]:
    • First available city: C C CCC
    • Then: H , J , I , G H , J , I , G H,J,I,GH, J, I, GH,J,I,G
So, Child 1 becomes:
C , H , J , F , E , D , B , I , G C , H , J , F , E , D , B , I , G C,H,J,F,E,D,B,I,GC, H, J, F, E, D, B, I, GC,H,J,F,E,D,B,I,G

Construction of Child 2:

  • Initial segment from Parent 2: [ J , I , G , E ] [ J , I , G , E ] [J,I,G,E][J, I, G, E][J,I,G,E].
  • Now, add the remaining cities from Parent 1 [ G , J , H , F , E , D , B , I , C ] [ G , J , H , F , E , D , B , I , C ] [G,J,H,F,E,D,B,I,C][G, J, H, F, E, D, B, I, C][G,J,H,F,E,D,B,I,C], skipping the ones already in Child 2 [ J , I , G , E ] [ J , I , G , E ] [J,I,G,E][J, I, G, E][J,I,G,E]:
    • First available city: H H HHH
    • Then: F , D , B , C F , D , B , C F,D,B,CF, D, B, CF,D,B,C
So, Child 2 becomes:
H , F , D , J , I , G , E , B , C H , F , D , J , I , G , E , B , C H,F,D,J,I,G,E,B,CH, F, D, J, I, G, E, B, CH,F,D,J,I,G,E,B,C

ii) Order Crossover #2

In Order Crossover #2 (OX2), instead of choosing a single segment, we select specific key positions from one parent to be passed to the child. The remaining cities are filled in the order they appear in the other parent, skipping any that are already included.
Given:
  • Parent 1: G , J , H , F , E , D , B , I , C G , J , H , F , E , D , B , I , C G,J,H,F,E,D,B,I,CG, J, H, F, E, D, B, I, CG,J,H,F,E,D,B,I,C
  • Parent 2: D , C , H , J , I , G , E , F , B D , C , H , J , I , G , E , F , B D,C,H,J,I,G,E,F,BD, C, H, J, I, G, E, F, BD,C,H,J,I,G,E,F,B
  • The key positions are the 3rd, 5th, and 7th sites.

Steps for OX2:

  1. Copy the cities at the key positions from Parent 1 to Child 1 and from Parent 2 to Child 2:
    • Key positions for Child 1: H H HHH (3rd), E E EEE (5th), B B BBB (7th) from Parent 1.
    • Key positions for Child 2: H H HHH (3rd), I I III (5th), E E EEE (7th) from Parent 2.
  2. Fill the remaining cities from the other parent:
    • For Child 1, take cities from Parent 2 [ D , C , H , J , I , G , E , F , B ] [ D , C , H , J , I , G , E , F , B ] [D,C,H,J,I,G,E,F,B][D, C, H, J, I, G, E, F, B][D,C,H,J,I,G,E,F,B], skipping those already in Child 1 [ H , E , B ] [ H , E , B ] [H,E,B][H, E, B][H,E,B].
    • For Child 2, take cities from Parent 1 [ G , J , H , F , E , D , B , I , C ] [ G , J , H , F , E , D , B , I , C ] [G,J,H,F,E,D,B,I,C][G, J, H, F, E, D, B, I, C][G,J,H,F,E,D,B,I,C], skipping those already in Child 2 [ H , I , E ] [ H , I , E ] [H,I,E][H, I, E][H,I,E].

Construction of Child 1:

  • Initial positions (from Parent 1): [ H , E , B ] [ H , E , B ] [H,E,B][H, E, B][H,E,B] at positions 3, 5, and 7.
  • Now, take cities from Parent 2 [ D , C , H , J , I , G , E , F , B ] [ D , C , H , J , I , G , E , F , B ] [D,C,H,J,I,G,E,F,B][D, C, H, J, I, G, E, F, B][D,C,H,J,I,G,E,F,B], skipping the ones already in Child 1:
    • First available city: D D DDD
    • Then: C , J , I , G , F C , J , I , G , F C,J,I,G,FC, J, I, G, FC,J,I,G,F
So, Child 1 becomes:
D , C , H , J , E , I , B , G , F D , C , H , J , E , I , B , G , F D,C,H,J,E,I,B,G,FD, C, H, J, E, I, B, G, FD,C,H,J,E,I,B,G,F

Construction of Child 2:

  • Initial positions (from Parent 2): [ H , I , E ] [ H , I , E ] [H,I,E][H, I, E][H,I,E] at positions 3, 5, and 7.
  • Now, take cities from Parent 1 [ G , J , H , F , E , D , B , I , C ] [ G , J , H , F , E , D , B , I , C ] [G,J,H,F,E,D,B,I,C][G, J, H, F, E, D, B, I, C][G,J,H,F,E,D,B,I,C], skipping the ones already in Child 2:
    • First available city: G G GGG
    • Then: J , F , D , B , C J , F , D , B , C J,F,D,B,CJ, F, D, B, CJ,F,D,B,C
So, Child 2 becomes:
G , J , H , F , I , D , E , B , C G , J , H , F , I , D , E , B , C G,J,H,F,I,D,E,B,CG, J, H, F, I, D, E, B, CG,J,H,F,I,D,E,B,C

Final Answer:

  • Child 1 (OX1):
C , H , J , F , E , D , B , I , G C , H , J , F , E , D , B , I , G C,H,J,F,E,D,B,I,GC, H, J, F, E, D, B, I, GC,H,J,F,E,D,B,I,G
  • Child 2 (OX1):
H , F , D , J , I , G , E , B , C H , F , D , J , I , G , E , B , C H,F,D,J,I,G,E,B,CH, F, D, J, I, G, E, B, CH,F,D,J,I,G,E,B,C
  • Child 1 (OX2):
D , C , H , J , E , I , B , G , F D , C , H , J , E , I , B , G , F D,C,H,J,E,I,B,G,FD, C, H, J, E, I, B, G, FD,C,H,J,E,I,B,G,F
  • Child 2 (OX2):
G , J , H , F , I , D , E , B , C G , J , H , F , I , D , E , B , C G,J,H,F,I,D,E,B,CG, J, H, F, I, D, E, B, CG,J,H,F,I,D,E,B,C




="Q9(b)">Question:-9(b)

Consider the following single layer perception as shown in the following figure.

original image
and the activation function of each unit is defined as:
Φ ( v ) = { 1 , if v 0 0 , otherwise. Φ ( v ) = 1 , if v 0 0 , otherwise. Phi(v)={[1″,”” if “v >= 0],[0″,”” otherwise. “]:}\Phi(\mathrm{v})=\left\{\begin{array}{l}1, \text { if } \mathrm{v} \geq 0 \\ 0, \text { otherwise. }\end{array}\right.Φ(v)={1, if v00, otherwise.
Calculate the output y y yyy of the unit for each of the following input patterns:
Patterns P 1 P 2 P 3 P 4 x 1 1 0 1 1 x 2 0 1 0 1 x 3 0 1 1 1 Patterns P 1 P 2 P 3 P 4 x 1 1 0 1 1 x 2 0 1 0 1 x 3 0 1 1 1 {:[” Patterns “,P_(1),P_(2),P_(3),P_(4)],[x_(1),1,0,1,1],[x_(2),0,1,0,1],[x_(3),0,1,1,1]:}\begin{array}{|l|l|l|l|l|} \hline \text { Patterns } & P_1 & P_2 & P_3 & P_4 \\ \hline x_1 & 1 & 0 & 1 & 1 \\ \hline x_2 & 0 & 1 & 0 & 1 \\ \hline x_3 & 0 & 1 & 1 & 1 \\ \hline \end{array} Patterns P1P2P3P4x11011x20101x30111
Also, find the modified weights after one iteration.

Answer:

Step 1: Understanding the Structure of the Perceptron

The given diagram represents a single-layer perceptron. The inputs x 1 x 1 x_(1)x_1x1, x 2 x 2 x_(2)x_2x2, and x 3 x 3 x_(3)x_3x3 are fed into a neuron with weights w 1 = 2 w 1 = 2 w_(1)=2w_1 = 2w1=2, w 2 = 4 w 2 = 4 w_(2)=-4w_2 = -4w2=4, and w 3 = 1 w 3 = 1 w_(3)=1w_3 = 1w3=1, respectively. The output of the perceptron is computed by summing the weighted inputs and applying a threshold activation function, defined as:
Φ ( v ) = { 1 if v 0 0 if v < 0 Φ ( v ) = 1 if v 0 0 if v < 0 Phi(v)={[1,”if “v >= 0],[0,”if “v < 0]:}\Phi(v) = \begin{cases} 1 & \text{if } v \geq 0 \\ 0 & \text{if } v < 0 \end{cases}Φ(v)={1if v00if v<0
where v v vvv is the weighted sum of inputs.
The weighted sum v v vvv is given by:
v = w 1 x 1 + w 2 x 2 + w 3 x 3 v = w 1 x 1 + w 2 x 2 + w 3 x 3 v=w_(1)x_(1)+w_(2)x_(2)+w_(3)x_(3)v = w_1 x_1 + w_2 x_2 + w_3 x_3v=w1x1+w2x2+w3x3
Then, we apply the activation function Φ ( v ) Φ ( v ) Phi(v)\Phi(v)Φ(v) to get the output y y yyy.

Step 2: Calculate the Output y y yyy for Each Pattern

We are provided with 4 input patterns:
Pattern x 1 x 1 x_(1)x_1x1 x 2 x 2 x_(2)x_2x2 x 3 x 3 x_(3)x_3x3
P 1 P 1 P_(1)P_1P1 1 0 0
P 2 P 2 P_(2)P_2P2 0 1 1
P 3 P 3 P_(3)P_3P3 1 0 1
P 4 P 4 P_(4)P_4P4 1 1 1
For each pattern, we will compute the weighted sum v v vvv and the output y = Φ ( v ) y = Φ ( v ) y=Phi(v)y = \Phi(v)y=Φ(v).

Pattern P 1 P 1 P_(1)P_1P1 ( x 1 = 1 , x 2 = 0 , x 3 = 0 x 1 = 1 , x 2 = 0 , x 3 = 0 x_(1)=1,x_(2)=0,x_(3)=0x_1 = 1, x_2 = 0, x_3 = 0x1=1,x2=0,x3=0):

v = ( 2 ) ( 1 ) + ( 4 ) ( 0 ) + ( 1 ) ( 0 ) = 2 v = ( 2 ) ( 1 ) + ( 4 ) ( 0 ) + ( 1 ) ( 0 ) = 2 v=(2)(1)+(-4)(0)+(1)(0)=2v = (2)(1) + (-4)(0) + (1)(0) = 2v=(2)(1)+(4)(0)+(1)(0)=2
Since v = 2 0 v = 2 0 v=2 >= 0v = 2 \geq 0v=20, the activation function gives:
y = Φ ( 2 ) = 1 y = Φ ( 2 ) = 1 y=Phi(2)=1y = \Phi(2) = 1y=Φ(2)=1

Pattern P 2 P 2 P_(2)P_2P2 ( x 1 = 0 , x 2 = 1 , x 3 = 1 x 1 = 0 , x 2 = 1 , x 3 = 1 x_(1)=0,x_(2)=1,x_(3)=1x_1 = 0, x_2 = 1, x_3 = 1x1=0,x2=1,x3=1):

v = ( 2 ) ( 0 ) + ( 4 ) ( 1 ) + ( 1 ) ( 1 ) = 0 4 + 1 = 3 v = ( 2 ) ( 0 ) + ( 4 ) ( 1 ) + ( 1 ) ( 1 ) = 0 4 + 1 = 3 v=(2)(0)+(-4)(1)+(1)(1)=0-4+1=-3v = (2)(0) + (-4)(1) + (1)(1) = 0 – 4 + 1 = -3v=(2)(0)+(4)(1)+(1)(1)=04+1=3
Since v = 3 < 0 v = 3 < 0 v=-3 < 0v = -3 < 0v=3<0, the activation function gives:
y = Φ ( 3 ) = 0 y = Φ ( 3 ) = 0 y=Phi(-3)=0y = \Phi(-3) = 0y=Φ(3)=0

Pattern P 3 P 3 P_(3)P_3P3 ( x 1 = 1 , x 2 = 0 , x 3 = 1 x 1 = 1 , x 2 = 0 , x 3 = 1 x_(1)=1,x_(2)=0,x_(3)=1x_1 = 1, x_2 = 0, x_3 = 1x1=1,x2=0,x3=1):

v = ( 2 ) ( 1 ) + ( 4 ) ( 0 ) + ( 1 ) ( 1 ) = 2 + 0 + 1 = 3 v = ( 2 ) ( 1 ) + ( 4 ) ( 0 ) + ( 1 ) ( 1 ) = 2 + 0 + 1 = 3 v=(2)(1)+(-4)(0)+(1)(1)=2+0+1=3v = (2)(1) + (-4)(0) + (1)(1) = 2 + 0 + 1 = 3v=(2)(1)+(4)(0)+(1)(1)=2+0+1=3
Since v = 3 0 v = 3 0 v=3 >= 0v = 3 \geq 0v=30, the activation function gives:
y = Φ ( 3 ) = 1 y = Φ ( 3 ) = 1 y=Phi(3)=1y = \Phi(3) = 1y=Φ(3)=1

Pattern P 4 P 4 P_(4)P_4P4 ( x 1 = 1 , x 2 = 1 , x 3 = 1 x 1 = 1 , x 2 = 1 , x 3 = 1 x_(1)=1,x_(2)=1,x_(3)=1x_1 = 1, x_2 = 1, x_3 = 1x1=1,x2=1,x3=1):

v = ( 2 ) ( 1 ) + ( 4 ) ( 1 ) + ( 1 ) ( 1 ) = 2 4 + 1 = 1 v = ( 2 ) ( 1 ) + ( 4 ) ( 1 ) + ( 1 ) ( 1 ) = 2 4 + 1 = 1 v=(2)(1)+(-4)(1)+(1)(1)=2-4+1=-1v = (2)(1) + (-4)(1) + (1)(1) = 2 – 4 + 1 = -1v=(2)(1)+(4)(1)+(1)(1)=24+1=1
Since v = 1 < 0 v = 1 < 0 v=-1 < 0v = -1 < 0v=1<0, the activation function gives:
y = Φ ( 1 ) = 0 y = Φ ( 1 ) = 0 y=Phi(-1)=0y = \Phi(-1) = 0y=Φ(1)=0

Step 3: Summarize the Output y y yyy for Each Pattern

Pattern x 1 x 1 x_(1)x_1x1 x 2 x 2 x_(2)x_2x2 x 3 x 3 x_(3)x_3x3 v v vvv Output y y yyy
P 1 P 1 P_(1)P_1P1 1 0 0 2 1
P 2 P 2 P_(2)P_2P2 0 1 1 -3 0
P 3 P 3 P_(3)P_3P3 1 0 1 3 1
P 4 P 4 P_(4)P_4P4 1 1 1 -1 0

Step 4: Modified Weights After One Iteration

To modify the weights after one iteration, we typically use the Perceptron Learning Rule, which updates weights when the perceptron makes an error. The update rule is:
w i w i + Δ w i w i w i + Δ w i w_(i)larrw_(i)+Deltaw_(i)w_i \leftarrow w_i + \Delta w_iwiwi+Δwi
where:
Δ w i = η ( t y ) x i Δ w i = η ( t y ) x i Deltaw_(i)=eta*(t-y)*x_(i)\Delta w_i = \eta \cdot (t – y) \cdot x_iΔwi=η(ty)xi
  • t t ttt is the target output (assuming the correct output),
  • y y yyy is the predicted output,
  • x i x i x_(i)x_ixi is the input,
  • η η eta\etaη is the learning rate (commonly set to 1 for simplicity).




Question:-10

Which of the following statements are true or false? Give a short proof or a counter example in support of your answers.

a) There is chance of occurrence of the premature convergence in Roulette-wheel selection scheme used in GA.
b) Gradient based optimization methods are used when the objective function is not smooth and one needs efficient local optimization.
c) The α α alpha\alphaα-cut of a fuzzy set A in uu\cup is defined as A α 0 = { x U μ A ( x ) α 0 } A α 0 = x U μ A ( x ) α 0 Aalpha_(0)={xin U∣mu_(A)(x) <= alpha_(0)}\mathrm{A} \alpha_0=\left\{\mathrm{x} \in U \mid \mu_{\mathrm{A}}(\mathrm{x}) \leq \alpha_0\right\}Aα0={xUμA(x)α0}.
d) A single perceptron with preprocessing is neither an auto associative network nor a multiple layer neural network.
e) If W ( k 0 ) = W ( k 0 + 1 ) = W ( k 0 + 2 ) W k 0 = W k 0 + 1 = W k 0 + 2 W(k_(0))=W(k_(0)+1)=W(k_(0)+2)\mathrm{W}\left(\mathrm{k}_0\right)=\mathrm{W}\left(\mathrm{k}_0+1\right)=\mathrm{W}\left(\mathrm{k}_0+2\right)W(k0)=W(k0+1)=W(k0+2), then perception is non-linear separable.

Answer:

a) There is chance of occurrence of premature convergence in Roulette-wheel selection scheme used in GA.

True.
Reason:
  • In Roulette-wheel selection (used in Genetic Algorithms), individuals are selected with a probability proportional to their fitness. However, if one or a few individuals have significantly higher fitness values than others, they will dominate the selection process, leading to premature convergence.
  • Premature convergence happens when the population loses genetic diversity too early, causing the algorithm to get stuck in local optima rather than exploring the global search space effectively.

b) Gradient based optimization methods are used when the objective function is not smooth and one needs efficient local optimization.

False.
Reason:
  • Gradient-based optimization methods, such as gradient descent, rely on computing the gradient (or derivative) of the objective function to find the direction of steepest descent. These methods require the objective function to be smooth and differentiable, at least locally, to compute the gradient.
  • If the objective function is not smooth (discontinuous, non-differentiable), gradient-based methods cannot be applied effectively because the gradient does not exist or is unreliable.

c) The α α alpha\alphaα-cut of a fuzzy set A in uu\cup is defined as A α 0 = { x U μ A ( x ) α 0 } A α 0 = { x U μ A ( x ) α 0 } A_(alpha_(0))={x in U∣mu_(A)(x) <= alpha_(0)}\mathrm{A}_{\alpha_0} = \{x \in U \mid \mu_{\mathrm{A}}(x) \leq \alpha_0 \}Aα0={xUμA(x)α0}.

False.
Reason:
  • The correct definition of an α α alpha\alphaα-cut of a fuzzy set A A AAA is: A α 0 = { x U μ A ( x ) α 0 } A α 0 = { x U μ A ( x ) α 0 } A_(alpha_(0))={x in U∣mu_(A)(x) >= alpha_(0)}A_{\alpha_0} = \{x \in U \mid \mu_{\mathrm{A}}(x) \geq \alpha_0 \}Aα0={xUμA(x)α0}It includes all elements of the universe U U UUU whose membership value in A A AAA is greater than or equal to α 0 α 0 alpha_(0)\alpha_0α0, not less than or equal. The given definition is incorrect because it uses <=\leq instead of >=\geq.

d) A single perceptron with preprocessing is neither an auto associative network nor a multiple layer neural network.

True.
Reason:
  • A single perceptron is a simple feedforward neural network with one layer of neurons. It can only solve linearly separable problems.
  • An autoassociative network is a network where the input and output dimensions are the same, and the network is trained to output the same values as the input (used for tasks like identity mapping or denoising).
  • A multiple layer neural network consists of multiple layers of neurons (i.e., a deep neural network), which a single perceptron is not.
  • A single perceptron with preprocessing may improve input representation, but it still does not fit the definition of an autoassociative network or a multilayer neural network.

e) If W ( k 0 ) = W ( k 0 + 1 ) = W ( k 0 + 2 ) W ( k 0 ) = W ( k 0 + 1 ) = W ( k 0 + 2 ) W(k_(0))=W(k_(0)+1)=W(k_(0)+2)\mathrm{W}(k_0) = \mathrm{W}(k_0 + 1) = \mathrm{W}(k_0 + 2)W(k0)=W(k0+1)=W(k0+2), then the perceptron is non-linearly separable.

False.
Reason:
  • The condition that W ( k 0 ) = W ( k 0 + 1 ) = W ( k 0 + 2 ) W ( k 0 ) = W ( k 0 + 1 ) = W ( k 0 + 2 ) W(k_(0))=W(k_(0)+1)=W(k_(0)+2)\mathrm{W}(k_0) = \mathrm{W}(k_0 + 1) = \mathrm{W}(k_0 + 2)W(k0)=W(k0+1)=W(k0+2) implies that the weight vector does not change over iterations k 0 k 0 k_(0)k_0k0, k 0 + 1 k 0 + 1 k_(0)+1k_0 + 1k0+1, and k 0 + 2 k 0 + 2 k_(0)+2k_0 + 2k0+2.
  • This does not necessarily mean that the problem is non-linearly separable. It could indicate that the perceptron has converged and found a solution to the problem (if the problem is linearly separable), or that the learning process has stalled (e.g., due to reaching a steady state without achieving separability).
  • Non-linear separability means that no linear boundary can separate the classes, but the given weight condition alone does not prove non-linear separability.

Final Answers:

a) True
b) False
c) False
d) True
e) False




Scroll to Top
Scroll to Top