home Forums # Technical Support System.Runtime.InteropServices.SEHException

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #1760
    Unknown
    Member

    Hi Juan,

    I wrote my fuzzylite code using visual c++ . I defined five inputs one output. I’m getting the above error at runtime. Error fired when rules are added. My rules are as shown below. The error fires once it start it to addRule. Can you please help me to solve this.

    Iroshani.

    RuleBlock* ruleblock = new RuleBlock;
    ruleblock->setEnabled(true);
    ruleblock->setName(“”);
    ruleblock->setConjunction(fl::null);
    ruleblock->setDisjunction(fl::null);
    ruleblock->setActivation(fl::null);

    ruleblock->addRule(fl::Rule::parse(“if IrrMin is HIGH AND IrrMax is HIGH and IrrMean is HIGH and IrrStd is LOW and IrrGradient is MEDIUM then FutureIrr is HIGH”, engine));
    ruleblock->addRule(fl::Rule::parse(“if IrrMin is MEDIUM and IrrMax is HIGH and IrrMean is HIGH and IrrStd is LOW and IrrGradient is MEDIUM then FutureIrr is HIGH”, engine));
    ruleblock->addRule(fl::Rule::parse(“if IrrMin is MEDIUM and IrrMax is HIGH and IrrMean is MEDIUM and IrrStd is LOW and IrrGradient is MEDIUM then FutureIrr is HIGH”, engine));
    ruleblock->addRule(fl::Rule::parse(“if IrrMin is MEDIUM and IrrMax is HIGH and IrrMean is MEDIUM and IrrStd is MEDIUM and IrrGradient is HIGH then FutureIrr is HIGH”, engine));
    ruleblock->addRule(fl::Rule::parse(“if IrrMin is MEDIUM and IrrMax is HIGH and IrrMean is MEDIUM and IrrStd is LOW and IrrGradient is HIGH then FutureIrr is HIGH”, engine));
    ruleblock->addRule(fl::Rule::parse(“if IrrMin is MEDIUM and IrrMax is HIGH and IrrMean is HIGH and IrrStd is LOW and IrrGradient is HIGH then FutureIrr is HIGH”, engine));
    ruleblock->addRule(fl::Rule::parse(“if IrrMin is MEDIUM and IrrMax is HIGH and IrrMean is MEDIUM and IrrStd is MEDIUM and IrrGradient is MEDIUM then FutureIrr is HIGH”, engine));
    ruleblock->addRule(fl::Rule::parse(“if IrrMin is MEDIUM and IrrMax is HIGH and IrrMean is HIGH and IrrStd is MEDIUM and IrrGradient is HIGH then FutureIrr is HIGH”, engine));
    ruleblock->addRule(fl::Rule::parse(“if IrrMin is MEDIUM and IrrMax is HIGH and IrrMean is HIGH and IrrStd is MEDIUM and IrrGradient is MEDIUM then FutureIrr is HIGH”, engine));

    #1762

    Hi,

    you should use QtFuzzyLite to design your controller.

    The error you have is that you need to select a Conjunction operator because the propositions in your rules are linked with “and”. If you had rules with “or”, you would also need a Disjunction operator. Please, use QtFuzzyLite to solve these issues.

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.