Matrix subtract(const Matrix &other) const
Subtracts another matrix from this matrix.
void multiply_scalar(double scalar)
Multiplies all elements in the matrix by a scalar.
void update_params(double learning_rate)
Updates the network parameters based on computed gradients.
void subtract_scalar(double scalar)
Subtracts a scalar value from all elements in the vector.
Defines the NeuralNetwork class for a simple feedforward neural network.