MPI-AMRVAC 3.1
The MPI - Adaptive Mesh Refinement - Versatile Advection Code (development version)
Loading...
Searching...
No Matches
Functions/Subroutines | Variables
mod_pfss Module Reference

module mod_pfss.t – potential field source surface model PURPOSE : to extrapolate global potential magnetic field of the sun from synoptic magnetograms 2013.11.04 Developed by S. Moschou and C. Xia 2014.04.01 Allow to change source surface (C. Xia) PRECONDITIONS: More...

Functions/Subroutines

subroutine, public harm_coef (mapname)
 
subroutine, public pfss (ixil, ixol, bpf, x)
 

Variables

double precision, public r_s =2.5d0
 
double precision, public r_0 =1.d0
 
integer, public lmax =0
 
logical, public trunc =.false.
 

Detailed Description

module mod_pfss.t – potential field source surface model PURPOSE : to extrapolate global potential magnetic field of the sun from synoptic magnetograms 2013.11.04 Developed by S. Moschou and C. Xia 2014.04.01 Allow to change source surface (C. Xia) PRECONDITIONS:

  1. 3D spherical coordinates
  2. A synoptic magnetogram in a binary file contains nphi, ntheta, theta(ntheta), phi(nphi), B_r(nphi,ntheta) succesively.
  3. nphi, ntheta are long integers and other arrays are double precision. theta contains decreasing radians with increasing indice (Pi to 0) phi contains increasing radians with increasing indice (0 to 2*Pi) USAGE: example for a magnetogram with name 'mdicr2020.dat':

    subroutine initglobaldata_usr ... R_0=1.d0 ! dimensionless Solar radius (default 1.0) R_s=2.5d0 ! dimensionless radius of source surface (default 2.5) lmax=120 ! use a fixed value instead of the value determined by the resolution of input magnetogram trunc=.true. ! use less spherical harmonics at larger distances call harm_coef('mdicr2020.dat') end subroutine initglobaldata_usr

    subroutine initonegrid_usr(ixI^L,ixO^L,w,x) ... double precision :: bpf(ixI^S,1:ndir) ... call pfss(ixI^L,ixO^L,bpf,x) w(ix^S,mag(:))=bpf(ix^S,:)

    end subroutine initonegrid_usr

Function/Subroutine Documentation

◆ harm_coef()

subroutine, public mod_pfss::harm_coef ( character(len=*)  mapname)

Definition at line 52 of file mod_pfss.t.

Here is the call graph for this function:

◆ pfss()

subroutine, public mod_pfss::pfss ( integer, intent(in)  ixi,
integer, intent(in)  l,
integer, intent(in)  ixo,
  l,
double precision, dimension(ixi^s,1:ndir), intent(out)  bpf,
double precision, dimension(ixi^s,1:ndim), intent(in)  x 
)

Definition at line 267 of file mod_pfss.t.

Variable Documentation

◆ lmax

integer, public mod_pfss::lmax =0

Definition at line 42 of file mod_pfss.t.

◆ r_0

double precision, public mod_pfss::r_0 =1.d0

Definition at line 40 of file mod_pfss.t.

◆ r_s

double precision, public mod_pfss::r_s =2.5d0

Definition at line 40 of file mod_pfss.t.

◆ trunc

logical, public mod_pfss::trunc =.false.

Definition at line 43 of file mod_pfss.t.