Région de recherche :

Date :

https://fr.mathworks.com › help › matlab › ref › double.round.html

Round to nearest decimal or integer - MATLAB - MathWorks

Y = round(X) rounds each element of X to the nearest integer. In the case of a tie, where an element has a fractional part of 0.5 (within roundoff error) in decimal, the round function rounds away from zero to the nearest integer with larger magnitude. example.

https://www.developpez.net › forums › d338434 › environnements-developpement › matlab › arrondir...

Comment arrondir un résultat à un certain nombre de chiffres ...

a=round (200*a)/200. Disons que tu veuilles arrondur au 1/1000 près (0.001), alors : a=round (1000*a)/1000. D'où la formule citée. Bref, lorsqu'on veut uniquement arrondir à un certain nombre de chiffres après la virgule, alors la formule est celle citée.

https://www.delftstack.com › fr › howto › matlab › matlab-round-number

Numéro rond dans Matlab - Delft Stack

Arrondir un nombre à l’aide de la fonction round() dans MATLAB. Si vous souhaitez arrondir un nombre à l’entier le plus proche ou obtenir le nombre de décimales souhaité, vous pouvez utiliser la fonction round(). Par exemple, arrondissons un nombre à virgule flottante ayant 5 décimales à 2 décimales.

https://www.mathworks.com › matlabcentral › answers › 168478

Round down and Round up? - MATLAB Answers - MATLAB Central - MathWorks

In MATLAB, the functions "floor" and "ceil" can be used to round down and round up, respectively. The "floor" function rounds a given input value down to the nearest integer. For example, "floor(3.7)" would return 3, and "floor(-2.3)" would return -3.

https://stackoverflow.com › questions › 15639655

math - Rounding off to nearest 0.5 in matlab - Stack Overflow

If you go the multiply by 2 - round - divide by 2 route, you may get some (very small) numerical errors. You can do it using mod to avoid this: x = 16.625; dist = mod(x, 0.5); floorVal = x - dist; newVal = floorVal; if dist >= 0.25, newVal = newVal + 0.5; end.

https://fr.mathworks.com › matlabcentral › answers › 37262-how-to-round-the-decimals

How to round the decimals? - MATLAB Answers - MATLAB Central - MathWorks

As of release R2014b you can use the round function in MATLAB to round to a specific number of decimal places.

https://fr.cyberaxe.org › article › round-function-in-matlab

Fonction ronde dans Matlab | Cyberaxe

Dans cet article, nous utilisons des exemples pratiques pour vous montrer comment utiliser cette fonction dans ses différents modes d'arrondi. Nous détaillons également les principales fonctions de Round et les types de données pris en charge pour chaque entrée.

https://www.developpez.net › forums › d918403 › environnements-developpement › matlab › arrondi...

Arrondi à l'entier inférieur ? - MATLAB - Developpez.com

Bonjour, je suis en train de programmer et je recherche une fonction ou une astuce me permettant d'arrondir un chiffre à l'entier inférieur, connaissez vous une fonction ou astuce ? 0 0. 04/05/2010, 17h57 #2. Merel. Membre éclairé.

https://fr.mathworks.com › help › matlab › ref › mod.html

Reste d’une division (opération modulo) - MATLAB - MathWorks

b = mod(a,m) renvoie le reste d’une division de a par m, où a est le dividende et m le diviseur. Cette fonction, souvent appelée « opération modulo », peut être exprimée ainsi : b = a - m.*floor(a./m). La fonction mod suit la convention selon laquelle mod(a,0) renvoie a. exemple.