Class Curve
Curve.
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: SpiceSharpParser.Common.Mathematics.Probability
Assembly: SpiceSharpParser.dll
Syntax
public class Curve : IEnumerable<Point>, IEnumerable
Constructors
| Improve this Doc View SourceCurve()
Initializes a new instance of the Curve class.
Declaration
public Curve()
Properties
| Improve this Doc View SourceItem[Int32]
Gets or sets a point.
Declaration
public Point this[int index] { get; }
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index | Point index. |
Property Value
Type | Description |
---|---|
Point | A curve's point. |
Points
Declaration
public List<Point> Points { get; protected set; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.List<Point> |
PointsCount
Gets the count of points.
Declaration
public int PointsCount { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Methods
| Improve this Doc View SourceAdd(Point)
Adds a point to the curve.
Declaration
public void Add(Point point)
Parameters
Type | Name | Description |
---|---|---|
Point | point | A point. |
Clear()
Clears the points.
Declaration
public void Clear()
Clone()
Clones the curve.
Declaration
public Curve Clone()
Returns
Type | Description |
---|---|
Curve | A cloned curve. |
ComputeAreaUnderCurve()
Computes the area under the curve.
Declaration
public double ComputeAreaUnderCurve()
Returns
Type | Description |
---|---|
System.Double | The area under curve. |
ComputeAreaUnderCurve(Double)
Computes the area under the curve.
Declaration
public double ComputeAreaUnderCurve(double x)
Parameters
Type | Name | Description |
---|---|---|
System.Double | x | X value of last point. |
Returns
Type | Description |
---|---|
System.Double | The area under curve. |
ComputeAreaUnderCurve(Int32)
Computes the area under the curve.
Declaration
public double ComputeAreaUnderCurve(int limitPointIndex)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | limitPointIndex | Index of last point. |
Returns
Type | Description |
---|---|
System.Double | The area under curve. |
GetEnumerator()
Gets the enumerator.
Declaration
public IEnumerator<Point> GetEnumerator()
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerator<Point> | The enumerator of points. |
GetFirstPoint()
Gets the first point.
Declaration
public Point GetFirstPoint()
Returns
Type | Description |
---|---|
Point | The first point. |
GetLastPoint()
Gets the last point.
Declaration
public Point GetLastPoint()
Returns
Type | Description |
---|---|
Point | The last point. |
ScaleY(Double)
Scales the curve.
Declaration
public void ScaleY(double scaleFactor)
Parameters
Type | Name | Description |
---|---|---|
System.Double | scaleFactor | Scaling factor. |
Explicit Interface Implementations
| Improve this Doc View SourceIEnumerable.GetEnumerator()
Gets the enumerator.
Declaration
IEnumerator IEnumerable.GetEnumerator()
Returns
Type | Description |
---|---|
System.Collections.IEnumerator | The enumerator. |
Implements
System.Collections.Generic.IEnumerable<T>
System.Collections.IEnumerable