MandelbrotSetMemberQ
Details and Options
- The Mandelbrot set is the set of all complex numbers
for which the sequence
does not diverge to infinity when starting with
. - MandelbrotSetMemberQ takes the following options:
-
MaxIterations 1000 maximum number of iterations to use WorkingPrecision Automatic the precision used in internal computations - With the option MaxIterations->n, the sequence
will be iterated at most n times to determine if the sequence diverges. - The default setting is MaxIterations->1000.
- If the maximum number of iterations is reached, z is assumed to be in the Mandelbrot set.
Examples
open all close allBasic Examples (3)
Test whether
is a member of the Mandelbrot set:
MandelbrotSetMemberQ[1 + I]Zero is known to be inside the Mandelbrot set:
MandelbrotSetMemberQ[0]It takes a few hundred iterations to determine that 0.2501 is not in the Mandelbrot set:
MandelbrotSetMemberQ[0.2501, MaxIterations -> 250]MandelbrotSetMemberQ[0.2501, MaxIterations -> 500]Scope (2)
MandelbrotSetMemberQ threads itself element-wise over lists:
MandelbrotSetMemberQ[{0 , 1, I / 2, I + 1}]MandelbrotSetMemberQ works on all kinds of numbers:
Quiet[MandelbrotSetMemberQ[{0, -2, -1.979, -2.9`2, 1 / 4, 0.26, I, 1 + I, -1 / Pi, N[1 / Pi, 200]}]]Options (2)
MaxIterations (1)
Sometimes MaxIterations needs to be increased to eliminate false positives:
{MandelbrotSetMemberQ[0.250005, MaxIterations -> 1000],
MandelbrotSetMemberQ[0.250005, MaxIterations -> 2000]}WorkingPrecision (1)
Using a lower WorkingPrecision can cause false positives:
{MandelbrotSetMemberQ[25001 / 100000, WorkingPrecision -> 5], MandelbrotSetMemberQ[25001 / 100000, WorkingPrecision -> 6]}Applications (2)
Generate the Mandelbrot set from randomly chosen points:
ListPlot[{Re[#], Im[#]}& /@ Quiet@Select[Table[4 * (RandomReal[] + RandomReal[] * I) - (2 + 2I), {30000}], MandelbrotSetMemberQ]]Approximate the first point along the line
that is not in the Mandelbrot set:
x = 0;
Quiet[While[MandelbrotSetMemberQ[x + x * I], x = x + .00001]];
xShow the point on the Mandelbrot set:
MandelbrotSetPlot[Epilog -> {Red, Line[{{0, 0}, {x, x}}], PointSize[Large], Point[{x, x}]}]Possible Issues (1)
With MaxIterations->Infinity, the calculation may not converge in a finite number of steps:
TimeConstrained[MandelbrotSetMemberQ[.25 + 10 ^ -13, MaxIterations -> Infinity], 1]Neat Examples (4)
MandelbrotSetMemberQ can be used to get an estimate of the area of the Mandelbrot set:
NIntegrate[Boole[MandelbrotSetMemberQ[x + I * y, MaxIterations -> 10000]],
{x, -2, 0.6}, {y, -1.3, 1.3},
Method -> {"MonteCarlo", RandomSeed -> 1}]Display the Julia sets for points in the Mandelbrot set:
GraphicsGrid[Table[If[Quiet[MandelbrotSetMemberQ[x + I y]], JuliaSetPlot[x + I y, Method -> "EscapeTime", Frame -> False], ""], {y, -1, 1, .2}, {x, -1.5, .5, .2}]]dat2 = Quiet[Select[Flatten[Table[{x, y}, {x, -2, .5, .03}, {y, -1, 1, .03}], 1], MandelbrotSetMemberQ[#[[1]] + I #[[2]], MaxIterations -> 44]&]];ListPointPlot3D[Flatten[Table[{#[[1]], #[[2]] Cos[t], #[[2]] Sin[t]}, {t, 0, Pi, .1}]& /@ dat2, 1], BoxRatios -> {1, 1, 1}, ColorFunction -> "Rainbow", PlotStyle -> Specularity[White, 0], Lighting -> {{"Directional", White, {{0, 0, 1}, {0, 0, 0}}}}]Use MandelbrotSetMemberQ to distinguish Julia sets that are Cantor sets:
GraphicsGrid[Table[JuliaSetPlot[r Exp[ξ Pi I], Frame -> False, Method -> If[Quiet@MandelbrotSetMemberQ[r Exp[ξ Pi I]], "OrbitDetection", "InverseIteration"]], {ξ, 0, 1, 1 / 6}, {r, .2, 1.8, .4}], ImageSize -> 200]Related Guides
History
Text
Wolfram Research (2014), MandelbrotSetMemberQ, Wolfram Language function, https://reference.wolfram.com/language/ref/MandelbrotSetMemberQ.html.
CMS
Wolfram Language. 2014. "MandelbrotSetMemberQ." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/MandelbrotSetMemberQ.html.
APA
Wolfram Language. (2014). MandelbrotSetMemberQ. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/MandelbrotSetMemberQ.html
BibTeX
@misc{reference.wolfram_2026_mandelbrotsetmemberq, author="Wolfram Research", title="{MandelbrotSetMemberQ}", year="2014", howpublished="\url{https://reference.wolfram.com/language/ref/MandelbrotSetMemberQ.html}", note=[Accessed: 13-June-2026]}
BibLaTeX
@online{reference.wolfram_2026_mandelbrotsetmemberq, organization={Wolfram Research}, title={MandelbrotSetMemberQ}, year={2014}, url={https://reference.wolfram.com/language/ref/MandelbrotSetMemberQ.html}, note=[Accessed: 13-June-2026]}