0
$\begingroup$

I am trying to plot the function $(-2(\alpha-1)/\alpha)^{(-2(\alpha+2)/\alpha)}$ in maple, but I got the following warning

plot( (-2*(alpha-1)/alpha)^(-2*(alpha+2)/alpha) ,alpha=5..10);

Warning, unable to evaluate the function to numeric values in the region; complex values were detected.

Actually the function have real values as roots but maple does not plot the values.

How do I plot it?

2 Answers 2

0

You claim that the expression has real values as roots. However, $$ \frac {-2(a-1)}a = \frac{2(1-a)}a < 0 $$ for $a > 1$ and thus especially for $a \in [5,10]$. I am quite unconvinced that your expression is real for all values of $a\in [5,10]$ and a simple check agrees with this suspicion;

seq((-2*(a-1)/a)^(-2*(a+2)/a),a = 5..10, 1):
evalf(%,2);

$- 0.21- 0.16\,i,- 0.13- 0.23\,i,- 0.056- 0.24\,i,- 0.24\,i, 0.044- 0.24\,i, 0.078- 0.23\,i$

Instead, try the complexplot command in the plots package, which hints that your expression may be complex for all values of $a\in[5,10]$.

plots:-complexplot((-2*(a-1)/a)^(-2*(a+2)/a),a = 5..10);

Complexplot of expression

  • 0
    But you have forgotten that the power has two factor. Then as an axample (-3)^(2x) can be written as 9^x and we can plot it.2017-02-07
  • 0
    Maple has a programming problem to give the roots. (-1)^(1/3) has three roots one of them real and the others complex. Maple thinks the complex roots and does not draw the graph. This is the main problem.2017-02-07
0

Extending @Therkel response.

If you want to plot only the real part then you can do it like this,

restart:with(plots):
plot( Re((-2*(alpha-1)/alpha)^(-2*(alpha+2)/alpha)),alpha=5..50,axes=boxed,color=red);

enter image description here

  • 0
    Actually Re takes real part only. I want to plot real roots, not real part of complex roots. I think maple has a programming problem for the cases.2017-02-07