@@ -22,14 +22,6 @@ plot(x^2 - 2x, 0, 4)
22
22
```
23
23
24
24
25
- * `plot(exs::Vector{Sym}, a, b; kwargs...)` will plot the functions evaluating `exs` over [a,b]
26
-
27
- Example:
28
-
29
- ```
30
- @vars x
31
- plot([sin(x), cos(x)], 0, 2pi)
32
- ```
33
25
34
26
* `plot(ex1, ex2, a, b; kwargs...)` will plot the two expressions in a parametric plot over the interval `[a,b]`.
35
27
@@ -83,6 +75,14 @@ vfieldplot(fx, fy)
83
75
```
84
76
85
77
78
+ * To plot two or more functions at once, the style `plot([ex1, ex2], a, b)` does not work. Rather, use
79
+ `plot(ex1, a, b); plot!(ex2)`, as in:
80
+
81
+ ```
82
+ @vars x
83
+ plot(sin(x), 0, 2pi)
84
+ plot!(cos(x))
85
+ ```
86
86
----
87
87
88
88
Some graphics provided by `SymPy` are available if `PyPlot` is installed.
@@ -127,7 +127,9 @@ using RecipesBase
127
127
@recipe f {T<:Sym} (:: Type{T} , v:: T ) = lambdify (v)
128
128
129
129
# # for vectors of expressions
130
- @recipe f {S<:AbstractVector{Sym}} (:: Type{S} , ss:: S ) = Function[lambdify (s) for s in ss]
130
+ # # This does not work. See: https://github.com/JuliaPlots/RecipesBase.jl/issues/19
131
+ # @recipe f(ss::AbstractVector{Sym}) = lambdify.(ss)
132
+ # @recipe function f{T<:Array{Sym,1}}(::Type{T}, ss::T) Function[lambdify(s) for s in ss] end
131
133
132
134
# # A vector field plot can be visualized as an n × n collection of arrows
133
135
# # over the region xlims × ylims
0 commit comments