Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

🔍Haskell Binary Relation: Streamlined analysis of relations on sets - Empty, Universal, Reflexive, Symmetric, Antisymmetric, Transitive, Equivalence. Recreate Reflexive, Symmetric, Transitive Closures. Simplify relation analysis in Haskell for enhanced productivity. 🚀

License

Notifications You must be signed in to change notification settings

Meet-forever/Haskell_Binary_Relation

Open more actions menu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Haskell Binary Relation

Project idea and instruction taken from: PLC-Project2

"If there are two sets, and we want to check if there is any connection between the two, we use relations." -- Meet Patel

Available Relations

- Empty
- Universal
- Reflexive
- Symmetric
- Antisymmetric
- Transitive
- Equivalence 
"The closure of a subset is the result of a closure operator applied to the subset. The closure of a subset under some operations is the smallest subset that is closed under these operations. It is often called the span (for example linear span) or the generated set." -- Wikipedia

Available Closures

- Reflexive Closure
- Symmetric Closure
- Transitive Closure

Sample Run:

*Main> r1 = add (1,2) (add (2,3) (add (3,4) emptyBinaryRelation)) 
*Main> r2 = add (1,2) (add (3, 4) (add (2,3) emptyBinaryRelation))
*Main> reflexive r1
False
*Main> symmetric r2
False
*Main> r2' = symmetricClosure r2
*Main> symmetric r2'
True
*Main> toString r2'
"[(1,2),(2,1),(2,3),(3,2),(3,4),(4,3)]"

About

🔍Haskell Binary Relation: Streamlined analysis of relations on sets - Empty, Universal, Reflexive, Symmetric, Antisymmetric, Transitive, Equivalence. Recreate Reflexive, Symmetric, Transitive Closures. Simplify relation analysis in Haskell for enhanced productivity. 🚀

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published
Morty Proxy This is a proxified and sanitized view of the page, visit original site.