<commit_before>
import GSLInterp
import Text.Printf
import qualified Data.Vector.Unboxed as V

test :: IO ()
test = do
  let x  = 2.5
  let nx = 11
  let dx = 2.0 * pi / (nx - 1)
  let xs = V.map (dx*) $ V.fromList [0..nx - 1]
  let ys = V.map sin xs
  s <- interpInit xs ys
  case s of 
    Just p  -> sequence_
      [ printf "%+e ~ %+e\n" (interpEval p x) (sin x)
      , printf "%+e ~ %+e\n" (interpEvalDeriv p x) (cos x)
      , printf "%+e ~ %+e\n" (interpEvalSecondDeriv p x) (- (sin x))<commit_msg>Minor cleanup in Test.hs<commit_after>import GSLInterp
import Text.Printf
import qualified Data.Vector.Unboxed as V

test :: IO ()
test = do
  let x  = 2.5
      nx = 21
      dx = 2.0 * pi / (nx - 1)
      xs = V.map (dx*) $ V.fromList [0..nx - 1]
      ys = V.map sin xs
  s <- interpInit xs ys
  case s of
    Just p  -> sequence_
      [ printf "%+e ~ %+e\n" (interpEval p x) (sin x)
      , printf "%+e ~ %+e\n" (interpEvalDeriv p x) (cos x)
      , printf "%+e ~ %+e\n" (interpEvalSecondDeriv p x) (- (sin x))
{'fraction_non_alphanumeric': 0.15964740450538686, 'fraction_numerical': 0.01762977473065622, 'mean_word_length': 2.2037617554858935, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2685860', 'n_tokens_mistral': 445, 'n_tokens_neox': 423, 'n_words': 141}