|
|
|
C++ sets class v. 1.0 |
| Release date: |
01/15/2001 |
| Author: |
Stephen Schmitt |
| License: |
Freeware Price: $0.00 US |
| Expiration: |
none |
| Operating System: |
Windows 95 |
| Requirements: |
C/C++ compiler |
| Download size: |
14 kilobytes Install support: No Install Support |
| Web site: |
|
|
Download C++ sets class |
|
|
|
|
Rate this application
|
Report broken links
|
| Description: The sets class can be used to perform set operations in your programs. It represents set elements as bits in a private array of unsigned long integers. The array size is a defined constant which can be changed to suit your application.
The sets class supports the following set operations by means of C++ operator overloading:
union
The union of two sets A, B is the set of all elements which belong to either A or B. In the sets class, the symbol + is the binary union operator:
A + B = {x: x is in A -or- x is in B }
intersection
The intersection of two sets A, B is the set of all elements which belong to both A and B. The symbol * is the binary intersection operator:
A * B = {x: x is in A -and- x is in B }
example
Let A = {1, 2, 3, 4} and B = {3, 4, 5, 6}. Then
A + B = {1, 2, 3, 4, 5, 6}
A * B = {3, 4}
complement
In set theory, sets are subsets of a fixed universal set U. In the sets class, U is the set of elements numbered from 1 to MAX_WORDS * WORD_SIZE. In the class declaration file below, the following definitions are made:
#define MAX_WORDS 2
#define WORD_SIZE ( 8 * sizeof( unsigned long ) )
These parameters make the range of U, 1 to 64 in sets. To increase or decrease the size of U, change the defined value of MAX_WORDS.
The complement of set A is the set of elements belonging to U but not belonging to A. The symbol ~ is the unary complement operator:
~A = {x: x is in U, x is not in A }
example
Let A = {1, 2, 3, 4} and B = {3, 4, 5, 6}. Then
~A = {5, 6, 7, . . .}
~B = {1, 2, 7, 8, 9, . . .}
difference
The difference of two sets A, B is the set of all elements which belong to A less those in B. The symbol - is the binary difference operator:
A - B = {x: x is in A, x is not in B}
example
Let A = {1, 2, 3, 4} and B = {3, 4, 5, 6}. Then
A - B = {1, 2}
It can be shown that A - B = A * ~B.
symmetric difference
The symmetric difference of two sets A, B is the set of all elements which belong to A or to B, but not both. |
|
|
|
Ratings:
|
There are no ratings yet.
Rate this listing yourself.
|
| Reviews: |
There are 0 reviews of this title by members and visitors.
Review this listing yourself.
|
|
Be the first! You can rate this application with just a few clicks.
Or you can rate it and add comments to make a review.
|
| Author's other listings: |
Almanac 1.0 Numerical Plotter 1.0 Simulated Annealing Demonstration 1.0 Spreadsheet Calculator (SCalc) for UNIX 1.0 T Interpreter 1.1 TimeWarp 3.0 TimeWarp for DOS 1.1 Xref a utility program 1.0 Zeno Interpreter 1.2
|
| |
|
Please report any broken link in this listing.
|
Featured Shareware Downloads
How To Use Your Mind v. 1.0 An excellent manual for use by students and teachersOS: Windows 95,98,ME,NT3,NT4,2k,XP $19.95 — try it free
|
Rapid E-Learning Suite Deluxe v. 5.0.0 Rapid E-Learning Suite-Create multimedia content with quizzes,screencast,videosOS: Windows 2k,XP,2k3,Vista $399.95 — try it free
|
PG Online Training Solution v. JULE-2008 Easy to use and customizable etraining solution. Free Support. Hosting. Updates.OS: Windows 2k,XP,2k3,Vista, Unix,Linux $249.00 — try it free
|
Keyboard Music v. 2.4 You and your kids can use computer keyboard to play musical instruments.OS: Windows 98,ME,NT3,NT4,2k,XP $15.00 — try it free
|
PC OMR v. 8.0 An intelligent test tool to collect data on paper forms for tests and surveys.OS: Windows 95,98,ME,NT3,NT4,2k,XP,2k3,Vista $499.00 — try it free
|
PL Table v. 4.30 Rich data set, graphing Periodic Table and powerful chemical reaction balancerOS: Windows 98,ME,NT4,2k,XP,2k3,Vista $39.95 — try it free
|
World Geography Tutor v. 1.2.4 Become 'worldly-wise' - master world geography with this learning and quiz tool.OS: Windows 95,98,ME,NT4,2k,XP $15.00 — try it free
|
ProLingo English to Spanish Dictionary v. 1.2.15 ProLingo English to Spanish talking dictionary for Windows OSOS: Windows ME,NT4,2k,XP,2k3,Vista $19.95 — try it free
|
Arabic School Software v. 1.0 Learn Arabic Fast and easy - Interactive Multimedia Teacher of ArabicOS: Windows 98,ME,NT3,NT4,2k,XP $39.95 — try it free
|
CheapestSoft KidsTime v. 1.4 KidsTime help parents control the time their kids spend playing computer games.OS: Windows NT3,NT4,2k,XP,2k3,Vista $19.99 — try it free
|
(ID: 6664-34689)
|
Sponsors
|