janhardo

695 Reputation

12 Badges

11 years, 40 days

MaplePrimes Activity


These are questions asked by janhardo

  • How to get the ln(z) 3d plot example in the FunctionAdvisor /plot ?
  • a table plot, to show different plots together 

 

Some more difficult calculation with complex numbers

Starting from the equation     
A = arctan(z/b)/b and arctan(z/b)/b = int(1/(b^2+z^2), z = 0 .. z)
made the substitution                               
z = i*b(t-1)/(t+1)
Thus obtaining NULL
A = -(int(1/t, t = 1 .. t))/(2*bi) and -(int(1/t, t = 1 .. t))/(2*bi) = log[10](t)/(2*bi) and log[10](t)/(2*bi) = log[10]((b*i+z)/(b*i-z))/(2*bi)
One of the important relations between logarithms and inverse trigonometrische functions

Download logaritmisc_functie_betrekking_goniometrische_functie.mw

I am studying something about complex numbers. 

What commands are specific to find in Maple for complex numbers ?

  • complexplot()
  • conformal()
  • conformal3d()

It seems that there are a lot of standard calculus statements can be used by adding the word : complex 
Iam using here a package downloaded from Maple website : complex analysis for mathematics and engineering

Got the impression that some modern plot commands for complex numbers are not yet in this book present ..and how about other commands?

an_introduction_to_complex_numbers.mws

How to add any/many subprocedure in a mainprocedure?
Somehow the mainprocedure must deliver the input for the mainprocedure

Here is a example 

Note: probably can this old procedure be rewritten in modern Maple programming language ?  

restart;

 

Code to Find the Max and Min Values in a List A

 

maxmin:=proc(A,maxv::evaln,minv::evaln)

   local i;

   maxv:=A[1]; minv:=A[1];

   for i from 2 to nops(A) do

     if eval(maxv) < A[i] then maxv:=A[i] end if;

     if eval(minv) > A[i] then minv:=A[i] end if;

   end do;

   RETURN()

end proc:

 

Now we can call the maxmin procedure from a procedure named optimize, which is designed to create the polygonal approximation, use maxmin to find the largest and smallest y-values from among the vertices, and produce some graphic output.

See the documentation in the book.

 

Code to Approximate the Max and Min Values of a Function  f :

 

optimize:=proc(f,a,b,N,pic::evaln)

  local X,Y,L,i,A,xmax,xmin;

  X:=array(0..N);Y:=array(0..N);L:=array(0..N);

  with(plots,display);

  for i from 0 to N do

    X[i]:=evalf(a+i*(b-a)/N);

    Y[i]:=f(X[i]);

    L[i]:=plot([[X[i],0],[X[i],Y[i]]],color=black):

  end do;

  A:=[seq(Y[i-1],i=1..N+1)];

  maxmin(A,maxv,minv); # USE OF SECOND PROCEDURE --------------

  xmax:={};xmin:={};

  for i from 0 to N do

    if Y[i]=maxv then xmax:=xmax union {X[i]} end if;

    if Y[i]=minv then xmin:=xmin union {X[i]} end if;

  end do; #----------------------------------------------------

  pic:=display({seq(L[i],i=1..N)}):

  print(`maximum y value is`,maxv,`and occurs at these x values`,xmax);

  print(`minimum y value is`,minv,`and occurs at these x values`,xmin);

  end proc:

 

Note that you must execute the code that defines maxmin before the procedure optimize will work. This only make sense.

 

We test the optimize procedure with the following function

 

f:=x->3+10*(-x^2+x^4)*exp(-x^2);

proc (x) options operator, arrow; 3+10*(-x^2+x^4)*exp(-x^2) end proc

(1)

on the interval [-1, 4].

 

optimize(f,-1,4,150,pic);

`maximum y value is`, 6.088066652, `and occurs at these x values`, {1.633333333}

 

`minimum y value is`, 1.391538737, `and occurs at these x values`, {-.6333333333, .6333333333}

(2)

pic;

 

 

Download procedure_en_subprocedures.mw

restart;

f:=(x,y)->x^4-3*x^2-2*y^3+3*y+0.5*x*y;

proc (x, y) options operator, arrow; x^4-3*x^2-2*y^3+3*y+.5*y*x end proc

(1)

 

Critical points: tangentline in x direction and y direction are  0  for some points on the surface  f(x,y)  

 

CriticalPoints:= [ solve( {diff(f(x,y),x)=0,diff(f(x,y),y)=0}, {x,y}) ];

[{x = 0.5935572277e-1, y = .7105957432}, {x = 1.191117672, y = .7741187286}, {x = 1.255942703, y = -.7776000848}, {x = -0.5877159444e-1, y = -.7036351094}, {x = -1.197482099, y = -.6326213916}, {x = -1.250162405, y = .6291421140}]

(2)

         

Seems that maple calculate 6 points on the surface with a default domain?

let me make a  3D plot of f  ( not specifying the domain values)

plot3d(f);

 

 

I calculated 6 critical points :how to show them in the plot? : i calculate the functionvalues for f
So now i do have x,y,z values for a 3D point
plot3D ({ f, points}) ?

?student

 

Some information to find in

• 

 Student[MultivariateCalculus]  ..link?

• 

Multivariate Calculus Study Guide

In order to make a procedure ( to make it general) out of the wanted calculated steps , i must first calculate these steps
List of wanted steps:

1. 

calculate (6 )critical points : i did

2. 

investigate of the found critical points :are there saddle points among them?
Show this in a table

3. 

show a critical point with 2 section lines in this critical point intersected in a plot

4. 

show these critical points in a plot

===========================================

How to make table out of this list.CriticalPoints. for easy reading.?

==========================================

CriticalPoints:= [ solve( {diff(f(x,y),x)=0,diff(f(x,y),y)=0}, {x,y}) ];

[{x = 0.5935572277e-1, y = .7105957432}, {x = 1.191117672, y = .7741187286}, {x = 1.255942703, y = -.7776000848}, {x = -0.5877159444e-1, y = -.7036351094}, {x = -1.197482099, y = -.6326213916}, {x = -1.250162405, y = .6291421140}]

(3)

 

Download zadelpunten_procedure.mw

First 7 8 9 10 11 12 13 Last Page 9 of 22