From a468544d39ef18c6e47fd59cf427a4e25fe22b7f Mon Sep 17 00:00:00 2001 From: bremner Date: Fri, 21 Apr 2006 17:39:32 +0000 Subject: cvs to svn conversion script git-svn-id: file:///export/data/bremner/svn/trunk/inetools@2344 09fa754a-f411-0410-976a-da6bfa213b30 --- float2rat.ds | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 float2rat.ds (limited to 'float2rat.ds') diff --git a/float2rat.ds b/float2rat.ds new file mode 100644 index 0000000..209eec8 --- /dev/null +++ b/float2rat.ds @@ -0,0 +1,11 @@ +#define DOCSTRING "\n\ +$Id$\n\ +\n\ +Converts floating point coefficent $f$ to rational by the \n\ +simple expedient of outputing 10^k*f/10^k for appropriate \n\ +$k$. Does no reduction of numbers. In particular this may cause overflow in \n\ +old versions of lrs input (and I'm not about cdd).\n\ +" + +int usage(){ fprintf(stderr,"\n%s\n",rcsid);fprintf(stderr,DOCSTRING); exit(1); } +#define CHECK_HELP if (argc > 1 && argv[1][0]=='-' && argv[1][1]=='h') usage(); -- cgit v1.2.3