Fractals/Mathematics/Derivative


notationEdit

  • variable z
  • constant parameter c
  • function f
  • derivative d
  • iteration number p
  • wrt = with respect to

Notation types[5]

  • Leibniz's notation
  • Euler's notation
  • Newton's notation ( dot notation)
  • Lagrange's notation ( prime mark notation)


 

Derivative of the iterated functionEdit

  "the derivative basically as it's calculated for anlytical DE using the implementation of the chain rule for the derivative of f(g(x)) where f(x) is say g(x)^p+c and the value of g(x) is current z. So f'(g(x)) is p*z^(p-1)  and g'(x) is the derivative from the previous iteration,  so on each iteration the new derivative is:  dz = dz*p*z^(p-1)  and new z = z^p+c as normal" FractalDave[6]
// initial values:
z = z
d = 1


// Recurrence steps: 
d = f'(z)*d   // calculating d and multiply the previous d
z = f(z)       // forward iteration


It can be computed with Maxima CAS :

display2d:false;
f:1/(z^3+d*z);
dz : diff(f,z,1); // first derivative of f wrt variable z 
dc :  diff(f,c,1); // first derivative of f wrt parameter c



Rational functionEdit

  
  

degree 3Edit

wrt z


// function 
f(z)= 1/(z^3 + c*z )

// first derivativwe wrt z
d = f'(z) = -(3z^2 +c)/(z^3 + cz)^2

// iteration:
z_(n+1) = f(z_n)


// initial values:
z = z
d = 1

// Recurrence steps:
d = - d*(3z^2 +c)/(z^3 + cz)^2
z = 1/(z^3 + c*z) 


degree 5Edit

 
Julia set f(z)=1 over az5+z3+bz
display2d:false;
f: 1/(a*z^5+ z^3 + b*z);
dz: diff(f,z,1);



in plain text:

  dz = -(5*a*z^4+3*z^2+b)/(a*z^5+z^3+b*z)^2


Example:

  • 1/((0.15*I+0.15)*z^5+(3*I-3)*z + z^3)


degree 5 by BuschmannEdit

 
Julia set drawn by distance estimation, the iteration is of the form   in black and white
f(z):=z^5/(4*z+2)-z^2+c+1

(%i4) diff(f(z), z,1);

(%o4) (5*z^4)/(4*z+2)-(4*z^5)/(4*z+2)^2-2*z

PolynomialsEdit

Complex quadratic polynomialEdit

z^2+cEdit
First derivative wrt cEdit

On parameter plane :

  •   is a variable
  •   is constant
 

This derivative can be found by iteration starting with

 
 

and then ( compute derivative before next z because it uses previous values of z):

 
 


This can be verified by using the chain rule for the derivative.


 
  • Maxima CAS function :


dcfn(p, z, c) :=
  if p=0 then 1
  else 2*fn(p-1,z,c)*dcfn(p-1, z, c)+1;

Example values :

 
 
 


It can be used for:

  • the distance estimation method for drawing a Mandelbrot set ( DEM/M )
First derivative wrt zEdit

  is first derivative with respect to z.

This derivative can be found by iteration starting with

 
 

and then :

 
 



description arbitrary name formula Initial conditions Recurrence step common names
iterated complex quadratic polynomial         z or f
first derivative with respect to z         dz, d (from derivative) or p ( from prime) of f'


Derivation of recurrence relation:


 

 


 

 

Following the derivative

"As we iterate z, we can look at the derivatives of P at z. In our case it is quite simple: P′(z)=2z. Multiplying all these numbers along an orbit yields the derivative at z of the composition Pn. This multiplication can be carried on iteratively as we iterate z " A Cheritat
 der = 1
 z = c # note that we start with c instead of 0, to avoid multiplying the derivative by 0
 for n in range(0,N):
   new_z = z*z+c
   new_der = der*2*z
   z = new_z
   der = new_der


It can be used for :

unsigned char ComputeColorOfDEMJ(complex double z){
// https://en.wikibooks.org/wiki/Fractals/Iterations_in_the_complex_plane/Julia_set#DEM.2FJ


  int nMax = iterMax;
  complex double dz = 1.0; //  is first derivative with respect to z.
  double distance;
  double cabsz;
	
  int n;

  for (n=0; n < nMax; n++){ //forward iteration

    if (cabs(z)> 1e60 || cabs(dz)> 1e60) break; // big values
    
  			
    dz = 2.0*z * dz; 
    z = z*z +c ; /* forward iteration : complex quadratic polynomial */ 
  }
  
  cabsz = cabs(z);
  distance = 2.0 * cabsz* log(cabsz)/ cabs(dz);
  if (distance <distanceMax) {//printf(" distance = %f \n", distance); 
  		return iColorOfBoundary;}
  
  
  return iColorOfExterior;
}
logistic mapEdit

Logistic map[8]

complex cubic polynomialEdit

wrt zEdit
 
Julia set for f(z) = z^3 +z*(0.1008317508132964*i + 1.004954206930806)
// function 
f(z)= z^3 + c*z 

// first derivativwe wrt z
d = f'(z) = 3*z^2 + c

// iteration:
z_(n+1) = f(z_n)


// initial values:
z = z
d = 1

// Recurrence steps:
d = (3*z^2 + c)*d
z = z^3 + c*z 


FAQEdit

  • why new d must be computed before new z ? [9]


AplicationsEdit

See alsoEdit

  • automatic differentiation[10]

ReferencesEdit

  1. mathoverflow question : whats-a-natural-candidate-for-an-analytic-function-that-interpolates-the-tower/43003
  2. Faa di Bruno and derivatives of an iterated function ON MAY 20, 2017 BY DCHOYLE
  3. A Cheritat wiki : Mandelbrot_set - Following_the_derivative
  4. fractalforums.org: period-detection
  5. Notation_for_differentiation in wikipedia
  6. fractalforums.org : all-periodic-bulbs-as-point-attractors
  7. A Cheritat wiki  : Mandelbrot_set - Interior_detection_methods
  8. Fractalforums.org : exterior-distance-estimation-for-logistic-map
  9. Following_the_derivative by Arnaud Cheritat
  10. Automatic_differentiation in wikipedia