Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Gyacomo
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Antoine Cyril David Hoffmann
Gyacomo
Commits
9027e3d0
Commit
9027e3d0
authored
1 year ago
by
Antoine Cyril David Hoffmann
Browse files
Options
Downloads
Patches
Plain Diff
Add anti aliasing in all initializations
parent
eefedc87
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/inital.F90
+36
-2
36 additions, 2 deletions
src/inital.F90
with
36 additions
and
2 deletions
src/inital.F90
+
36
−
2
View file @
9027e3d0
...
@@ -230,7 +230,7 @@ END SUBROUTINE init_gyrodens
...
@@ -230,7 +230,7 @@ END SUBROUTINE init_gyrodens
!******************************************************************************!
!******************************************************************************!
SUBROUTINE
init_phi
SUBROUTINE
init_phi
USE
grid
,
ONLY
:
total_nkx
,
local_nky
,
local_nz
,&
USE
grid
,
ONLY
:
total_nkx
,
local_nky
,
local_nz
,&
ngz
,
iky0
,
ikx0
,
contains_ky0
ngz
,
iky0
,
ikx0
,
contains_ky0
,
AA_x
,
AA_y
USE
fields
,
ONLY
:
phi
,
moments
USE
fields
,
ONLY
:
phi
,
moments
USE
prec_const
,
ONLY
:
xp
USE
prec_const
,
ONLY
:
xp
USE
initial_par
,
ONLY
:
iseed
,
init_noiselvl
,
init_background
USE
initial_par
,
ONLY
:
iseed
,
init_noiselvl
,
init_background
...
@@ -261,6 +261,16 @@ SUBROUTINE init_phi
...
@@ -261,6 +261,16 @@ SUBROUTINE init_phi
phi
(
iky0
,
ikx0
,
iz
)
=
REAL
(
phi
(
iky0
,
ikx0
,
iz
),
xp
)
!origin must be real
phi
(
iky0
,
ikx0
,
iz
)
=
REAL
(
phi
(
iky0
,
ikx0
,
iz
),
xp
)
!origin must be real
END
DO
END
DO
ENDIF
ENDIF
! Putting to zero modes that are not in the 2/3 Orszag rule
IF
(
LINEARITY
.NE.
'linear'
)
THEN
DO
ikx
=
1
,
total_nkx
DO
iky
=
1
,
local_nky
DO
iz
=
1
,
local_nz
+
ngz
phi
(
iky
,
ikx
,
iz
)
=
phi
(
iky
,
ikx
,
iz
)
*
AA_x
(
ikx
)
*
AA_y
(
iky
)
ENDDO
ENDDO
ENDDO
ENDIF
!**** ensure no previous moments initialization
!**** ensure no previous moments initialization
moments
=
0._xp
moments
=
0._xp
!**** Zonal Flow initialization *******************************************
!**** Zonal Flow initialization *******************************************
...
@@ -283,7 +293,7 @@ END SUBROUTINE init_phi
...
@@ -283,7 +293,7 @@ END SUBROUTINE init_phi
!!!!!!! Initialize a ppj ES potential and cancel the moments
!!!!!!! Initialize a ppj ES potential and cancel the moments
!******************************************************************************!
!******************************************************************************!
SUBROUTINE
init_phi_ppj
SUBROUTINE
init_phi_ppj
USE
grid
,
ONLY
:
total_nkx
,
local_nky
,
local_nz
,&
USE
grid
,
ONLY
:
total_nkx
,
local_nky
,
local_nz
,
AA_x
,
AA_y
,
&
ngz
,
iky0
,
ikx0
,
contains_ky0
,
ieven
,
kxarray
,
kyarray
,
zarray
,
deltakx
ngz
,
iky0
,
ikx0
,
contains_ky0
,
ieven
,
kxarray
,
kyarray
,
zarray
,
deltakx
USE
fields
,
ONLY
:
phi
,
moments
USE
fields
,
ONLY
:
phi
,
moments
USE
prec_const
,
ONLY
:
xp
USE
prec_const
,
ONLY
:
xp
...
@@ -321,6 +331,16 @@ SUBROUTINE init_phi_ppj
...
@@ -321,6 +331,16 @@ SUBROUTINE init_phi_ppj
phi
(
iky0
,
ikx0
,
iz
)
=
REAL
(
phi
(
iky0
,
ikx0
,
iz
),
xp
)
!origin must be real
phi
(
iky0
,
ikx0
,
iz
)
=
REAL
(
phi
(
iky0
,
ikx0
,
iz
),
xp
)
!origin must be real
END
DO
END
DO
ENDIF
ENDIF
! Putting to zero modes that are not in the 2/3 Orszag rule
IF
(
LINEARITY
.NE.
'linear'
)
THEN
DO
ikx
=
1
,
total_nkx
DO
iky
=
1
,
local_nky
DO
iz
=
1
,
local_nz
+
ngz
phi
(
iky
,
ikx
,
iz
)
=
phi
(
iky
,
ikx
,
iz
)
*
AA_x
(
ikx
)
*
AA_y
(
iky
)
ENDDO
ENDDO
ENDDO
ENDIF
!**** ensure no previous moments initialization
!**** ensure no previous moments initialization
moments
=
0._xp
moments
=
0._xp
END
SUBROUTINE
init_phi_ppj
END
SUBROUTINE
init_phi_ppj
...
@@ -375,6 +395,20 @@ SUBROUTINE initialize_blob
...
@@ -375,6 +395,20 @@ SUBROUTINE initialize_blob
ENDDO
ENDDO
ENDDO
ENDDO
ENDDO
ENDDO
! Putting to zero modes that are not in the 2/3 Orszag rule
IF
(
LINEARITY
.NE.
'linear'
)
THEN
DO
ikx
=
1
,
total_nkx
DO
iky
=
1
,
local_nky
DO
iz
=
1
,
local_nz
+
ngz
DO
ip
=
1
,
local_np
+
ngp
DO
ij
=
1
,
local_nj
+
ngj
moments
(
ia
,
ip
,
ij
,
iky
,
ikx
,
iz
,
:)
=
moments
(
ia
,
ip
,
ij
,
iky
,
ikx
,
iz
,
:)
*
AA_x
(
ikx
)
*
AA_y
(
iky
)
ENDDO
ENDDO
ENDDO
ENDDO
ENDDO
ENDIF
ENDDO
ENDDO
END
SUBROUTINE
initialize_blob
END
SUBROUTINE
initialize_blob
!******************************************************************************!
!******************************************************************************!
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment