/// <summary>
 /// Initializes a new instance of the <see cref="FunctionValueOptimization{TData}" /> class.
 /// </summary>
 /// <param name="hypothesis">The hypothesis.</param>
 /// <param name="coefficients">The fixed coefficients of the function.</param>
 public FunctionValueOptimization([NotNull] IDifferentiableHypothesis <TData> hypothesis, [NotNull] Vector <TData> coefficients)
 {
     _coefficients = coefficients;
     _hypothesis   = hypothesis;
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ResidualSumOfSquaresCostFunction" /> class.
 /// </summary>
 /// <param name="hypothesis">The hypothesis.</param>
 /// <param name="trainingSet">The training set.</param>
 public ResidualSumOfSquaresCostFunction([NotNull] IDifferentiableHypothesis <double> hypothesis, [NotNull] IReadOnlyCollection <DataPoint <double> > trainingSet)
 {
     _hypothesis  = hypothesis;
     _trainingSet = trainingSet;
 }