Safe Haskell | None |
---|---|
Language | Haskell2010 |
AUTHOR
- Dr. Alistair Ward
DESCRIPTION
- Defines the weightings, associated with each of the soft-constraints used to compare & select between alternative timetables.
- Hard-constraints (e.g. that a student or teacher can't be in more than one place at a time, or that the capacity of a location can't be exceeded), are never violated, & so don't need to be quantified for subsequent comparison.
Synopsis
- data TimetableCriteriaWeights w = MkTimetableCriteriaWeights {
- getWeightOfMaximiseComplianceWithFreePeriodPreferences :: CriterionWeight w
- getWeightOfMaximiseMeanRatioOfStudentClassSizeToLocationCapacity :: CriterionWeight w
- getWeightOfMaximiseMeanStudentClassSize :: CriterionWeight w
- getWeightOfMaximiseSynchronisationOfSynchronisedCourses :: CriterionWeight w
- getWeightOfMaximiseWeightedMeanStudentBodyUtilisationRatio :: CriterionWeight w
- getWeightOfMinimiseAverageAbsoluteDeviationFromIdealTimeslotRequest :: CriterionWeight w
- getWeightOfMinimiseDispersionOfStudentFreePeriodsPerDay :: CriterionWeight w
- getWeightOfMinimiseDispersionOfTeacherFreePeriodsPerDay :: CriterionWeight w
- getWeightOfMinimiseDispersionOfTeacherWorkload :: CriterionWeight w
- getWeightOfMinimiseMeanInterCampusMigrationsOfStudents :: CriterionWeight w
- getWeightOfMinimiseMeanInterCampusMigrationsOfTeachers :: CriterionWeight w
- getWeightOfMinimiseMeanLocationChangesOfTeachers :: CriterionWeight w
- getWeightOfMinimiseMeanLocusOperandiOfTeachers :: CriterionWeight w
- getWeightOfMinimiseMeanRatioOfIncompletelyBookedCoreKnowledge :: CriterionWeight w
- getWeightOfMinimiseMeanRatioOfIncompletelyBookedOptionalKnowledge :: CriterionWeight w
- getWeightOfMinimiseMeanStudentBodyCombinationsPerLesson :: CriterionWeight w
- getWeightOfMinimiseRatioOfConsecutiveEqualLessons :: CriterionWeight w
- getWeightOfMinimiseRatioOfSeparatedEqualLessonsWithinAnyDay :: CriterionWeight w
- associationList :: [(String, TimetableCriteriaWeights w -> CriterionWeight w)]
- tag :: String
- weightOfMaximiseComplianceWithFreePeriodPreferencesTag :: String
- weightOfMaximiseMeanRatioOfStudentClassSizeToLocationCapacityTag :: String
- weightOfMaximiseMeanStudentClassSizeTag :: String
- weightOfMaximiseSynchronisationOfSynchronisedCoursesTag :: String
- weightOfMaximiseWeightedMeanStudentBodyUtilisationRatioTag :: String
- weightOfMinimiseAverageAbsoluteDeviationFromIdealTimeslotRequestTag :: String
- weightOfMinimiseDispersionOfStudentFreePeriodsPerDayTag :: String
- weightOfMinimiseDispersionOfTeacherFreePeriodsPerDayTag :: String
- weightOfMinimiseDispersionOfTeacherWorkloadTag :: String
- weightOfMinimiseMeanInterCampusMigrationsOfStudentsTag :: String
- weightOfMinimiseMeanInterCampusMigrationsOfTeachersTag :: String
- weightOfMinimiseMeanLocationChangesOfTeachersTag :: String
- weightOfMinimiseMeanLocusOperandiOfTeachersTag :: String
- weightOfMinimiseMeanRatioOfIncompletelyBookedCoreKnowledgeTag :: String
- weightOfMinimiseMeanRatioOfIncompletelyBookedOptionalKnowledgeTag :: String
- weightOfMinimiseMeanStudentBodyCombinationsPerLessonTag :: String
- weightOfMinimiseRatioOfConsecutiveEqualLessonsTag :: String
- weightOfMinimiseRatioOfSeparatedEqualLessonsWithinAnyDayTag :: String
- calculateWeightedMean :: (Fractional weightedMean, Real criterionValue, Real criterionWeight) => TimetableCriteriaWeights criterionWeight -> Criterion criterionValue -> Criterion criterionValue -> Criterion criterionValue -> Criterion criterionValue -> Criterion criterionValue -> Criterion criterionValue -> Criterion criterionValue -> Criterion criterionValue -> Criterion criterionValue -> Criterion criterionValue -> Criterion criterionValue -> Criterion criterionValue -> Criterion criterionValue -> Criterion criterionValue -> Criterion criterionValue -> Criterion criterionValue -> Criterion criterionValue -> Criterion criterionValue -> Writer [Maybe criterionValue] weightedMean
- zeroWeightOfMaximiseComplianceWithFreePeriodPreferences :: Num w => Mutator w
- zeroWeightOfMaximiseSynchronisationOfSynchronisedCourses :: Num w => Mutator w
- zeroWeightOfMinimiseAverageAbsoluteDeviationFromIdealTimeslotRequest :: Num w => Mutator w
- zeroWeightOfMinimiseDispersionOfStudentFreePeriodsPerDay :: Num w => Mutator w
- zeroWeightOfMinimiseMeanInterCampusMigrationsOfStudents :: Num w => Mutator w
- zeroWeightOfMinimiseMeanInterCampusMigrationsOfTeachers :: Num w => Mutator w
- zeroWeightOfMinimiseMeanLocationChangesOfTeachers :: Num w => Mutator w
- zeroWeightOfMinimiseMeanLocusOperandiOfTeachers :: Num w => Mutator w
- zeroWeightOfMinimiseMeanRatioOfIncompletelyBookedOptionalKnowledge :: Num w => Mutator w
- zeroWeightOfMinimiseMeanStudentBodyCombinationsPerLesson :: Num w => Mutator w
- zeroWeightOfMinimiseRatioOfConsecutiveEqualLessons :: Num w => Mutator w
- zeroWeightOfMinimiseRatioOfSeparatedEqualLessonsWithinAnyDay :: Num w => Mutator w
Types
Type-synonyms
Data-types
data TimetableCriteriaWeights w Source #
The weight of criteria used to select a timetable from alternatives.
MkTimetableCriteriaWeights | |
|
Instances
Constants
associationList :: [(String, TimetableCriteriaWeights w -> CriterionWeight w)] Source #
The ordered list of tags & accessors.
weightOfMaximiseComplianceWithFreePeriodPreferencesTag :: String Source #
Used to qualify XML.
weightOfMaximiseMeanRatioOfStudentClassSizeToLocationCapacityTag :: String Source #
Used to qualify XML.
weightOfMaximiseMeanStudentClassSizeTag :: String Source #
Used to qualify XML.
weightOfMaximiseSynchronisationOfSynchronisedCoursesTag :: String Source #
Used to qualify XML.
weightOfMaximiseWeightedMeanStudentBodyUtilisationRatioTag :: String Source #
Used to qualify XML.
weightOfMinimiseAverageAbsoluteDeviationFromIdealTimeslotRequestTag :: String Source #
Used to qualify XML.
weightOfMinimiseDispersionOfStudentFreePeriodsPerDayTag :: String Source #
Used to qualify XML.
weightOfMinimiseDispersionOfTeacherFreePeriodsPerDayTag :: String Source #
Used to qualify XML.
weightOfMinimiseDispersionOfTeacherWorkloadTag :: String Source #
Used to qualify XML.
weightOfMinimiseMeanInterCampusMigrationsOfStudentsTag :: String Source #
Used to qualify XML.
weightOfMinimiseMeanInterCampusMigrationsOfTeachersTag :: String Source #
Used to qualify XML.
weightOfMinimiseMeanLocationChangesOfTeachersTag :: String Source #
Used to qualify XML.
weightOfMinimiseMeanLocusOperandiOfTeachersTag :: String Source #
Used to qualify XML.
weightOfMinimiseMeanRatioOfIncompletelyBookedCoreKnowledgeTag :: String Source #
Used to qualify XML.
weightOfMinimiseMeanRatioOfIncompletelyBookedOptionalKnowledgeTag :: String Source #
Used to qualify XML.
weightOfMinimiseMeanStudentBodyCombinationsPerLessonTag :: String Source #
Used to qualify XML.
weightOfMinimiseRatioOfConsecutiveEqualLessonsTag :: String Source #
Used to qualify XML.
weightOfMinimiseRatioOfSeparatedEqualLessonsWithinAnyDayTag :: String Source #
Used to qualify XML.
Functions
calculateWeightedMean Source #
:: (Fractional weightedMean, Real criterionValue, Real criterionWeight) | |
=> TimetableCriteriaWeights criterionWeight | |
-> Criterion criterionValue | complianceWithFreePeriodPreferences: maximum when each unallocated time-slot complies with the preferences of both student-bodies & teachers. |
-> Criterion criterionValue | classSizeOverLocationCapacity: maximum when location which has been booked, is completely filled by the student-class. |
-> Criterion criterionValue | A timetable is preferred, when the mean over the size of student-classes, relative to the total number of students, is greatest. |
-> Criterion criterionValue | synchronisationOfSynchronisedCourses: maximum if the lessons for all synchronised courses, are synchronised. |
-> Criterion criterionValue | weightedMeanStudentBodyUtilisationRatio: maximum if all student-bodies are fully utilised. |
-> Criterion criterionValue | averageAbsoluteDeviationFromIdealTimeslotRequest: maximum if all lessons, whose course specifies an ideal time-slot, have been booked exactly on it, falling towards minimum as the mean absolute deviation increases. |
-> Criterion criterionValue | dispersionOfStudentFreePeriodsPerDay: maximum when the deviation in the number of free student-periods per day is zero, falling towards minimum when they all fall on one day. |
-> Criterion criterionValue | dispersionOfTeacherFreePeriodsPerDay: maximum when the deviation in the number of free teacher-periods per day is zero, falling towards minimum when they all fall on one day. |
-> Criterion criterionValue | dispersionOfTeacherWorkload: maximum when the deviation in the workload between teachers is zero, falling towards minimum as their workloads move away from the mean. |
-> Criterion criterionValue | meanInterCampusMigrationsOfStudents: maximum when each student migrates to a different campus between each timeslot. |
-> Criterion criterionValue | meanInterCampusMigrationsOfTeachers: maximum when each teacher migrates to a different campus between each timeslot. |
-> Criterion criterionValue | meanLocationChangesOfTeachers: maximum when the location of each teacher changes at every time-slot, falling towards minimum as each lesson is taught at the same location. |
-> Criterion criterionValue | meanLocusOperandiOfTeachers: maximum when the locus-operandi of each teacher is just one location, falling towards minimum as each lesson taught is in a different location. |
-> Criterion criterionValue | meanRatioOfIncompletelyBookedCoreKnowledge: maximum when all of a student-body's required core subjects are completely booked, falling towards minimum when none are met. |
-> Criterion criterionValue | meanRatioOfIncompletelyBookedOptionalKnowledge: maximum when all of a student-body's required optional subjects are completely booked, falling towards minimum when none are met. |
-> Criterion criterionValue | meanStudentBodyCombinationsPerLesson: maximum when each student-body studies a subject, as a member of a constant student-class, falling towards minimum as the mean number of different student-body-combinations per subject rises. |
-> Criterion criterionValue | ratioOfConsecutiveEqualLessons: maximum when blocks of consecutive identical lessons are booked, whose length equals that requested for the course to which they belong. |
-> Criterion criterionValue | ratioOfSeparatedEqualLessonsWithinAnyDay: maximum when only one contiguous block of lessons in any subject, has been booked each day, falling towards minimum where separated blocks of equal lessons occur within any one day. |
-> Writer [Maybe criterionValue] weightedMean | The individual criteria values, & their weighted mean. |
- Returns the weighted sum of the specified criteria, divided by the sum of the weights.
- The magnitude of each criterion should be in the same range, so that none dominates the total, thus making the total a clear measure of the value attributed to each.
- The magnitude of the value of each criterion should be independent of the dimensions of the timetable (observerIds, days per week, time-slots per day), so that should any of these change, the balance between criteria doesn't shift; i.e. they should be dimensionless.
Mutators
zeroWeightOfMaximiseComplianceWithFreePeriodPreferences :: Num w => Mutator w Source #
zeroWeightOfMaximiseSynchronisationOfSynchronisedCourses :: Num w => Mutator w Source #
zeroWeightOfMinimiseAverageAbsoluteDeviationFromIdealTimeslotRequest :: Num w => Mutator w Source #
zeroWeightOfMinimiseDispersionOfStudentFreePeriodsPerDay :: Num w => Mutator w Source #
zeroWeightOfMinimiseMeanInterCampusMigrationsOfStudents :: Num w => Mutator w Source #
zeroWeightOfMinimiseMeanInterCampusMigrationsOfTeachers :: Num w => Mutator w Source #
zeroWeightOfMinimiseMeanLocationChangesOfTeachers :: Num w => Mutator w Source #
zeroWeightOfMinimiseMeanLocusOperandiOfTeachers :: Num w => Mutator w Source #
zeroWeightOfMinimiseMeanRatioOfIncompletelyBookedOptionalKnowledge :: Num w => Mutator w Source #
zeroWeightOfMinimiseMeanStudentBodyCombinationsPerLesson :: Num w => Mutator w Source #
zeroWeightOfMinimiseRatioOfConsecutiveEqualLessons :: Num w => Mutator w Source #
zeroWeightOfMinimiseRatioOfSeparatedEqualLessonsWithinAnyDay :: Num w => Mutator w Source #