[#FeeFrac-EvaluateFee]
= xref:FeeFrac.adoc[FeeFrac]::EvaluateFee
:relfileprefix: ../
:mrdocs:

Compute the fee for a given size `at&lowbar;size` using this object&apos;s feerate&period;

== Synopsis

Declared in `&lt;util&sol;feefrac&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;bool RoundDown&gt;
int64&lowbar;t
EvaluateFee(int32&lowbar;t at&lowbar;size) const noexcept;
----

== Description

This effectively corresponds to evaluating (this&hyphen;&gt;fee &ast; at&lowbar;size) &sol; this&hyphen;&gt;size, with the result rounded towards negative infinity (if RoundDown) or towards positive infinity (if !RoundDown)&period;

Requires this&hyphen;&gt;size &gt; 0, at&lowbar;size &gt;&equals; 0, and that the correct result fits in a int64&lowbar;t&period; This is guaranteed to be the case when 0 &lt;&equals; at&lowbar;size &lt;&equals; this&hyphen;&gt;size&period;

== Return Value

The fee corresponding to at&lowbar;size at this object&apos;s feerate&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *at&lowbar;size*
| The size to evaluate the fee at&period;
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
