Implemented some form of LM optimization, but it's proper fucked somehow.

This commit is contained in:
2023-01-30 02:07:10 +01:00
parent cb2dad39ec
commit 32fb672bf5
7 changed files with 107 additions and 42 deletions

View File

@@ -142,8 +142,8 @@ raytrace system ray =
raytrace1 :: ( Floating a, Ord a, Mode a, Scalar a ~ Double, Epsilon a
, MonadState Double m
, MonadWriter [HitRecord a] m -- ^ Tracing yields a list of
, MonadError TraceError m) => -- ^ This can fail
Ray a -> Element BakedIOR a -> m (Ray a)
, MonadError TraceError m) -- ^ This can fail
=> Ray a -> Element BakedIOR a -> m (Ray a)
raytrace1 ray element = do
n1 <- get
let stopP = isStop element