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 have the following mapping on the complex plane: $$ z \mapsto \tau \mu z-1, $$ where $\mu$ is complex, $\tau$ is real number. I want to draw the image of left unit semidisk and play with $\tau$.

μ = 0.16255558520216132` + 0.1849493244071408` I;

pic[τ_] := Block[{d, ds},
   d = Disk[{0, 0}, 1, {π/2, 3 π/2}];
   ds =
    Fold[GeometricTransformation, d,
       {RotationTransform[Arg@#, {0, 0}],
        ScalingTransform[τ Abs@# {1, 1}],
        TranslationTransform[{-1, 0}]
        }] & @ μ;
   Graphics@{Gray, d, Red, Opacity[.5], ds}
   ];

Manipulate[
 Dynamic@Show[pic[τ], Frame -> True, Axes -> True, 
   AxesOrigin -> {0, 0}, PlotRange -> zz {{-100, 100}, {-100, 100}},
   ImageSize -> 400
   ],
 {τ, 0.01, 1000, 0.01},
 {zz, 0.01, 10, 0.01}
 ]

Here zz is introduced to control zooming. The problem is that I get different (wrong) images for different zooms. It is clearly seen for big $\tau$'s.

enter image description hereenter image description hereenter image description here

It looks very like a bug, but I can not rule out that I'm making some silly mistake (Mathematica 8.0.4). So, what is the problem here and what is the best way of doing the job (I have several mappings for different $\mu$ actually)?

share|improve this question
1  
I'd have implemented pic[] this way: pic[τ_] := Block[{d, ds}, d = Disk[{0, 0}, 1, {π/2, 3 π/2}]; ds = GeometricTransformation[d, Composition[TranslationTransform[{-1, 0}], ScalingTransform[τ Abs[μ] {1, 1}], RotationTransform[Arg[μ], {0, 0}]]]; Graphics @ {Gray, d, Red, Opacity[.5], ds}] –  J. M. Aug 17 '12 at 17:24
3  
Here's another way to visualize your transformation of a disk: ParametricPlot[Through[{Re, Im}[τ μ r Exp[I θ] - 1]], {r, 0, 1}, {θ, π/2, 3 π/2}]] –  J. M. Aug 17 '12 at 17:38
    
@J.M. thank you very much! Unfortunately Composition produces the same erroneous result. ParametricPlot is a viable alternative. Still the problem with composite GeometricTransformations remains. –  faleichik Aug 17 '12 at 20:18
2  
Minimal example of the problem: Evaluate Graphics@GeometricTransformation[Disk[],Composition[ScalingTransform[{800,800}]‌​,RotationTransform[0.1,{0,0}]]] and resize the graphic with the mouse. –  Simon Woods Aug 17 '12 at 21:41
1  
You can apply the transformations beforehand to the key-coordinates of the disk, which transforms Disk[{0, 0}, 1, {α, β}] to Disk[{-1, 0}, τ Abs[μ], {α, β} + Arg[μ]]. This explicit form will work fine with Graphics. –  Silvia Aug 18 '12 at 17:57
show 2 more comments

Your Answer

 
discard

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

Browse other questions tagged or ask your own question.