From 8fdd2158ab7a122e9c72a7f41c8bac1a794cf53c Mon Sep 17 00:00:00 2001 From: Don Stewart Date: Tue, 10 Jun 2008 00:52:13 +0000 Subject: make empty lines with backslashes CPP friendly --- lib/Numeric/GSL/Matrix.hs | 2 +- lib/Numeric/GSL/Minimization.hs | 12 ++++++------ lib/Numeric/LinearAlgebra/Algorithms.hs | 4 ++-- 3 files changed, 9 insertions(+), 9 deletions(-) (limited to 'lib/Numeric') diff --git a/lib/Numeric/GSL/Matrix.hs b/lib/Numeric/GSL/Matrix.hs index acf4e77..370356f 100644 --- a/lib/Numeric/GSL/Matrix.hs +++ b/lib/Numeric/GSL/Matrix.hs @@ -299,7 +299,7 @@ L \* U obtains a permuted version of the original matrix: 2.+3.i -7. 0. 1. 2. -3. 1. -1.i 2.i -\ +\ -- CPP \> l \<\> u 2.+3.i -7. 0. 1. 2. -3. diff --git a/lib/Numeric/GSL/Minimization.hs b/lib/Numeric/GSL/Minimization.hs index 0a2d577..a1d009b 100644 --- a/lib/Numeric/GSL/Minimization.hs +++ b/lib/Numeric/GSL/Minimization.hs @@ -31,14 +31,14 @@ import Foreign.C.Types(CInt) {- | The method of Nelder and Mead, implemented by /gsl_multimin_fminimizer_nmsimplex/. The gradient of the function is not required. This is the example in the GSL manual: @minimize f xi = minimizeNMSimplex f xi (replicate (length xi) 1) 1e-2 100 -\ +\ -- f [x,y] = 10*(x-1)^2 + 20*(y-2)^2 + 30 -\ +\ -- main = do let (s,p) = minimize f [5,7] print s print p -\ +\ -- \> main [0.9920430849306285,1.9969168063253164] 0. 512.500 1.082 6.500 5. @@ -104,14 +104,14 @@ foreign import ccall "gsl-aux.h minimize" @minimize = minimizeConjugateGradient 1E-2 1E-4 1E-3 30 f [x,y] = 10*(x-1)^2 + 20*(y-2)^2 + 30 -\ +\ -- df [x,y] = [20*(x-1), 40*(y-2)] -\ +\ -- main = do let (s,p) = minimize f df [5,7] print s print p -\ +\ -- \> main [1.0,2.0] 0. 687.848 4.996 6.991 diff --git a/lib/Numeric/LinearAlgebra/Algorithms.hs b/lib/Numeric/LinearAlgebra/Algorithms.hs index 1de018c..bbc5986 100644 --- a/lib/Numeric/LinearAlgebra/Algorithms.hs +++ b/lib/Numeric/LinearAlgebra/Algorithms.hs @@ -300,12 +300,12 @@ multiplicative factor of the default tolerance used by GNU-Octave (see 'pinv'). @\> let m = 'fromLists' [[1,0, 0] ,[0,1, 0] ,[0,0,1e-10]] -\ +\ -- \> 'pinv' m 1. 0. 0. 0. 1. 0. 0. 0. 10000000000. -\ +\ -- \> pinvTol 1E8 m 1. 0. 0. 0. 1. 0. -- cgit v1.2.3