big commit before big mess
This commit is contained in:
@@ -2,8 +2,10 @@
|
||||
|
||||
## Points 3d
|
||||
|
||||
Bientôt les quaternions ?
|
||||
|
||||
## Portable Net Map
|
||||
|
||||
.pgm
|
||||
Fichiers de type `PGM` utilisés ici en version 16 bits, donc
|
||||
65536 niveaux de gris.
|
||||
|
||||
|
||||
@@ -49,7 +49,8 @@ subroutine write_points3d(array, start, length, fname)
|
||||
open(newunit=io, file=fname)
|
||||
do i = 1, length
|
||||
j = i + start
|
||||
write(io, '(3F12.6)') array(j)%x, array(j)%y, array(j)%z
|
||||
write(io, '(3F12.6, I8)') &
|
||||
array(j)%x, array(j)%y, array(j)%z, array(j)%seq
|
||||
enddo
|
||||
close(io)
|
||||
|
||||
|
||||
65
Fraktalism/mods/xperiment.f90
Normal file
65
Fraktalism/mods/xperiment.f90
Normal file
@@ -0,0 +1,65 @@
|
||||
module xperiment
|
||||
|
||||
implicit none
|
||||
contains
|
||||
|
||||
!===============================================================
|
||||
! nouveau 24 mai 2022
|
||||
|
||||
subroutine parasites_0(pic, cx, cy, maxiter)
|
||||
implicit none
|
||||
|
||||
! here is the wtf
|
||||
integer, intent(inout), dimension (:,:) :: pic
|
||||
|
||||
real, intent(in) :: cx, cy
|
||||
integer, intent(in) :: maxiter
|
||||
|
||||
integer :: ix, iy, width, height
|
||||
real :: fx, fy, coef
|
||||
logical :: burps
|
||||
! write(0, *) "subroutine parasites_0" , maxiter
|
||||
! write(0, *) "constantes", cx, cy
|
||||
|
||||
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_0
|
||||
|
||||
!---------------------------------------------------------------
|
||||
!
|
||||
! aucune idee de l'utilisation de ce truc !
|
||||
!
|
||||
subroutine loop_of_parasites_0(nbre, mode)
|
||||
implicit none
|
||||
integer, intent(in) :: 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_0
|
||||
|
||||
!===============================================================
|
||||
end module xperiment
|
||||
Reference in New Issue
Block a user