SWAP wet experiment
- case base of observations about 100 lawns - select a subset of those cases - find the cases with wet grass - find the cases with a specific cause (rain, sprinkler, ..) and wet grass - check the possibility of a specific cause (rain, sprinkler, ..) given wet grass - see and run http://eulersharp.sourceforge.net/2007/07test/swet_test ### swetD.n3 :obs001 :ascribed :Cloudy, :NonSprinkler, :Rain, :WetGrass. :obs002 :ascribed :NonCloudy, :Sprinkler, :NonRain, :WetGrass. :obs003 :ascribed :Cloudy, :NonSprinkler, :Rain, :WetGrass. :obs004 :ascribed :NonCloudy, :Sprinkler, :Rain, :WetGrass. :obs005 :ascribed :Cloudy, :NonSprinkler, :Rain, :WetGrass. :obs006 :ascribed :Cloudy, :NonSprinkler, :Rain, :WetGrass. :obs007 :ascribed :Cloudy, :NonSprinkler, :NonRain, :NonWetGrass. :obs008 :ascribed :NonCloudy, :NonSprinkler, :NonRain, :NonWetGrass. :obs009 :ascribed :NonCloudy, :NonSprinkler, :Rain, :WetGrass. :obs010 :ascribed :NonCloudy, :NonSprinkler, :Rain, :NonWetGrass. ### swetA.n3 [] e:answer {:obs :like :obs001}. [] e:answer {:obs :like :obs002}. [] e:answer {:obs :like :obs003}. [] e:answer {:obs :like :obs004}. [] e:answer {:obs :like :obs005}. ### swetQ01.n3 @forAll :OBS. { ?S e:answer {:obs :like :OBS}. :OBS :ascribed :WetGrass. } => { ?S e:answer {:OBS :ascribed :WetGrass}. }. ### swetA01.n3 _:e1 e:answer {:obs001 :ascribed :WetGrass}. _:e2 e:answer {:obs002 :ascribed :WetGrass}. _:e3 e:answer {:obs003 :ascribed :WetGrass}. _:e4 e:answer {:obs004 :ascribed :WetGrass}. _:e5 e:answer {:obs005 :ascribed :WetGrass}. _:e6 e:answer {:obs006 :ascribed :WetGrass}. ### swetQ21.n3 @forAll :OBS. { ?S e:answer {:obs :like :OBS}. :OBS :ascribed :Sprinkler, :WetGrass. } => { ?S e:answer {:OBS :ascribed :Sprinkler, :WetGrass}. }. ### swetA21.n3 _:e2 e:answer {:obs002 :ascribed :Sprinkler. :obs002 :ascribed :WetGrass}. _:e4 e:answer {:obs004 :ascribed :Sprinkler. :obs004 :ascribed :WetGrass}. _:e12 e:answer {:obs012 :ascribed :Sprinkler. :obs012 :ascribed :WetGrass}. _:e14 e:answer {:obs014 :ascribed :Sprinkler. :obs014 :ascribed :WetGrass}. ### swetQ.n3 { <swetA21.n3> log:semantics ?A. ?A math:memberCount ?D. <swetA01.n3> log:semantics ?E. ?E math:memberCount ?H. (?D ?H) math:quotient ?I. } => { {{:obs :ascribed :Sprinkler} :given {:obs :ascribed :WetGrass}} e:possibility ?I. }. ### swet_result.n3 {{:obs :ascribed :Sprinkler} :given {:obs :ascribed :WetGrass}} e:possibility 0.5679012345679012 .