From c05d80a223aff8038e97b7059418c9774e0f9faf Mon Sep 17 00:00:00 2001 From: tTh Date: Sat, 11 Feb 2023 20:28:05 +0100 Subject: [PATCH] minor changes --- Fraktalism/README.md | 7 +++++-- Fraktalism/fraktals.f90 | 1 - Fraktalism/henon.f90 | 3 +-- Fraktalism/julia.f90 | 33 --------------------------------- Fraktalism/lorentz.f90 | 31 ------------------------------- Fraktalism/mods/xperiment.f90 | 10 ---------- 6 files changed, 6 insertions(+), 79 deletions(-) delete mode 100644 Fraktalism/julia.f90 delete mode 100644 Fraktalism/lorentz.f90 diff --git a/Fraktalism/README.md b/Fraktalism/README.md index 2ca85fc..7f32aa0 100644 --- a/Fraktalism/README.md +++ b/Fraktalism/README.md @@ -9,8 +9,8 @@ qui montre ma première expérience dans ce domaine. ## La technique Le gros des calculs de fractales est fait dans `mods/fraktals.f90`, -et la gestion des pixels 'physiques' est faite par le -module externe `spitpgm`. +et la gestion des pixels 'physiques' est faite par les +modules externes `spitpgm` et `pixrgb`. Les fonctions d'usage général sont dans [mods/](répertoire mods/) ave trop peu @@ -38,3 +38,6 @@ Generally writen as a *sequencial unformated* file. - Rajouter des formules - Ne pas procastiner sur le reste +## See also + +- https://www.maths.town/fractal-articles/mandelbulb/mandelbulb-all-powers/ diff --git a/Fraktalism/fraktals.f90 b/Fraktalism/fraktals.f90 index b82ee52..688fac7 100644 --- a/Fraktalism/fraktals.f90 +++ b/Fraktalism/fraktals.f90 @@ -153,5 +153,4 @@ function modulus2(pt) modulus2 = real(pt)*real(pt) + imag(pt)*imag(pt) end !----------------------------------------------------- - end module fraktals diff --git a/Fraktalism/henon.f90 b/Fraktalism/henon.f90 index bf64b41..bc663db 100644 --- a/Fraktalism/henon.f90 +++ b/Fraktalism/henon.f90 @@ -8,7 +8,7 @@ program henon integer :: w, h integer :: foo, bar double precision :: px, py - w = 2000 ; h=1600 + w = 2000 ; h = 1600 write(0, *) "###### Mapping of Henon " @@ -25,7 +25,6 @@ program henon !----------------------------------------------------- contains !----------------------------------------------------- - !----------------------------------------------------- subroutine compute_pixel_henon(a, b, maxpasse, passe, limit, rx, ry) implicit none diff --git a/Fraktalism/julia.f90 b/Fraktalism/julia.f90 deleted file mode 100644 index 79e5cc5..0000000 --- a/Fraktalism/julia.f90 +++ /dev/null @@ -1,33 +0,0 @@ -!----------------------------------------------------- -! JULIA -! ===== -! this is the main program -!----------------------------------------------------- - -program julia - - use spitpgm - use fraktals - - implicit none - - integer, dimension(512, 342) :: picz - integer :: argc - character(200) :: filename, string - real :: cx, cy - - argc = IARGC() - if (3 .NE. argc) then - STOP ": JULIA PROGGY NEED PARAMETERS !" - endif - - call getarg(1, filename) - call getarg(2, string) ; read (string, *) cx - call getarg(3, string) ; read (string, *) cy - - call simple_julia(picz, cx, cy, 2500) - call spit_as_pgm_8(picz, trim(filename)) - -end program - -!----------------------------------------------------- diff --git a/Fraktalism/lorentz.f90 b/Fraktalism/lorentz.f90 deleted file mode 100644 index 0b1e0a6..0000000 --- a/Fraktalism/lorentz.f90 +++ /dev/null @@ -1,31 +0,0 @@ -! -! this is the main programm -! -!----------------------------------------------------- - -program lorentz - - use spitpgm - use fraktals - - implicit none - - integer, dimension(800, 600) :: picz - integer :: argc - character(200) :: filename - - argc = IARGC() - if (1 .NE. argc) then - STOP ": LORENTZ NEED A FILENAME !" - endif - - call getarg(1, filename) - - write (0, "(A)") "Lorentz -> "//trim(filename) - - call lorentz_0(picz, 50000) - call spit_as_pgm_8(picz, trim(filename)) - -end program - -!----------------------------------------------------- diff --git a/Fraktalism/mods/xperiment.f90 b/Fraktalism/mods/xperiment.f90 index a729336..4503c3d 100644 --- a/Fraktalism/mods/xperiment.f90 +++ b/Fraktalism/mods/xperiment.f90 @@ -8,8 +8,6 @@ module xperiment subroutine parasites_1(pic, cx, cy, maxiter) implicit none - - ! here is the wtf integer, intent(inout), dimension (:,:) :: pic real, intent(in) :: cx, cy @@ -23,22 +21,18 @@ subroutine parasites_1(pic, cx, cy, maxiter) width = ubound(pic, 1) ; height = ubound(pic, 2) coef = float(maxiter) - do ix = 1, width fx = cx + (float(ix) / (float(width)/4.0) - 2.0) burps = (RAND() .lt. 0.01) do iy = 1, height fy = cy + (float(iy) / (float(height)/4.0) - 2.0) - if (burps) then pic(ix, iy) = int(fx * fy * coef * 1.005) else pic(ix, iy) = int(fx * fy * coef) endif - enddo enddo - end subroutine parasites_1 !--------------------------------------------------------------- @@ -52,13 +46,9 @@ subroutine loop_of_parasites_1(nbre, mode) integer :: idx if (mode .NE. 0) STOP "BAD MODE" - do idx = 0, nbre - write(0, *) "popcorn loop ", idx - enddo - end subroutine loop_of_parasites_1 !===============================================================