Skip to content

Commit

Permalink
Initial GPL v.3 release
Browse files Browse the repository at this point in the history
  • Loading branch information
Serguei Patchkovskii authored and Serguei Patchkovskii committed Sep 3, 2022
1 parent d24c548 commit 2271388
Show file tree
Hide file tree
Showing 101 changed files with 35,923 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .filters/keywords.clean
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/bin/bash
sed \
-e 's/\$Id[^\$]*\$/\$Id\$/g' \
-e 's/\$Date[^\$]*\$/\$Date\$/g' \
-e 's/\$Author[^\$]*\$/\$Author\$/g' \
-e 's/\$Revision[^\$]*\$/\$Revision\$/g' \
-
15 changes: 15 additions & 0 deletions .filters/keywords.smudge
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#!/bin/bash
# Inspired by: https://github.com/turon/git-rcs-keywords/blob/master/.git_filters/rcs-keywords.smudge
filename="${1-"."}"
basename="$(basename "$filename")"
# Read the last commit from the log
author="$(git log -- "$filename" | awk '(NR<=3)&&/^Author: /{print substr($0,8)}')"
date="$(git log -- "$filename" | awk '(NR<=3)&&/^Date: /{print substr($0,8)}')"
ident="$(git log -- "$filename" | awk '(NR<=3)&&/^commit /{print $2}')"
#
sed \
-e 's/\$Date[^\$]*\$/\$Date: '"$date"' \$/g' \
-e 's/\$Author[^\$]*\$/\$Author: '"$author"' \$/g' \
-e 's/\$Revision[^\$]*\$/\$Revision: '"$ident"' \$/g' \
-e 's/\$Id[^\$]*\$/\$Id: '"$basename $date $author"' \$/g' \
-
19 changes: 19 additions & 0 deletions .github/workflows/fortran.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: C/C++ CI

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: compile
run: make
- name: quick test
run: make -C examples check-min
18 changes: 18 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
*.o
*.mod
*.x
*.x_*
*.il
*.a
*__genmod.f90
*.optrpt
*.dbg
*.swp
*.table
makefile.dep
#
preprocess/*
#
examples/*.out
examples/*.table
examples/*.gpl
90 changes: 90 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
.PHONY: goal clean
goal: makefile.dep
make hydrogen_tunnel_v2.x
make general_tunnel.x

MAKEFLAGS = -r

.SUFFIXES: .f90 .o .x .c .dep

#
# This is the default; a config file may override it.
#
ACT = sed -e 's/^!\*nq/ /' # Disable quad-math statements
# ACT = sed -e 's/^!\*qd/ /' -e 's/^!\*lq/ /' # Enable quad-math statements everywhere
ACT2 = # Disable FFTW3
#ACT2 = -e 's/^!\*ft/ /' # Enable FFTW3 calls
#
# System-specific overrides
#
include vanilla.mak
# include configs/ifort_opt.mak
# include configs/ifort_quad_opt.mak
# include configs/gfortran_opt.mak
# include configs/gfortran_quad_opt.mak

#
# Finish the set-up
#
LIBS = $(LAPACK) $(LAPACK) $(LIBEXTRA)

#
# Compiling and archiving rules
#
.f90.o:
$(ACT) $(ACT2) $< >preprocess/$<
$(F90) -c preprocess/$<

dgefa.o: dgefa.f
$(F90) -c dgefa.f

dgedi.o: dgedi.f
$(F90) -c dgedi.f

clean:
-/bin/rm -f *.{o,mod,x,il,a} *__genmod.f90 checkpoint_{field,main}.* makefile.dep *.optrpt ./preprocess/*.f90

makefile.dep: $(shell echo *.f90)
./make-depend.sh $^ > $@

#
# Explicit dependencies
#

LIBHYDROGEN += accuracy.o
LIBHYDROGEN += constants.o
LIBHYDROGEN += derivative_tools.o
LIBHYDROGEN += dgedi.o
LIBHYDROGEN += dgefa.o
LIBHYDROGEN += find_minimum.o
LIBHYDROGEN += fftw.o
LIBHYDROGEN += find_root.o
LIBHYDROGEN += lapack.o
LIBHYDROGEN += math.o
LIBHYDROGEN += poly_tools.o
LIBHYDROGEN += sort_tools.o
LIBHYDROGEN += timer.o
LIBHYDROGEN += tridiagonal_tools.o
LIBHYDROGEN += tridiagonal_cmtql1.o
LIBHYDROGEN += versions.o
LIBHYDROGEN += general_tunnel_bound.o
LIBHYDROGEN += general_tunnel_continuum.o
LIBHYDROGEN += general_tunnel_asymptotic.o
LIBHYDROGEN += general_tunnel_data.o
LIBHYDROGEN += general_tunnel_dump.o
LIBHYDROGEN += general_tunnel_nonadiabatic.o
LIBHYDROGEN += general_tunnel_potential.o

#
# Building the binaries
#
hydrogen_tunnel_v2.x: hydrogen_tunnel_v2.o $(LIBHYDROGEN)
$(F90) -o hydrogen_tunnel_v2.x hydrogen_tunnel_v2.o $(LIBHYDROGEN) $(LIBS)

general_tunnel.x: general_tunnel.o $(LIBHYDROGEN)
$(F90) -o general_tunnel.x general_tunnel.o $(LIBHYDROGEN) $(LIBS)

#
# Automatically-generated dependencies
#
include makefile.dep
Loading

0 comments on commit 2271388

Please sign in to comment.