[Scilab-users] [EXTERNAL] Re: submatrix issue

paul.carrico at free.fr paul.carrico at free.fr
Sun Jun 3 21:58:00 CEST 2018


Hi Rafael, 

Thanks for your interest,; I think I was wrong in my way of using 3
vectors at the same time, 

To answer to your question, the structure is 

N = Node number 

2/3 = number of coordinates (2 for 2D and 3 for 3D obviously) 

X 

Y 

(Z) if in 3D 

[same structure for all the nodes] 

Obviously I can use a loop, but vectorization is more efficient; I was
thinking on a generic code that works for all the configuration .. the
silmpliest way is to check since the beginning if we are in 3D or not,
and to add anorther line if necessary: 

- one vector to get the node number 

- one for X and one for Y 

if we are in 3D, then a new vector dealing to Z will be added 

I'll have a look on it tomorrow :-) 

Regards 

Paul 

Le 2018-06-03 15:56, Rafael Guerra a écrit :

> Paul, 
> 
> Does your input ASCII file have N-lines with 3-values on each row: 
> 
> X1 Y1 Z1 
> 
> X2 Y2 Z2 
> 
>> 
> or instead, does it have one value per row over Nx3 rows: 
> 
> X1 
> 
> Y1 
> 
> Z1 
> 
> X2 
> 
> Y2 
> 
> Z2 
> 
>> 
> ? 
> 
> Regards, 
> 
> Rafael 
> 
> _______________________________________________
> users mailing list
> users at lists.scilab.org
> http://lists.scilab.org/mailman/listinfo/users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.scilab.org/pipermail/users/attachments/20180603/cf3d45e6/attachment.htm>


More information about the users mailing list