Weird behavior of CAS and algebraic view

Masacroso shared this question 5 years ago
Needs Answer

We can plot a function from the reals to the complex plane using the command curve as I did here:

with the use of the commands real and imaginary. But you cant define a function in the algebraic view directly as

  1. f(x)=i^x

this is not accepted by the program. BUT you can define this function properly in the CAS view with

  1. f(x):= i^x

what is perfectly recognized and you can evaluate any value for f(x). The weird thing is that you cant call this function from a curve command like this

  1. curve[x,real(f(x)),imaginary(f(x)),x,-10,10]

But a similar code works in the algebraic view

  1. curve[x,real(i^x),imaginary(i^x),x,-10,10]

In resume: you can define complex functions in the CAS view perfectly but you cant call them in other view or cell for a parametric plot. By the other hand you cant define complex functions in the algebraic view but, unexpectedly, you can define complex functions inside of commands as curve.

There is a way to fix this behavior? Thank you.

© 2022 International GeoGebra Institute