Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

I'd like to have first a function plot and then the same plot repeated inside a Manipulate, with additional things (like tangent planes etc.). I can do

plot=Plot3D[<whatever>]

and then

Manipulate[Show[plot,<whatever>],...]

but there is one problem. I'd like to have the second plot semi-opaque, so that things are more visible.

My question is either (1) how to achieve this using my approach with plot=Plot3D[...], or (2) is there any better approach?

I've seen this question, but the first answer seemed too complicated (am I wrong?) and the second one didn't work for me...

share|improve this question
add comment

1 Answer 1

plot[opt : OptionsPattern[Plot]] := Plot[Sin@x, {x, 0, 2 Pi}, Filling -> Bottom, opt];
plot[]

Mathematica graphics

Manipulate[
 Show[
  plot[FillingStyle -> {Opacity[0.1]}, PlotStyle -> Directive[Red, Opacity[.3]]],
  Plot[ a x, {x, 0, 6}]], 
{a, 0.1, 1/6}]

Mathematica graphics

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.