Mercurial > repos > public > sbplib_julia
comparison test/LazyTensors/lazy_tensor_operations_test.jl @ 1364:1b8f1af8382a
Merge bugfix/lazytensors
author | Vidar Stiernström <vidar.stiernstrom@it.uu.se> |
---|---|
date | Sun, 21 May 2023 20:57:25 +0200 |
parents | 4c0bc52e170f |
children | fddd3a906535 |
comparison
equal
deleted
inserted
replaced
1361:689978b1ef16 | 1364:1b8f1af8382a |
---|---|
186 v = rand(3) | 186 v = rand(3) |
187 @test a*Ã isa TensorComposition | 187 @test a*Ã isa TensorComposition |
188 @test a*Ã == Ã*a | 188 @test a*Ã == Ã*a |
189 @test range_size(a*Ã) == range_size(Ã) | 189 @test range_size(a*Ã) == range_size(Ã) |
190 @test domain_size(a*Ã) == domain_size(Ã) | 190 @test domain_size(a*Ã) == domain_size(Ã) |
191 @test a*Ã*v == a.*A*v | 191 @test a*Ã*v ≈ a.*A*v rtol=1e-14 |
192 end | 192 end |
193 | 193 |
194 | 194 |
195 @testset "InflatedTensor" begin | 195 @testset "InflatedTensor" begin |
196 I(sz...) = IdentityTensor(sz...) | 196 I(sz...) = IdentityTensor(sz...) |