Scilab Home page | Wiki | Bug tracker | Forge | Mailing list archives | ATOMS | File exchange
Please login or create an account
Change language to: English - Português - Русский - 日本語

Please note that the recommended version of Scilab is 6.0.0. This page might be outdated.
See the recommended documentation of this function

Aide de Scilab >> Xcos > Fonctions utilitaires Scilab > vec2var

vec2var

Transform a vector of double in a scilab variable

Calling Sequence

[var]=vec2var(vec)

Module

Description

var2vec / vec2var functions are used inside the interfacing functions of Scilab blocks to give the possibility to the user to handle Scilab objects with the register of real parameters (rpar) and with the discrete state register (z).

[var]=vec2var(vec)

Arguments

  • vec : Input parameter. A vector of real numbers.

  • var : Output parameter. Can be any types of Scilab objects.

Example

-->a=list("cos",[1.1,2])
a  = 
a(1)
cos   
a(2)
1.1    2.  
-->b=var2vec(a)         
b  =
4.244-314  
1.273-313  
8.488-314  
2.122-314  
4.941-324  
8.488-314  
5.093-313  
2.122-314  
2.122-314  
9.881-324  
1.1        
2.         
-->c=vec2var(b)
c  =
c(1)
cos   
c(2)
1.1    2.
Scilab Enterprises
Copyright (c) 2011-2017 (Scilab Enterprises)
Copyright (c) 1989-2012 (INRIA)
Copyright (c) 1989-2007 (ENPC)
with contributors
Last updated:
Thu Oct 02 13:54:43 CEST 2014