allocatable_array_test,
a Fortran90 code which
demonstrates how a main program can declare an allocatable array,
which is then passed to a subroutine which allocates it, initializes
it, and returns it to the calling program for further use.
analemma,
a Fortran90 code which
evaluates the equation of time, a formula for the difference between
the uniform 24 hour day and the actual position of the sun,
creating data files that can be plotted with gnuplot(),
based on code by Brian Tung.
annulus_monte_carlo,
a Fortran90 code which
uses the Monte Carlo method to estimate the integral of a function
over the interior of a circular annulus in 2D.
apportionment,
a Fortran90 code which
demonstrates some of the methods
used or proposed for fairly assigning
seats in the House of Representatives to each state;
arpack,
a Fortran90 code which
is a numerical software library for solving large scale eigenvalue
problems. The package is designed to compute a few eigenvalues and
corresponding eigenvectors of large sparse or structured matrices,
using the Implicitly Restarted Arnoldi Method (IRAM) or, in the case
of symmetric matrices, the corresponding variant of the Lanczos
algorithm. It is used by many popular numerical computing environments
such as SciPy, Mathematica, GNU Octave and MATLAB to provide this
functionality.
asa005,
a Fortran90 code which
evaluates the Cumulative Density Function (CDF) of the noncentral T
Probability Density Function (PDF), by BE Cooper.
This is a version of Applied Statistics Algorithm 5;
asa006,
a Fortran90 code which
computes the Cholesky factorization of a symmetric positive
definite (SPD) matrix, by Michael Healy.
This is a version of Applied Statistics Algorithm 6;
asa007,
a Fortran90 code which
computes the inverse of a symmetric positive definite (SPD) matrix,
by Michael Healy.
This is a version of Applied Statistics Algorithm 7.
asa047,
a Fortran90 code which
minimizes a scalar function of several variables
using the Nelder-Mead algorithm,
by R ONeill.
This is a version of Applied Statistics Algorithm 47.
asa053,
a Fortran90 code which
produces sample matrices from the Wishart distribution,
by William Smith and Ronald Hocking.
This is a version of Applied Statistics Algorithm 53.
asa058,
a Fortran90 code which
implements the K-means data clustering algorithm,
by David Sparks.
This is a version of Applied Statistics Algorithm 58.
asa063,
a Fortran90 code which
evaluates the incomplete Beta function,
by KL Majumder and G Bhattacharjee.
This is a version of Applied Statistics Algorithm 63.
asa066,
a Fortran90 code which
evaluates the Cumulative Density Function (CDF) of the normal
probability distribution, by David Hill.
This is a version of Applied Statistics Algorithm 66.
asa076,
a Fortran90 code which
evaluates the Owen T function, needed to compute the
Cumulative Density Function (CDF) of the
noncentral T distribution,
by Young and Minder.
This is a version of Applied Statistics Algorithm 76.
asa091,
a Fortran90 code which
evaluates the percentage points of the Chi-Squared distribution,
by Best and Roberts.
This is a version of Applied Statistics Algorithm 91.
asa109,
a Fortran90 code which
inverts the incomplete Beta function,
by Cran, Martin and Thomas.
This is a version of Applied Statistics Algorithm 109.
asa111,
a Fortran90 code which
evaluates the percentage points of the normal distribution,
by Beasley and Springer.
This is a version of Applied Statistics Algorithm 111.
asa113,
a Fortran90 code which
implements a clustering algorithm using transfers and swaps,
by Banfield and Bassill.
This is a version of Applied Statistics Algorithm 113.
asa152,
a Fortran90 code which
evaluates the Probability Density Function (PDF)
and Cumulative Density Function
(CDF) associated with the hypergeometric distribution,
by Richard Lund;
this is a version of Applied Statistics Algorithm 152.
asa159,
a Fortran90 code which
randomly generates an RxC contingency table,
by Michael Patefield;
This is a version of Applied Statistics Algorithm 159.
asa172,
a Fortran90 code which
generates all M-dimensional indices in a given range,
simulating the behavior of an arbitrary number of nested loops,
by OFlaherty and MacKenzie.
This is a version of Applied Statistics Algorithm 172.
asa189,
a Fortran90 code which
estimates the parameters of a beta binomial distribution based on a sample
of values generated by the distribution, by D Smith;
this is a version of Applied Statistics Algorithm 189;
asa205,
a Fortran90 code which
generates all the contingency
tables corresponding to a given set of row and column sums.
This is a version of Applied Statistics Algorithm 205.
asa226,
a Fortran90 code which
evaluates the Cumulative Density Function (CDF)
of the noncentral Beta distribution,
by Russell Lenth.
This is a version of Applied Statistics Algorithm 226.
asa241,
a Fortran90 code which
evaluates the percentage points of the normal distribution,
by Michael Wichura.
This is a version of Applied Statistics Algorithm 241.
asa243,
a Fortran90 code which
evaluates the Cumulative Density Function (CDF)
of the noncentral T distribution,
by Russell Lenth;
this is a version of Applied Statistics Algorithm 243.
asa266,
a Fortran90 code which
evaluates various properties of
the Dirichlet Probability Density Function (PDF);
this is a version of Applied Statistics Algorithm 266;
asa299,
a Fortran90 code which
computes the lattice points in an M-dimensional simplex,
by Chasalow and Brand;
this is a version of Applied Statistics Algorithm 299;
asa310,
a Fortran90 code which
computes the Cumulative Density Function (CDF) of
the noncentral Beta distribution,
by Chattamvelli and Shanmugam;
this is a version of Applied Statistics Algorithm 310.
asa314,
a Fortran90 code which
computes the inverse of a matrix whose elements are subject to
modulo arithmetic,
by Roger Payne.
This is a version of Applied Statistics Algorithm 314;
backward_euler,
a Fortran90 code which
solves one or more ordinary differential equations (ODE)
using the (implicit) backward Euler method, using a version
of fsolve() for the implicit equation.
band_qr,
a Fortran90 code which
computes the QR factorization of a banded matrix, and solves
related linear systems,
by Alfredo Remon, Enrique Quintana-Orti, Gregorio Quintana-Orti.
barycentric_interp_1d,
a Fortran90 code which
defines and evaluates the barycentric Lagrange polynomial p(x)
which interpolates data, so that p(x(i)) = y(i).
The barycentric approach means that very high degree polynomials can
safely be used.
bdf2,
a Fortran90 code which
solves one or more ordinary differential equations (ODE)
using the (implicit) backward difference formula of order 2 (BDF2),
using fsolve() to solve the implicit equation.
bdf3,
a Fortran90 code which
solves one or more ordinary differential equations (ODE)
using the (implicit) backward difference formula of order 3 (BDF),
using fsolve() to solve the implicit equation.
bellman_ford,
a Fortran90 code which
implements the Bellman-Ford algorithm for finding the shortest distance
from a given node to all other nodes in a directed graph whose
edges have been assigned real-valued lengths.
bins,
a Fortran90 code which
sorts data into order, or lumps
it into bins, or selects an item of particular rank, or finds
the unique elements in a list.
bisection_integer,
a Fortran90 code which
seeks an integer solution to the equation F(X)=0,
using bisection within a user-supplied change of sign interval [A,B].
bisection_rc,
a Fortran90 code which
seeks a solution to the equation F(X)=0 using bisection
within a user-supplied change of sign interval [A,B].
The procedure is written using reverse communication (RC).
black_scholes,
a Fortran90 code which
implements some simple approaches to
the Black-Scholes option valuation theory,
creating graphics files for processing by gnuplot(),
by Desmond Higham.
brownian_motion_simulation,
a Fortran90 code which
simulates Brownian motion in an M-dimensional region,
creating graphics files for processing by gnuplot().
bvls,
a Fortran90 code which
applies linear least squares (LLS) methods to solve a system for which
lower and upper constraints may have been placed on every variable,
by Charles Lawson and Richard Hanson.
c_comment,
a Fortran90 code which
reads an ASCII text file,
and writes a copy, in which C++ style comments have been replaced by
equivalent C-style comments.
calpak,
a Fortran90 code which
computes various simple calendrical quantities. It can work with
various calendars including Egyptian, English, French Revolutionary,
Gregorian, Julian, and Julian Ephemeris Date. It can convert a
date from one calendar to another. It can return the day of the week
for a given date. It can convert from day-number/year to
day/month/year format. It can calculate the time difference
between two dates.
candy_count,
a Fortran90 code which
counts the types of candy in a rectangular container, which might be
a vector, matrix, or 3D box. The candy is assumed to have C possible
types, and to have been entered into the container in a cycle that
begins with type 1. While the vector case is easy, it is already
difficult to come up with a general formula for the MxN matrix case.
cauchy_principal_value,
a Fortran90 code which
uses Gauss-Legendre quadrature to estimate the Cauchy Principal Value
(CPV) of certain singular integrals.
cdflib,
a Fortran90 code which
evaluates the cumulative density function (CDF), inverse CDF,
and certain other inverse functions, for distributions including
beta, binomial, chi-square, noncentral chi-square, F, noncentral F,
gamma, negative binomial, normal, Poisson, and students T,
by Barry Brown, James Lovato, Kathy Russell.
cell,
a Fortran90 code which
defines a cell array, a generalization of an array which
compactly stores and retrieves vector or matrix data of
varying size, such as the rows of a triangular matrix.
cg,
a Fortran90 code which
implements a simple version of the conjugate gradient (CG) method
for solving a system of linear equations of the form A*x=b,
suitable for situations in which the matrix A is positive definite,
only real, positive eigenvalues and symmetric.
cg_rc,
a Fortran90 code which
implements the conjugate gradient (CG) method for solving
a positive definite sparse linear system A*x=b,
using reverse communication (RC).
change_dynamic,
a Fortran90 code which
uses dynamic programming to solve the change making problem,
in which a given sum is to be formed using coins of various
denominations.
chebyshev_polynomial,
a Fortran90 code which
considers the Chebyshev polynomials T(i,x), U(i,x), V(i,x) and W(i,x).
Functions are provided to evaluate the polynomials, determine their
zeros,
produce their polynomial coefficients, produce related quadrature rules,
project other functions onto these polynomial bases, and integrate
double and triple products of the polynomials.
chebyshev_series,
a Fortran90 code which
evaluates a Chebyshev series approximating a function f(x),
while efficiently computing one, two or three derivatives of the
series, which approximate f'(x), f''(x), and f'''(x),
by Manfred Zimmer.
circle_monte_carlo,
a Fortran90 code which
applies a Monte Carlo method to estimate the integral of a function
along the circumference of the unit circle in 2D;
circle_segment,
a Fortran90 code which
carries out computations associated with a circle segment, including
height, angle, area, centroid, sampling, and quadrature,
creating some graphics images using gnuplot().
closest_pair_brute,
a Fortran90 code which
uses brute force to solve a 2D version of the closest pair problem,
which identifies the closest pair of points in a given collection.
closest_point_brute,
a Fortran90 code which
uses brute force to find the nearest of a set of N points in D
dimensions to a given test point. This is sometimes called a
nearest neighbor calculation.
cnf_io,
a Fortran90 code which
reads or writes DIMACS Conjunctive Normal Form (CNF) files
defining satisfiability problems in terms of a boolean formula.
color_digraph_adj,
a Fortran90 code which
carries out operations on color digraphs, a directed graph in which
each node has been assigned a color. That information is stored in
an adjacency matrix in which the diagonal elements record colors.
Operations include counting the colors, computing in- and out-degrees,
computing the in- and out-degree sequences, counting the edges,
printing the adjacency matrix, generating fixed and random examples.
color_graph_adj,
a Fortran90 code which
carries out operations on color graphs, an undirected graph in which
each node has been assigned a color. That information is stored in
an adjacency matrix in which the diagonal elements record colors.
Operations include counting the colors, computing degrees,
computing the degree sequences, counting the edges,
printing the adjacency matrix, generating fixed and random examples.
communicator_mpi,
a Fortran90 code which
creates new communicators involving a subset of initial
set of MPI processes in the default communicator MPI_COMM_WORLD.
companion_matrix,
a Fortran90 code which
computes the companion matrix for a polynomial.
The polynomial may be represented in the standard monomial basis,
or as a sum of Chebyshev, Gegenbauer, Hermite, Laguerre, or Lagrange
basis polynomials. All the roots of the polynomial can be determined as
the eigenvalues of the corresponding companion matrix.
compass_search,
a Fortran90 code which
seeks the minimizer of a scalar function of several variables
using compass search,
a direct search algorithm that does not use derivatives.
complex_numbers_test,
a Fortran90 code which
demonstrates some simple features involved in the use of
complex numbers.
components,
a Fortran90 code which
organizes contiguous cells into labeled clusters, for a
1D, 2D, or 3D array. This code has uses in image analysis
and percolation simulation.
continuity_exact,
a Fortran90 code which
returns a 2D velocity vector field (u,v)(x,y) which is an exact
solution of the partial differential equation (PDE) sometimes
called the continuity equation of fluid mechanics, which
has the form ux + vy = 0.
cross_chaos,
a Fortran90 code which
creates a dot-plot of an elaborate cross by repeatedly applying
a randomized linear transformation to a starting point.
crystal_coordinates,
a Fortran90 code which
generates the coordinates of a set of 4 * NX * NY * NZ
points in a rectangular block of NX * NY * NZ cells, with
face-centered cubic (FCC) symmetry.
cuda_loop,
a Fortran90 code which
shows how, in a CUDA program running on a Graphics Processing
Unit (GPU), the choice of block and thread factors determines
the allocation of tasks to processors.
cvt_basis,
a Fortran90 code which
uses discrete Centroidal Voronoi Tessellation (CVT) techniques to
produce a small set of basis vectors that are good cluster centers
for a large set of data vectors;
cvt_basis_flow,
a Fortran90 code which
extracts dominant solution modes from solutions of a flow
problem governed by the Navier Stokes Equations (NSE)
using Centroidal Voronoi Tessellation (CVT) methods.
cvt_box,
a Fortran90 code which
calculates a Centroidal Voronoi Tessellation (CVT)
constrained to a box region, with points projected to the boundary;
differ,
a Fortran90 code which
is given function values at equally spaced locations, and the
order of a derivative, and uses the finite difference method (FDM)
to compute a linear combination of these function values which
approximated that derivative.
digraph_adj,
a Fortran90 code which
carries out operations on digraphs, a directed graph.
Information is stored in an adjacency matrix.
Operations include computing in- and out-degrees,
computing the in- and out-degree sequences, counting the edges,
printing the adjacency matrix, generating fixed and random examples.
digraph_arc,
a Fortran90 code which
carries out operations on digraphs, a directed graph.
Information is stored in an arc list, pairs of nodes forming edges.
Operations include computing in- and out-degrees,
computing the in- and out-degree sequences, counting the edges,
printing the arc list, generating fixed and random examples.
dirichlet,
a Fortran90 code which
evaluates the Dirichlet kernel function, sometimes called the periodic
sinc function. The function includes a parameter n, normally
taken to be an integer.
The function is defined by diric(x,n)=sin(0.5*n*x)/n/sin(0.5*x).
Sample plots of these functions are made.
discrete_pdf_sample_2d,
a Fortran90 code which
demonstrates how to construct a Probability Density Function (PDF)
from a table of sample data, and then to use that PDF to create
new samples.
disk_grid,
a Fortran90 code which
computes grid points within the interior of
a disk of user specified radius and center in 2D,
using gnuplot() to create an image of the grid.
disk01_positive_monte_carlo,
a Fortran90 code which
applies a Monte Carlo method to estimate the integral of a function
over the interior of the unit positive disk in 2D;
divdif,
a Fortran90 code which
creates, prints and manipulates divided difference polynomials from
a table of values (x,f(x)). The code can compute the coefficients of
the Newton and power sum forms of the interpolating polynomial. It
can compute the derivative or antiderivate polynomial. It can compute
the form of the Lagrange basis polynomials. It can compute the
points and weights for Newton Cotes quadrature rules. It can compute
the weights for a Lagrange interpolation scheme.
doomsday,
a Fortran90 code which
is given the year, month and day of a date, and uses
John Conway's doomsday algorithm
to determine the corresponding day of the week.
doughnut_exact,
a Fortran90 code which
evaluates an exact solution of a system of ordinary differential
equations (ODE) whose trajectories lie on a torus or doughnut,
and for which an exact solution is known.
doughnut_ode,
a Fortran90 code which
sets up and solves a system of ordinary differential equations
(ODE) whose trajectories lie on a torus or doughnut, and for which
an exact solution is known.
dqed,
a Fortran90 code which
solves (square) systems of nonlinear equations, or minimizes the
residual in a set of nonlinear equations, using least squares,
by Richard Hanson and Fred Krogh.
dream,
a Fortran90 code which
implements the DREAM algorithm for accelerating
Markov Chain Monte Carlo (MCMC) convergence using differential
evolution,
using five user functions to define the problem, by Guannan Zhang.
edge,
a Fortran90 code which
defines some test functions in 1D, 2D and 3D for the detection
of edges or discontinuities. It uses gnuplot() to display the
jumps in curves and surfaces.
eispack,
a Fortran90 code which
carries out eigenvalue computations.
It includes a function to compute the singular value decomposition (SVD)
of a rectangular matrix.
superseded by lapack();
ellipse,
a Fortran90 code which
carries out geometric calculations for ellipses and ellipsoids,
including area, distance to a point, eccentricity, perimeter, points
along the perimeter, random sampling, conversion between standard
and quadratic forms.
ellipsoid,
a Fortran90 code which
carries out geometric calculations for ellipsoids, including
area, random sampling, conversion between standard and quadratic
forms.
ellipsoid_monte_carlo,
a Fortran90 code which
uses the Monte Carlo method to estimate the value of integrals
over the interior of an ellipsoid in M dimensions.
elliptic_integral,
a Fortran90 code which
evaluates complete elliptic integrals of first, second and third kind,
using the Carlson elliptic integral functions.
etdrk4,
a Fortran90 code which
uses the ETD RK4 method to solve systems of stiff ordinary
differential equations (ODE),
by Aly-Khan Kassam, Lloyd Trefethen.
exactness,
a Fortran90 code which
investigates the exactness of quadrature rules that estimate the
integral of a function with a density, such as 1, exp(-x) or
exp(-x^2), over an interval such as [-1,+1], [0,+oo) or (-oo,+oo).
extract,
a Fortran90 code which
pulls a copy of a Fortran
block data, function, module, program or subroutine from a big file,
and saves the copy in a little file.
f90_combinatorics,
a Fortran90 code which
considers a variety of problems in combinatorics involving
counting, combinations, permutations, and so on.
f90_exact,
a Fortran90 code which
evaluates exact solutions to a few selected examples of
ordinary differential equations (ODE) and partial differential
equations (PDE).
f90_monte_carlo,
a Fortran90 code which
uses Monte Carlo sampling to estimate areas and integrals.
f90_ode,
a Fortran90 code which
sets up various systems of ordinary differential equations (ODE).
f90_ode_solver,
a Fortran90 code which
solves one or more differential equations (ODE) using a method of a
particular order, either explicit or implicit. Some methods require
a nonlinear equation solver. Some methods used a fixed stepsize,
while others adapt the stepsize based on an error estimate.
f90_random_test,
a Fortran90 code which
calls the random number generator (RNG) routines.
f90_rule,
a Fortran90 code which
computes a quadrature rule which
estimates the integral of a function f(x), which might be defined over
a one dimensional region (a line) or more complex shapes such as
a circle, a triangle, a quadrilateral, a polygon, or a higher
dimensional region, and which might include an associated weight
function w(x).
f90_simulation,
a Fortran90 code which
uses simulation to study card games, contests, and other processes
which have a random element. Usually, the purpose is to try to
predict the average behavior of the system over many trials.
f90split,
a Fortran90 code which
reads a Fortran file and creates individual files for every
blockdata, function, module, program, or subroutine in the file.
fair_dice_simulation,
a Fortran90 code which
simulates N games where two fair dice are thrown and summed,
creating graphics files for processing by gnuplot().
fd_predator_prey,
a Fortran90 code which
solves a pair of predator prey ordinary differential equations (ODE)
using the finite difference method (FDM), and plots the data with
gnuplot().
fd1d_advection_diffusion_steady,
a Fortran90 code which
applies the finite difference method (FDM) to solve the
steady advection diffusion equation v*ux-k*uxx=0 in
one spatial dimension, with constant velocity v and diffusivity k,
writing graphics files for processing by gnuplot().
fd1d_advection_ftcs,
a Fortran90 code which
applies the finite difference method (FDM) to solve the time-dependent
advection equation ut = - c * ux in one spatial dimension, with
a constant velocity, using the forward time centered space (FTCS)
method, writing graphics files for processing by gnuplot().
fd1d_advection_lax,
a Fortran90 code which
applies the finite difference method (FDM) to solve the time-dependent
advection equation ut = - c * ux in one spatial dimension, with
a constant velocity, using the Lax method to approximate the
time derivative, writing graphics files for processing by gnuplot().
fd1d_advection_lax_wendroff,
a Fortran90 code which
applies the finite difference method (FDM) to solve the time-dependent
advection equation ut = - c * ux in one spatial dimension, with
a constant velocity, using the Lax-Wendroff method to approximate the
time derivative,
writing graphics files for processing by gnuplot().
fd1d_burgers_lax,
a Fortran90 code which
applies the finite difference method (FDM) and the Lax Wendroff method
to solve the non-viscous time-dependent Burgers equation
in one spatial dimension.
fd1d_burgers_leap,
a Fortran90 code which
applies the finite difference method (FDM) and the leapfrog approach
to solve the non-viscous time-dependent Burgers equation
in one spatial dimension.
fd1d_predator_prey,
a Fortran90 code which
implements the finite difference method (FDM) for a predator-prey
system with time and 1D spatial dependence, by Marcus Garvie.
fd1d_wave,
a Fortran90 code which
applies the finite difference method (FDM) to solve the time-dependent
wave equation utt = c * uxx in one spatial dimension.
fem_basis,
a Fortran90 code which
defines and evaluates basis functions associated with
the finite element method (FEM) for any degree
in an M-dimensional simplex: 1D interval, 2D triangle,
3D tetrahedron, and higher dimensional generalizations.)
fem_io,
a Fortran90 code which
reads or writes FEM files,
which describe the nodes, elements, and function values
associated with a finite element method (FEM) model;
fem_to_gmsh,
a Fortran90 code which
reads a pair of FEM files defining node coordinates and elements,
of a 1D, 2D or 3D mesh, namely
a file of node coordinates and a file of elements defined by
node indices, and creates a gmsh() mesh file.
fem_to_medit,
a Fortran90 code which
reads FEM files defining the node coordinates, boundary
nodes, and elements of a finite element mesh, and rewrites the data
as a medit() MESH file.
fem_to_triangle,
a Fortran90 code which
reads FEM files defining a 2D mesh of triangles, namely
a file of node coordinates and a file of elements defined by
node indices, and creates a corresponding pair of node
and element files for Jonathan Shewchuk's triangle() program
fem_to_xml,
reads a pair of FEM files defining node coordinates and elements,
of a 1D, 2D or 3D mesh, namely
a file of node coordinates and a file of elements defined by
node indices, and creates a corresponding XML file for input
to dolfin() or fenics().
fem1d,
a Fortran90 code which
applies the finite element method (FEM),
using piecewise linear basis functions, to a linear
two point boundary value problem (BVP) in 1D;
fem1d_adaptive,
a Fortran90 code which
uses an adaptive mesh when
applying the finite element method (FEM),
with piecewise linear basis functions, to a linear
two point boundary value problem (BVP) in 1D;
fem1d_bvp_linear,
a Fortran90 code which
applies the finite element method (FEM),
with piecewise linear elements,
to a two point boundary value problem (BVP) in one spatial dimension,
and compares the computed and exact solutions
with the L2 and seminorm errors.
fem1d_bvp_quadratic,
a Fortran90 code which
applies the finite element method (FEM),
with piecewise quadratic elements,
to a two point boundary value problem (BVP) in one spatial dimension,
and compares the computed and exact solutions
with the L2 and seminorm errors.
fem1d_lagrange,
a Fortran90 code which
sets up the matrices and vectors associated with the finite element
method (FEM) solution of a boundary value problem (BVP) -u''+u=f(x),
using Lagrange basis polynomials.
fem1d_nonlinear,
a Fortran90 code which
applies the finite element method (FEM),
with piecewise linear basis functions, to a nonlinear
two point boundary value problem (BVP) in 1D;
fem1d_pmethod,
a Fortran90 code which
applies the p-method version of
the finite element method (FEM) to a linear
two point boundary value problem (BVP) in 1D;
fem1d_project,
a Fortran90 code which
projects data into a finite element space, including the least squares
approximation of data, or the projection of a finite element solution
from one mesh to another.
fem1d_sample,
a Fortran90 code which
samples a scalar or vector finite element function of one variable,
defined by FEM files,
returning interpolated values at the sample points.
fem2d_bvp_linear,
a Fortran90 code which
applies the finite element method (FEM),
with piecewise linear elements,
to a 2D boundary value problem (BVP) in a rectangle,
and compares the computed and exact solutions
with the L2 and seminorm errors.
fem2d_bvp_quadratic,
a Fortran90 code which
applies the finite element method (FEM),
with piecewise quadratic elements,
to a 2D boundary value problem (BVP) in a rectangle,
and compares the computed and exact solutions
with the L2 and seminorm errors.
fem2d_bvp_serene,
a Fortran90 code which
applies the finite element method (FEM), with serendipity elements,
to a 2D boundary value problem (BVP) in a rectangle,
and compares the computed and exact solutions
with the L2 and seminorm errors.
fem2d_heat,
a Fortran90 code which
uses the finite element method (FEM) and the backward
Euler method to solve the time-dependent heat equation
on an arbitrary triangulated region in 2D. The user supplies
some information in some problem-dependent subroutines.
fem2d_heat_rectangle,
a Fortran90 code which
implements the finite element method (FEM) for
the time dependent heat equation on a triangulated
square in 2D;
fem2d_poisson_rectangle,
a Fortran90 code which
solves the 2D Poisson equation on a rectangle,
using the finite element method (FEM),
and piecewise quadratic triangular elements.
fem2d_poisson_rectangle_linear,
a Fortran90 code which
solves the 2D Poisson equation on a rectangle,
using the finite element method (FEM),
and piecewise linear triangular elements.
fem2d_project,
a Fortran90 code which
projects a function f(x,y), given as a data,
into a given finite element method (FEM) space
of piecewise linear (PWL) triangular elements.
fem2d_project_function,
a Fortran90 code which
projects a function f(x,y), given as a formula,
into a given finite element method (FEM) space
of piecewise linear (PWL) triangular elements.
fem2d_sample,
a Fortran90 code which
samples at arbitray points a finite element function,
defined by FEM files,
three text files describing the nodes, triangles, and coefficients.
fem3d_project,
a Fortran90 code which
projects a function F(X,Y,Z), given as tabulated data,
into a space of piecewise linear (PWL) tetrahedral elements
associated with the finite element method (FEM).
fermat_factor,
a Fortran90 code which
uses Fermat's factorization method to decompose an integer
N into the product of two factors, N = A^2-B^2 = (A+B)*(A-B).
fftw_test,
a Fortran90 code which
calls fftw(), which
computes Fast Fourier Transforms (FFT),
by Matteo Frigo and Steven Johnson.
file_name_sequence,
a Fortran90 code which
demonstrates ways to generate a sequence of filenames, which can
be useful when generating a sequence of still snapshots
to be animated later.
files_multiple,
a Fortran90 code which
demonstrates how a program can open multiple output files at one time,
and write data to any one specific file it chooses.
filon_rule,
a Fortran90 code which
uses Filon's method to approximate integrals which include an
oscillatory factor of sin(k*x) or cos(k*x).
fisher_exact,
a Fortran90 code which
returns an exact solution u(x,t) of the Kolmogorov Petrovsky Piskonov
Fisher partial differential equation (PDE): ut=uxx+u*(1-u).
flame_exact,
a Fortran90 code which
returns the exact solution y(t) of an ordinary differential equation
(ODE) which models the growth of a ball of flame in a combustion process.
The exact solution is defined in terms of the Lambert W function.
fsolve,
a Fortran90 code which
solves systems of nonlinear equations,
inspired by the fsolve() function in minpack(),
with special interfaces fsolve_bdf2(), fsolve_be() and
fsolve_tr() for handling systems associated
with implicit ODE solvers of type bdf2, backward Euler,
midpoint, or trapezoidal.
geometry,
a Fortran90 code which
performs geometric calculations in 2, 3 and M dimensional space,
including the computation of angles, areas, containment, distances,
intersections, lengths, and volumes.
gfortran_quadmath_test,
a Fortran90 code which
illustrates the use of quadruple real precision arithmetic
with the Gnu Fortran compiler.
gl_fast_rule,
a Fortran90 code which
carries out the rapid computation of the Kth value and weight of
an N point Gauss-Legendre quadrature rule,
by Ignace Bogaert.
glomin,
a Fortran90 code which
finds a global minimum of a scalar function of a scalar variable,
without the use of derivative information,
by Richard Brent.
gmsh_to_fem,
a Fortran90 code which
reads a mesh data file created by gmsh()
and writes a pair of node and element files that correspond
to the FEM format.
gnuplot_test,
a Fortran90 code which
uses gnuplot() to create various kinds of plots.
gprof_test,
a Fortran90 code which
uses the gprof() profiling tool.
graph_adj,
a Fortran90 code which
carries out operations on abstract graphs, with undirected edges,
represented by an adjacency matrix. Operations include breadth-first
search, the computation of a minimum spanning tree,
an Euler or Hamilton circuit, blocks, chromatic polynomial,
or transitive closure.
graph_arc,
a Fortran90 code which
carries out operations on graphs.
Information is stored in an arc list, pairs of nodes forming edges.
Operations include the chromatic polynomial, computing degrees,
computing the degree sequence, counting the edges,
determining edge and node connectivity, Euler circuits,
spanning trees, shortest path,
printing the arc list, generating fixed and random examples.
graph_theory,
a Fortran90 code which
carries out operations on abstract graphs, such as a
breadth-first-search, the computation of a minimum spanning tree,
an Euler or Hamilton circuit, blocks, chromatic polynomial, or
transitive closure. Objects include undirected and directed
graphs, weighted graphs, and trees.
hankel_cholesky,
a Fortran90 code which
computes the upper Cholesky factor R of a
symmetric positive definite (SPD) Hankel matrix H so that H = R' * R.
hankel_spd,
a Fortran90 code which
computes a lower triangular matrix L that is the Cholesky factor
of a symmetric positive definite (SPD) Hankel matrix H, that is,
H = L * L'.
heated_plate,
a Fortran90 code which
solves the steady (time independent) heat equation in a 2D
rectangular region, and is intended as
a starting point for implementing a parallel version.
A contour plot of the solution is created using gnuplot().
heated_plate_openmp,
a Fortran90 code which
solves the steady (time independent) heat equation in a 2D
rectangular region, using OpenMP to run in parallel.
helmholtz_exact,
a Fortran90 code which
evaluates an exact solution z(x,y) for the Helmholtz equation,
a sort of eigenvalue version of a partial differential equation (PDE)
arising after separation of variables is a applied to the wave
equation.
This example considers a problem in which z(x,y) represents the vertical
deflection of the surface of a vibrating circular membrane such as
a drumhead. The Helmholtz equation has the form
- del^2 Z = k^2 Z.
helmholtz_openmp,
a Fortran90 code which
solves the discretized Helmholtz equation in 2D
using the OpenMP application program interface
for carrying out parallel computations in a shared memory environment.
hermite_cubic,
a Fortran90 code which
computes the value, derivatives or integral of
a Hermite cubic polynomial, or manipulate an interpolating function
made up of piecewise Hermite cubic polynomials.
hermite_exactness,
a Fortran90 code which
tests the monomial exactness of quadrature rules for estimating
Hermite-type integrals of a function f(x) with density
rho(x)=exp(-x^2) over the interval (-oo,+oo).
hermite_polynomial,
a Fortran90 code which
evaluates the physicist's Hermite polynomial,
the probabilist's Hermite polynomial,
the Hermite function, and related functions.
hermite_product_polynomial,
a Fortran90 code which
defines Hermite product polynomials, creating a multivariate
polynomial as the product of univariate Hermite polynomials.
hex_grid_angle,
a Fortran90 code which
produces a hexagonal grid of points in the unit
square or an arbitrary box, allowing the user to specify an
arbitrary center, angle, and grid density.
hexahedron_jaskowiec_rule,
a Fortran90 code which
returns a symmetric Jaskowiec quadrature rule for the hexahedron,
with exactness up to total degree 21.
hexahedron_witherden_rule,
a Fortran90 code which
returns a symmetric Witherden quadrature rule for the hexahedron,
with exactness up to total degree 11.
high_card_simulation,
a Fortran90 code which
simulates a situation in which you see the cards in a deck one by one,
and must select the one you think is the highest and stop;
using gnuplot() for graphics.
hyper_2f1,
a Fortran90 code which
evaluates the hypergeometric functions 2F1(a,b,c;x) for real
or complex parameters a, b, c, and argument x,
by N. Michel and M. Stoitsov.
hyperball_integrals,
a Fortran90 code which
returns the exact value of the integral of any monomial
over the interior of the unit hyperball in M dimensions.
hyperball_monte_carlo,
a Fortran90 code which
applies a Monte Carlo method to estimate the integral of a function
over the interior of the unit ball in M dimensions;
hypercube_exactness,
a Fortran90 code which
tests the polynomial exactness of a quadrature rule
over the interior of the unit hypercube in M dimensions.
hypercube_integrals,
a Fortran90 code which
returns the exact value of the integral of any monomial
over the interior of the unit hypercube in M dimensions.
hypercube_monte_carlo,
a Fortran90 code which
applies a Monte Carlo method to estimate the integral of a function
over the interior of the unit hypercube in M dimensions.
hypergeometric,
a Fortran90 code which
evaluates the generalized hypergeometric functions pFq,
for integer p and q, for complex arguments of large magnitude,
by Warren Perger, Atul Bhalla, and Mark Nardin.
hypersphere,
a Fortran90 code which
carries out various operations for an M dimensional hypersphere,
including converting between Cartesian and spherical coordinates,
stereographic projection, sampling the surface of the sphere, and
computing the surface area and volume.
hypersphere_integrals,
a Fortran90 code which
returns the exact value of the integral of any monomial
over the surface of the unit hypersphere in M dimensions.
hypersphere_monte_carlo,
a Fortran90 code which
applies a Monte Carlo method to estimate the integral of a function
on the surface of the unit sphere in M dimensions;
ising_2d_simulation,
a Fortran90 code which
carries out a Monte Carlo simulation of an Ising model,
a 2D array of positive and negative charges,
each of which is likely to flip to be in agreement with neighbors,
using gnuplot() to make images of the initial and final
configurations.
ising_3d_simulation,
a Fortran90 code which
carries out a Monte Carlo simulation of an Ising model,
a 3D array of positive and negative charges,
each of which is likely to flip to be in agreement with neighbors.
jacobi_eigenvalue,
a Fortran90 code which
implements the Jacobi iteration for the determination
of the eigenvalues and eigenvectors of a real symmetric matrix.
kdv_exact,
a Fortran90 code which
evaluates an exact solution u(x,t) of the Korteweg-deVries (KdV)
partial differential equation (PDE), representing the motion of a
soliton. The equation has the form u' - 6 u ux + uxxx = 0.
knapsack_01_brute,
a Fortran90 code which
uses brute force to solve small versions of the 0/1 knapsack problem,
in which a knapsack of limited weight capacity is to be packed as
full as possible, selecting items from a set of varying weights;
knapsack_brute,
a Fortran90 code which
uses brute force to solve small versions of the knapsack problem,
in which N items are available, each with given value and weight.
A thief's knapsack can carry no more than Wmax pounds. The thief
seeks a selection of items to carry in the knapsack of maximum
total value.
knapsack_random,
a Fortran90 code which
randomly chooses a subset of N items, each with given value and weight.
It then evaluates whether this is a feasible solution to a
problem in which a thief's knapsack can carry no more than Wmax pounds,
and it is desired to maximum the total value of the selected items.
knapsack_rational,
a Fortran90 code which
solves the rational knapsack problem, in which a knapsack of limited
weight capacity is filled with profitable items. This variation of
the 0/1 knapsack problem allows a fractional part of an item to
be included in the knapsack. The result is an upper bound on the
maximum possible profit for the 0/1 knapsack problem.
knapsack_values,
a Fortran90 code which
returns some simple examples of the knapsack problem,
in which N items are available, each with given value V and weight W.
A thief's knapsack can carry no more than K pounds. The thief
seeks a selection S of items to carry in the knapsack of maximum
total value.
kronrod_rule,
a Fortran90 code which
computes a Gauss and Gauss-Kronrod pair of quadrature rules
of arbitrary order,
by Robert Piessens, Maria Branders.
lagrange,
a Fortran90 code which
evaluates any Lagrange basis polynomial L(i)(x), its antiderivative,
or its first or second derivatives. Sample plots are made.
lagrange_interp_1d,
a Fortran90 code which
evaluates the Lagrange polynomial p(x)
which interpolates data depending on a 1D argument,
so that p(x(i)) = y(i).
lagrange_interp_2d,
a Fortran90 code which
evaluates the Lagrange polynomial p(x,y)
which interpolates data depending on a 2D argument
that was evaluated on a product grid,
so that p(x(i),y(j)) = z(i,j).
lagrange_interp_nd,
a Fortran90 code which
evaluates the Lagrange polynomial p(x) which
interpolates data depending on a multidimensional argument
that was evaluated on a product grid,
so that p(x(i)) = z(i).
laguerre_exactness,
a Fortran90 code which
tests the monomial exactness of Gauss-Laguerre quadrature rules
for estimating the integral of a function f(x) with density
rho(x)=exp(-x) over the interval [0,+oo).
laguerre_integrands,
a Fortran90 code which
implements test problems for Gauss-Laguerre quadrature rules
for estimating the integral of a function with density exp(-x)
over the interval [0,+oo).
laguerre_rule,
a Fortran90 code which
computes and print a Gauss-Laguerre quadrature rule
for estimating the integral of a function with density exp(-x)
over the interval [0,+oo).
lapack_test,
a Fortran90 code which
calls lapack(), which
is a standard linear algebra package for solving linear systems,
computing matrix factorizations, and solving eigenvalue problems.
A precompiled copy of the lapack() library is often available
on most scientific computing systems.
lapack_d,
a Fortran90 code which
is the double precision real version of the lapack()
linear algebra code.
laplacian_matrix,
a Fortran90 code which
carries out computations related to the discrete
Laplacian operator, including full or sparse evaluation,
evaluation for unequally spaced data sampling points,
application to data samples, solution of associated
linear systems, eigenvalues and eigenvectors, and extension
to 2D and 3D geometry.
lau_np,
a Fortran90 code which
implements heuristic algorithms for various NP-hard
combinatorial problems, including the integer linear programming
problem, the K-center problem, the K-median problem, the 0-1 knapsack
problem, the multiple knapsack problem, the graph matching problem,
the graph partitioning problem, the minimal Steiner tree problem,
and the traveling salesman problem;
lebesgue,
a Fortran90 code which
is given nodes in 1D, and
plots the Lebesgue function, and estimates the Lebesgue constant,
which measures the maximum magnitude of the potential error
of Lagrange polynomial interpolation, and which uses gnuplot()
to make plots of the Lebesgue function.
legendre_exactness,
a Fortran90 code which
tests the monomial exactness of quadrature rules for estimating
Legendre-type integrals of a function f(x) with density rho(x)=1
over the interval [-1,+1].
legendre_fast_rule,
a Fortran90 code which
uses a fast algorithm to compute a Gauss-Legendre quadrature rule
for estimating the integral of a function with density rho(x)=1
over the interval [-1,+1].
legendre_product_polynomial,
a Fortran90 code which
defines Legendre product polynomials, creating a multivariate
polynomial as the product of univariate Legendre polynomials.
legendre_rule,
a Fortran90 code which
computes Gauss-Legendre quadrature rules
for estimating the integral of a function with density rho(x)=1
over the interval [-1,+1].
levy_dragon_chaos,
a Fortran90 code which
creates a dot-plot of the Levy dragon by repeatedly applying
a randomized linear transformation to a starting point.
line_cvt_lloyd,
a Fortran90 code which
applies the Lloyd iteration repeatedly to N points,
to compute a Centroidal Voronoi Tessellation (CVT)
over the interior of a line segment in 1D.
line_fekete_rule,
a Fortran90 code which
estimates the location of N Fekete points, for polynomial
interpolation or quadrature,
over the interior of a line segment in 1D.
line_ncc_rule,
a Fortran90 code which
computes a Newton Cotes Closed (NCC) quadrature rule,
using equally spaced points,
over the interior of a line segment in 1D.
line_nco_rule,
a Fortran90 code which
computes a Newton Cotes Open (NCO) quadrature rule,
using equally spaced points,
over the interior of a line segment in 1D.
linpack_d,
a Fortran90 code which
factors and solves linear systems using double precision arithmetic,
by Jack Dongarra, Jim Bunch, Cleve Moler, Pete Stewart.
The matrix and vector data is assumed to be real.
linpack_z,
a Fortran90 code which
factors and solves linear systems using double precision arithmetic,
by Jack Dongarra, Jim Bunch, Cleve Moler, Pete Stewart.
The matrix and vector data is assumed to be complex.
llsq,
a Fortran90 code which
solves the simple linear least squares (LLS) problem of finding the
formula of a straight line y=a*x+b which minimizes the root mean
square error to N data points.
local_min,
a Fortran90 code which
finds a local minimum of a scalar function of a scalar variable,
without the use of derivative information,
by Richard Brent.
local_min_rc,
a Fortran90 code which
finds a local minimum of a scalar function of a scalar variable,
without the use of derivative information,
using reverse communication (RC),
by Richard Brent.
log_normal_truncated_ab,
a Fortran90 code which
returns quantities related to the log normal Probability
Distribution Function (PDF) truncated to the interval [A,B].
logistic_exact,
a Fortran90 code which
evaluates an exact solution y(t) of the logistic equation,
which models population growth in the face of a limited carrying capacity,
an ordinary differential equation (ODE) of the
y' = r * ( y - y^2 / k ).
lorenz_ode,
a Fortran90 code which
approximates solutions to the Lorenz system of ordinary differential
equations (ODE),
creating output files that can be displayed by gnuplot().
lorenz96_ode,
a Fortran90 code which
sets up and solves a system of ordinary differential equations
(ODE) devised by Edward Lorenz, as a test of predictability for
data assimilation applications.
mandelbrot_openmp,
a Fortran90 code which
generates an ASCII Portable Pixel Map (PPM) image
of the Mandelbrot fractal set,
using OpenMP for parallel execution.
matman,
a Fortran90 code which
allows a user to interactively define and manipulate matrices
using integer, real, or rational arithmetic, and to perform
various operations in linear algebra or linear programming modes.
matrix_chain_brute,
a Fortran90 code which
finds the cost of the most efficient ordering to use when
multiplying a sequence of matrices, using brute force.
matrix_chain_dynamic,
a Fortran90 code which
finds the cost of the most efficient ordering to use when
multiplying a sequence of matrices, using dynamic programming.
menger_sponge_chaos,
a Fortran90 code which
creates a dot-plot of the 3D Menger sponge by repeatedly applying
a randomized linear transformation to a starting point.
mgmres,
a Fortran90 code which
applies the restarted Generalized Minimum Residual (GMRES) algorithm
to solve a sparse linear system, using Compressed Row Storage (CRS) or
sparse triplet (ST) format, by Lili Ju.
mgs,
a Fortran90 code which
is an obscure legacy code, which the student is encouraged to
study, understand, and document. This example is due to Diane O'Leary.
middle_square,
a Fortran90 code which
implements the middle square algorithm for generating random integers.
This is a very early method, attributed to von Neumann, which actually
is deeply flawed, with short cycles.
midpoint,
a Fortran90 code which
solves one or more ordinary differential equations (ODE)
using the (implicit) midpoint method, with a version of
fsolve() handling the associated nonlinear equation,
and using a fixed time step.
midpoint_adaptive,
a Fortran90 code which
solves one or more ordinary differential equations (ODE)
using the (implicit) midpoint method, with fsolve() solving
the implicit equation, and an adaptive time step.
Plots of the solution and timestep history are created using gnuplot().
midpoint_explicit,
a Fortran90 code which
solves one or more ordinary differential equations (ODE)
using the (explicit) midpoint method, also called the
modified Euler method.
midpoint_fixed,
a Fortran90 code which
solves one or more ordinary differential equations (ODE)
using the (implicit) midpoint method, using a fixed point
iteration for the nonlinear equation.
minpack,
a Fortran90 code which
solves systems of nonlinear equations, or the least squares
minimization of the residual of linear or nonlinear equations,
by Jorge More, Danny Sorenson, Burton Garbow, Kenneth Hillstrom.
monomial,
a Fortran90 code which
enumerates, lists, ranks, unranks and randomizes multivariate
monomials in a space of M dimensions, with total degree less than N,
equal to N, or lying within a given range.
multitask_mpi,
a Fortran90 code which
demonstrates how to multitask, that is, to execute several unrelated
and distinct tasks simultaneously, using
the message passing interface (MPI) for parallel execution.
multitask_openmp,
a Fortran90 code which
demonstrates how to multitask, that is, to execute several unrelated
and distinct tasks simultaneously, using OpenMP for parallel
execution.
naca,
a Fortran90 code which
takes the parameters of certain NACA airfoils and returns the
coordinates of a sequence of points that outline the wing shape.
The data is displayed with the gnuplot() graphics program.
navier_stokes_2d_exact,
a Fortran90 code which
evaluates an exact solution to the incompressible time-dependent
Navier-Stokes equations (NSE) over an arbitrary domain in 2D.
navier_stokes_3d_exact,
a Fortran90 code which
evaluates an exact solution to the incompressible time-dependent
Navier-Stokes equations (NSE) over an arbitrary domain in 3D.
nearest_interp_1d,
a Fortran90 code which
interpolates data using a piecewise constant interpolant
defined by the nearest neighbor criterion,
creating graphics files for processing by gnuplot().
neighbors_to_metis_graph,
a Fortran90 code which
reads a file describing the neighbor
structure of a mesh of triangles or tetrahedrons, and writes a
metis_graph() file suitable for input to one of the family of
programs based on metis();
nint_exactness_mixed,
a Fortran90 code which
measures the exactness of an M-dimensional quadrature rule
based on a mixture of 1D quadrature rule factors.
nms,
a Fortran90 code which
includes a wide variety of numerical software, including
solvers for linear systems of equations, interpolation of data,
numerical quadrature, linear least squares (LLS) data fitting,
the solution of nonlinear equations,
ordinary differential equations (ODE), optimization and
nonlinear least squares (NLS), simulation and random numbers,
trigonometric approximation and Fast Fourier Transforms (FFT).
openmp_test,
a Fortran90 code which
uses OpenMP, which
is an application program interface
for carrying out parallel computations in a shared memory environment.
optimize_test,
a Fortran90 code which
looks at the use of automatic optimization by the compiler
to make the executable code run faster.
ornstein_uhlenbeck,
a Fortran90 code which
approximates solutions of the Ornstein-Uhlenbeck
stochastic ordinary differential equation (SDE) using the Euler method
and the Euler-Maruyama method,
and creating graphics files for processing by gnuplot().
padua,
a Fortran90 code which
returns the coordinates of the 2D Padua points,
as well as interpolation weights or quadrature weights,
and images of the points in gnuplot() graphics files.
partition_brute,
a Fortran90 code which
uses a brute force algorithm to seek solutions of the partition
problem, splitting a set of integers into two subsets with equal sum.
patterson_rule,
a Fortran90 code which
returns the points and weights of a 1D Gauss-Patterson quadrature rule
of order 1, 3, 7, 15, 31, 63, 127, 255 or 511.
pce_burgers,
a Fortran90 code which
solves a version of the time-dependent viscous Burgers equation,
with uncertain viscosity,
using a polynomial chaos expansion in terms of Hermite polynomials,
by Gianluca Iaccarino.
pce_ode_hermite,
a Fortran90 code which
sets up a simple scalar ordinary differential equation (ODE)
for exponential decay with an uncertain decay rate,
using a polynomial chaos expansion in terms of Hermite polynomials.
pdb_to_xyz,
a Fortran90 code which
reads a Protein Data Bank (PDB) file,
and, for each ATOM record in the file, extracts the atomic
spatial coordinates and writes them to an XYZ file.
pdflib,
a Fortran90 code which
evaluates Probability Density Functions (PDF)
and produces random samples from them,
including beta, binomial, chi, exponential, gamma, inverse chi,
inverse gamma, multinomial, normal, scaled inverse chi, and uniform.
persistence,
a Fortran90 code which
demonstrates how to initialize, get, or set data stored
within a function, using static/persistent/saved/local memory.
poisson_1d,
a Fortran code which
solves a discretized version of the Poisson equation -uxx = f(x)
on the interval a ≤ x ≤ b, with Dirichlet boundary conditions
u(a) = ua, u(b) = ub.
The linear system is solved using Gauss-Seidel iteration.
poisson_2d_exact,
a Fortran90 code which
evaluates exact solutions u(x,y)
to the Poisson partial differential equation (PDE):
del^2 U = f(x,y) over a specified region with given boundary conditions.
poisson_openmp,
a Fortran90 code which
computes an approximate solution to the Poisson equation in a
rectangle, using the Jacobi iteration to solve the linear system,
and OpenMP to carry out the Jacobi iteration in parallel.
poisson_simulation,
a Fortran90 code which
simulates a Poisson process in which events randomly occur with an
average waiting time of Lambda, creating output for graphics
by gnuplot().
polygon,
a Fortran90 code which
computes properties of an arbitrary polygon in the plane, defined
by a sequence of vertices, including interior angles, area, centroid,
containment of a point, convexity, counter clockwise ordering,
diameter, distance to a point, inradius, lattice area, nearest
point in set, outradius, uniform sampling, and triangulation.
polygon_triangulate,
a Fortran90 code which
triangulates a possibly nonconvex polygon in 2D,
and which uses gnuplot() to display the external edges and
internal diagonals of the triangulation.
polynomial_conversion,
a Fortran90 code which
converts representations of a polynomial between monomial, Bernstein,
Chebyshev, Gegenbauer, Hermite, Laguerre and Legendre forms.
polynomials,
a Fortran90 code which
defines multivariate polynomials over rectangular domains, for
which certain information is to be determined, such as the maximum
and minimum values.
porous_medium_exact,
a Fortran90 code which
returns an exact solution u(x,t) of the porous medium equation (PME),
related to the diffusion equation, and based on the Barenblatt solution.
The partial differential equation (PDE) has the form
dudt=Del^2(u^m). This system reduces to a diffusion equation
if the exponent m is set to 1.
prism_jaskowiec_rule,
a Fortran90 code which
returns symmetric quadrature rules, with exactness up to total
degree 20, over the interior of a prism with triangular base,
by Jan Jaskowiec, Natarajan Sukumar.
prism_witherden_rule,
a Fortran90 code which
returns a symmetric Witherden quadrature rule for a prism with
triangular base, with exactness up to total degree 10.
ps_gg_align,
a Fortran90 code which
implements global string alignment algorithms which work in linear space,
and compute both the optimal score and the optimal alignment.
Gaps in the alignment are assigned an affine gap penalty.
The algorithms are due to Chao.
ps_lg_align,
a Fortran90 code which
implements local string alignment algorithms which work in linear space,
and compute both the optimal score and the optimal alignment.
Gaps in the alignment are assigned an affine gap penalty.
The algorithms are due to Chao.
ps_qg_align,
a Fortran90 code which
implements quasi-global string alignment algorithms which work in
linear space, and compute both the optimal score and the optimal
alignment.
Gaps in the alignment are assigned an affine gap penalty.
The algorithms are due to Chao.
pwl_interp_2d_scattered,
a Fortran90 code which
evaluates a piecewise linear interpolant to data which is available
at an irregularly arranged set of points.
pwl_product_integral,
a Fortran90 code which
calculates the exact value of the integral of the product of two
piecewise linear functions f(x) and g(x).
pyramid_jaskowiec_rule,
a Fortran90 code which
returns quadrature rules, with exactness up to total degree 20,
over the interior of a pyramid in 3D,
by Jan Jaskowiec, Natarajan Sukumar.
pyramid_monte_carlo,
a Fortran90 code which
applies a Monte Carlo method to estimate integrals of a function
over the interior of the unit pyramid in 3D;
pyramid_witherden_rule,
a Fortran90 code which
returns a Witherden quadrature rule, with exactness up to total
degree 10, over the interior of a pyramid.
quad_mpi,
a Fortran90 code which
approximates an integral using a quadrature rule, and carries out the
computation in parallel using the Message Passing Interface (MPI).
quad_serial,
a Fortran90 code which
approximates an integral using a quadrature rule,
and is intended as a starting point for parallelization exercises.
quad2d,
a Fortran90 code which
estimates an integral over a 2D rectangle using quadrature,
intended as the starting point for program optimization
or parallelization.
quadmom,
a Fortran90 code which
computes a Gaussian quadrature rule for a weight function rho(x)
based on the Golub-Welsch procedure that only requires knowledge
of the moments of rho(x).
quadrature_golub_welsch,
a Fortran90 code which
computes the points and weights of a Gaussian quadrature rule using the
Golub-Welsch procedure, assuming that the points have been specified.
quadrature_least_squares,
a Fortran90 code which
computes weights for sub-interpolatory quadrature rules,
that is, it estimates integrals by integrating a polynomial that
approximates the function data in a least squares sense.
quadrature_weights_vandermonde,
a Fortran90 code which
computes the weights of a quadrature rule using the Vandermonde
matrix, assuming that the points have been specified.
quadrature_weights_vandermonde_2d,
a Fortran90 code which
computes the weights of a 2D quadrature rule using the Vandermonde
matrix, assuming that the points have been specified.
quadrilateral_witherden_rule,
a Fortran90 code which
returns a symmetric Witherden quadrature rule for the quadrilateral,
with exactness up to total degree 21.
r8col,
a Fortran90 code which
contains utility routines for an R8COL, that is,
a double precision real MxN array, considered as N column vectors,
each of length M. The data may be thought of as a matrix of
multiple columns, and many operations will be carried out columnwise.
r8poly,
a Fortran90 code which
operates on real polynomials, including evaluation, differentiation,
integration, multiplication, synthetic division, shifting the
base, computing a power, taking the norm. It also defines
Chebyshev, Lagrange and Legendre polynomials.
r8row,
a Fortran90 code which
contains utilities for an R8ROW, that is,
a double precision real MxN array, considered as M row vectors,
each of length N. The data may be thought of as a matrix of
multiple rows, and many operations will be carried out rowwise.
random_data,
a Fortran90 code which
uses a random number generator (RNG) to sample points distributed
according to various probability density functions (PDF),
spatial dimensions, and geometries, including the M-dimensional cube,
ellipsoid, simplex and sphere.
random_mpi,
a Fortran90 code which
generates the same sequence of values from a
random number generator (RNG)
for both sequential execution and parallel execution under
the Message Passing Interface (MPI).
ranlib,
a Fortran90 code which
is a library of random number generators which
produces random samples from Probability Density Functions (PDF),
including Beta, Chi-square Exponential, F, Gamma, Multivariate normal,
Noncentral chi-square, Noncentral F, Univariate normal,
random permutations, Real uniform, Binomial, Negative Binomial,
Multinomial, Poisson and Integer uniform,
by Barry Brown and James Lovato.
rcm,
a Fortran90 code which
applies the Reverse Cuthill McKee (RCM) algorithm for
reordering the nodes of a graph, and reducing the bandwidth of a
corresponding sparse matrix;
reactor_simulation,
a Fortran90 code which
is a simple Monte Carlo simulation of the shielding effect of a slab
of a certain thickness in front of a neutron source. This was
provided as an example with the book 'Numerical Methods and Software'.
region,
a Fortran90 code which
reads 3D magnetic resonance imaging (MRI) voxel data, and groups
the voxels into connected regions, called components or segments;
rk1,
a Fortran90 code which
solves one or more ordinary differential equations (ODE)
using an explicit Runge-Kutta method of order 1, usually known
as Euler's explicit method.
rk1_implicit,
a Fortran90 code which
solves one or more ordinary differential equations (ODE)
using the Runge-Kutta order 1 implicit method, using fsolve()
to solve the implicit equation, and using a fixed time step.
rk1_implicit() is commonly called the backward Euler method.
rk2,
a Fortran90 code which
solves one or more ordinary differential equations (ODE)
using an explicit Runge-Kutta method of order 2,
also known as Heun's method, the modified Euler method, or
the explicit midpoint method.
rk2_implicit,
a Fortran90 code which
solves one or more ordinary differential equations (ODE)
using the Runge-Kutta order 2 implicit method, using fsolve()
to solve the implicit equation, and using a fixed time step.
rk2_implicit() is also known as the implicit midpoint method.
rnglib,
a Fortran90 code which
implements a random number generator (RNG) with splitting facilities,
allowing multiple independent streams to be computed,
by L'Ecuyer and Cote.
root_rc,
a Fortran90 code which
seeks a solution of a scalar nonlinear equation f(x) = 0,
or a system of nonlinear equations,
using reverse communication (RC), by Gaston Gonnet.
row_echelon_integer,
a Fortran90 code which
carries out the exact computation of the integer row echelon form
(IREF) and integer reduced row echelon form (IRREF) of an integer
matrix.
rref2,
a Fortran90 code which
computes the reduced row echelon
form (RREF) of a matrix, which can be used to analyze matrices
which are square or rectangular, singular or invertible.
runge,
a Fortran90 code which
evaluates the Runge() function, its first and second derivatives,
and its antiderivative. This function causes a breakdown for
polynomial interpolation over equally spaced nodes in [-1,+1].
The functions are plotted using gnuplot().
sandia_cvt,
a Fortran90 code which
positions a given number of points in an
arbitrary region, using probabilistic Centroidal Voronoi
Tessellation (CVT) techniques to achieve good coverage and
separation; developed for Sandia National Laboratory;
sandia_sparse,
a Fortran90 code which
produces a M-dimensional sparse grid, based on a variety of 1D
quadrature rules; only isotropic grids are generated, that is, the same
rule is used in each dimension, and the same maximum order is used in
each dimension.
satisfy_brute,
a Fortran90 code which
uses brute force to find all assignments of values to a set of
logical variables which make a complicated logical statement true.
satisfy_mpi,
a Fortran90 code which
demonstrates, for a particular circuit, an exhaustive search
for solutions of the circuit satisfiability problem, using
the Message Passing Interface (MPI) to work in parallel.
satisfy_openmp,
a Fortran90 code which
demonstrates, for a particular circuit, an exhaustive search
for solutions of the circuit satisfiability problem,
using OpenMP for parallel execution.
schedule_openmp,
a Fortran90 code which
demonstrates the default, static, and dynamic methods of scheduling
loop iterations in OpenMP to avoid work imbalance.
sde,
a Fortran90 code which
illustrates properties of
stochastic ordinary differential equations (SODE), and
common algorithms for their analysis, including the Euler method,
the Euler-Maruyama method, and the Milstein method,
making graphics files for processing and display by gnuplot(),
by Desmond Higham;
sftpack,
a Fortran90 code which
implements the slow Fourier transform, intended as a teaching
tool and comparison with the Fast Fourier Transform (FFT).
sierpinski_carpet_chaos,
a Fortran90 code which
creates a dot-plot of the Sierpinski carpet by repeatedly applying
a randomized linear transformation to a starting point.
sierpinski_triangle_chaos,
a Fortran90 code which
creates a dot-plot of the Sierpinski triangle by repeatedly applying
a randomized linear transformation to a starting point.
sigmoid,
a Fortran90 code which
evaluates derivatives of any order for the sigmoid function
s(x)=1/(1+exp(-x)). The test code creates graphics images
using gnuplot().
simplex_gm_rule,
a Fortran90 code which
defines Grundmann-Moeller quadrature rules
over the interior of a triangle in 2D, a tetrahedron in 3D,
or a simplex in M dimensions.
simplex_integrals,
a Fortran90 code which
returns the exact value of the integral of any monomial
over the interior of the unit simplex in M dimensions.
sinc,
a Fortran90 code which
evaluates the sinc() function, its first and second derivative
and its antiderivative.
The normalized function is defined by sincn=sin(pi*x)/(pi*x),
the unnormalized function is sincu=sin(x)/x.
Plots of these functions are made.
sine_gordon_exact,
a Fortran90 code which
returns an exact solution of the Sine-Gordon equation,
a partial differential equation (PDE) of the form uxy=sin(u).
slap,
a Fortran90 code which
forms the Sparse Linear Algebra Package (SLAP),
for the iterative solution of sparse linear systems,
by Anne Greenbaum and Mark Seager.
sparse_count,
a Fortran90 code which
analyzes sparse grids in which a single family
of 1D quadrature rules is used for all spatial dimensions,
with a variety of growth rules.
sparse_display,
a Fortran90 code which
reads information defining a matrix of numbers and display
the sparsity pattern or location of the nonzero elements using
gnuplot(). This operation is similar to the MATLAB spy() command.
sparse_grid_hw,
a Fortran90 code which
creates sparse grids based on Gauss-Legendre, Gauss-Hermite,
Gauss-Patterson, or a nested variation of Gauss-Hermite rules,
by Florian Heiss and Viktor Winschel.
specfun,
a Fortran90 code which
computes special functions, including Bessel I, J, K and Y functions,
and the Dawson, E1, EI, Erf, Gamma, log Gamma, Psi/Digamma functions,
by William Cody and Laura Stoltz;
sphere_cubed_grid,
a Fortran90 code which
uses the projection of a cube to create grids of points,
lines, and quadrilaterals
on the surface of the unit sphere in 3D.
sphere_cvt,
a Fortran90 code which
uses a Centroidal Voronoi Tessellation (CVT) to
generate a mesh of well-separated points
on the surface of the unit sphere in 3D.
sphere_delaunay,
a Fortran90 code which
reads a file containing the coordinates of points
on the surface of the unit sphere in 3D,
computes the Delaunay triangulation,
and outputs a PostScript (PS) file of the image;
sphere_grid,
a Fortran90 code which
generates grids of points, or of
points and lines, or of points and lines and faces,
on the surface of the unit sphere in 3D.
sphere_llq_grid,
a Fortran90 code which
uses longitudes and latitudes to create grids of points,
lines, and quadrilaterals
on the surface of the unit sphere in 3D.
sphere_llt_grid,
a Fortran90 code which
uses longitudes and latitudes to create grids of points,
lines, and triangles
on the surface of the unit sphere in 3D.
sphere_monte_carlo,
a Fortran90 code which
applies a Monte Carlo method to estimate the integral of a function
on the surface of the unit sphere in 3D;
sphere_stereograph,
a Fortran90 code which
computes the stereographic mapping between points
on the surface of the unit sphere in 3D
and points on the plane Z = 1;
a generalized mapping is also available.
sphere_triangle_monte_carlo,
a Fortran90 code which
applies a Monte Carlo method to estimate the integral of a function
over a spherical triangle on the surface of the unit sphere in 3D;
sphere_triangle_quad,
a Fortran90 code which
uses quadrature to estimate the integral of a function
over a spherical triangle on the surface of the unit sphere in 3D.
sphere_voronoi,
a Fortran90 code which
reads a file containing the coordinates of points
on the surface of the unit sphere in 3D,
computes the Voronoi diagram,
and outputs a PostScript (PS) file of the image;
square_arbq_rule,
a Fortran90 code which
returns quadrature rules,
with exactness up to total degree 20,
over the interior of the symmetric square in 2D,
by Hong Xiao and Zydrunas Gimbutas.
square_integrals,
a Fortran90 code which
returns the exact value of the integral of any monomial
over the interior of the unit square or symmetric unit square in 2D.
square_minimal_rule,
a Fortran90 code which
returns almost minimal quadrature rules,
with exactness up to total degree 55,
over the interior of the symmetric square in 2D,
by Mattia Festa and Alvise Sommariva.
square_monte_carlo,
a Fortran90 code which
applies a Monte Carlo method to estimate the integral of a function
over the interior of the unit square in 2D.
square_symq_rule,
a Fortran90 code which
returns symmetric quadrature rules,
with exactness up to total degree 20,
over the interior of the symmetric square in 2D,
by Hong Xiao and Zydrunas Gimbutas.
ss_gg_align,
a Fortran90 code which
implements the sequence/sequence global gap alignment,
one of the string matching algorithms described in the
reference by Chao.
standing_wave_exact,
a Fortran90 code which
returns an exact standing wave solution u(x,t)
of the partial differential equation (PDE): utt = c^2 uxx,
describing a wave in a 1D spatial region with propagation speed c.
starpac,
a Fortran90 code which
performs statistical data analysis. It includes functions for nonlinear
least squares regression, time series analysis in both time and
frequency domains), line printer graphics, basic statistical analysis,
and linear least squares regression, by Janet Donaldson.
steinerberger,
a Fortran90 code which
evaluates the Steinerberger function, a continuous function
with discontinuous derivative, which is very hard to accurately
plot, integrate, minimize, or interpolate.
Plots are made of several of the functions.
stiff_exact,
a Fortran90 code which
returns an exact solution y(t) to a stiff ordinary differential
equation (ODE) of the form y' = lambda * ( cos(t-t0) - y).
stochastic_diffusion,
a Fortran90 code which
implements several versions of a stochastic diffusivity coefficient,
using gnuplot() to create graphic images of sample realizations of
the diffusivity field.
stochastic_heat2d,
a Fortran90 code which
implements a finite difference method (FDM) for the steady
2D heat equation,
with a stochastic heat diffusivity coefficient.
stokes_2d_exact,
a Fortran90 code which
evaluates exact solutions (u,v,p)(x,y) to the incompressible steady
Stokes equations in 2D, which are a system of partial differential
equations (PDE) of the form: -uxx-uyy+px=f, -vxx-vyy+py=g, ux+vy=h.
string_pde,
a Fortran90 code which
sets up and solves the partial differential equations (PDE) describing
a vibrating string,
creating files that can be displayed by gnuplot().
stripack_bench,
a Fortran90 code which
times the execution of stripack()'s Delaunay triangulation
procedure over the surface of a sphere, for a random set
of N nodes.
stripack_delaunay,
a Fortran90 code which
reads points on the unit sphere,
calls stripack() to compute the Delaunay triangulation,
and writes it to a file.
stroud_rule,
a Fortran90 code which
defines quadrature rules for a variety of M-dimensional regions,
including the interior of the square, cube and hypercube, the pyramid,
cone and ellipse, the hexagon, the M-dimensional octahedron,
the circle, sphere and hypersphere, the triangle,
tetrahedron and simplex, and the surface of the circle, sphere
and hypersphere.
subset,
a Fortran90 code which
enumerates, generates, randomizes, ranks and unranks combinatorial
objects including combinations, compositions, Gray codes, index sets,
partitions, permutations, polynomials, subsets, and Young tables.
Backtracking routines are included to solve some combinatorial
problems.
subset_sum,
a Fortran90 code which
seeks solutions of the subset sum problem, in which it is desired
to find a subset of integers which has a given sum.
subset_sum_backtrack,
a Fortran90 code which
uses backtracking to find solutions of the subset sum problem,
in which it is desired to find a subset of integers which has a given sum.
subset_sum_brute,
a Fortran90 code which
uses brute force to find solutions of the subset sum problem,
in which it is desired to find a subset of integers which
has a given sum.
subset_sum_swap,
a Fortran90 code which
uses swapping to try to improve an initial estimated solution
of the subset sum problem, which seeks a subset of a set of integers
which has a given sum. Even when an exact solution exists, this
approach often only finds an approximate solution.
svd_basis_weight,
a Fortran90 code which
applies the singular value decomposition (SVD) to a collection
of weighted data vectors, extracting dominant modes;
svd_snowfall,
a Fortran90 code which
reads a file containing historical snowfall data and
analyzes the data with the Singular Value Decomposition (SVD),
displaying the results using gnuplot().
svd_test,
a Fortran90 code which
demonstrates the Singular Value Decomposition (SVD).
svd_truncated,
a Fortran90 code which
demonstrates the computation of the reduced or truncated
Singular Value Decomposition (SVD) that is useful for cases when
one dimension of the matrix is much smaller than the other.
table_columns,
a Fortran90 code which
reads a table file of N points
in M dimensions and creates a new file by copying various
columns, with repetition and shuffling;
test_con,
a Fortran90 code which
defines tests for the continuation problem, which considers
a function F(X) with N-dimensional argument X and N-1 dimensional
result. In general, this defines an implicit one-dimensional
curve of solutions X(LAMBDA). A continuation code starts from
a single point on this curve and tries to compute a sequence of
solutions that form a path.
test_matrix,
a Fortran90 code which
defines test matrices for which the condition number, determinant,
eigenvalues, eigenvectors, inverse, null vectors, P*L*U factorization
or linear system solution are known. Examples include the
Fibonacci, Hilbert, Redheffer, Vandermonde, Wathen and Wilkinson
matrices.
test_opt_con,
a Fortran90 code which
defines test problems for the
minimization of a scalar function of several variables,
with the search constrained to lie within a specified hyper-rectangle.
test_optimization,
a Fortran90 code which
implements test problems for optimization
of a scalar function of several variables,
as described by Molga and Smutnicki.
tetrahedron,
a Fortran90 code which
computes properties, including the centroid,
circumsphere, dihedral angles, edge lengths, face angles, face areas,
insphere, quality, solid angles, and volume,
of a tetrahedron in 3D.
tetrahedron_arbq_rule,
a Fortran90 code which
returns quadrature rules,
with exactness up to total degree 15,
over the interior of a tetrahedron in 3D,
by Hong Xiao and Zydrunas Gimbutas.
tetrahedron_felippa_rule,
a Fortran90 code which
returns a Felippa quadrature rule for approximating integrals
over the interior of a tetrahedron in 3D.
tetrahedron_jaskowiec_rule,
a Fortran90 code which
returns quadrature rules, with exactness up to total degree 20,
over the interior of a tetrahedron in 3D,
by Jan Jaskowiec, Natarajan Sukumar.
tetrahedron_keast_rule,
a Fortran90 code which
returns a Keast quadrature rule, with exactness between 0 and 8,
over the interior of a tetrahedron in 3D.
tetrahedron_witherden_rule,
a Fortran90 code which
returns a symmetric Witherden quadrature rule for the tetrahedron,
with exactness up to total degree 10.
three_body_ode,
a Fortran90 code which
simulates the behavior of three planets,
constrained to lie in a plane,
and moving under the influence of gravity,
by Walter Gander and Jiri Hrebicek.
toms178,
a Fortran90 code which
optimizes a scalar functional of multiple variables
using the Hooke-Jeeves method, by Arthur Kaupe.
This is a version of ACM TOMS algorithm 178.
toms291,
a Fortran90 code which
evaluates the logarithm of the Gamma function,
by Malcolm Pike and David Hill.
This is a version of ACM TOMS algorithm 291.
toms419,
a Fortran90 code which
seeks all the zeroes of a polynomial with complex coefficients;
this is commonly called cpoly();
this is a version of ACM TOMS algorithm 419,
by Jenkins and Traub.
toms446,
a Fortran90 code which
manipulates Chebyshev series for interpolation and approximation;
this is a version of ACM TOMS algorithm 446,
by Roger Broucke.
toms453,
a Fortran90 code which
determines the abscissas and weights for a
Gaussian quadrature formula for the Bromwich integral;
this is a version of ACM TOMS algorithm 453.
toms462,
a Fortran90 code which
evaluates the upper right tail of the bivariate normal
Probability Density Function (PDF); that is,
the probability that normal variables X and Y with correlation R will
satisfy H <= X and K <= Y; this is a version of ACM TOMS algorithm 462.
toms493,
a Fortran90 code which
seeks the roots of a real polynomial, commonly called rpoly();
this is a version of ACM TOMS algorithm 493,
by Michael Jenkins.
toms515,
a Fortran90 code which
selects subsets of size K from a set of size N.
This is a version of ACM TOMS Algorithm 515,
by Bill Buckles, Matthew Lybanon.
toms611,
a Fortran90 code which
seeks the minimizer of a scalar functional of multiple variables.
This is a version of ACM TOMS algorithm 611, by David Gay.
toms655,
a Fortran90 code which
computes the weights for interpolatory quadrature rules;
this is commonly called IQPACK,
by Sylvan Elhay and Jaroslav Kautsky.
This is a version of ACM TOMS algorithm 655.
toms660,
a Fortran90 code which
takes scattered 2D data and produces an interpolating function F(X,Y).
This is a version of ACM TOMS algorithm 660,
called qshep2d,
by Robert Renka.
toms661,
a Fortran90 code which
takes scattered 3D data and produces an interpolating function F(X,Y,Z).
This is a version of ACM TOMS algorithm 661,
called qshep3d,
by Robert Renka.
toms672,
a Fortran90 code which
generates an interpolatory quadrature rule of highest possible order,
given preassigned abscissas.
This can be used to generate Gauss-Kronrod and Gauss-Patterson
quadrature rules.
This is commonly called EXTEND.
This is a version of ACM TOMS algorithm 672.
toms715,
a Fortran90 code which
evaluates special functions, including the Bessel I, J, K, and Y
functions of order 0, of order 1, and of any real order, the
Dawson integral, the error function, exponential integrals, the
gamma function, the normal distribution function, the psi function.
This is a version of ACM TOMS algorithm 715.
toms726,
a Fortran90 code which
computes recursion coefficients for orthogonal polynomials,
and the abscissa and weights for related quadrature rules.
by Walter Gautschi.
This is commonly called ORTHPOL.
This is a version of ACM TOMS algorithm 726.
toms792,
a Fortran90 code which
tests functions that interpolate scattered data in the plane;
by Robert Renka;
this is a version of ACM TOMS algorithm 792.
toms886,
a Fortran90 code which
defines the Padua points for interpolation in a 2D region,
including the rectangle, triangle, and ellipse,
by Marco Caliari, Stefano de Marchi, Marco Vianello.
This is a version of ACM TOMS algorithm 886.
trapezoidal,
a Fortran90 code which
solves one or more ordinary differential equations (ODE)
using the (implicit) trapezoidal method, and a version of
fsolve() to handle the nonlinear equation.
traveling_wave_exact,
a Fortran90 code which
returns an exact traveling wave solution u(x,t)
of the partial differential equation (PDE): utt = c^2 uxx,
describing a wave in a 1D spatial region with propagation speed c.
treepack,
a Fortran90 code which
defines, analyzes, and manipulates trees,
a simple kind of graph with no circuits.
Special cases include rooted and binary trees.
Representations include adjacency, arc, Pruefer code,
and parent.
Operations include center, diameter, eccentricity, enumeration,
generation one at a time, random selection, traversal.
triangle,
a Fortran90 code which
computes properties, including angles, area, centroid, circumcircle,
edge lengths, incircle, orientation, orthocenter, and quality,
of a triangle in 2D.
triangle_analyze,
a Fortran90 code which
reads a triangle defined in a file, and
computes angles, area, centroid, circumcircle, edge lengths,
incircle, orientation, orthocenter, and quality.
triangle_svg,
a Fortran90 code which
uses Scalable Vector Graphics (SVG) to plot a triangle and
any number of points, to illustrate quadrature rules and
sampling techniques.
triangle_symq_rule,
a Fortran90 code which
returns efficient symmetric quadrature rules,
with exactness up to total degree 50,
over the interior of an arbitrary triangle in 2D,
by Hong Xiao and Zydrunas Gimbutas.
triangle_to_fem,
a Fortran90 code which reads the NODE and ELE files
created by Jonathan Shewchuk's triangle() program to
describe a triangular mesh, and writes a corresponding pair of
node and element files in the 2D FEM format.
triangle_to_medit,
a Fortran90 code which
reads the NODE and ELE files created by
Jonathan Shewchuk's triangle() program to describe a triangular mesh,
and writes a corresponding medit() MESH file.
triangle_to_xml,
a Fortran90 code which reads the NODE and ELE files created by
Jonathan Shewchuk's triangle() program to describe a triangular
mesh in 2D, and writes out
a corresponding XML mesh file for use by dolfin() or fenics().
triangle_twb_rule,
a Fortran90 code which
generates the points and weights of quadrature rules
over the interior of a triangle in 2D,
determined by Taylor, Wingate, and Bos.
triangle_wandzura_rule,
a Fortran90 code which
returns Wandzura quadrature rules of exactness 5, 10, 15, 20, 25
or 30 over the interior of the triangle in 2D.
triangulation,
a Fortran90 code which
computes the triangulation of points in the plane,
and performs various operations using a triangulation, including
searching a Delaunay triangulation to find
which triangle contains a given point.
triangulation_l2q,
a Fortran90 code which
reads information about a 3-node (linear) triangulation
and creates data defining a corresponding 6-node (quadratic)
triangulation;
triangulation_q2l,
a Fortran90 code which
reads information about a 6-node triangulation and creates data
defining a corresponding 3-node triangulation;
triangulation_quad,
a Fortran90 code which
reads information about a triangulation and the value of a function
at the nodes and estimates the integral of the function over the
triangulated region.
triangulation_rcm,
a Fortran90 code which
reads files describing a triangulation of nodes in 2D, and applies the
Reverse Cuthill McKee (RCM) algorithm
to produce a renumbering of the triangulation with a reduced
bandwidth.
triangulation_t3_to_t4,
a Fortran90 code which
reads information about a 3-node triangulation and creates data
defining a corresponding 4-node triangulation (vertices + centroid);
triangulation_triangle_neighbors,
a Fortran90 code which
reads data defining a triangulation, determines the neighboring
triangles of each triangle, and writes that information to a file.
truncated_normal,
a Fortran90 code which
works with the truncated normal distribution over [A,B], or
[A,+oo) or (-oo,B], returning the probability density function (PDF),
the cumulative density function (CDF), the inverse CDF, the mean,
the variance, and sample values.
truncated_normal_rule,
a Fortran90 code which
computes a quadrature rule for a normal probability density function
(PDF), also called a Gaussian distribution, that has been
truncated to [A,+oo), (-oo,B] or [A,B].
two_body_ode,
a Fortran90 code which
sets up and solves ordinary differential equations (ODE) which
simulate the behavior of two bodies, constrained to lie in a plane,
moving under the influence of gravity, with one body much more
massive than the other.
ubvec,
a Fortran90 code which
demonstrates how unsigned binary vectors, strings of 0 and 1,
represent nonnegative integers or subsets or other mathematical
objects, for which various arithmetic and logical operations can
be defined.
vandermonde_approx_1d,
a Fortran90 code which
finds a polynomial approximant to data y(x) of a 1D argument
by setting up and solving an overdetermined linear system
for the polynomial coefficients involving the Vandermonde matrix.
vandermonde_approx_2d,
a Fortran90 code which
finds a polynomial approximant p(x,y) to data z(x,y) of a 2D argument
by setting up and solving an overdetermined linear system
for the polynomial coefficients involving the Vandermonde matrix.
vandermonde_interp_1d,
a Fortran90 code which
finds a polynomial interpolant to data y(x) of a 1D argument
by setting up and solving a linear system for the
polynomial coefficients involving the Vandermonde matrix,
creating graphics files for processing by gnuplot().
vandermonde_interp_2d,
a Fortran90 code which
finds a polynomial interpolant to data z(x,y) of a 2D argument
by setting up and solving a linear system for the polynomial
coefficients involving the Vandermonde matrix.
wathen_matrix,
a Fortran90 code which
compares storage schemes (full, banded, sparse triplet ) and
solution strategies (Linpack full, Linpack banded, conjugate gradient)
for linear systems involving the Wathen matrix, which can arise when
solving a problem using the finite element method (FEM).
wave_mpi,
a Fortran90 code which
uses the finite difference method (FDM) to estimate a solution to
the wave equation, using the Message Passing Interface (MPI)
for parallel execution.
weekday,
a Fortran90 code which
determines the day of the week corresponding to a given date,
such as 14 October 1066, Julian calendar, which was a Saturday.
wishart_matrix,
a Fortran90 code which
produces sample matrices from the Wishart or Bartlett distributions,
useful for sampling random covariance matrices.
wordsnake,
a Fortran90 code which
tries to find a good solution to the "Wordsnake Puzzle", in which
a list of words is reordered, trying to maximize the overlap of
successive words.
xyz_to_pdb,
a Fortran90 code which
reads an XYZ file
containing a list of spatial coordinates, and writes a
Protein Data Bank (PDB) file containing ATOM records
with the given coordinates.
zero_chandrupatla,
a Fortran90 code which
finds a zero of a scalar function of a scalar variable,
starting from a change of sign interval, using the
Chandrupatla method, which can converge faster than
bisection, regula falsi, or Brent's method,
by Tirupathi Chandrapatla.
zero_itp,
a Fortran90 code which
finds a zero of a scalar function of a scalar variable,
starting from a change of sign interval, using the
Interpolate/Truncate/Project (ITP) method, which has
faster convergence than the bisection method.
zero_laguerre,
a Fortran90 code which
uses Laguerre's method to find the zero of a function.
The method needs first and second derivative information.
The method almost always works when the function is a polynomial.