Skip to content

Commit 3067555

Browse files
committed
minor documentation updates
1 parent 8e6f0fd commit 3067555

File tree

3 files changed

+22
-20
lines changed

3 files changed

+22
-20
lines changed

README.md

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,11 @@ Multidimensional B-Spline Interpolation of Data on a Regular Grid
99

1010
# Brief description
1111

12-
The library provides subroutines for 1D-6D interpolation using b-splines. The code is written in modern Fortran (i.e., Fortran 2003+).
12+
The library provides subroutines for 1D-6D interpolation using B-splines. The code is written in modern Fortran (i.e., Fortran 2003+). There are two ways to use the module, via a basic subroutine interface and an object-oriented interface. Both are thread safe.
1313

14-
The core routines are:
14+
## Subroutine interface
15+
16+
The core routines for the subroutine interface are:
1517

1618
```Fortran
1719
@@ -40,34 +42,33 @@ subroutine db6ink(x,nx,y,ny,z,nz,q,nq,r,nr,s,ns,fcn,kx,ky,kz,kq,kr,ks,tx,ty,tz,t
4042
subroutine db6val(xval,yval,zval,qval,rval,sval,idx,idy,idz,idq,idr,ids,tx,ty,tz,tq,tr,ts,nx,ny,nz,nq,nr,ns,kx,ky,kz,kq,kr,ks,bcoef,f,iflag,inbvx,inbvy,inbvz,inbvq,inbvr,inbvs,iloy,iloz,iloq,ilor,ilos)
4143
```
4244

43-
The ```ink``` routines compute the interpolant coefficients, and the ```val``` routines evalute the interpolant at the specified value of each coordinate. Eventually, object-oriented wrappers will be created for these routines for ease of use. The 2D and 3D routines are extensively refactored versions of the original routines from the [NIST Core Math Library](http://www.nist.gov/itl/math/mcsd-software.cfm). The others are new, and are simply extensions of the same algorithm into higher dimensions.
45+
The ```ink``` routines compute the interpolant coefficients, and the ```val``` routines evalute the interpolant at the specified value of each coordinate. Eventually, object-oriented wrappers will be created for these routines for ease of use. The 2D and 3D routines are extensively refactored versions of the original routines from the [NIST Core Math Library](http://www.nist.gov/itl/math/mcsd-software.cfm). The others are new, and are simply extensions of the same algorithm into the other dimensions.
46+
47+
## Object-oriented interface
4448

45-
In addition to the main subroutines, an object-oriented wrapper is also provided. For example, for the 3D case:
49+
In addition to the main subroutines, an object-oriented interface is also provided. For example, for the 3D case:
4650

4751
```Fortran
4852
type(bspline_3d) :: s
4953
call s%initialize(x,y,z,fcn,kx,ky,kz,iflag)
5054
call s%evaluate(xval,yval,zval,idx,idy,idz,f,iflag)
5155
call s%destroy()
5256
```
53-
Which uses the default "not-a-knot" end conditions. You can also specify the knot vectors (in this case, `tx`, `ty`, and `tz`) manually during class initialization via:
57+
Which uses the default "not-a-knot" end conditions. You can also specify the knot vectors (in this case, `tx`, `ty`, and `tz`) manually during class initialization:
5458

5559
```Fortran
56-
type(bspline_3d) :: s
5760
call s%initialize(x,y,z,fcn,kx,ky,kz,tx,ty,tz,iflag)
58-
call s%evaluate(xval,yval,zval,idx,idy,idz,f,iflag)
59-
call s%destroy()
6061
```
6162

62-
See the examples for more details.
63+
See the [examples](https://github.com/jacobwilliams/bspline-fortran/tree/master/src/tests) for more details.
6364

6465
# Compiling
6566

66-
A simple bash script ```build.sh``` is provided for building bspline-fortran with gfortran using [FoBiS](https://github.com/szaghi/FoBiS). It also builds the API documentation using [FORD](https://github.com/cmacmackin/ford).
67+
A simple bash script ```build.sh``` is provided for building bspline-fortran with gfortran using [FoBiS](https://github.com/szaghi/FoBiS). It also builds the API documentation using [FORD](https://github.com/cmacmackin/ford). The library can also be compiled with the Intel Fortran Compiler (and presumably any other Fortran compiler that supports modern standards).
6768

6869
# Documentation
6970

70-
The latest API documentation can be found [here](http://jacobwilliams.github.io/bspline-fortran/). This was generated using [FORD](https://github.com/cmacmackin/ford).
71+
The latest API documentation can be found [here](http://jacobwilliams.github.io/bspline-fortran/). This was generated from the source code using [FORD](https://github.com/cmacmackin/ford) (note that the build script will also generate these files).
7172

7273
# License
7374

bspline-fortran.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ exclude: test_oo.f90
2020
Brief description
2121
---------------
2222

23-
The library provides subroutines for 1D-6D interpolation using b-splines. The code is written in modern Fortran (i.e., Fortran 2003+).
23+
The library provides subroutines for 1D-6D interpolation using B-splines. The code is written in modern Fortran (i.e., Fortran 2003+).
2424

2525
License
2626
---------------
@@ -34,4 +34,4 @@ See also
3434

3535
Keywords
3636
---------------
37-
* Bspline, spline, interpolation, data fitting, multivariate interpolation, multidimensional interpolation
37+
* Bspline, spline, interpolation, data fitting, multivariate interpolation, multidimensional interpolation

build.sh

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ SRCDIR='./src/' # library source directory
1313
TESTSRCDIR='./src/tests/' # unit test source directory
1414
BINDIR='./bin/' # build directory for unit tests
1515
LIBDIR='./lib/' # build directory for library
16+
FORDMD='bspline-fortran.md' # FORD config file name
1617

1718
#compiler flags:
1819

@@ -24,25 +25,25 @@ FCOMPILERFLAGS='-c -O2 -std=f2008'
2425
if hash FoBiS.py 2>/dev/null; then
2526

2627
echo "Building library..."
27-
28+
2829
FoBiS.py build -compiler ${FCOMPILER} -cflags "${FCOMPILERFLAGS}" -dbld ${LIBDIR} -s ${SRCDIR} -dmod ./ -dobj ./ -t ${MODCODE} -o ${LIBOUT} -mklib static -colors
29-
30+
3031
echo "Building test programs..."
31-
32+
3233
FoBiS.py build -compiler ${FCOMPILER} -cflags "${FCOMPILERFLAGS}" -dbld ${BINDIR} -s ${TESTSRCDIR} -dmod ./ -dobj ./ -colors -libs ${LIBDIR}${LIBOUT} --include ${LIBDIR}
3334

3435
else
3536
echo "FoBiS.py not found! Cannot build library. Install using: sudo pip install FoBiS.py"
3637
fi
3738

38-
# build the documentation:
39+
# build the documentation using FORD:
3940

4041
if hash ford 2>/dev/null; then
4142

4243
echo "Building documentation..."
43-
44-
ford ./bspline-fortran.md
45-
44+
45+
ford ${FORDMD}
46+
4647
else
4748
echo "Ford not found! Cannot build documentation. Install using: sudo pip install ford"
4849
fi

0 commit comments

Comments
 (0)