fortplot_matplotlib_vector_wrappers Module

Streamplot and quiver visualisation wrappers for matplotlib facade



Interfaces

public interface quiver

  • private subroutine quiver_rgb(x, y, u, v, scale, color, width, headwidth, headlength, units, angles, pivot, alpha, scale_units, c, colormap)

    Draw a quiver plot with an RGB color.

    Parameters x : real(wp), contiguous, intent(in) Arrow origins on the x-axis. y : real(wp), contiguous, intent(in) Arrow origins on the y-axis. u : real(wp), contiguous, intent(in) X components. v : real(wp), contiguous, intent(in) Y components. scale : real(wp), optional Arrow scaling factor. color : real(wp)(3), optional Solid RGB color. width : real(wp), optional Shaft width. headwidth : real(wp), optional Arrow head width. headlength : real(wp), optional Arrow head length. units : character(len=), optional Length unit keyword. angles : character(len=), optional Angle convention keyword. pivot : character(len=), optional Pivot keyword. alpha : real(wp), optional Arrow transparency. scale_units : character(len=), optional Scaling unit keyword. c : real(wp), optional Per-arrow scalar values. colormap : character(len=*), optional Colormap name.

    Arguments

    Type IntentOptional Attributes Name
    real(kind=wp), intent(in), contiguous :: x(:)
    real(kind=wp), intent(in), contiguous :: y(:)
    real(kind=wp), intent(in), contiguous :: u(:)
    real(kind=wp), intent(in), contiguous :: v(:)
    real(kind=wp), intent(in), optional :: scale
    real(kind=wp), intent(in), optional :: color(3)
    real(kind=wp), intent(in), optional :: width
    real(kind=wp), intent(in), optional :: headwidth
    real(kind=wp), intent(in), optional :: headlength
    character(len=*), intent(in), optional :: units
    character(len=*), intent(in), optional :: angles
    character(len=*), intent(in), optional :: pivot
    real(kind=wp), intent(in), optional :: alpha
    character(len=*), intent(in), optional :: scale_units
    real(kind=wp), intent(in), optional :: c(:)
    character(len=*), intent(in), optional :: colormap
  • private subroutine quiver_string(x, y, u, v, color, scale, width, headwidth, headlength, units, angles, pivot, alpha, scale_units, c, colormap)

    Draw a quiver plot with a named color.

    Parameters x : real(wp), contiguous, intent(in) Arrow origins on the x-axis. y : real(wp), contiguous, intent(in) Arrow origins on the y-axis. u : real(wp), contiguous, intent(in) X components. v : real(wp), contiguous, intent(in) Y components. color : character(len=), intent(in) Named or hex color string. scale : real(wp), optional Arrow scaling factor. width : real(wp), optional Shaft width. headwidth : real(wp), optional Arrow head width. headlength : real(wp), optional Arrow head length. units : character(len=), optional Length unit keyword. angles : character(len=), optional Angle convention keyword. pivot : character(len=), optional Pivot keyword. alpha : real(wp), optional Arrow transparency. scale_units : character(len=), optional Scaling unit keyword. c : real(wp), optional Per-arrow scalar values. colormap : character(len=), optional Colormap name.

    Arguments

    Type IntentOptional Attributes Name
    real(kind=wp), intent(in), contiguous :: x(:)
    real(kind=wp), intent(in), contiguous :: y(:)
    real(kind=wp), intent(in), contiguous :: u(:)
    real(kind=wp), intent(in), contiguous :: v(:)
    character(len=*), intent(in) :: color
    real(kind=wp), intent(in), optional :: scale
    real(kind=wp), intent(in), optional :: width
    real(kind=wp), intent(in), optional :: headwidth
    real(kind=wp), intent(in), optional :: headlength
    character(len=*), intent(in), optional :: units
    character(len=*), intent(in), optional :: angles
    character(len=*), intent(in), optional :: pivot
    real(kind=wp), intent(in), optional :: alpha
    character(len=*), intent(in), optional :: scale_units
    real(kind=wp), intent(in), optional :: c(:)
    character(len=*), intent(in), optional :: colormap

public interface add_quiver

  • private subroutine add_quiver_rgb(x, y, u, v, scale, color, width, headwidth, headlength, units, angles, pivot, alpha, scale_units, c, colormap)

    Object-oriented alias for quiver with RGB color.

    Parameters x : real(wp), contiguous, intent(in) Arrow origins on the x-axis. y : real(wp), contiguous, intent(in) Arrow origins on the y-axis. u : real(wp), contiguous, intent(in) X components. v : real(wp), contiguous, intent(in) Y components. scale : real(wp), optional Arrow scaling factor. color : real(wp)(3), optional Solid RGB color. width : real(wp), optional Shaft width. headwidth : real(wp), optional Arrow head width. headlength : real(wp), optional Arrow head length. units : character(len=), optional Length unit keyword. angles : character(len=), optional Angle convention keyword. pivot : character(len=), optional Pivot keyword. alpha : real(wp), optional Arrow transparency. scale_units : character(len=), optional Scaling unit keyword. c : real(wp), optional Per-arrow scalar values. colormap : character(len=*), optional Colormap name.

    Arguments

    Type IntentOptional Attributes Name
    real(kind=wp), intent(in), contiguous :: x(:)
    real(kind=wp), intent(in), contiguous :: y(:)
    real(kind=wp), intent(in), contiguous :: u(:)
    real(kind=wp), intent(in), contiguous :: v(:)
    real(kind=wp), intent(in), optional :: scale
    real(kind=wp), intent(in), optional :: color(3)
    real(kind=wp), intent(in), optional :: width
    real(kind=wp), intent(in), optional :: headwidth
    real(kind=wp), intent(in), optional :: headlength
    character(len=*), intent(in), optional :: units
    character(len=*), intent(in), optional :: angles
    character(len=*), intent(in), optional :: pivot
    real(kind=wp), intent(in), optional :: alpha
    character(len=*), intent(in), optional :: scale_units
    real(kind=wp), intent(in), optional :: c(:)
    character(len=*), intent(in), optional :: colormap
  • private subroutine add_quiver_string(x, y, u, v, color, scale, width, headwidth, headlength, units, angles, pivot, alpha, scale_units, c, colormap)

    Object-oriented alias for quiver with a named color.

    Parameters x : real(wp), contiguous, intent(in) Arrow origins on the x-axis. y : real(wp), contiguous, intent(in) Arrow origins on the y-axis. u : real(wp), contiguous, intent(in) X components. v : real(wp), contiguous, intent(in) Y components. color : character(len=), intent(in) Named or hex color string. scale : real(wp), optional Arrow scaling factor. width : real(wp), optional Shaft width. headwidth : real(wp), optional Arrow head width. headlength : real(wp), optional Arrow head length. units : character(len=), optional Length unit keyword. angles : character(len=), optional Angle convention keyword. pivot : character(len=), optional Pivot keyword. alpha : real(wp), optional Arrow transparency. scale_units : character(len=), optional Scaling unit keyword. c : real(wp), optional Per-arrow scalar values. colormap : character(len=), optional Colormap name.

    Arguments

    Type IntentOptional Attributes Name
    real(kind=wp), intent(in), contiguous :: x(:)
    real(kind=wp), intent(in), contiguous :: y(:)
    real(kind=wp), intent(in), contiguous :: u(:)
    real(kind=wp), intent(in), contiguous :: v(:)
    character(len=*), intent(in) :: color
    real(kind=wp), intent(in), optional :: scale
    real(kind=wp), intent(in), optional :: width
    real(kind=wp), intent(in), optional :: headwidth
    real(kind=wp), intent(in), optional :: headlength
    character(len=*), intent(in), optional :: units
    character(len=*), intent(in), optional :: angles
    character(len=*), intent(in), optional :: pivot
    real(kind=wp), intent(in), optional :: alpha
    character(len=*), intent(in), optional :: scale_units
    real(kind=wp), intent(in), optional :: c(:)
    character(len=*), intent(in), optional :: colormap

Subroutines

public subroutine streamplot(x, y, u, v, density, linewidth, color, cmap, label, arrowsize, arrowstyle, colormap)

Draw streamlines for a vector field.

Read more…

Arguments

Type IntentOptional Attributes Name
real(kind=wp), intent(in), contiguous :: x(:)
real(kind=wp), intent(in), contiguous :: y(:)
real(kind=wp), intent(in), contiguous :: u(:,:)
real(kind=wp), intent(in), contiguous :: v(:,:)
real(kind=wp), intent(in), optional :: density
real(kind=wp), intent(in), optional :: linewidth
real(kind=wp), intent(in), optional :: color(3)
character(len=*), intent(in), optional :: cmap
character(len=*), intent(in), optional :: label
real(kind=wp), intent(in), optional :: arrowsize
character(len=*), intent(in), optional :: arrowstyle
character(len=*), intent(in), optional :: colormap