You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
julia> s = Fun(sin, [0., 7.]);
julia> c = Fun(cos, [0., 7.]);
julia> as = abs(s);
julia> ac = abs(c);
julia> ac+as;
ERROR: assertion failed: domainscompatible(a,b)
in conversion_rule at /Users/goretkin/.julia/v0.3/ApproxFun/src/Spaces/Ultraspherical/UltrasphericalOperators.jl:273
in maxspace at /Users/goretkin/.julia/v0.3/ApproxFun/src/Fun/FunctionSpace.jl:109
in maxspace at /Users/goretkin/.julia/v0.3/ApproxFun/src/Spaces/Modifier/VectorSpace.jl:149
in + at /Users/goretkin/.julia/v0.3/ApproxFun/src/Fun/Fun.jl:119
I think the point here is to add ac + as without recomputing the coefficients, though one stopgap could be to override the addition method on Fun{PiecewiseSpace} directly and compute Fun( (x)-> ac[x] + as[x], unique(merge_sorted(breaks(ac.space), breaks(as.space))))
The text was updated successfully, but these errors were encountered:
julia> ac+as;
ERROR: assertion failed: domainscompatible(a,b)
in conversion_rule at /Users/goretkin/.julia/v0.3/ApproxFun/src/Spaces/Ultraspherical/UltrasphericalOperators.jl:273
in maxspace at /Users/goretkin/.julia/v0.3/ApproxFun/src/Fun/FunctionSpace.jl:109
in maxspace at /Users/goretkin/.julia/v0.3/ApproxFun/src/Spaces/Modifier/VectorSpace.jl:149
in + at /Users/goretkin/.julia/v0.3/ApproxFun/src/Fun/Fun.jl:119
I spent a couple of hours trying to figure out how I should implement this but I don't know enough about ApproxFun. I put what I started in a gist https://gist.github.com/goretkin/5d4fb776b9ef09f4bd1fhttps://gist.github.com/goretkin/5d4fb776b9ef09f4bd1f
I think the point here is to add ac + as without recomputing the coefficients, though one stopgap could be to override the addition method on Fun{PiecewiseSpace} directly and compute Fun( (x)-> ac[x] + as[x], unique(merge_sorted(breaks(ac.space), breaks(as.space))))
—
Reply to this email directly or view it on GitHub #45.
I spent a couple of hours trying to figure out how I should implement this but I don't know enough about ApproxFun. I put what I started in a gist https://gist.github.com/goretkin/5d4fb776b9ef09f4bd1f
I think the point here is to add
ac + as
without recomputing the coefficients, though one stopgap could be to override the addition method onFun{PiecewiseSpace}
directly and computeFun( (x)-> ac[x] + as[x], unique(merge_sorted(breaks(ac.space), breaks(as.space))))
The text was updated successfully, but these errors were encountered: