# Performing arithmetic operations in quadruple precision

**URL:** <https://discourse.julialang.org/t/performing-arithmetic-operations-in-quadruple-precision/4265>\
**Category:** General Usage\
**Created:** [June 14, 2017, 9:46am UTC](https://discourse.julialang.org/t/performing-arithmetic-operations-in-quadruple-precision/4265 "2017-06-14T09:46:30Z")\
**Posts on this page:** 1\
**Showing post:** 14

<div class="post-metadata">

**Author:** ![greg\_plowman](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/greg_plowman/32/8100_2.png) [@greg\_plowman](https://discourse.julialang.org/u/greg_plowman)\
**Post date:** [October 25, 2017, 8:40pm UTC](https://discourse.julialang.org/t/performing-arithmetic-operations-in-quadruple-precision/4265/14 "2017-10-25T20:40:17Z")

</div>

Also see this: [Change default precision - #47 by stevengj](https://discourse.julialang.org/t/change-default-precision/6520/47)

```julia
using DecFP
using ChangePrecision

y = Dec128(5)/Dec128(36)-Dec128(7)*√Dec128(15)/Dec128(30)

@changeprecision Dec128 begin
    z = 5/36 - 7*√15/30
end

y == z # true

```

EDIT: or more concisely:

```julia
@changeprecision Dec128 z = 5/36-7*√15/30

```

---

_[View the full topic](https://discourse.julialang.org/t/performing-arithmetic-operations-in-quadruple-precision/4265)._
