what is the equivalent matlab function for the operator || || ?

10 visualizaciones (últimos 30 días)
mari pavithra
mari pavithra el 14 de Mzo. de 2015
Editada: Andrew Newell el 14 de Mzo. de 2015
I am having an expression r=||x-Ab|| which I have to convert it into a matlab code.But i have no idea what is this || || operator.can anyone tell me what does it mean and what is the equivalent matlab fuction for it.
  1 comentario
Geoff Hayes
Geoff Hayes el 14 de Mzo. de 2015
mari - please provide some context for this operator. What does it mean to you? What goes between the two pairs of vertical bars?

Iniciar sesión para comentar.

Respuesta aceptada

Andrew Newell
Andrew Newell el 14 de Mzo. de 2015
Editada: Andrew Newell el 14 de Mzo. de 2015
You're probably referring to the matrix norm, which is a generalization of the idea of "distance". The equivalent MATLAB function is norm. If there is no subscript on your operator symbol, it probably represents the 2-norm, which is the default for the MATLAB function. For your example, you could write
r = norm(x-A*b);
See also Operator norm.

Más respuestas (0)

Categorías

Más información sobre Migrate GUIDE Apps 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