public void TestGraph() { var option = new GraphOption { xDelta = 20, yDelta = 0.5, yRatio = 0.5, SampleCount = 500 }; var graphPlotter = new GraphPlotter(option); graphPlotter.Plot(Math.Tanh, new Interv(5, 102)); graphPlotter.Plot(x => Math.Cos(x) + 1, new Interv(10, 90), 3); var graph = graphPlotter.GetGraphBlock(); var blockReference = new BlockReference(Point3d.Origin, graph); var first = Interaction.GetPoint("\nSpecify extent point 1"); Interaction.InsertScalingEntity(blockReference, first, "\nSpecify extent point 2"); }
public GraphPlotter(GraphOption opt) { this.Option = opt; this.XRange = opt.xRange; this.YRange = opt.yRange; }