【发布时间】:2017-10-03 15:18:56
【问题描述】:
我正在 Mac 和 Linux 上使用 秒差距、直径和温度单位做关于未知区域行星问题的家庭作业或学校作业/作业演示。我将 FuzzyVariable 应用于行星名称和单位。
我添加了(import nrc.fuzzy.*)。
;Distância do Coruscant
(defglobal ?*gVarDistanciaDeCoruscant* = (new nrc.fuzzy.FuzzyVariable "distanciaDeCoruscant" 0.0 30000.0 "parsecs"))
;Temperatura dos Planetas
(defglobal ?*gVarTemperatura* = (new nrc.fuzzy.FuzzyVariable "temperatura" 0 8000 "K"))
;Planetas Vizinhos
(defglobal ?*gVarPlanetasVizinhos* = (new nrc.fuzzy.FuzzyVariable "distanciaPlanetasVizinhos" 0.0 400000.0 "d"))
;Raio em termos de unidades coruscantenses
(defglobal ?*gVarTamanho* = (new nrc.fuzzy.FuzzyVariable "tamanho" 0 500 "EU"))
;Quando o planeta foi descoberto
(defglobal ?*gVarDescobertaTempo* = (new nrc.fuzzy.FuzzyVariable "descoberta" 50000BBY 400ABY))
(call nrc.fuzzy.FuzzyValue setMatchThreshold 0.1)
还有终端,Jess 给出了错误:
Jess reported an error in routine new
while executing (new nrc.fuzzy.FuzzyVariable "distanciaDeCoruscant" 0.0 30000.0 "parsec")
while executing definition for defglobal ?*gVarDistanciaDeCoruscant*
while executing (batch "/Users/UNISAL/Documents/AI/StarWars.clp").
Message: Class nrc.fuzzy.FuzzyVariable not found.
Program text: ( defglobal ?*gVarDistanciaDeCoruscant* = ( new nrc.fuzzy.FuzzyVariable "distanciaDeCoruscant" 0.0 30000.0 "parsec" ) ) at line 26 in file /Users/UNISAL/Documents/AI/StarWars.clp.
Nested exception is:
nrc.fuzzy.FuzzyVariable
我认为 Mac 和 Linux 没有 Jess 的这个包。是否可以添加兼容 Mac 和 Linux 的遗漏包?
我需要将我的作业/作业演示文稿提交给我的老师,以获得好成绩。
您可以查看整个文档:https://gist.github.com/gusbemacbe/8ad836256edcfb5edbffe206cad6c9e8
【问题讨论】:
-
很可能 CLASSPATH 未设置为包含
nrc.fuzzy.FuzzyVariable。