∀x∀y (x=y iff ∀z , (z∈x iff z∈y )): Axiom of Extensionality in set theory #55
Unanswered
TaviTruman
asked this question in
Q&A
Replies: 2 comments
-
|
Okay, I am now working to implement the concrete implementation, and have made the following changes: |
Beta Was this translation helpful? Give feedback.
0 replies
-
|
Okay - I want to explore the logic set design and implementation of Logic Programming in Guan. This is not 100% working code but we are getting closer.
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I am staring to get a handle in using Guan but would like to run this by the community first. To test my understanding the foundations of Guan I thought I'd implement the "Axiom of Extensionality."
Here's me thinking out loud:
This first-order logic formula states that for every pair of sets x and y, x is equal to y if and only if for every element z, z is an element of x if and only if z is an element of y.
In other words, this formula asserts that two sets are equal if they have exactly the same elements. This is known as the Axiom of Extensionality in set theory, which is one of the fundamental principles of set theory. The symbols used are ∀ (for all), iff (if and only if), and ∈ (is an element of).
To express the Axiom of Extensionality in Guan, you'll need to define predicates to represent set membership (element of) and set equality. Here's an example of how you might implement the Axiom of Extensionality in Guan:
In this implementation, setEquality represents the equality of sets X and Y, and elementOf represents the membership of an element Z in a set X or Y. The forall keyword represents "for all," and the implies keyword represents "implies."
Please note that this is a high-level representation of how you might implement the Axiom of Extensionality in Guan. I know I need need to provide the specific implementation details for the ElementOfPredicateType and SetEqualityPredicateType classes, as well as register the predicates and rule in your Guan system.
Guam Implementation: (NOTE: this is NOT working code; not yet!)
I'll create a custom predicate for set membership (ElementOf) and set equality (SetEquality), then write a rule in Guan to represent the Axiom of Extensionality. Note that this example assumes you have already set up a Guan project and have knowledge of how to define custom predicates.
Add this rule to Guan system as a string in your C# code:
Prototype Implementation: (NOT Ready for Use)
Beta Was this translation helpful? Give feedback.
All reactions