calc_nsites_cube Function

private function calc_nsites_cube(this, length_x, length_y, length_z) result(n_sites)

Type Bound

cube

Arguments

Type IntentOptional Attributes Name
class(cube) :: this
integer, intent(in) :: length_x
integer, intent(in) :: length_y
integer, intent(in), optional :: length_z

Return Value integer


Contents

Source Code


Source Code

    function calc_nsites_cube(this, length_x, length_y, length_z) result(n_sites)
        class(cube) :: this
        integer, intent(in) :: length_x, length_y
        integer, intent(in), optional :: length_z
        integer :: n_sites
        character(*), parameter :: this_routine = "calc_nsites_cube"

        unused_var(this)
        if (max(length_x, length_y, length_z) < 2) then
            call stop_all(this_routine, "too small cube lengths specified! (< 2)")
        end if

        n_sites = length_x * length_y * length_z

    end function calc_nsites_cube