Scilab Website | Contribute with GitLab | Mailing list archives | ATOMS toolboxes
Scilab Online Help
6.0.2 - Português

Change language to:
English - Français - 日本語 - Русский

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

Ajuda do Scilab >> Funções Elementares > Ponto flutuante > nearfloat

nearfloat

get previous or next floating-point number

Seqüência de Chamamento

xnear = nearfloat(dir, x)

Parâmetros

dir

string ("succ" ou "pred")

x

escalar real, vetor ou matriz de reais

xnear

escalar real, vetor ou matriz de reais

Descrição

Esta função computa, elemento a elemento, os vizinhos correspondentes dos elementos de x (no conjunto de pontos flutuantes subjacente, ver number_properties), os sucessores se dir = "succ" e e os predecessores se dir = "pred"

Exemplos

format("e",22)
nearfloat("succ",1) - 1
1 - nearfloat("pred",1)
format("v") //retoma o formato padrão

Ver Também

  • number_properties — determina parâmetros de ponto flutuante
  • frexp — separa um número em ponto flutuante em potência de base 2 e mantissa
Report an issue
<< isnan Ponto flutuante nextpow2 >>

Copyright (c) 2022-2023 (Dassault Systèmes)
Copyright (c) 2017-2022 (ESI Group)
Copyright (c) 2011-2017 (Scilab Enterprises)
Copyright (c) 1989-2012 (INRIA)
Copyright (c) 1989-2007 (ENPC)
with contributors
Last updated:
Thu Feb 14 15:00:39 CET 2019