namespace default=http://www.wsmo.org/2004/d3/d3.2/v0.1/20040524/resources/dt.flr# dc=http://purl.org/dc/elements/1.1 wsml=http://www.wsmo.org/2004/d16/d16.1/v0.2/20040418/ ontology http://www.wsmo.org/2004/d3/d3.2/v0.1/20040524/resources/dt.flr non-functional-properties dc:title "Date and Time Ontology" dc:creator "DERI International" dc:subject "Date, Time, Date and Time Algebra" dc:description "generic representation and alegbra for date and time" dc:publisher "DERI International" dc:contributor "Holger Lausen, Axel Polleres, Ruben Lara" dc:date "20040524" dc:type "domain ontology" dc:format "text" dc:source http://www.wsmo.org/2004/d3/d3.2/v0.1/20040524/resources/dt.flr dc:language "English" dc:relation http://www.isi.edu/~pan/damltime/time-entry.owl, http://daml.umbc.edu/ontologies/cobra/0.4/calendarclock, http://www.w3.org/TR/xmlschema-2/ dc:coverage "general" dc:rights http://www.deri.org/privacy.html dc:version "1.15" comment: conceptDefinitions concept instant non-functional-properties dc:description "An instant represents a particular point in time" concept interval non-functional-properties dc:description "An interval represents a duration between 2 points in time" start oftype instant end oftype instant concept date non-functional-properties dc:description "class date and its representation according to the Gregorian calendar" subconceptOf instant dayOfMonth oftype dayOfMonth monthOfYear oftype monthOfYear year oftype year concept dayOfMonth non-functional-properties dc:description "day of a month is represented by an integer" subconceptOf integer concept year non-functional-properties dc:description "year is represented by an integer" subconceptOf integer concept monthOfYear non-functional-properties dc:description "monthOfYear is represented by an integer and has additional properties" subconceptOf integer name oftype string daysAfterBeginOfYear oftype integer concept time hourOfDay oftype hourOfDay minuteOfHour oftype minuteOfHour secondOfMinute oftype secondOfMinute concept secondOfMinute non-functional-properties dc:description "a secondOfMinute is represented by an integer" subconceptOf integer concept minuteOfHour non-functional-properties dc:description "a minuteOfHour is represented by an integer" subconceptOf integer concept hourOfDay non-functional-properties dc:description "a hourOfDay is represented by an integer" subconceptOf integer concept dateAndTime non-functional-properties dc:description "class date and time and representing together a specific point of time (instant)" subconceptOf instant date oftype date time oftype time comment: axiom-defintions axiom validMonthOfYear non-functional-properties dc:description "integrity constraint for valid monthOfYear:" logical-expression "forall (X) X memberOf monthOfYear and not (X < 0 or X > 12)." axiom validDayOfMonth non-functional-properties dc:description "integrity constraint for valid dayOfMonths:" logical-expression "forall(X) X memberOf dayOfMonth and not (X < 0 or X > 31)." axiom validDate non-functional-properties dc:description "Integrity Constraints for date" logical-expression "forall(X) X memberOf date and not (invalid(X.dayOfMonth) or invlaid(X.monthOfYear) or invalid(X.year))." axiom validHourOfDay non-functional-properties dc:description "integrity constraint for valid time:" logical-expression "forall(X) X memberOf time and not (invalid(X.hourOfDay) or invalid(X.minuteOfHour) or invalid(X.secondOfMinute))." axiom validSecondOfMinute non-functional-properties dc:description "integrity constraint for valid secondOfMinute:" logical-expression "forall(X) X memberOf secondOfMinute and not (X < 0 or X > 59)." axiom validMinuteOfHour non-functional-properties dc:description "integrity constraint for valid minuteOfHour:" logical-expression "forall(X) X memberOf minuteOfHour and not (X < 0 or X > 59)." axiom validHourOfDay non-functional-properties dc:description "integrity constraint for valid hourOfDay:" logical-expression "forall(X) X memberOf hourOfDay and not (X < 0 or X > 23)." axiom validDateAndTime non-functional-properties dc:description "integrity constraint for valid dateAndTimes:" logical-expression "forall(X) X memberOf dateAndTime and not (invalid(X.date) or invalid(X.time))." axiom equalityDate non-functional-properties dc:description "computes equality of a date" logical-expression "equal(X, Y) <- Y memberOf date and X memberOf date and X.dayOfMonth = Y.dayOfMonth and X.monthOfYear = Y.monthOfYear and X.year = Y.year." axiom beforeDate non-functional-properties dc:description "computes if a given date X is before another date Y" logical-expression "before(X, Y) <- Y memberOf date and X memberOf date and ((X.dayOfMonth = Y.dayOfMonth and X.monthOfYear = Y.monthOfYear and X.year = Y.year) or (X.monthOfYear < Y.monthOfYear and X.year = Y.year) or (X.year < Y.year))." axiom afterDate non-functional-properties dc:description "computes if a given date X is after another date Y" logical-expression "after(X, Y) <- Y memberOf date and X memberOf date and ((X.dayOfMonth > Y.dayOfMonth and X.monthOfYear = Y.monthOfYear and X.year = Y.year) or (X.monthOfYear > Y.monthOfYear and X.year = Y.year) or (X.year > Y.year))." axiom daysAfterChrist non-functional-properties dc:description "a simplified helper predicatge for calculating the differences between dates" logical-expression "daysAfterChrist(D, X) <- D memberOf date and Z is D.monthOfYear and X is (D.dayOfMonth + Z.daysAfterBeginOfYear + (D.year*365))." axiom daysBetweenDates non-functional-properties dc:description "the difference in days between 2 dates" logical-expression "daysBetween(D1, D2, X) <- D1 memberOf date and D2 memberOf date and daysAfterChrist(D1, DAC_D1) and daysAfterChrist(D2, DAC_D2) and X is DAC_D1 - DAC_D2." axiom equalityTime non-functional-properties dc:description "computes if two given times are the same" logical-expression "equal(X, Y) <- X memberOf time and Y memberOf time and X.secondOfMinute = Y.secondOfMinute and X.minuteOfHour = Y.minuteOfHour and X.hourOfDay = Y.hourOfDay." axiom beforeTime non-functional-properties dc:description "computes if a given time X is before another time Y" logical-expression "before(X, Y) <- X memberOf time and Y memberOf time and ((X.secondOfMinute < Y.secondOfMinute and X.minuteOfHour = Y.minuteOfHour and X.hourOfDay = Y.hourOfDay) or (X.minuteOfHour < Y.minuteOfHour and X.hourOfDay = Y.hourOfDay) or (X.hourOfDay < Y.hourOfDay))." axiom afterTime non-functional-properties dc:description "computes if a given time X is after another time Y" logical-expression "after(X, Y) <- X memberOf time and Y memberOf time and ((X.secondOfMinute > Y.secondOfMinute and X.minuteOfhour = Y.minuteOfhour and X.hourOfDay = Y.hourOfDay) or (X.minuteOfhour > Y.minuteOfhour and X.hourOfDay = Y.hourOfDay) or (X.hourOfDay > Y.hourOfDay))." axiom secondsFromMidnight non-functional-properties dc:description "computes the amount of seconds from midnight (helper predicate for calculating difference)" logical-expression "secondsFromMidnight(T, X) <- T memberOf time and X is T.secondOfMinute + (T.minuteOfHour*60) + (T.hourOfDay*60*60)." axiom secondsBetweenTimes non-functional-properties dc:description "the difference in seconds between 2 times" logical-expression "secondsBetween(T1, T2, X) <- T1 memberOf time and T2 memberOf time and secondsFromMidnight(T1, SFM_T1) and secondsFromMidnight(T2, SFM_T2) and X is SFM_T1 - SFM_T2." axiom equalityDateAndTime non-functional-properties dc:description "computes if Date and Time are equal" logical-expression "equal(X, Y) <- X memberOf dateAndTime and Y memberOf dateAndTime and equal(X.date, Y.date) and equal(X.time, Y.time)." axiom beforeDateAndTime non-functional-properties dc:description "computes if a given date and time X is before another date and time Y" logical-expression "before(X, Y) <- X memberOf dateAndTime and Y memberOf dateAndTime and ((equal(X.date, Y.date) and before(X.time, Y.time)) or before(X.date, Y.date))." axiom afterDateAndTime non-functional-properties dc:description "computes if a given date and time X is after another date and time Y" logical-expression "after(X, Y) <- X memberOf dateAndTime and Y memberOf dateAndTime and ((equal(X.date, Y.date) and after(X.time, Y.time)) or after(X.date, Y.date))." axiom secondsBetweenDateAndTime non-functional-properties dc:description "computes the difference in seconds between two different DateAndTime" logical-expression "secondsBetween(D1, D2, X) <- D1 memberOf dateAndTime and D2 memberOf dateAndTime and daysAfterChrist(D1.date, DAC_D1) and daysAfterChrist(D2.date, DAC_D2) and secondsFromMidnight(D1.time, SFM_T1) and secondsFromMidnight(D2.time, SFM_T2) and X is SFM_T1 + DAC_D1 * 24 * 60 * 60 - (SFM_T2 + DAC_D2 * 24 * 60 * 60)." axiom daysBetweenDateAndTime non-functional-properties dc:description "the difference in (decimal) days between two different DateAndTime" logical-expression "daysBetween(D1, D2, X) <- D1 memberOf dateAndTime and D2 memberOf dateAndTime and secondsBetween(D1, D2, Z) and X is Z/60/60/24." axiom intervalContainment non-functional-properties dc:description "computes if a interval X contains a second interval Y" logical-expression "contains(X, Y) <- X memberOf interval and Y memberOf interval and (before(X.start, Y.start) or equal(X.start, Y.start)) and (after(X.end, Y.end) or equal(X.end, Y.end))." axiom instantContainment non-functional-properties dc:description "computes if a interval X contains a instant Y" logical-expression "contains(X, Y) <- X memberOf interval and Y memberOf instant and (before(X.start, Y) or equal(X.start, Y)) and (after(X.end, Y) or equal(X.end, Y))." comment: instance-definitions comment: concrete month are defined as instances will be changed to axioms (3 valued predicates)! instance 1 memberOf monthOfYear daysAfterBeginOfYear hasValue 31 name hasValue "January" instance 2 memberOf monthOfYear daysAfterBeginOfYear hasValue 59 name hasValue "February" instance 3 memberOf monthOfYear daysAfterBeginOfYear hasValue 90 name hasValue "March" instance 4 memberOf monthOfYear daysAfterBeginOfYear hasValue 120 name hasValue "April" instance 5 memberOf monthOfYear daysAfterBeginOfYear hasValue 151 name hasValue "May" instance 6 memberOf monthOfYear daysAfterBeginOfYear hasValue 181 name hasValue "June" instance 7 memberOf monthOfYear daysAfterBeginOfYear hasValue 212 name hasValue "July" instance 8 memberOf monthOfYear daysAfterBeginOfYear hasValue 243 name hasValue "August" instance 9 memberOf monthOfYear daysAfterBeginOfYear hasValue 273 name hasValue "September" instance 10 memberOf monthOfYear daysAfterBeginOfYear hasValue 304 name hasValue "October" instance 11 memberOf monthOfYear daysAfterBeginOfYear hasValue 334 name hasValue "November" instance 12 memberOf monthOfYear daysAfterBeginOfYear hasValue 365 name hasValue "December"