Skip to content

Commit d88e0fc

Browse files
committed
include documentation
1 parent 90559a4 commit d88e0fc

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

docs/src/types.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,10 @@ Base.cat
8484
SparseArrays.blockdiag
8585
```
8686

87+
### `FillMap``
88+
89+
Type for lazily representing constantly filled matrices.
90+
8791
## Methods
8892

8993
### Multiplication methods

src/LinearMaps.jl

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -247,11 +247,14 @@ include("show.jl") # show methods for LinearMap objects
247247
LinearMap(A::LinearMap; kwargs...)::WrappedMap
248248
LinearMap(A::AbstractMatrix; kwargs...)::WrappedMap
249249
LinearMap(J::UniformScaling, M::Int)::UniformScalingMap
250+
LinearMap(λ::Number, M::Int, N::Int) = FillMap(λ, (M, N))::FillMap
251+
LinearMap(λ::Number, dims::Dims{2}) = FillMap(λ, dims)::FillMap
250252
LinearMap{T=Float64}(f, [fc,], M::Int, N::Int = M; kwargs...)::FunctionMap
251253
252254
Construct a linear map object, either from an existing `LinearMap` or `AbstractMatrix` `A`,
253255
with the purpose of redefining its properties via the keyword arguments `kwargs`;
254-
a `UniformScaling` object `J` with specified (square) dimension `M`; or
256+
a `UniformScaling` object `J` with specified (square) dimension `M`; from a `Number`
257+
object to lazily represent filled matrices; or
255258
from a function or callable object `f`. In the latter case, one also needs to specify
256259
the size of the equivalent matrix representation `(M, N)`, i.e., for functions `f` acting
257260
on length `N` vectors and producing length `M` vectors (with default value `N=M`).

0 commit comments

Comments
 (0)