how do i generate vector

2 visualizaciones (últimos 30 días)
Marek Endrizal
Marek Endrizal el 21 de Oct. de 2020
Respondida: Ameer Hamza el 21 de Oct. de 2020
hi... how do i generate 2, 6, 5, 3, vectors? in that order
  2 comentarios
Walter Roberson
Walter Roberson el 21 de Oct. de 2020
Do you mean that you need to run a calculation that gives you that vector as a result? If so then typically those assignments restrict the operations that are permitted?
KSSV
KSSV el 21 de Oct. de 2020
A = [2 6 5 3] ;

Iniciar sesión para comentar.

Respuestas (1)

Ameer Hamza
Ameer Hamza el 21 de Oct. de 2020
A slightly unusual way, but it fulfills the requirement
fun = @(x) round(sin(-0.688014*x + 3.625700) .* exp(-0.367642*x) .* log(2609741*x));
y = fun(1:4)
Result
>> y
y =
2 6 5 3

Categorías

Más información sobre Octave en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by