Scientific.Analysis.TDoubleArray
TDoubleArray = Array of Double
Owns a finite sequence $(x_1,\ldots,x_n)$ of real values.
Unit
Scientific.AnalysisDeclared in Scientific.Analysis.pas
Provides numerical methods and elementary statistical transforms. The routines illustrate documentation ranging from short inline symbols such as $\mu$ and $\sigma$ to complete display equations.
Scientific.Analysis.TDoubleArray
TDoubleArray = Array of Double
Owns a finite sequence $(x_1,\ldots,x_n)$ of real values.
Scientific.Analysis.TGaussianFunctionTRealFunction
TGaussianFunction = class(TRealFunction)
end
Represents a Gaussian density with mean $\mu$ and deviation $\sigma$.
Scientific.Analysis.ArithmeticMean
function ArithmeticMean(const Values: Array of Double): Double
Computes the arithmetic mean of $n$ observations.
| Name | Description |
|---|---|
Values | Observations $(x_1,\ldots,x_n)$. |
Their arithmetic mean $\bar{x}$.
| Exception | Condition |
|---|---|
Exception | When the sequence is empty. |
Scientific.Analysis.Entropy
function Entropy(const Probabilities: Array of Double): Double
Computes Shannon entropy in bits.
| Name | Description |
|---|---|
Probabilities | Values $p_i\in[0,1]$. |
The information entropy $H(P)$ in bits.
| Exception | Condition |
|---|---|
Exception | When a probability lies outside $[0,1]$. |
Scientific.Analysis.Logistic
function Logistic(const X: Double): Double
Evaluates the logistic sigmoid.
| Name | Description |
|---|---|
X | Real argument $x$. |
A value strictly between zero and one.
Scientific.Analysis.NewtonStep
function NewtonStep(
const F: IRealFunction;
const Derivative: IRealFunction;
const X: Double
): Double
Performs one Newton-Raphson root update.
| Name | Description |
|---|---|
F | Function $f$ whose root is sought. |
Derivative | Derivative function $f'$. |
X | Current approximation $x_k$. |
The next approximation $x_{k+1}$.
| Exception | Condition |
|---|---|
Exception | When $f'(x_k)$ is numerically zero. |
Scientific.Analysis.NormalPDF
function NormalPDF(
const X: Double;
const Mean: Double;
const StandardDeviation: Double
): Double
Evaluates a normal probability density without constructing an object.
| Name | Description |
|---|---|
X | Observation $x$. |
Mean | Distribution mean $\mu$. |
StandardDeviation | Positive standard deviation $\sigma$. |
The normal density $p(x)$.
| Exception | Condition |
|---|---|
Exception | When $\sigma\leq 0$. |
Scientific.Analysis.PopulationVariance
function PopulationVariance(const Values: Array of Double): Double
Computes population variance around the arithmetic mean.
| Name | Description |
|---|---|
Values | Observations $(x_1,\ldots,x_n)$. |
Their population variance $\sigma^2$.
| Exception | Condition |
|---|---|
Exception | When the sequence is empty. |
Scientific.Analysis.SimpsonEstimate
function SimpsonEstimate(
const F: IRealFunction;
const A: Double;
const B: Double
): Double
Estimates an integral with one Simpson panel.
| Name | Description |
|---|---|
F | Integrand $f$. |
A | Lower bound $a$. |
B | Upper bound $b$. |
The Simpson estimate of the definite integral.
Scientific.Analysis.Softmax
function Softmax(const Values: Array of Double): TDoubleArray
Converts arbitrary scores into a categorical probability distribution.
Subtracting $m$ leaves the result unchanged while improving numerical stability.
| Name | Description |
|---|---|
Values | Scores $(z_1,\ldots,z_n)$. |
Probabilities whose sum is one, or an empty sequence.
Scientific.Analysis.TGaussianFunction.CreateParent: Scientific.Analysis.TGaussianFunction
constructor Create(const AMean: Double; const AStandardDeviation: Double)
Creates $\mathcal{N}(\mu,\sigma^2)$ for a positive $\sigma$.
| Name | Description |
|---|---|
AMean | Distribution mean $\mu$. |
AStandardDeviation | Standard deviation $\sigma>0$. |
| Exception | Condition |
|---|---|
Exception | When $\sigma\leq 0$. |
Scientific.Analysis.TGaussianFunction.EvaluateParent: Scientific.Analysis.TGaussianFunction
function Evaluate(const X: Double): Double; override
Evaluates the Gaussian probability density at $x$.
| Name | Description |
|---|---|
X | Observation $x$. |
The density $\mathcal{N}(x\mid\mu,\sigma^2)$.
Scientific.Analysis.TGaussianFunction.MeanParent: Scientific.Analysis.TGaussianFunction
Mean : Double
Distribution mean $\mu=\mathbb{E}[X]$.
Scientific.Analysis.TGaussianFunction.StandardDeviationParent: Scientific.Analysis.TGaussianFunction
StandardDeviation : Double
Standard deviation $\sigma=\sqrt{\operatorname{Var}(X)}$.