The implementation of the interfaces defined in scalar_schw.
Utility routine to count the number of digits in an integer. Used to construct filenames.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer(kind=ip), | intent(in) | :: | l | The integer to count the number of digits in. |
Construct unique filenames using a base name and the mode numbers l and m for reading in external inital data. The base name is constructed based on the run time parameters input_directory and input_basename.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer(kind=ip), | intent(in) | :: | l | The -mode of this mode. |
||
integer(kind=ip), | intent(in) | :: | m | The -mode of this mode. |
The return value is the concatenation of the input_directory and input_basename and the mode information.
Calculate a flux from the derivative data and the equation coefficient.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
complex(kind=wp), | intent(in), | dimension(2) | :: | u | The input state vector . |
|
real(kind=wp), | intent(in) | :: | C11 | The coefficient of the second radial derivative term, . |
||
real(kind=wp), | intent(in) | :: | C02 | The coefficient of the mixed second derivative term, . |
On return the flux.
Calculate the number of m-modes for a given value of l. For the scalar charge in orbit around a Schwarzschild black hole we only need to evolve modes with even due to symmetries.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer(kind=ip), | intent(in) | :: | l | The -value. |
The return value is the number of -modes that is evolved for this .
Calculate the total number of modes from lmin to lmax.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer(kind=ip), | intent(in) | :: | lmin | The minimum value of to include in the sum, . |
||
integer(kind=ip), | intent(in) | :: | lmax | The maximum value of to include in the sum. . |
The return value is to total number of -modes from all modes from to .
Utility function for linear extrapolation of data to the horizon and Scri+.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=wp), | intent(in), | dimension(3) | :: | x | A 1d array of size (3) of reals that contains the 3 coordinate locations involved in the extrapolation. The first element is the coordinate where the extrapolation is needed, that last two elements are the locations where data is known. |
|
complex(kind=wp), | intent(in), | dimension(2:3) | :: | y | A 1d array of size(2) that contains the known data. |
The return value is the extrapolated data at the required location.
Loop over all mode and store it's corresponding and m-values. This should maybe made into a type bound procedure.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(scal_schw), | intent(inout) | :: | this | The mode information will be set for this scal_schw object. |
||
integer(kind=ip), | intent(in) | :: | lmin | The mininum -value. |
||
integer(kind=ip), | intent(in) | :: | lmax | The mininum -value. |
Calculate the characteristic fluxes for all elements for a single mode.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(cgf), | intent(in) | :: | rho | A complex grid function containing the time derivative variable, . |
||
type(cgf), | intent(in) | :: | pi | A complex grid function containing the radial derivative variable, . |
||
integer(kind=ip), | intent(in) | :: | nmodes | The total number of modes. |
||
integer(kind=ip), | intent(in) | :: | mode | The mode for which the flux is calculated. |
||
type(rgf), | intent(in) | :: | r | A real grid function that contains the Scharzschild radial coordinate. |
||
type(scal_schw_eff), | intent(inout) | :: | effs | The effective source object. Needed to add and subtract the derivatives of the singular field when calculating fluxes at the world-tube boundary. |
||
type(tdc) | :: | time_dc | The time dependent coordinate object. Needed to transform the derivatives of the field when calculating fluxes at the boundary of the time dependent coordinate region. |
|||
type(rgfb), | intent(in), | dimension(:) | :: | e_lambda | A 1d array of size (2) of real boundary grid functions that contains the characteristic speeds at the element boundary. |
|
type(rgfb), | intent(in), | dimension(:,:) | :: | e_s | A 2d array of size (2,2) of real boundary grid functions that contains the matrix used to convert from characteristic to evolved variables. |
|
type(rgfb), | intent(in), | dimension(:,:) | :: | e_sinv | A 2d array of size (2,2) of real boundary grid functions that contains the matrix used to convert from evolved to characteristic variables. |
|
type(rgf), | intent(in), | dimension(:) | :: | e_coeffs | A 1d array of real grid functions that contains the coefficients for the wave equation. |
|
type(ref_element), | intent(in) | :: | r_elem | The reference element. |
||
type(cgf), | intent(inout) | :: | rho_flux | On output contains the component of the characteristic flux. |
||
type(cgf), | intent(inout) | :: | pi_flux | On output contains the component of the characteristic flux. |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(scal_schw), | intent(inout), | target | :: | this | The equation that is being initialized. |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(scal_schw), | intent(inout) | :: | this | The equation for which the RHS is calculated. |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(scal_schw), | intent(inout) | :: | this | The routine is called on this equation. |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(scal_schw), | intent(inout) | :: | this | The routine is called on this equation. |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(scal_schw), | intent(inout) | :: | this | The routine is called on this equation. |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(scal_schw), | intent(inout) | :: | this | The routine is called on this equation. |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(scal_schw), | intent(inout) | :: | this | The routine is called on this equation. |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(scal_schw), | intent(inout) | :: | this | The routine is called on this equation. |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(scal_schw), | intent(inout) | :: | this | The routine is called on this equation. |
||
integer(kind=ip), | intent(in) | :: | elem | The index of the element where the transformation is calculated. |
||
integer(kind=ip), | intent(in) | :: | node | The index of the node within that element where the transformation is calculated. |
||
logical, | intent(in) | :: | inner | If .true. use the transformation for the inner region. If .false. use the transformation for the outer region. |
||
complex(kind=wp), | intent(inout) | :: | dpsidt | On input holds the time derivative in Tortoise coordinates. On output holds the time derivative in hyperboloidal coordinates. |
||
complex(kind=wp), | intent(inout) | :: | dpsidr | On input holds the radial derivative in Tortoise coordinates. On output holds the radial derivative in hyperboloidal coordinates. |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
character(len=*), | intent(in) | :: | var_name | The input variable name. |
||
integer(kind=ip), | intent(in) | :: | mode | the mode number. |
The return value is the converted variable name.