您好,欢迎访问三七文档
当前位置:首页 > IT计算机/网络 > AI人工智能 > 不确定性推理部分参考答案
第6章不确定性推理部分参考答案6.8设有如下一组推理规则:r1:IFE1THENE2(0.6)r2:IFE2ANDE3THENE4(0.7)r3:IFE4THENH(0.8)r4:IFE5THENH(0.9)且已知CF(E1)=0.5,CF(E3)=0.6,CF(E5)=0.7。求CF(H)=?解:(1)先由r1求CF(E2)CF(E2)=0.6×max{0,CF(E1)}=0.6×max{0,0.5}=0.3(2)再由r2求CF(E4)CF(E4)=0.7×max{0,min{CF(E2),CF(E3)}}=0.7×max{0,min{0.3,0.6}}=0.21(3)再由r3求CF1(H)CF1(H)=0.8×max{0,CF(E4)}=0.8×max{0,0.21)}=0.168(4)再由r4求CF2(H)CF2(H)=0.9×max{0,CF(E5)}=0.9×max{0,0.7)}=0.63(5)最后对CF1(H)和CF2(H)进行合成,求出CF(H)CF(H)=CF1(H)+CF2(H)+CF1(H)×CF2(H)=0.6926.10设有如下推理规则r1:IFE1THEN(2,0.00001)H1r2:IFE2THEN(100,0.0001)H1r3:IFE3THEN(200,0.001)H2r4:IFH1THEN(50,0.1)H2且已知P(E1)=P(E2)=P(H3)=0.6,P(H1)=0.091,P(H2)=0.01,又由用户告知:P(E1|S1)=0.84,P(E2|S2)=0.68,P(E3|S3)=0.36请用主观Bayes方法求P(H2|S1,S2,S3)=?解:(1)由r1计算O(H1|S1)先把H1的先验概率更新为在E1下的后验概率P(H1|E1)P(H1|E1)=(LS1×P(H1))/((LS1-1)×P(H1)+1)=(2×0.091)/((2-1)×0.091+1)=0.16682由于P(E1|S1)=0.84P(E1),使用P(H|S)公式的后半部分,得到在当前观察S1下的后验概率P(H1|S1)和后验几率O(H1|S1)P(H1|S1)=P(H1)+((P(H1|E1)–P(H1))/(1-P(E1)))×(P(E1|S1)–P(E1))=0.091+(0.16682–0.091)/(1–0.6))×(0.84–0.6)=0.091+0.18955×0.24=0.136492O(H1|S1)=P(H1|S1)/(1-P(H1|S1))=0.15807(2)由r2计算O(H1|S2)先把H1的先验概率更新为在E2下的后验概率P(H1|E2)P(H1|E2)=(LS2×P(H1))/((LS2-1)×P(H1)+1)=(100×0.091)/((100-1)×0.091+1)=0.90918由于P(E2|S2)=0.68P(E2),使用P(H|S)公式的后半部分,得到在当前观察S2下的后验概率P(H1|S2)和后验几率O(H1|S2)P(H1|S2)=P(H1)+((P(H1|E2)–P(H1))/(1-P(E2)))×(P(E2|S2)–P(E2))=0.091+(0.90918–0.091)/(1–0.6))×(0.68–0.6)=0.25464O(H1|S2)=P(H1|S2)/(1-P(H1|S2))=0.34163(3)计算O(H1|S1,S2)和P(H1|S1,S2)先将H1的先验概率转换为先验几率O(H1)=P(H1)/(1-P(H1))=0.091/(1-0.091)=0.10011再根据合成公式计算H1的后验几率O(H1|S1,S2)=(O(H1|S1)/O(H1))×(O(H1|S2)/O(H1))×O(H1)=(0.15807/0.10011)×(0.34163)/0.10011)×0.10011=0.53942再将该后验几率转换为后验概率P(H1|S1,S2)=O(H1|S1,S2)/(1+O(H1|S1,S2))=0.35040(4)由r3计算O(H2|S3)先把H2的先验概率更新为在E3下的后验概率P(H2|E3)P(H2|E3)=(LS3×P(H2))/((LS3-1)×P(H2)+1)=(200×0.01)/((200-1)×0.01+1)=0.09569由于P(E3|S3)=0.36P(E3),使用P(H|S)公式的前半部分,得到在当前观察S3下的后验概率P(H2|S3)和后验几率O(H2|S3)P(H2|S3)=P(H2|¬E3)+(P(H2)–P(H2|¬E3))/P(E3))×P(E3|S3)由当E3肯定不存在时有P(H2|¬E3)=LN3×P(H2)/((LN3-1)×P(H2)+1)=0.001×0.01/((0.001-1)×0.01+1)=0.00001因此有P(H2|S3)=P(H2|¬E3)+(P(H2)–P(H2|¬E3))/P(E3))×P(E3|S3)=0.00001+((0.01-0.00001)/0.6)×0.36=0.00600O(H2|S3)=P(H2|S3)/(1-P(H2|S3))=0.00604(5)由r4计算O(H2|H1)先把H2的先验概率更新为在H1下的后验概率P(H2|H1)P(H2|H1)=(LS4×P(H2))/((LS4-1)×P(H2)+1)=(50×0.01)/((50-1)×0.01+1)=0.33557由于P(H1|S1,S2)=0.35040P(H1),使用P(H|S)公式的后半部分,得到在当前观察S1,S2下H2的后验概率P(H2|S1,S2)和后验几率O(H2|S1,S2)P(H2|S1,S2)=P(H2)+((P(H2|H1)–P(H2))/(1-P(H1)))×(P(H1|S1,S2)–P(H1))=0.01+(0.33557–0.01)/(1–0.091))×(0.35040–0.091)=0.10291O(H2|S1,S2)=P(H2|S1,S2)/(1-P(H2|S1,S2))=0.10291/(1-0.10291)=0.11472(6)计算O(H2|S1,S2,S3)和P(H2|S1,S2,S3)先将H2的先验概率转换为先验几率O(H2)=P(H2)/(1-P(H2))=0.01/(1-0.01)=0.01010再根据合成公式计算H1的后验几率O(H2|S1,S2,S3)=(O(H2|S1,S2)/O(H2))×(O(H2|S3)/O(H2))×O(H2)=(0.11472/0.01010)×(0.00604)/0.01010)×0.01010=0.06832再将该后验几率转换为后验概率P(H2|S1,S2,S3)=O(H1|S1,S2,S3)/(1+O(H1|S1,S2,S3))=0.06832/(1+0.06832)=0.06395可见,H2原来的概率是0.01,经过上述推理后得到的后验概率是0.06395,它相当于先验概率的6倍多。6.11设有如下推理规则r1:IFE1THEN(100,0.1)H1r2:IFE2THEN(50,0.5)H2r3:IFE3THEN(5,0.05)H3且已知P(H1)=0.02,P(H2)=0.2,P(H3)=0.4,请计算当证据E1,E2,E3存在或不存在时P(Hi|Ei)或P(Hi|﹁Ei)的值各是多少(i=1,2,3)?解:(1)当E1、E2、E3肯定存在时,根据r1、r2、r3有P(H1|E1)=(LS1×P(H1))/((LS1-1)×P(H1)+1)=(100×0.02)/((100-1)×0.02+1)=0.671P(H2|E2)=(LS2×P(H2))/((LS2-1)×P(H2)+1)=(50×0.2)/((50-1)×0.2+1)=0.9921P(H3|E3)=(LS3×P(H3))/((LS3-1)×P(H3)+1)=(5×0.4)/((5-1)×0.4+1)=0.769(2)当E1、E2、E3肯定存在时,根据r1、r2、r3有P(H1|¬E1)=(LN1×P(H1))/((LN1-1)×P(H1)+1)=(0.1×0.02)/((0.1-1)×0.02+1)=0.002P(H2|¬E2)=(LN2×P(H2))/((LN2-1)×P(H2)+1)=(0.5×0.2)/((0.5-1)×0.2+1)=0.111P(H3|¬E3)=(LN3×P(H3))/((LN3-1)×P(H3)+1)=(0.05×0.4)/((0.05-1)×0.4+1)=0.0326.13设有如下一组推理规则:r1:IFE1ANDE2THENA={a}(CF={0.9})r2:IFE2AND(E3ORE4)THENB={b1,b2}(CF={0.8,0.7})r3:IFATHENH={h1,h2,h3}(CF={0.6,0.5,0.4})r4:IFBTHENH={h1,h2,h3}(CF={0.3,0.2,0.1})且已知初始证据的确定性分别为:CER(E1)=0.6,CER(E2)=0.7,CER(E3)=0.8,CER(E4)=0.9。假设|Ω|=10,求CER(H)。解:其推理过程参考例6.9具体过程略6.15设U=V={1,2,3,4}且有如下推理规则:IFxis少THENyis多其中,“少”与“多”分别是U与V上的模糊集,设少=0.9/1+0.7/2+0.4/3多=0.3/2+0.7/3+0.9/4已知事实为xis较少“较少”的模糊集为较少=0.8/1+0.5/2+0.2/3请用模糊关系Rm求出模糊结论。解:先用模糊关系Rm求出规则IFxis少THENyis多所包含的模糊关系RmRm(1,1)=(0.9∧0)∨(1-0.9)=0.1Rm(1,2)=(0.9∧0.3)∨(1-0.9)=0.3Rm(1,3)=(0.9∧0.7)∨(1-0.9)=0.7Rm(1,4)=(0.9∧0.9)∨(1-0.9)=0.7Rm(2,1)=(0.7∧0)∨(1-0.7)=0.3Rm(2,2)=(0.7∧0.3)∨(1-0.7)=0.3Rm(2,3)=(0.7∧0.7)∨(1-0.7)=0.7Rm(2,4)=(0.7∧0.9)∨(1-0.7)=0.7Rm(3,1)=(0.4∧0)∨(1-0.4)=0.6Rm(3,2)=(0.4∧0.3)∨(1-0.4)=0.6Rm(3,3)=(0.4∧0.7)∨(1-0.4)=0.6Rm(3,4)=(0.4∧0.9)∨(1-0.4)=0.6Rm(4,1)=(0∧0)∨(1-0)=1Rm(4,2)=(0∧0.3)∨(1-0)=1Rm(4,3)=(0∧0.7)∨(1-0)=1Rm(3,4)=(0∧0.9)∨(1-0)=1即:0.10.30.70.90.30.30.70.70.60.60.60.61111mR因此有'0.10.30.70.90.30.30.70.70.8,0.5,0.2,00.60.60.60.611110.3,0.3.0.7,0.8Y即,模糊结论为Y’={0.3,0.3,0.7,0.8}6.16设U=V=W={1,2,3,4}且设有如下规则:r1:IFxisFTHENyisGr2:IFyisGTHENzisHr3:IFxisFTHENzisH其中,F、G、H的模糊集分别为:F=1/1+0.8/2+0.5/3+0.4/4G=0.1/2+0.2/3+0.4/4H=0.2/2+0.5/3+0.8/4请分别对各种模糊关系验证满足模糊三段论的情况。解:本题的解题思路是:由模糊集F和G求出r1所表示的模糊关系R1m,R1c,R1g再由模糊集G和H求出r2所表示的模糊关系R2m,R2c,R2g再由模糊集F和H求出r3所表示的模糊关系R3m,R3c,R3g然后再将R1m,R1c,R1g分别与R2m,R2c,R2g合成得R12m,R12c,R12g最后将R12m,R12c,R12g分别与R3m,R3c,R3g比较
本文标题:不确定性推理部分参考答案
链接地址:https://www.777doc.com/doc-1497224 .html