public bool Equals(Filter other) { if (other is null) { return(false); } if (ReferenceEquals(this, other)) { return(true); } return(StartUtc.Equals(other.StartUtc) && EndUtc.Equals(other.EndUtc) && DateRangeType == other.DateRangeType && string.Equals(DesignUid, other.DesignUid) && string.Equals(DesignFileName, other.DesignFileName) && ((ContributingMachines ?? other.ContributingMachines) == null || ContributingMachines.ScrambledEquals(other.ContributingMachines)) && OnMachineDesignId == other.OnMachineDesignId && string.Equals(OnMachineDesignName, other.OnMachineDesignName) && ElevationType == other.ElevationType && VibeStateOn == other.VibeStateOn && string.Equals(PolygonUid, other.PolygonUid) && PolygonType == other.PolygonType && string.Equals(PolygonName, other.PolygonName) && ((PolygonLL ?? other.PolygonLL) == null || PolygonLL.ScrambledEquals(other.PolygonLL)) && ForwardDirection == other.ForwardDirection && LayerNumber == other.LayerNumber && string.Equals(AlignmentUid, other.AlignmentUid) && string.Equals(AlignmentFileName, other.AlignmentFileName) && StartStation.Equals(other.StartStation) && EndStation.Equals(other.EndStation) && LeftOffset.Equals(other.LeftOffset) && RightOffset.Equals(other.RightOffset) && AutomaticsType == other.AutomaticsType && TemperatureRangeMin.Equals(other.TemperatureRangeMin) && TemperatureRangeMax.Equals(other.TemperatureRangeMax) && PassCountRangeMin.Equals(other.PassCountRangeMin) && PassCountRangeMax.Equals(other.PassCountRangeMax)); }
//this method calculates the degree of membership for a particular value public override double CalculateDOM(double val) { //test for the case where the triangle's left or right offsets are zero //(to prevent divide by zero errors below) if (RightOffset.Equals(0.0) && PeakPoint.Equals(val) || LeftOffset.Equals(0.0) && PeakPoint.Equals(val)) { return(1.0); } //find DOM if left of center if ((val <= PeakPoint) && (val >= (PeakPoint - LeftOffset))) { double grad = 1.0 / LeftOffset; return(grad * (val - (PeakPoint - LeftOffset))); } //find DOM if right of center if (val > PeakPoint && (val < (PeakPoint + RightOffset))) { double grad = 1.0 / -RightOffset; return(grad * (val - PeakPoint) + 1.0); } //out of range of this FLV, return zero return(0.0); }
public bool Equals(FilterResult other) { if (ReferenceEquals(null, other)) { return(false); } if (ReferenceEquals(this, other)) { return(true); } return(Id.Equals(other.Id) && Uid.Equals(other.Uid) && string.Equals(Name, other.Name) && string.Equals(Description, other.Description) && StartUtc.Equals(other.StartUtc) && EndUtc.Equals(other.EndUtc) && OnMachineDesignId == other.OnMachineDesignId && OnMachineDesignName == other.OnMachineDesignName && AssetIDs.ScrambledEquals(other.AssetIDs) && VibeStateOn == other.VibeStateOn && CompactorDataOnly.Equals(other.CompactorDataOnly) && ElevationType == other.ElevationType && PolygonLL.ScrambledEquals(other.PolygonLL) && PolygonGrid.ScrambledEquals(other.PolygonGrid) && ForwardDirection == other.ForwardDirection && (AlignmentFile == null ? other.AlignmentFile == null : AlignmentFile.Equals(other.AlignmentFile)) && StartStation.Equals(other.StartStation) && EndStation.Equals(other.EndStation) && LeftOffset.Equals(other.LeftOffset) && RightOffset.Equals(other.RightOffset) && LayerType.Equals(other.LayerType) && (LayerDesignOrAlignmentFile == null ? other.LayerDesignOrAlignmentFile == null : LayerDesignOrAlignmentFile.Equals(other.LayerDesignOrAlignmentFile)) && BenchElevation.Equals(other.BenchElevation) && LayerNumber == other.LayerNumber && LayerThickness.Equals(other.LayerThickness) && ContributingMachines.ScrambledEquals(other.ContributingMachines) && SurveyedSurfaceExclusionList.ScrambledEquals(other.SurveyedSurfaceExclusionList) && ExcludedSurveyedSurfaceUids.ScrambledEquals(other.ExcludedSurveyedSurfaceUids) && ReturnEarliest.Equals(other.ReturnEarliest) && GpsAccuracy.Equals(other.GpsAccuracy) && GpsAccuracyIsInclusive.Equals(other.GpsAccuracyIsInclusive) && BladeOnGround.Equals(other.BladeOnGround) && TrackMapping.Equals(other.TrackMapping) && WheelTracking.Equals(other.WheelTracking) && (DesignFile == null ? other.DesignFile == null : DesignFile.Equals(other.DesignFile)) && AutomaticsType == other.AutomaticsType && TemperatureRangeMin.Equals(other.TemperatureRangeMin) && TemperatureRangeMax.Equals(other.TemperatureRangeMax) && PassCountRangeMin.Equals(other.PassCountRangeMin) && PassCountRangeMax.Equals(other.PassCountRangeMax)); }