Converts a fractional price to a decimal price.

Namespace: Imsl.Finance
Assembly: ImslCS (in ImslCS.dll) Version: 6.5.0.0

Syntax

C#
public static double Dollarde(
	double fractionalDollar,
	int fraction
)
Visual Basic (Declaration)
Public Shared Function Dollarde ( _
	fractionalDollar As Double, _
	fraction As Integer _
) As Double
Visual C++
public:
static double Dollarde(
	double fractionalDollar, 
	int fraction
)

Parameters

fractionalDollar
Type: System..::.Double
A double which specifies a fractional number.
fraction
Type: System..::.Int32
A int which specifies the denominator.

Return Value

A double which specifies the dollar price expressed as a decimal number.

Remarks

It is computed using the following:

{\it idollar} + \left( {{\it 
            fractionalDollar} - {\it idollar}} \right) \times {{10^{\left( {{\it 
            ifrac} + 1} \right)} } \over {\it fraction}}

where {\it idollar} is the integer part of {\it fractionalDollar}, and {\it ifrac} is the integer part of {\rm {log}}({\it fraction}).

See Also