Skip to content
Snippets Groups Projects
Commit c71a7bdf authored by Stephan Hilb's avatar Stephan Hilb
Browse files

add support for true scalar functions

parent 7120ad33
No related branches found
No related tags found
No related merge requests found
...@@ -120,7 +120,8 @@ function _sample(f::FeFunction) ...@@ -120,7 +120,8 @@ function _sample(f::FeFunction)
(x .- A[:, 1]) (x .- A[:, 1])
ε = eps() ε = eps()
if all(xloc .>= -ε) && sum(xloc) <= 1 + ε if all(xloc .>= -ε) && sum(xloc) <= 1 + ε
out[fcolon..., I] .= evaluate(f, xloc) # use view here to handle scalar data assigment as well
view(out, fcolon..., I) .= evaluate(f, xloc)
end end
end end
end end
... ...
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment