summaryrefslogtreecommitdiff
path: root/src/auxiliaryFunctions/sign/dsigns.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/auxiliaryFunctions/sign/dsigns.c')
-rw-r--r--src/auxiliaryFunctions/sign/dsigns.c28
1 files changed, 16 insertions, 12 deletions
diff --git a/src/auxiliaryFunctions/sign/dsigns.c b/src/auxiliaryFunctions/sign/dsigns.c
index 99735e87..0715d537 100644
--- a/src/auxiliaryFunctions/sign/dsigns.c
+++ b/src/auxiliaryFunctions/sign/dsigns.c
@@ -1,20 +1,24 @@
/*
-** -*- C -*-
-**
-** ssigns.c
-** Made by Bruno JOFRET <bruno.jofret@inria.fr>
-**
-** Started on Thu Feb 8 10:26:22 2007 jofret
-** Last update Thu Feb 8 15:58:44 2007 jofret
-**
-** Copyright INRIA 2007
-*/
+ * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
+ * Copyright (C) 2007-2008 - INRIA - Bruno JOFRET
+ *
+ * This file must be used under the terms of the CeCILL.
+ * This source file is licensed as described in the file COPYING, which
+ * you should have received as part of this distribution. The terms
+ * are also available at
+ * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+ *
+ */
#include "sign.h"
int dsigns(double num) {
- if (num >= 0) {
+ if (num > 0) {
return 1;
}
- return -1;
+ if (num < 0) {
+ return -1;
+ }
+ /* num == 0 */
+ return 0;
}