Type conversion error

Type conversion error - 消息

#1 已发布: 2020/5/13 08:30:08
Eugene

Eugene

0个赞,共7个帖子。

组: User

Does anyone know how to solve this error?

Capture.PNG
#2 已发布: 2020/5/13 11:18:01
Alvaro

Alvaro

1,139个赞,共1,805个帖子。

组: User

Hi. The error came from try to compare the vector time1 with the scalar T(1,1) in the first if. Maybe with the vectorization operator you can solve the issue, evaluating vectorize(rel(time1)).

Clipboard01.jpg

If not, you can try to modify the code with a loop for each element in the time1, like in this example:

Clipboard01.jpg

Best regards.
Alvaro.
1位用户喜欢此帖子
frapuano 2020/5/13 13:56:00
#3 已发布: 2020/5/14 03:33:37
Eugene

Eugene

0个赞,共7个帖子。

组: User

Thanks. First one didn't work. Will try to add a loop as you suggested.
#4 已发布: 2020/5/14 06:55:34
Jean Giraud

Jean Giraud

983个赞,共6,866个帖子。

组: User

Wrote

Thanks. First one didn't work. Will try to add a loop as you suggested.


From a complex vector.

for_Vector.PNG
#5 已发布: 2020/5/14 07:43:21
Davide Carpi

Davide Carpi

1,443个赞,共2,936个帖子。

组: Moderator

Also, you might use vectorize(rel(time1)) to apply the scalar function at each time1 value.
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
#6 已发布: 2020/5/14 15:22:11
Jean Giraud

Jean Giraud

983个赞,共6,866个帖子。

组: User

More in there as cumulative.

Vector Cumulative.sm (24.17 KiB)已下载 1109 次。
  • 有新帖
  • 无新帖