0
$\begingroup$

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...

$\endgroup$
2
$\begingroup$
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

| improve this answer | |
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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