Closed YeabsiraNigusse closed 1 week ago
@samwondim , Yab claims that this function can be beneficial for you, can you take a look?
@samwondim , Yab claims that this function can be beneficial for you, can you take a look?
@Yagth @samwondim refer the RTE pseudocode for detail look. the two transformation do the same thing except their parameter.
@Yagth i have finalized the function and added it as a utility function. you can check it out.
@YeabsiraNigusse, so does the issue #143 still persists or it no longer needs to be addressed?
@YeabsiraNigusse, so does the issue #143 still persists or it no longer needs to be addressed?
Yeah, I think we no longer need the issue since the transformation is now represented by a general helper function. For the getDominant
function case, we could take another approach, such as updating the dominant set each time the expression changes, rather than recalculating it every time. This is more computationally efficient. However, if we can't do this due to the complexity of the function (RTE), we might need to reconsider it. We discussed this approach in the last meeting, so for now, we can consider the issue resolved.
Description
I have added a function called setDifference and test functions for it. it is used for making a subtract redundant constraint transformation over a given expression. This function assumes it receives a set1 and the set2 expression as parameters. It then removes redundant elements from set1 expression that already exist in the set2. This function also can be used for lCCSUBTRACT transformation with command set and current expression given as a parameter. The function uses isMember from general helpers functions.
Motivation and Context
It is one of the main transformations applied to an expression, and it solves the problem of subtracting redundant constraints from the expression.
It does not fix any existing issues but creates this new issue.
How Has This Been Tested?
i have added functions inside
general-helper-function-test file
. the file contain a unit test with different test cases and checks the function output withassertEqual
built-in metta function.No Environment needed. running the the test file would be enough.
Types of changes
Checklist: