# OfficeRational

An exact unsigned rational number used by Exif.

Struct 

`OfficeIMO.Drawing`

**Namespace**

`OfficeIMO.Drawing`

**Assembly**

`OfficeIMO.Core`

**Source revision**

`15caddadea70` with working tree changes

**Source**

[OfficeExifTypes.cs:135](https://github.com/EvotecIT/OfficeIMO/blob/15caddadea7080f6e4b3027fdb95451a0210bdb1/OfficeIMO.Core/Raster/OfficeExifTypes.cs#L135)

**Base**

`ValueType`

**Modifiers**

sealed

An exact unsigned rational number used by Exif.

## Inheritance

- ValueType
- OfficeRational

## Usage

Explore 4 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

### Returned or exposed by 2

- Property [OfficeExifGpsCoordinate.LatitudeDms](/api/core/officeimo-drawing-officeexifgpscoordinate/#property-latitudedms)
- Property [OfficeExifGpsCoordinate.LongitudeDms](/api/core/officeimo-drawing-officeexifgpscoordinate/#property-longitudedms)

### Accepted by parameters 2

- Method [OfficeExifGpsCoordinate.TryCreate](/api/core/officeimo-drawing-officeexifgpscoordinate/#method-trycreate-officeimo-drawing-officerational-string-officeimo-drawing-officerational-string-officeimo-drawing-officeexifgpscoordinate) parameter `latitude`
- Method [OfficeExifGpsCoordinate.TryCreate](/api/core/officeimo-drawing-officeexifgpscoordinate/#method-trycreate-officeimo-drawing-officerational-string-officeimo-drawing-officerational-string-officeimo-drawing-officeexifgpscoordinate) parameter `longitude`

Filter members 

Show inherited

## Constructors

`public OfficeRational(uint numerator, uint denominator)` [#](#constructor-ctor-uint32-uint32)

[OfficeExifTypes.cs:135](https://github.com/EvotecIT/OfficeIMO/blob/15caddadea7080f6e4b3027fdb95451a0210bdb1/OfficeIMO.Core/Raster/OfficeExifTypes.cs#L135)

Creates a rational, retaining a zero denominator when present in source metadata.

Parameters

**numerator uint required**

**denominator uint required**

## Methods

`public double ToDouble()` [#](#method-todouble)

[OfficeExifTypes.cs:141](https://github.com/EvotecIT/OfficeIMO/blob/15caddadea7080f6e4b3027fdb95451a0210bdb1/OfficeIMO.Core/Raster/OfficeExifTypes.cs#L141)

Returns the quotient, or NaN for a zero denominator.

Returns

`double`

`public override string ToString()` [#](#method-tostring)

[OfficeExifTypes.cs:143](https://github.com/EvotecIT/OfficeIMO/blob/15caddadea7080f6e4b3027fdb95451a0210bdb1/OfficeIMO.Core/Raster/OfficeExifTypes.cs#L143)

Returns the fully qualified type name of this instance.

Returns

`string` The fully qualified type name.

## Inherited Methods

`public override bool Equals(object? obj)` [#](#method-equals-object)

Inherited from ValueType

Parameters

**obj object? required**

Returns

`bool`

`public override int GetHashCode()` [#](#method-gethashcode)

Inherited from ValueType

Returns

`int`

`public Type GetType()` [#](#method-gettype)

Inherited from object

Returns

`Type`

## Properties

`public uint Numerator { get; }` [#](#property-numerator)

[OfficeExifTypes.cs:137](https://github.com/EvotecIT/OfficeIMO/blob/15caddadea7080f6e4b3027fdb95451a0210bdb1/OfficeIMO.Core/Raster/OfficeExifTypes.cs#L137)

The numerator.

`public uint Denominator { get; }` [#](#property-denominator)

[OfficeExifTypes.cs:139](https://github.com/EvotecIT/OfficeIMO/blob/15caddadea7080f6e4b3027fdb95451a0210bdb1/OfficeIMO.Core/Raster/OfficeExifTypes.cs#L139)

The denominator.

<!-- PowerForge markdown artifact sha256:5FD4D4D40B01C216043C99D31C0CBA2EB2EAD5B0D20B02177E1A92FC6B8837E9 -->
