Question: c++ please dont give me any answer from chegg , not simillar please i want only the answer to copy it , thx Relation Properties



Relation Properties Recall from class that a relation between finite sets can be represented using a zero-one matrix. The matrix of a relation on a set is a square matrix. Write C++ functions that take as an input a square zero-one matrix and determine if the matrix represents a relation that is reflexive, symmetric and antisymetric. Test your functions in a program. Given is the partial code for the program. The main function is complete. You need to provide the code for the 3 functions isReflexive(), isSymmetric, and isAntiSymmetric(). Make sure you return the correct boolean value. Provide comments describing your code. How to submit When you are done with the C++ program copy and paste the code into a Word document (Or any text editor). Save the file as LastName.FirstName.HW4.docx Post it on Blackboard See sample output below: return the correct boolean value. Provide comments describing your code. How to submit When you are done with the Ct+ program copy and paste the code into a Word document (Or any text editor). Save the file as LastName.FirstName.HW4.docx Post it on Blackboard See sample output below: The given matrix is: ref lexive not symmetric not ant isymmetric \#include using namespace std; bool is Reflexive (int a [] [4]); bool isSymmetric (int a[] [4]); bool isAntiSymmetric (int a[][4]); cout "The given matrix is: " endl; if (isReflexive(myArray)) cout "reflexive" endl; else cout "not reflexive" endl; if (isSymmetric(myArray)) cout "symmetric" endl; else cout "not symmetric" endl; if (isAntiSymmetric(myArray)) cout "antisymmetric" endl; else cout "not antisymmetric" endl
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
