MATLAB Answers

What does Sel do in this code?

4 views (last 30 days)
Hey all, I am a chemical engineering student researching how to model a distillation column. I have a found a code that does this, but I'm not sure what's happening in it.
[t,x]=ode15s('cola_lv',[0 20000],0.5*ones(1,82)');
Xinit = x(sel(size(x),1,1),:)';
I understand everything here except this "sel" command. I've never heard of it in during my studies. What exactly is it doing? I also cannot seem to use this command in my version of Matlab (2020b). Is this a package command, and if so, where do I go to download it?

  1 Comment

KSSV
KSSV on 27 Oct 2020
From where you got this code?

Sign in to comment.

Accepted Answer

Walter Roberson
Walter Roberson on 27 Oct 2020
Very old MATLAB!
It looks to me as if is just doing indexing. I think it is equivalent of
Xinit = x(end,:).';

  0 Comments

Sign in to comment.

More Answers (0)

Tags

Products

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by