This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class MonotoneCubicSpline | |
{ | |
private readonly double[] _x; | |
private readonly double[] _y; | |
private readonly int _n; | |
private readonly double[] _m; | |
public MonotoneCubicSpline(IList<Point> points) | |
{ | |
_x = points.OrderBy(p => p.X).Select(p => p.X).ToArray(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace Interpolation | |
{ | |
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Windows; | |
/// <summary> | |
/// Douglas Peucker Reduction algorithm. | |
/// </summary> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ----------------------------------------------------------------------- | |
// Copyright (C) 2017 Adam Hancock | |
// | |
// Viewer.cs can not be copied and/or distributed without the express | |
// permission of Adam Hancock | |
// ----------------------------------------------------------------------- | |
namespace Controls | |
{ | |
using System; |
NewerOlder