Documentation
Fp
.
Multiplication
Search
return to top
source
Imports
Init
Fp.Basic
Fp.Rounding
Imported by
f_mul
e_mul
mulfixed
f_mul_comm
e_mul_comm
mulfixed_comm
mul
mul_comm
mul_one_is_id
source
def
f_mul
{
v
e
w
f
:
Nat
}
(
a
:
FixedPoint
v
e
)
(
b
:
FixedPoint
w
f
)
:
FixedPoint
(
v
+
w
) (
e
+
f
)
Equations
f_mul
a
b
=
{
sign
:=
a
.
sign
^^
b
.
sign
,
val
:=
BitVec.setWidth'
⋯
a
.
val
*
BitVec.setWidth'
⋯
b
.
val
,
hExOffset
:=
⋯
}
Instances For
source
def
e_mul
{
v
e
w
f
:
Nat
}
(
a
:
EFixedPoint
v
e
)
(
b
:
EFixedPoint
w
f
)
:
EFixedPoint
(
v
+
w
) (
e
+
f
)
Equations
One or more equations did not get rendered due to their size.
Instances For
source
def
mulfixed
{
e
s
:
Nat
}
(
he
:
0
<
e
)
(
a
b
:
PackedFloat
e
s
)
(
m
:
RoundingMode
)
:
PackedFloat
e
s
Equations
mulfixed
he
a
b
m
=
round
e
s
m
(
e_mul
(
a
.
toEFixed
he
)
(
b
.
toEFixed
he
)
)
Instances For
source
theorem
f_mul_comm
(
a
b
:
FixedPoint
34
16
)
:
f_mul
a
b
=
f_mul
b
a
source
theorem
e_mul_comm
(
a
b
:
EFixedPoint
34
16
)
:
e_mul
a
b
=
e_mul
b
a
source
theorem
mulfixed_comm
(
a
b
:
PackedFloat
5
2
)
(
m
:
RoundingMode
)
:
mulfixed
⋯
a
b
m
=
mulfixed
⋯
b
a
m
source
def
mul
{
e
s
:
Nat
}
(
a
b
:
PackedFloat
e
s
)
(
m
:
RoundingMode
)
:
PackedFloat
e
s
Equations
One or more equations did not get rendered due to their size.
Instances For
source
theorem
mul_comm
(
a
b
:
PackedFloat
5
2
)
(
m
:
RoundingMode
)
:
mul
a
b
m
=
mul
b
a
m
source
theorem
mul_one_is_id
(
a
:
PackedFloat
5
2
)
(
m
:
RoundingMode
)
(
ha
:
¬
a
.
isNaN
=
true
)
:
mul
a
oneE5M2
m
=
a