Автор работы: Пользователь скрыл имя, 17 Октября 2011 в 00:12, курсовая работа
Система является интеллектуальной, если она обладает знаниями и умеет использовать их для достижения сформулированной цели. Знания – это то, без чего нет интеллектуальной системы. Экспертные системы (в дальнейшем ЭС) явились первыми действительно интеллектуальными системами и, в конечном счете, интеллектуальность определила их коммерческий успех.
Введение 3
Архитектура экспертной системы 7
Классификация экспертных систем 10
Классификация моделей представления знаний 13
Тема курсового проекта 15
Блок-схема программы 16
Код программы 18
Использованная литература 27
(assert (otvet-72))
else
(assert (otvet-46)))
)
(defrule vopros-23""
(vopros-23)
(not (repair ?))
=>
(if(answerquest "Kaktus pokrit bolshimi koluchkami i u nego mnogo reber? (yes/no) ")
then
(assert (otvet-32))
else
(assert (otvet-28)))
)
(defrule vopros-24""
(vopros-24)
(not (repair ?))
=>
(bind ?response
(voprosi "Kakogo cveta rastenie? (green/broun)" green broun))
(if (eq ?response green)
then
(assert (otvet-53)))
(if (eq ?response broun)
then
(assert (otvet-54)))
)
(defrule vopros-5""
(vopros-5)
(not (repair ?))
=>
(bind ?response
(voprosi "Segmenti y kaktusa sharovidnie s koluchkami ili ploskie s voloskami? (shar/ploski)" shar ploski))
(if (eq ?response shar)
then
(assert (otvet-5)))
(if (eq ?response ploski)
then
(assert (otvet-73)))
)
(defrule vopros-6""
(vopros-6)
(not (repair ?))
=>
(if(answerquest "Pobegi celnie, ne razdelenie na segmenti (vetvlenie v osnovanii)? (yes/no) ")
then
(assert (vopros-75))
else
(assert (vopros-6-1)))
)
(defrule vopros-6-1""
(vopros-6-1)
(not (repair ?))
=>
(if(answerquest "Pobegi sostoiat iz pohojih segmentov (vetvlenie iz koncov pobegov)? (yes/no) ")
then
(assert (vopros-76))
else
(assert (otvet-81)))
)
(defrule vopros-76""
(vopros-76)
(not (repair ?))
=>
(bind ?response
(voprosi "Vetvi napravleni vverh ili vniz? (vverh/vniz) "
vverh vniz))
(if (eq ?response vverh)
then
(assert (otvet-78)))
(if (eq ?response vniz)
then
(assert (otvet-79)))
)
(defrule vopros-75""
(vopros-75)
(not (repair ?))
=>
(bind ?response
(voprosi "Vetvi tonkie ili tolstie? (tonkie/tolstie) " tonkie
tolstie))
(if (eq ?response tonkie)
then
(assert (otvet-77-1)))
(if (eq ?response tolstie)
then
(assert (otvet-77-2)))
)
(defrule vopros-7""
(vopros-7)
(not (repair ?))
=>
(if(answerquest "Na kaktuse zametni vertikalnie rebra, na kotorih v odin riad raspolagaiutsia koluchki? (yes/no) ")
then
(assert (vopros-85))
else
(assert (vopros-7-1)))
)
(defrule vopros-7-1""
(vopros-7-1)
(not (repair ?))
=>
(if(answerquest "Kaktus pokrit spiralnimi bygorkami? (yes/no) ")
then
(assert (vopros-86))
else
(assert (otvet-87)))
)
(defrule vopros-85""
(vopros-85)
(not (repair ?))
=>
(if(answerquest "Rebra visokie?(Vishe 5mm?) (yes/no) ")
then
(assert (otvet-88))
else
(assert (otvet-89)))
)
(defrule vopros-86""
(vopros-86)
(not (repair ?))
=>
(if(answerquest "Est li v pazuhah bugorkov kakie libo obrazovania i butoni poiavlaiutsa iz vershini? (yes/no) ")
then
(assert (otvet-90))
else
(assert (otvet-91)))
)
(defrule answer1""
(otvet-12)
=>
(assert (repair "Cereus peruvianus - golubovataia okraska steblia virajena slabo, koluchki korichnevie."))
)
(defrule answer2""
(otvet-11)
=>
(assert (repair "Opuncia vestita - stebel gusto pokrit dlinnimi belimi voloskami."))
)
(defrule answer3""
(otvet-72)
=>
(assert (repair "Frailea katafrakta - stebel nebolshoi, sharovidnii, bugorki pochti ploskie, koluchki zolotistie, kroshechnie, prijati k steblu."))
)
(defrule answer4""
(otvet-46)
=>
(assert (repair "Ehinopsis obrepanda - stebel plosko-sharovidnii, krupnii. Cvetki krupnie s dlinnoi trubkoi, belie ili rozovie."))
)
(defrule answer5""
(otvet-32)
=>
(assert (repair "Ferokaktus latispinus - stebel plosko-sharovidnii, reber okolo 20, centralnie koluchki osobenno ploskie - neskolko milimetrov shirinoi - krasnie ili jeltie."))
)
(defrule answer6""
(otvet-28)
=>
(assert (repair "Astrofitum miriostigma - Koluchek net. Belie hlopia. Reber obichno 5."))
)
(defrule answer7""
(otvet-53)
=>
(assert (repair "Kopiapoa hipogea - bugorki ploskie s beloopushennimi areolami i s 1-6 ochen korotkimi bistro opadaushimi temnimi koluchkami."))
)
(defrule answer8""
(otvet-54)
=>
(assert (repair "Gimnokalicium saglionis - krupnoe rastenie, v komnatnih ysloviah do 20cm diametrom.Bugorki krupnie. Koluchki dlinnie dugovidno izognutie, cobrani v rozetki po 8-10 shtuk, dostigaiut 4cm."))
)
(defrule answer9""
(otvet-5)
=>
(assert (repair "Tefrokaktus artikuliatus - segmenti sharovidnie, koluchki dlinnie, ploskie, belovatie, bumagovidnie."))
)
(defrule answer10""
(otvet-73)
=>
(assert (repair "Opuncia leukotriha - segmenti udlinennie s belimi volosovidnimi koluchkami."))
)
(defrule answer11""
(otvet-81)
=>
(assert (repair "Opuncia tuna - segmenti cherveobraznie, vetvei ochen mnogo, kust ochen gustoi: monstroznaia forma."))
)
(defrule answer12""
(otvet-78)
=>
(assert (repair "Gatiora salikorniodes - Koluchek prakticheski net. Segmenti - tonkie cilindricheskie vetki dlinoi 2-4cm i diametrom 2-4mm. Vetvlenie is koncov segmentov. Cvetki mnogochislenie, oranjevie."))
)
(defrule answer13""
(otvet-79)
=>
(assert (repair "Shlumbergera buklei (dekabrist) - Segmenti svetlo-zelenie. Cvetki malinovo-rozovie, radialnosimetrichnie."))
)
(defrule answer14""
(otvet-77-1)
=>
(assert (repair "Aporokaktus flagelliformis - Vetvi dlinnie i tonkie, ne bolee 1cm v diametre, svisaiushie. Na nih 8-10 clabovirajennih reber s gustimi koluchkami."))
)
(defrule answer15""
(otvet-77-2)
=>
(assert (repair "Bolivicerius samaipatanus - Vetvi dlinnie, moshnie (3-6cm diametr). Reber 14-16. Koluchki korichnevatie, do 3cm dlinoi."))
)
(defrule answer16""
(otvet-87)
=>
(assert (repair "Lobivia hertrihiana- koluchki ne bolee 2cm dlinoi, jeltovatie, slegka izognutie. Reber 11. Cvetki iarko-krasnie."))
)
(defrule answer17""
(otvet-88)
=>
(assert (repair "Ehinocereus triglohidiatus - reber obichno 7. Koluchek menshe 10, dlinoi 2-7cm, tverdie, izognutie. Vse stebli v gruppe primerno odinakovie."))
)
(defrule answer18""
(otvet-89)
=>
(assert (repair "Hamecerius - stebli miagkie, svetlo-zelenie, tonkie(2cm v diametre). Reber 6-9. Koluchki melkie, shetinkovidnie, belie."))
)
(defrule answer19""
(otvet-90)
=>
(assert (repair "Rebucia albiflora - koluchki ochen tonkie, belie, volosovidnie. Stebli krohotnie (okolo 1cm), miagkie. Cvetki nebolshie, belo-rozovie."))
)
(defrule answer20""
(otvet-91)
=>
(assert (repair "Mammillaria elongata - Kust krupnii, bolee 10cm diametrom i visotoi. Koluchki radialnie, jeltie."))
)
(defrule tema ""
(declare (salience 10))
=>
(printout t crlf crlf)
(printout t "Vibor kaktusa v magazine")
(printout t crlf crlf))
(defrule print-repair ""
(declare (salience 10))
(repair ?item)
=>
(printout t crlf crlf)
(printout t "Vash vibor:")
(printout t crlf crlf)
(format t " %s%n%n%n"
?item))
Информация о работе Экспертная система распознавания кактусов