#pragma once

#include "OptionPricer.h"
#include "../../2_dimensional/Gaussian2d.h"

class HullWhiteOptionPricer : public OptionPricer
{

	const std::function<double(double)> m_strike_transform;

	//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
	// for generating closed form value of digital option in arrears price
	//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
	std::unique_ptr<Gaussian2d> m_gauss_price;

public:

	HullWhiteOptionPricer(const std::string& ub_error, double lb, double ub, double beta, const std::function<double (double)>& strike_transform, double mux_price, double muy_price, double Cxx_price, double Cyy_price, double Cxy_price);

	double digital_option_in_arrears_price(double k) const override;
};