Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <h2>The complete solution for Mathematica 7.0.1: fixing bugs</h2> <p><strong>The code with comments:</strong></p> <pre><code>(*controls the resolution of rasterized graphics*) magnification = 5; SetOptions[$FrontEnd, PrintingStyleEnvironment -&gt; "Working"] (*Turn off history for saving memory*) $HistoryLength = 0; (*Epilog will give us the bounding box of the graphics*) g1 = Plot3D[Sin[x y], {x, 0, Pi}, {y, 0, Pi}, AlignmentPoint -&gt; Center, AspectRatio -&gt; 0.925, Axes -&gt; {True, True, True}, AxesEdge -&gt; {{-1, -1}, {1, -1}, {-1, -1}}, BaseStyle -&gt; {FontFamily -&gt; "Arial", FontSize -&gt; 12}, Boxed -&gt; False, BoxRatios -&gt; {3, 3, 1}, LabelStyle -&gt; Directive[Black], ImagePadding -&gt; All, ImageSize -&gt; 5*72, PlotRange -&gt; All, PlotRangePadding -&gt; None, TicksStyle -&gt; Directive[10], ViewPoint -&gt; {2, -2, 2}, ViewVertical -&gt; {0, 0, 1}, AxesStyle -&gt; Directive[Opacity[0]], FaceGrids -&gt; {{-1, 0, 0}, {0, 1, 0}}, Mesh -&gt; None, ImagePadding -&gt; 40, Epilog -&gt; {Red, AbsoluteThickness[1], Line[{ImageScaled[{0, 0}], ImageScaled[{0, 1}], ImageScaled[{1, 1}], ImageScaled[{1, 0}], ImageScaled[{0, 0}]}]}]; (*The options list should NOT contain ImagePadding-&gt;Full.Even it is \ before ImagePadding-&gt;40 it is not replaced by the latter-another bug!*) axes = Graphics3D[{Opacity[0], Point[PlotRange /. AbsoluteOptions[g1] // Transpose]}, AlignmentPoint -&gt; Center, AspectRatio -&gt; 0.925, Axes -&gt; {True, True, True}, AxesEdge -&gt; {{-1, -1}, {1, -1}, {-1, -1}}, AxesStyle -&gt; Directive[10, Black], BaseStyle -&gt; {FontFamily -&gt; "Arial", FontSize -&gt; 12}, Boxed -&gt; False, BoxRatios -&gt; {3, 3, 1}, LabelStyle -&gt; Directive[Black], ImageSize -&gt; 5*72, PlotRange -&gt; All, PlotRangePadding -&gt; None, TicksStyle -&gt; Directive[10], ViewPoint -&gt; {2, -2, 2}, ViewVertical -&gt; {0, 0, 1}, ImagePadding -&gt; 40, Epilog -&gt; {Red, AbsoluteThickness[1], Line[{ImageScaled[{0, 0}], ImageScaled[{0, 1}], ImageScaled[{1, 1}], ImageScaled[{1, 0}], ImageScaled[{0, 0}]}]}]; (*fixing bug with ImagePadding loosed when specifyed as option in \ Plot3D*) g1 = AppendTo[g1, ImagePadding -&gt; 40]; (*Increasing ImageSize without damage.Explicit setting for \ ImagePadding is important (due to a bug in behavior of \ ImagePadding-&gt;Full)!*) g1 = Magnify[g1, magnification]; g2 = Rasterize[g1, Background -&gt; None]; (*Fixing bug with non-working option Background-&gt;None when graphics \ is Magnifyed*) g2 = g2 /. {255, 255, 255, 255} -&gt; {0, 0, 0, 0}; (*Fixing bug with icorrect exporting of Ticks in PDF when Graphics3D \ and 2D Raster are combined*) axes = First@ImportString[ExportString[axes, "PDF"], "PDF"]; (*Getting explicid ImageSize of graphics imported form PDF*) imageSize = Last@Transpose[{First@#, Last@#} &amp; /@ Sort /@ Transpose@ First@Cases[axes, Style[{Line[x_]}, ___, RGBColor[1.`, 0.`, 0.`, 1.`], ___] :&gt; x, Infinity]] (*combining Graphics3D and Graphics*) result = Show[axes, Epilog -&gt; Inset[g2, {0, 0}, {0, 0}, imageSize]] Export["C:\\result.pdf", result] </code></pre> <p>Here is what I see in the Notebook:</p> <p><img src="https://i.stack.imgur.com/BQmrT.png" alt="screenshot"></p> <p>And here is what I get in the PDF:</p> <p><img src="https://i.stack.imgur.com/PLG3l.png" alt="screenshot"></p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload