feenox-1.2/ 0000775 0001750 0001750 00000000000 15055303133 006401 5 feenox-1.2/depcomp 0000755 0001750 0001750 00000056217 15055303022 007704 #! /bin/sh
# depcomp - compile a program generating dependencies as side-effects
scriptversion=2024-06-19.01; # UTC
# Copyright (C) 1999-2024 Free Software Foundation, Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with this program. If not, see .
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that program.
# Originally written by Alexandre Oliva .
case $1 in
'')
echo "$0: No command. Try '$0 --help' for more information." 1>&2
exit 1;
;;
-h | --h*)
cat <<\EOF
Usage: depcomp [--help] [--version] PROGRAM [ARGS]
Run PROGRAMS ARGS to compile a file, generating dependencies
as side-effects.
Environment variables:
depmode Dependency tracking mode.
source Source file read by 'PROGRAMS ARGS'.
object Object file output by 'PROGRAMS ARGS'.
DEPDIR directory where to store dependencies.
depfile Dependency file to output.
tmpdepfile Temporary file to use when outputting dependencies.
libtool Whether libtool is used (yes/no).
Report bugs to .
GNU Automake home page: .
General help using GNU software: .
EOF
exit $?
;;
-v | --v*)
echo "depcomp (GNU Automake) $scriptversion"
exit $?
;;
esac
# Get the directory component of the given path, and save it in the
# global variables '$dir'. Note that this directory component will
# be either empty or ending with a '/' character. This is deliberate.
set_dir_from ()
{
case $1 in
*/*) dir=`echo "$1" | sed -e 's|/[^/]*$|/|'`;;
*) dir=;;
esac
}
# Get the suffix-stripped basename of the given path, and save it the
# global variable '$base'.
set_base_from ()
{
base=`echo "$1" | sed -e 's|^.*/||' -e 's/\.[^.]*$//'`
}
# If no dependency file was actually created by the compiler invocation,
# we still have to create a dummy depfile, to avoid errors with the
# Makefile "include basename.Plo" scheme.
make_dummy_depfile ()
{
echo "#dummy" > "$depfile"
}
# Factor out some common post-processing of the generated depfile.
# Requires the auxiliary global variable '$tmpdepfile' to be set.
aix_post_process_depfile ()
{
# If the compiler actually managed to produce a dependency file,
# post-process it.
if test -f "$tmpdepfile"; then
# Each line is of the form 'foo.o: dependency.h'.
# Do two passes, one to just change these to
# $object: dependency.h
# and one to simply output
# dependency.h:
# which is needed to avoid the deleted-header problem.
{ sed -e "s,^.*\.[$lower]*:,$object:," < "$tmpdepfile"
sed -e "s,^.*\.[$lower]*:[$tab ]*,," -e 's,$,:,' < "$tmpdepfile"
} > "$depfile"
rm -f "$tmpdepfile"
else
make_dummy_depfile
fi
}
# A tabulation character.
tab=' '
# A newline character.
nl='
'
# Character ranges might be problematic outside the C locale.
# These definitions help.
upper=ABCDEFGHIJKLMNOPQRSTUVWXYZ
lower=abcdefghijklmnopqrstuvwxyz
alpha=${upper}${lower}
if test -z "$depmode" || test -z "$source" || test -z "$object"; then
echo "depcomp: Variables source, object and depmode must be set" 1>&2
exit 1
fi
# Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po.
depfile=${depfile-`echo "$object" |
sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`}
tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`}
rm -f "$tmpdepfile"
# Avoid interference from the environment.
gccflag= dashmflag=
# Some modes work just like other modes, but use different flags. We
# parameterize here, but still list the modes in the big case below,
# to make depend.m4 easier to write. Note that we *cannot* use a case
# here, because this file can only contain one case statement.
if test "$depmode" = hp; then
# HP compiler uses -M and no extra arg.
gccflag=-M
depmode=gcc
fi
if test "$depmode" = dashXmstdout; then
# This is just like dashmstdout with a different argument.
dashmflag=-xM
depmode=dashmstdout
fi
cygpath_u="cygpath -u -f -"
if test "$depmode" = msvcmsys; then
# This is just like msvisualcpp but w/o cygpath translation.
# Just convert the backslash-escaped backslashes to single forward
# slashes to satisfy depend.m4
cygpath_u='sed s,\\\\,/,g'
depmode=msvisualcpp
fi
if test "$depmode" = msvc7msys; then
# This is just like msvc7 but w/o cygpath translation.
# Just convert the backslash-escaped backslashes to single forward
# slashes to satisfy depend.m4
cygpath_u='sed s,\\\\,/,g'
depmode=msvc7
fi
if test "$depmode" = xlc; then
# IBM C/C++ Compilers xlc/xlC can output gcc-like dependency information.
gccflag=-qmakedep=gcc,-MF
depmode=gcc
fi
case "$depmode" in
gcc3)
## gcc 3 implements dependency tracking that does exactly what
## we want. Yay! Note: for some reason libtool 1.4 doesn't like
## it if -MD -MP comes after the -MF stuff. Hmm.
## Unfortunately, FreeBSD c89 acceptance of flags depends upon
## the command line argument order; so add the flags where they
## appear in depend2.am. Note that the slowdown incurred here
## affects only configure: in makefiles, %FASTDEP% shortcuts this.
for arg
do
case $arg in
-c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;;
*) set fnord "$@" "$arg" ;;
esac
shift # fnord
shift # $arg
done
"$@"
stat=$?
if test $stat -ne 0; then
rm -f "$tmpdepfile"
exit $stat
fi
mv "$tmpdepfile" "$depfile"
;;
gcc)
## Note that this doesn't just cater to obsolete pre-3.x GCC compilers.
## but also to in-use compilers like IBM xlc/xlC and the HP C compiler.
## (see the conditional assignment to $gccflag above).
## There are various ways to get dependency output from gcc. Here's
## why we pick this rather obscure method:
## - Don't want to use -MD because we'd like the dependencies to end
## up in a subdir. Having to rename by hand is ugly.
## (We might end up doing this anyway to support other compilers.)
## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like
## -MM, not -M (despite what the docs say). Also, it might not be
## supported by the other compilers which use the 'gcc' depmode.
## - Using -M directly means running the compiler twice (even worse
## than renaming).
if test -z "$gccflag"; then
gccflag=-MD,
fi
"$@" -Wp,"$gccflag$tmpdepfile"
stat=$?
if test $stat -ne 0; then
rm -f "$tmpdepfile"
exit $stat
fi
rm -f "$depfile"
echo "$object : \\" > "$depfile"
# The second -e expression handles DOS-style file names with drive
# letters.
sed -e 's/^[^:]*: / /' \
-e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile"
## This next piece of magic avoids the "deleted header file" problem.
## The problem is that when a header file which appears in a .P file
## is deleted, the dependency causes make to die (because there is
## typically no way to rebuild the header). We avoid this by adding
## dummy dependencies for each header file. Too bad gcc doesn't do
## this for us directly.
## Some versions of gcc put a space before the ':'. On the theory
## that the space means something, we add a space to the output as
## well. hp depmode also adds that space, but also prefixes the VPATH
## to the object. Take care to not repeat it in the output.
## Some versions of the HPUX 10.20 sed can't process this invocation
## correctly. Breaking it into two sed invocations is a workaround.
tr ' ' "$nl" < "$tmpdepfile" \
| sed -e 's/^\\$//' -e '/^$/d' -e "s|.*$object$||" -e '/:$/d' \
| sed -e 's/$/ :/' >> "$depfile"
rm -f "$tmpdepfile"
;;
hp)
# This case exists only to let depend.m4 do its work. It works by
# looking at the text of this script. This case will never be run,
# since it is checked for above.
exit 1
;;
sgi)
if test "$libtool" = yes; then
"$@" "-Wp,-MDupdate,$tmpdepfile"
else
"$@" -MDupdate "$tmpdepfile"
fi
stat=$?
if test $stat -ne 0; then
rm -f "$tmpdepfile"
exit $stat
fi
rm -f "$depfile"
if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files
echo "$object : \\" > "$depfile"
# Clip off the initial element (the dependent). Don't try to be
# clever and replace this with sed code, as IRIX sed won't handle
# lines with more than a fixed number of characters (4096 in
# IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines;
# the IRIX cc adds comments like '#:fec' to the end of the
# dependency line.
tr ' ' "$nl" < "$tmpdepfile" \
| sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' \
| tr "$nl" ' ' >> "$depfile"
echo >> "$depfile"
# The second pass generates a dummy entry for each header file.
tr ' ' "$nl" < "$tmpdepfile" \
| sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \
>> "$depfile"
else
make_dummy_depfile
fi
rm -f "$tmpdepfile"
;;
xlc)
# This case exists only to let depend.m4 do its work. It works by
# looking at the text of this script. This case will never be run,
# since it is checked for above.
exit 1
;;
aix)
# The C for AIX Compiler uses -M and outputs the dependencies
# in a .u file. In older versions, this file always lives in the
# current directory. Also, the AIX compiler puts '$object:' at the
# start of each line; $object doesn't have directory information.
# Version 6 uses the directory in both cases.
set_dir_from "$object"
set_base_from "$object"
if test "$libtool" = yes; then
tmpdepfile1=$dir$base.u
tmpdepfile2=$base.u
tmpdepfile3=$dir.libs/$base.u
"$@" -Wc,-M
else
tmpdepfile1=$dir$base.u
tmpdepfile2=$dir$base.u
tmpdepfile3=$dir$base.u
"$@" -M
fi
stat=$?
if test $stat -ne 0; then
rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3"
exit $stat
fi
for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3"
do
test -f "$tmpdepfile" && break
done
aix_post_process_depfile
;;
tcc)
# tcc (Tiny C Compiler) understand '-MD -MF file' since version 0.9.26
# FIXME: That version still under development at the moment of writing.
# Make that this statement remains true also for stable, released
# versions.
# It will wrap lines (doesn't matter whether long or short) with a
# trailing '\', as in:
#
# foo.o : \
# foo.c \
# foo.h \
#
# It will put a trailing '\' even on the last line, and will use leading
# spaces rather than leading tabs (at least since its commit 0394caf7
# "Emit spaces for -MD").
"$@" -MD -MF "$tmpdepfile"
stat=$?
if test $stat -ne 0; then
rm -f "$tmpdepfile"
exit $stat
fi
rm -f "$depfile"
# Each non-empty line is of the form 'foo.o : \' or ' dep.h \'.
# We have to change lines of the first kind to '$object: \'.
sed -e "s|.*:|$object :|" < "$tmpdepfile" > "$depfile"
# And for each line of the second kind, we have to emit a 'dep.h:'
# dummy dependency, to avoid the deleted-header problem.
sed -n -e 's|^ *\(.*\) *\\$|\1:|p' < "$tmpdepfile" >> "$depfile"
rm -f "$tmpdepfile"
;;
## The order of this option in the case statement is important, since the
## shell code in configure will try each of these formats in the order
## listed in this file. A plain '-MD' option would be understood by many
## compilers, so we must ensure this comes after the gcc and icc options.
pgcc)
# Portland's C compiler understands '-MD'.
# Will always output deps to 'file.d' where file is the root name of the
# source file under compilation, even if file resides in a subdirectory.
# The object file name does not affect the name of the '.d' file.
# pgcc 10.2 will output
# foo.o: sub/foo.c sub/foo.h
# and will wrap long lines using '\' :
# foo.o: sub/foo.c ... \
# sub/foo.h ... \
# ...
set_dir_from "$object"
# Use the source, not the object, to determine the base name, since
# that's sadly what pgcc will do too.
set_base_from "$source"
tmpdepfile=$base.d
# For projects that build the same source file twice into different object
# files, the pgcc approach of using the *source* file root name can cause
# problems in parallel builds. Use a locking strategy to avoid stomping on
# the same $tmpdepfile.
lockdir=$base.d-lock
trap "
echo '$0: caught signal, cleaning up...' >&2
rmdir '$lockdir'
exit 1
" 1 2 13 15
numtries=100
i=$numtries
while test $i -gt 0; do
# mkdir is a portable test-and-set.
if mkdir "$lockdir" 2>/dev/null; then
# This process acquired the lock.
"$@" -MD
stat=$?
# Release the lock.
rmdir "$lockdir"
break
else
# If the lock is being held by a different process, wait
# until the winning process is done or we timeout.
while test -d "$lockdir" && test $i -gt 0; do
sleep 1
i=`expr $i - 1`
done
fi
i=`expr $i - 1`
done
trap - 1 2 13 15
if test $i -le 0; then
echo "$0: failed to acquire lock after $numtries attempts" >&2
echo "$0: check lockdir '$lockdir'" >&2
exit 1
fi
if test $stat -ne 0; then
rm -f "$tmpdepfile"
exit $stat
fi
rm -f "$depfile"
# Each line is of the form `foo.o: dependent.h',
# or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'.
# Do two passes, one to just change these to
# `$object: dependent.h' and one to simply `dependent.h:'.
sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile"
# Some versions of the HPUX 10.20 sed can't process this invocation
# correctly. Breaking it into two sed invocations is a workaround.
sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" \
| sed -e 's/$/ :/' >> "$depfile"
rm -f "$tmpdepfile"
;;
hp2)
# The "hp" stanza above does not work with aCC (C++) and HP's ia64
# compilers, which have integrated preprocessors. The correct option
# to use with these is +Maked; it writes dependencies to a file named
# 'foo.d', which lands next to the object file, wherever that
# happens to be.
# Much of this is similar to the tru64 case; see comments there.
set_dir_from "$object"
set_base_from "$object"
if test "$libtool" = yes; then
tmpdepfile1=$dir$base.d
tmpdepfile2=$dir.libs/$base.d
"$@" -Wc,+Maked
else
tmpdepfile1=$dir$base.d
tmpdepfile2=$dir$base.d
"$@" +Maked
fi
stat=$?
if test $stat -ne 0; then
rm -f "$tmpdepfile1" "$tmpdepfile2"
exit $stat
fi
for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2"
do
test -f "$tmpdepfile" && break
done
if test -f "$tmpdepfile"; then
sed -e "s,^.*\.[$lower]*:,$object:," "$tmpdepfile" > "$depfile"
# Add 'dependent.h:' lines.
sed -ne '2,${
s/^ *//
s/ \\*$//
s/$/:/
p
}' "$tmpdepfile" >> "$depfile"
else
make_dummy_depfile
fi
rm -f "$tmpdepfile" "$tmpdepfile2"
;;
tru64)
# The Tru64 compiler uses -MD to generate dependencies as a side
# effect. 'cc -MD -o foo.o ...' puts the dependencies into 'foo.o.d'.
# At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put
# dependencies in 'foo.d' instead, so we check for that too.
# Subdirectories are respected.
set_dir_from "$object"
set_base_from "$object"
if test "$libtool" = yes; then
# Libtool generates 2 separate objects for the 2 libraries. These
# two compilations output dependencies in $dir.libs/$base.o.d and
# in $dir$base.o.d. We have to check for both files, because
# one of the two compilations can be disabled. We should prefer
# $dir$base.o.d over $dir.libs/$base.o.d because the latter is
# automatically cleaned when .libs/ is deleted, while ignoring
# the former would cause a distcleancheck panic.
tmpdepfile1=$dir$base.o.d # libtool 1.5
tmpdepfile2=$dir.libs/$base.o.d # Likewise.
tmpdepfile3=$dir.libs/$base.d # Compaq CCC V6.2-504
"$@" -Wc,-MD
else
tmpdepfile1=$dir$base.d
tmpdepfile2=$dir$base.d
tmpdepfile3=$dir$base.d
"$@" -MD
fi
stat=$?
if test $stat -ne 0; then
rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3"
exit $stat
fi
for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3"
do
test -f "$tmpdepfile" && break
done
# Same post-processing that is required for AIX mode.
aix_post_process_depfile
;;
msvc7)
if test "$libtool" = yes; then
showIncludes=-Wc,-showIncludes
else
showIncludes=-showIncludes
fi
"$@" $showIncludes > "$tmpdepfile"
stat=$?
grep -v '^Note: including file: ' "$tmpdepfile"
if test $stat -ne 0; then
rm -f "$tmpdepfile"
exit $stat
fi
rm -f "$depfile"
echo "$object : \\" > "$depfile"
# The first sed program below extracts the file names and escapes
# backslashes for cygpath. The second sed program outputs the file
# name when reading, but also accumulates all include files in the
# hold buffer in order to output them again at the end. This only
# works with sed implementations that can handle large buffers.
sed < "$tmpdepfile" -n '
/^Note: including file: *\(.*\)/ {
s//\1/
s/\\/\\\\/g
p
}' | $cygpath_u | sort -u | sed -n '
s/ /\\ /g
s/\(.*\)/'"$tab"'\1 \\/p
s/.\(.*\) \\/\1:/
H
$ {
s/.*/'"$tab"'/
G
p
}' >> "$depfile"
echo >> "$depfile" # make sure the fragment doesn't end with a backslash
rm -f "$tmpdepfile"
;;
msvc7msys)
# This case exists only to let depend.m4 do its work. It works by
# looking at the text of this script. This case will never be run,
# since it is checked for above.
exit 1
;;
#nosideeffect)
# This comment above is used by automake to tell side-effect
# dependency tracking mechanisms from slower ones.
dashmstdout)
# Important note: in order to support this mode, a compiler *must*
# always write the preprocessed file to stdout, regardless of -o.
"$@" || exit $?
# Remove the call to Libtool.
if test "$libtool" = yes; then
while test "X$1" != 'X--mode=compile'; do
shift
done
shift
fi
# Remove '-o $object'.
IFS=" "
for arg
do
case $arg in
-o)
shift
;;
$object)
shift
;;
*)
set fnord "$@" "$arg"
shift # fnord
shift # $arg
;;
esac
done
test -z "$dashmflag" && dashmflag=-M
# Require at least two characters before searching for ':'
# in the target name. This is to cope with DOS-style filenames:
# a dependency such as 'c:/foo/bar' could be seen as target 'c' otherwise.
"$@" $dashmflag |
sed "s|^[$tab ]*[^:$tab ][^:][^:]*:[$tab ]*|$object: |" > "$tmpdepfile"
rm -f "$depfile"
cat < "$tmpdepfile" > "$depfile"
# Some versions of the HPUX 10.20 sed can't process this sed invocation
# correctly. Breaking it into two sed invocations is a workaround.
tr ' ' "$nl" < "$tmpdepfile" \
| sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \
| sed -e 's/$/ :/' >> "$depfile"
rm -f "$tmpdepfile"
;;
dashXmstdout)
# This case only exists to satisfy depend.m4. It is never actually
# run, as this mode is specially recognized in the preamble.
exit 1
;;
makedepend)
"$@" || exit $?
# Remove any Libtool call
if test "$libtool" = yes; then
while test "X$1" != 'X--mode=compile'; do
shift
done
shift
fi
# X makedepend
shift
cleared=no eat=no
for arg
do
case $cleared in
no)
set ""; shift
cleared=yes ;;
esac
if test $eat = yes; then
eat=no
continue
fi
case "$arg" in
-D*|-I*)
set fnord "$@" "$arg"; shift ;;
# Strip any option that makedepend may not understand. Remove
# the object too, otherwise makedepend will parse it as a source file.
-arch)
eat=yes ;;
-*|$object)
;;
*)
set fnord "$@" "$arg"; shift ;;
esac
done
obj_suffix=`echo "$object" | sed 's/^.*\././'`
touch "$tmpdepfile"
${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@"
rm -f "$depfile"
# makedepend may prepend the VPATH from the source file name to the object.
# No need to regex-escape $object, excess matching of '.' is harmless.
sed "s|^.*\($object *:\)|\1|" "$tmpdepfile" > "$depfile"
# Some versions of the HPUX 10.20 sed can't process the last invocation
# correctly. Breaking it into two sed invocations is a workaround.
sed '1,2d' "$tmpdepfile" \
| tr ' ' "$nl" \
| sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \
| sed -e 's/$/ :/' >> "$depfile"
rm -f "$tmpdepfile" "$tmpdepfile".bak
;;
cpp)
# Important note: in order to support this mode, a compiler *must*
# always write the preprocessed file to stdout.
"$@" || exit $?
# Remove the call to Libtool.
if test "$libtool" = yes; then
while test "X$1" != 'X--mode=compile'; do
shift
done
shift
fi
# Remove '-o $object'.
IFS=" "
for arg
do
case $arg in
-o)
shift
;;
$object)
shift
;;
*)
set fnord "$@" "$arg"
shift # fnord
shift # $arg
;;
esac
done
"$@" -E \
| sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \
-e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \
| sed '$ s: \\$::' > "$tmpdepfile"
rm -f "$depfile"
echo "$object : \\" > "$depfile"
cat < "$tmpdepfile" >> "$depfile"
sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile"
rm -f "$tmpdepfile"
;;
msvisualcpp)
# Important note: in order to support this mode, a compiler *must*
# always write the preprocessed file to stdout.
"$@" || exit $?
# Remove the call to Libtool.
if test "$libtool" = yes; then
while test "X$1" != 'X--mode=compile'; do
shift
done
shift
fi
IFS=" "
for arg
do
case "$arg" in
-o)
shift
;;
$object)
shift
;;
"-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI")
set fnord "$@"
shift
shift
;;
*)
set fnord "$@" "$arg"
shift
shift
;;
esac
done
"$@" -E 2>/dev/null |
sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::\1:p' | $cygpath_u | sort -u > "$tmpdepfile"
rm -f "$depfile"
echo "$object : \\" > "$depfile"
sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::'"$tab"'\1 \\:p' >> "$depfile"
echo "$tab" >> "$depfile"
sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::\1\::p' >> "$depfile"
rm -f "$tmpdepfile"
;;
msvcmsys)
# This case exists only to let depend.m4 do its work. It works by
# looking at the text of this script. This case will never be run,
# since it is checked for above.
exit 1
;;
none)
exec "$@"
;;
*)
echo "Unknown depmode $depmode" 1>&2
exit 1
;;
esac
exit 0
# Local Variables:
# mode: shell-script
# sh-indentation: 2
# eval: (add-hook 'before-save-hook 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-time-zone: "UTC0"
# time-stamp-end: "; # UTC"
# End:
feenox-1.2/src/ 0000775 0001750 0001750 00000000000 15055303133 007170 5 feenox-1.2/src/help.h 0000664 0001750 0001750 00000004224 15055303017 010214 #define FEENOX_HELP_ONE_LINER "a cloud-first free no-fee no-X uniX-like finite-element(ish) computational engineering tool"
#define FEENOX_HELP_USAGE "[options] inputfile [replacement arguments] [petsc options]"
#define FEENOX_HELP_OPTIONS_BASE "\
-h, --help display options and detailed explanations of command-line usage\n\
-v, --version display brief version information and exit\n\
-V, --versions display detailed version information\n\
-c, --check validates if the input file is sane or not\n\
--pdes list the types of PROBLEMs that FeenoX can solve, one per line\n\
--elements_info output a document with information about the supported element types\n\
--ast dump an abstract syntax tree of the input\n\
--linear force FeenoX to solve the PDE problem as linear\n\
--non-linear force FeenoX to solve the PDE problem as non-linear\n\
"
#define FEENOX_HELP_OPTIONS_PDE "\
--progress print ASCII progress bars when solving PDEs\n\
--mumps ask PETSc to use the direct linear solver MUMPS\n\
--gamg ask PETSc to use a GAMG-preconditioned iterative linear solver\n\
"
#define FEENOX_HELP_EXTRA "\
Instructions will be read from standard input if “-” is passed as\n\
inputfile, i.e.\n\
\n\
$ echo 'PRINT 2+2' | feenox -\n\
4\n\
\n\
The optional [replacement arguments] part of the command line mean that\n\
each argument after the input file that does not start with an hyphen\n\
will be expanded verbatim in the input file in each occurrence of $1,\n\
$2, etc. For example\n\
\n\
$ echo 'PRINT $1+$2' | feenox - 3 4\n\
7\n\
\n\
PETSc and SLEPc options can be passed in [petsc options] (or [options])\n\
as well, with the difference that two hyphens have to be used instead of\n\
only once. For example, to pass the PETSc option -ksp_view the actual\n\
FeenoX invocation should be\n\
\n\
$ feenox input.fee --ksp_view\n\
\n\
For PETSc options that take values, en equal sign has to be used:\n\
\n\
$ feenox input.fee --mg_levels_pc_type=sor\n\
\n\
See https://www.seamplex.com/feenox/examples for annotated examples.\n\
"
feenox-1.2/src/version.c 0000664 0001750 0001750 00000013273 15055303016 010747 /*------------ -------------- -------- --- ----- --- -- - -
* FeenoX version and description routines
*
* Copyright (C) 2009--2025 Jeremy Theler
*
* This file is part of FeenoX.
*
* FeenoX is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "help.h"
#include "pdes/available.h"
#include
#include
#ifdef HAVE_READLINE
#include
#endif
#ifdef HAVE_SUNDIALS
#include
#endif
#ifdef HAVE_PETSC
#include
#include
#endif
#ifdef HAVE_SLEPC
#include
#endif
void feenox_show_help(const char *progname, int extra) {
// in parallel runs only print from first processor
if (feenox.mpi_rank != 0) {
return;
}
// TODO: use a defined string with %s
printf("usage: %s %s\n\n", progname, FEENOX_HELP_USAGE);
printf("%s\n", FEENOX_HELP_OPTIONS_BASE);
if (extra) {
printf("%s\n", FEENOX_HELP_OPTIONS_PDE);
printf("%s\n", FEENOX_HELP_EXTRA);
} else {
printf("Run with --help for further explanations.\n");
}
if (extra) {
printf("Report bugs at https://github.com/seamplex/feenox/issues\n");
printf("Ask questions at https://github.com/seamplex/feenox/discussions\n");
printf("Feenox home page: https://www.seamplex.com/feenox/\n");
}
return;
}
void feenox_show_version(int version) {
// in parallel runs only print from first processor
if (feenox.mpi_rank != 0) {
return;
}
if (version == version_available_pdes) {
#ifdef HAVE_PETSC
printf(AVAILABLE_PDES);
#else
printf("FeenoX was not linked against PETSc. No PDEs are available.\n");
#endif
return;
} else if (version == version_elements_info) {
feenox_mesh_element_types_init();
feenox_mesh_elements_info();
return;
}
feenox_shortversion();
if (version) {
printf("\n");
}
switch (version) {
case version_copyright:
feenox_copyright();
break;
case version_info:
feenox_longversion();
break;
}
fflush(stdout);
return;
}
void feenox_shortversion(void) {
// in parallel runs only print from first processor
if (feenox.mpi_rank != 0) {
return;
}
printf("FeenoX ");
#ifdef FEENOX_GIT_BRANCH
printf("%s %s\n", FEENOX_GIT_VERSION, strcmp(FEENOX_GIT_BRANCH, "main") ? FEENOX_GIT_BRANCH : "");
#else
printf("%s\n", PACKAGE_VERSION);
#endif
printf("%s\n", FEENOX_HELP_ONE_LINER);
return;
}
void feenox_copyright(void) {
// in parallel runs only print from first processor
if (feenox.mpi_rank != 0) {
return;
}
/* It is important to separate the year from the rest of the message,
as done here, to avoid having to retranslate the message when a new
year comes around. */
printf("Copyright © %d--%d Jeremy Theler, https://seamplex.com/feenox\n\
GNU General Public License v3+, https://www.gnu.org/licenses/gpl.html. \n\
FeenoX is free software: you are free to change and redistribute it.\n\
There is NO WARRANTY, to the extent permitted by law.\n", 2009, 2025);
}
void feenox_longversion(void) {
// in parallel runs only print from first processor
if (feenox.mpi_rank != 0) {
return;
}
#ifdef FEENOX_GIT_DATE
printf("Last commit date : %s\n", FEENOX_GIT_DATE);
#endif
// these guys here prevent reproducible builds in debian
/*
#ifdef FEENOX_COMPILATION_DATE
printf("Build date : %s\n", FEENOX_COMPILATION_DATE);
#endif
#ifdef FEENOX_COMPILATION_USERNAME
printf("Builder : %s@%s\n", FEENOX_COMPILATION_USERNAME, FEENOX_COMPILATION_HOSTNAME);
#endif
*/
#ifdef FEENOX_COMPILER_ARCH
printf("Build architecture : %s\n", FEENOX_COMPILER_ARCH);
#endif
#ifdef FEENOX_COMPILER_VERSION
printf("Compiler version : %s\n", FEENOX_COMPILER_VERSION);
#endif
#ifdef FEENOX_COMPILER_SHOW
printf("Compiler expansion : %s\n", FEENOX_COMPILER_SHOW);
#endif
#ifdef FEENOX_COMPILER_CFLAGS
printf("Compiler flags : %s\n", FEENOX_COMPILER_CFLAGS);
#endif
printf("GSL version : %s\n", gsl_version);
#ifdef HAVE_SUNDIALS
char sundials_version[BUFFER_TOKEN_SIZE];
SUNDIALSGetVersion(sundials_version, BUFFER_TOKEN_SIZE-1);
#else
char *sundials_version = "N/A";
#endif
printf("SUNDIALS version : %s\n", sundials_version);
// printf("Readline version : %s\n",
// #if HAVE_READLINE
// rl_library_version
// #else
// "N/A"
// #endif
// );
#ifdef HAVE_PETSC
char petscversion[BUFFER_TOKEN_SIZE];
char petscarch[BUFFER_TOKEN_SIZE];
PetscGetVersion(petscversion, BUFFER_TOKEN_SIZE);
printf("PETSc version : %s\n", petscversion);
PetscGetArchType(petscarch, BUFFER_TOKEN_SIZE);
if (strlen(petscarch) > 0) {
printf("PETSc arch : %s\n", petscarch);
}
printf("PETSc options : %s\n", petscconfigureoptions);
#else
printf("PETSc version : N/A\n");
#endif
#ifdef HAVE_SLEPC
char slepcversion[BUFFER_TOKEN_SIZE];
SlepcGetVersion(slepcversion, BUFFER_TOKEN_SIZE);
#else
char *slepcversion = "N/A";
#endif
printf("SLEPc version : %s\n", slepcversion);
return;
}
feenox-1.2/src/feenox.h 0000664 0001750 0001750 00000234055 15055303016 010556 /*------------ -------------- -------- --- ----- --- -- - -
* FeenoX common framework header
*
* Copyright (C) 2009--2025 Jeremy Theler
*
* This file is part of FeenoX.
*
* FeenoX is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#ifndef FEENOX_H
#define FEENOX_H
#ifdef HAVE_CONFIG_H
#include
#endif
// for POSIX in C99
#ifndef _GNU_SOURCE
#define _GNU_SOURCE
#endif
#if defined(HAVE___BUILTIN_EXPECT)
# define feenox_unlikely(cond) __builtin_expect(!!(cond),0)
# define feenox_likely(cond) __builtin_expect(!!(cond),1)
#else
# define feenox_unlikely(cond) (cond)
# define feenox_likely(cond) (cond)
#endif
// for inlining as much as possible GSL
#define HAVE_INLINE
#define GSL_RANGE_CHECK_OFF
#ifndef sunrealtype
#define sunrealtype realtype
#endif
// we need all the includes here so they all follow the inline directive above
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#ifdef HAVE_SUNDIALS
#include
// #include
#include
#include
#include
#include
#include
#ifndef sunrealtype
#define sunrealty realtype
#endif
#endif
// petsc complains if its headers are included from c++ within extern C
#ifdef HAVE_PETSC
#ifdef __cplusplus
extern "C++" {
#endif // C++
#include
#include
#include
#include
#include
#ifdef HAVE_SLEPC
#include
#endif // HAVE_SLEPC
#ifdef __cplusplus
}
#endif // C++
// PETSC_NULL is deprecated but it was not defined before 3.16
#if PETSC_VERSION_LT(3,16,0)
#define PETSC_NULLPTR PETSC_NULL
#endif
#endif // HAVE_PETSC
#include "contrib/uthash.h"
#include "contrib/utlist.h"
#include "contrib/kdtree.h"
#define FEENOX_OK 0
#define FEENOX_ERROR 1
#define FEENOX_UNHANDLED 2
#define FEENOX_VECTOR_INITIAL 0
#define FEENOX_VECTOR_NO_INITIAL 1
#define BUFFER_TOKEN_SIZE 256
#define BUFFER_LINE_SIZE 4096
// number of internal functions, functional and vector functions
#define N_BUILTIN_FUNCTIONS 70
#define N_BUILTIN_FUNCTIONALS 8
#define N_BUILTIN_VECTOR_FUNCTIONS 8
// no son enums porque hacemos operaciones con las mascaras de abajo
#define EXPR_UNDEFINED 0
#define EXPR_OPERATOR 1
#define EXPR_CONSTANT 2
#define EXPR_VARIABLE 3
#define EXPR_VECTOR 4
#define EXPR_MATRIX 5
#define EXPR_BUILTIN_FUNCTION 6
#define EXPR_BUILTIN_VECTORFUNCTION 7
#define EXPR_BUILTIN_FUNCTIONAL 8
#define EXPR_FUNCTION 9
#define EXPR_BASICTYPE_MASK 1023
#define EXPR_CURRENT 0
#define EXPR_INITIAL_TRANSIENT 2048
#define EXPR_INITIAL_STATIC 4096
// constants for custom error handling
#define ON_ERROR_NO_QUIT 1
#define ON_ERROR_NO_REPORT 2
// type of phase space componentes (the values come from SUNDIALs, do not change!)
#define DAE_ALGEBRAIC 0.0
#define DAE_DIFFERENTIAL 1.0
// reasonable defaults
#define DEFAULT_DT 1.0/16.0
#define DEFAULT_DAE_RTOL 1e-6
#define DEFAULT_RANDOM_METHOD gsl_rng_mt19937
#define DEFAULT_PRINT_FORMAT "%g"
#define DEFAULT_PRINT_SEPARATOR "\t"
#define CHAR_PROGRESS_BUILD "."
#define CHAR_PROGRESS_SOLVE "-"
#define CHAR_PROGRESS_GRADIENT "="
#define DEFAULT_ROOT_MAX_TER 1024
#define DEFAULT_ROOT_TOLERANCE (9.765625e-4) // (1/2)^-10
#define DEFAULT_INTEGRATION_INTERVALS 1024
#define DEFAULT_INTEGRATION_TOLERANCE (9.765625e-4) // (1/2)^-10
#define DEFAULT_INTEGRATION_KEY GSL_INTEG_GAUSS31
#define DEFAULT_DERIVATIVE_STEP (9.765625e-4) // (1/2)^-10
#define DEFAULT_CONDITION_THRESHOLD (9.765625e-4) // (1/2)^-10
#define DEFAULT_FIT_MAX_ITER 100
#define DEFAULT_FIT_XTOL 1e-8
#define DEFAULT_FIT_GTOL 1e-8
#define DEFAULT_FIT_FTOL 0.0
#define DEFAULT_SOLVE_METHOD gsl_multiroot_fsolver_dnewton
#define DEFAULT_SOLVE_EPSREL 0 // zero means do not look for deltas in derivatives
#define DEFAULT_SOLVE_EPSABS 1e-6
#define DEFAULT_SOLVE_MAX_ITER 128
#define MINMAX_ARGS 10
// zero & infinite
#define ZERO (8.881784197001252323389053344727e-16) // (1/2)^-50
#define INFTY (1125899906842624.0) // 2^50
#define MESH_INF 1e22
#define MESH_TOL 1e-6
#define MESH_FAILED_INTERPOLATION_FACTOR 1.5
#define DEFAULT_INTERPOLATION (*gsl_interp_linear)
#define DEFAULT_MULTIDIM_INTERPOLATION_THRESHOLD 9.5367431640625e-07 // (1/2)^-20
#define DEFAULT_SHEPARD_RADIUS 1.0
#define DEFAULT_SHEPARD_EXPONENT 2
// these are Gmsh's nomenclature, we then convert to vtk/frd with "tables"
#define ELEMENT_TYPE_UNDEFINED 0
#define ELEMENT_TYPE_LINE2 1
#define ELEMENT_TYPE_TRIANGLE3 2
#define ELEMENT_TYPE_QUADRANGLE4 3
#define ELEMENT_TYPE_TETRAHEDRON4 4
#define ELEMENT_TYPE_HEXAHEDRON8 5
#define ELEMENT_TYPE_PRISM6 6
#define ELEMENT_TYPE_PYRAMID5 7
#define ELEMENT_TYPE_LINE3 8
#define ELEMENT_TYPE_TRIANGLE6 9
#define ELEMENT_TYPE_QUADRANGLE9 10
#define ELEMENT_TYPE_TETRAHEDRON10 11
#define ELEMENT_TYPE_HEXAHEDRON27 12
#define ELEMENT_TYPE_PRISM18 13
#define ELEMENT_TYPE_PYRAMID14 14
#define ELEMENT_TYPE_POINT1 15
#define ELEMENT_TYPE_QUADRANGLE8 16
#define ELEMENT_TYPE_HEXAHEDRON20 17
#define ELEMENT_TYPE_PRISM15 18
#define NUMBER_ELEMENT_TYPE 19
#define M_SQRT5 2.23606797749978969640917366873127623544061835961152572427089
#define FEENOX_SOLUTION_NOT_GRADIENT 0
#define FEENOX_SOLUTION_GRADIENT 1
#define feenox_distribution_define_mandatory(type, name, quoted_name, description) {\
feenox_call(feenox_distribution_init(&(type.name), quoted_name)); \
if (type.name.defined == 0) { feenox_push_error_message("undefined %s '%s'", description, quoted_name); return FEENOX_ERROR; } \
if (type.name.full == 0) { feenox_push_error_message("%s '%s' is not defined over all volumes", description, quoted_name); return FEENOX_ERROR; } }
enum version_type {
version_compact,
version_copyright,
version_info,
version_available_pdes,
version_elements_info,
};
// macro to check error returns in function calls
#define feenox_call(function) if (__builtin_expect((function), FEENOX_OK) != FEENOX_OK) return FEENOX_ERROR
#define feenox_call_null(function) if (__builtin_expect((function), FEENOX_OK) != FEENOX_OK) return NULL
#define feenox_check_null(function) if ((function) == NULL) return FEENOX_ERROR
#ifdef HAVE_SUNDIALS
#define ida_call(function) if ((err = __builtin_expect(!!(function), FEENOX_OK)) < 0) { feenox_push_error_message("IDA returned error %d", err); return FEENOX_ERROR; }
#endif
#ifdef HAVE_PETSC
#define petsc_call(function) if (__builtin_expect((function), 0)) { feenox_push_error_message("PETSc error"); CHKERRQ(1); }
#define petsc_call_null(function) if (__builtin_expect((function), 0)) { feenox_push_error_message("PETSc error"); return NULL; }
#endif
#define feenox_free(p) free(p); p = NULL;
// macro to check malloc() for NULL (ass means assignement, you ass!)
#define feenox_check_alloc(ass) if ((ass) == NULL) { feenox_push_error_message("cannot allocate memory"); return FEENOX_ERROR; }
#define feenox_check_alloc_null(ass) if ((ass) == NULL) { feenox_push_error_message("cannot allocate memory"); return NULL; }
#define feenox_check_minusone(ass) if ((ass) == -1) { feenox_push_error_message("cannot allocate memory"); return FEENOX_ERROR; }
#define feenox_check_minusone_null(ass) if ((ass) == -1) { feenox_push_error_message("cannot allocate memory"); return NULL; }
// macro to access internal special variables
#define feenox_special_var(var) (feenox.special_vars.var)
// value of a variable
#define feenox_var_value(var) (*(var->value))
// value of a special variable
#define feenox_special_var_value(var) feenox_var_value(feenox_special_var(var))
// pointer to the content of an object
#define feenox_value_ptr(obj) (obj->value)
// GSL's equivalent to PETSc's ADD_VALUES
#define gsl_vector_add_to_element(vector,i,x) gsl_vector_set((vector),(i),gsl_vector_get((vector),(i))+(x))
#define gsl_matrix_add_to_element(matrix,i,j,x) gsl_matrix_set((matrix),(i),(j),gsl_matrix_get((matrix),(i),(j))+(x))
#define is_element_local(msh, elm) \
((msh->mpi_matches_partitions == mpi_matches_partitions_serial) || \
(msh->mpi_matches_partitions == mpi_matches_partitions_one_to_one && \
(e->geometrical_entity != NULL && \
e->geometrical_entity->partition != NULL && \
(e->geometrical_entity->partition[0]-1) == feenox.mpi_rank)) || \
(msh->mpi_matches_partitions == mpi_matches_partitions_one_to_many && \
(e->geometrical_entity != NULL && \
e->geometrical_entity->partition != NULL && \
(((e->geometrical_entity->partition[0]-1)*feenox.mpi_size)/msh->n_partitions) == feenox.mpi_rank)) || \
(msh->mpi_matches_partitions == mpi_matches_partitions_no && \
(e->index >= msh->first_element && e->index < msh->last_element)))
// forward declarations
typedef struct feenox_t feenox_t;
typedef struct builtin_function_t builtin_function_t;
typedef struct builtin_functional_t builtin_functional_t;
typedef struct builtin_vectorfunction_t builtin_vectorfunction_t;
typedef struct expr_t expr_t;
typedef struct expr_item_t expr_item_t;
typedef struct var_t var_t;
typedef struct var_ll_t var_ll_t;
typedef struct vector_t vector_t;
typedef struct matrix_t matrix_t;
typedef struct function_t function_t;
typedef struct function_ll_t function_ll_t;
typedef struct alias_t alias_t;
typedef struct instruction_t instruction_t;
typedef struct conditional_block_t conditional_block_t;
typedef struct assignment_t assignment_t;
typedef struct file_t file_t;
typedef struct print_t print_t;
typedef struct print_token_t print_token_t;
typedef struct printf_t printf_t;
typedef struct print_function_t print_function_t;
typedef struct multidim_range_t multidim_range_t;
typedef struct print_vector_t print_vector_t;
typedef struct read_data_t read_data_t;
typedef struct sort_vector_t sort_vector_t;
typedef struct phase_object_t phase_object_t;
typedef struct dae_t dae_t;
typedef struct mesh_t mesh_t;
typedef struct mesh_write_t mesh_write_t;
typedef struct mesh_write_dist_t mesh_write_dist_t;
typedef struct mesh_integrate_t mesh_integrate_t;
typedef struct mesh_find_extrema_t mesh_find_extrema_t;
typedef struct fit_t fit_t;
typedef struct solve_t solve_t;
typedef struct dump_t dump_t;
typedef struct reaction_t reaction_t;
typedef struct physical_group_t physical_group_t;
typedef struct geometrical_entity_t geometrical_entity_t;
typedef struct physical_name_t physical_name_t;
typedef struct property_t property_t;
typedef struct property_data_t property_data_t;
typedef struct material_t material_t;
typedef struct material_ll_t material_ll_t;
typedef struct distribution_t distribution_t;
// nice but not needed
// typedef struct name_item_t name_item_t;
typedef struct bc_t bc_t;
typedef struct bc_data_t bc_data_t;
typedef struct node_t node_t;
typedef struct node_relative_t node_relative_t;
typedef struct element_t element_t;
typedef struct element_ll_t element_ll_t;
typedef struct element_type_t element_type_t;
typedef struct cell_t cell_t;
typedef struct neighbor_t neighbor_t;
typedef struct gauss_t gauss_t;
typedef struct elementary_entity_t elementary_entity_t;
typedef struct node_data_t node_data_t;
// individual item (factor) of an algebraic expression
struct expr_item_t {
size_t n_chars;
int type; // defines #EXPR_ because we need to operate with masks
size_t level; // hierarchical level
size_t tmp_level; // for partial sums
size_t oper; // number of the operator if applicable
double constant; // value of the numerical constant if applicable
double value; // current value
// vector with (optional) auxiliary stuff (last value, integral accumulator, rng, etc)
double *aux;
builtin_function_t *builtin_function;
builtin_vectorfunction_t *builtin_vectorfunction;
builtin_functional_t *builtin_functional;
var_t *variable;
vector_t *vector;
matrix_t *matrix;
function_t *function;
vector_t **vector_arg;
var_t *functional_var_arg;
// algebraic expression of the arguments of the function
expr_t *arg;
// lists of which variables and functions this item (and its daughters)
var_ll_t *variables;
function_ll_t *functions;
expr_item_t *next;
};
// algebraic expression
struct expr_t {
expr_item_t *items;
double value;
char *string; // just in case we keep the original string
// lists of which variables and functions this expression depends on
var_ll_t *variables;
function_ll_t *functions;
expr_t *next;
};
// variable
struct var_t {
char *name;
int initialized;
int reallocated;
int used;
int assigned_init;
int assigned_zero;
// these are pointers so the actual holder can be anything, from another
// variable (i.e. an alias), a vector element (another alias) or even
// more weird stufff (a fortran common?)
double *value;
double *initial_static;
double *initial_transient;
UT_hash_handle hh;
};
struct var_ll_t {
var_t *var;
var_ll_t *next;
};
struct function_ll_t {
function_t *function;
function_ll_t *next;
};
// vector
struct vector_t {
char *name;
int initialized;
int reallocated;
int used;
int assigned_init;
int assigned_zero;
expr_t size_expr;
int size;
gsl_vector *value;
gsl_vector *initial_transient;
gsl_vector *initial_static;
// linked list with the expressions of the initial elements
expr_t *datas;
UT_hash_handle hh;
};
// matrix
struct matrix_t {
char *name;
int initialized;
int reallocated;
int used;
int assigned_init;
int assigned_zero;
expr_t cols_expr;
expr_t rows_expr;
int cols;
int rows;
gsl_matrix *value;
gsl_matrix *initial_transient;
gsl_matrix *initial_static;
// flag para saber si el apuntador de arriba lo alocamos nosotros o alguien mas
int realloced;
expr_t *datas;
UT_hash_handle hh;
};
// alias
struct alias_t {
int initialized;
var_t *new_variable;
expr_t row;
expr_t col;
var_t *variable;
vector_t *vector;
matrix_t *matrix;
alias_t *next;
};
// function
struct function_t {
char *name;
char *name_in_mesh;
int initialized;
int used;
// may be:
// - algebraic, either globally or on a per-material (physical groups) basis
// - pointwise-defined
// + given in the input with DATA
// + given in FeenoX vectors with VECTORS
// + given in a file with FILE
// + in a mesh
// * data at nodes
// * data at cells
// - computed in a user-provided routine (used to be supported, not anymore)
//
enum {
function_type_undefined,
function_type_algebraic,
function_type_pointwise_data,
function_type_pointwise_file,
function_type_pointwise_mesh_property,
function_type_pointwise_mesh_node,
function_type_pointwise_mesh_cell,
// function_type_routine,
// function_type_routine_internal,
} type;
// number of arguments the function takes
int n_arguments;
int n_arguments_given; // check to see if the API gave us all the arguments the function needs
// array of pointers to already-existing variables for the arguments
var_t **var_argument;
int var_argument_allocated;
// expression for algebraic functions
expr_t algebraic_expression;
// number of tuples (independent, dependent) data for pointwise functions
size_t data_size;
// vectors with the data
vector_t **vector_argument;
vector_t *vector_value;
// this is in case there is a derivative of a mesh-based function and
// we want to interpolate with the shape functions
// warning! we need to put data on the original function and not on the derivatives
function_t *spatial_derivative_of;
int spatial_derivative_with_respect_to;
// hints in case the grid is tensor-product regular
int rectangular_mesh;
expr_t expr_x_increases_first;
int x_increases_first;
expr_t *expr_rectangular_mesh_size;
size_t *rectangular_mesh_size;
double **rectangular_mesh_point;
// helpers to interpolate 1D with GSL
gsl_interp *interp;
gsl_interp_accel *interp_accel;
gsl_interp_type interp_type;
// multidimensional interpolation type
enum {
interp_undefined,
interp_nearest,
interp_shepard,
interp_shepard_kd,
interp_bilinear
} multidim_interp;
expr_t expr_multidim_threshold;
expr_t expr_shepard_radius;
expr_t expr_shepard_exponent;
double multidim_threshold;
double shepard_radius;
double shepard_exponent;
// material property like E, nu, k, etc.
property_t *property;
// mesh over which the function is defined
mesh_t *mesh;
double mesh_time; // for time-dependent functions read from .msh
// pointer to a k-dimensional tree to speed up stuff
void *kd;
// ----- ------- ----------- -- - -
// funcion que hay que llamar para funciones tipo usercall
// double (*routine)(const double *);
// ----- ------- ----------- -- - -
// funcion que hay que llamar para funciones internas
// double (*routine_internal)(const double *, function_t *);
// void *params;
// if this is true, we can hint feenox to do the implicit SOLVE_PROBLEM
int is_solution;
// if this is true and the parser sees this function,
// then pde.compute_gradients is set to true
int is_gradient;
int dummy_for_derivatives;
double dummy_for_derivatives_value;
UT_hash_handle hh;
};
struct feenox_expression_derivative_params {
expr_t *expr;
var_t *variable;
function_t *function;
};
// internal function (this is initialized directly into the data space from builtin_functions.h)
struct builtin_function_t {
char name[BUFFER_TOKEN_SIZE];
int min_arguments;
int max_arguments;
double (*routine)(struct expr_item_t *);
};
// internal function over vectors
struct builtin_vectorfunction_t {
char name[BUFFER_TOKEN_SIZE];
int min_arguments;
int max_arguments;
double (*routine)(struct vector_t **);
};
// internal functional
// a functional is _like_ a regular function but its second argument is a variable
// (not an expression) that is used to evaluate the first argument (which is an expression
// of this variable) for different values and do something about it, for instance
// compute a derivative or an integral.
// There can also be more optional arguments (expressions) after this second special argument,
// i.e. integral(1+x,x,0,1) or derivative(1+x,x,0.5)
struct builtin_functional_t {
char name[BUFFER_TOKEN_SIZE];
int min_arguments; // contando la variable del segundo argumento
int max_arguments;
double (*routine)(struct expr_item_t *, struct var_t *);
};
// instruction
struct instruction_t {
int (*routine)(void *);
void *argument;
int argument_alloced;
instruction_t *next;
};
// conditional block
struct conditional_block_t {
conditional_block_t *father;
conditional_block_t *else_of;
expr_t condition;
instruction_t *first_true_instruction;
instruction_t *first_false_instruction;
int evaluated_to_true;
int evaluated_to_false;
conditional_block_t *next;
};
// igualacion algebraica
struct assignment_t {
int initialized;
var_t *variable;
vector_t *vector;
matrix_t *matrix;
// expresiones que indican el rango de indices para asignaciones vectoriales/matriciales
expr_t i_min;
expr_t i_max;
expr_t j_min;
expr_t j_max;
// expresiones que indican la fila y la columna en funcion de i y de j
expr_t row;
expr_t col;
// to sum up:
// a(row, col)[t_min,tmax]
// la expresion del miembro derecho
expr_t rhs;
// flag que indica si el assignment pide _init o _0
int initial_static;
int initial_transient;
// si este es true entonces la asignacion es una sola (aun cuando el miembro
// izquierdo sea un vector o matriz), i.e.
// A(127,43) es escalar
// A(2*i+1,14) no es escalar
int scalar;
// si esto es true, entonces las asignaciones vector o matriz son plain, i.e.
// A(i,j)
int plain;
// diferenciamos, en caso de las matrices, aquellas dependencias solo en i o en j
// A(i,4) = 5 es un assignment que depende solo de i
int expression_only_of_i;
// A(8,j) = 1 es un assignment que depende solo de j
int expression_only_of_j;
assignment_t *next;
};
// a file, either input or output
struct file_t {
char *name;
int initialized;
char *format;
int n_format_args;
int n_format_args_given;
expr_t *arg;
char *mode;
char *path;
FILE *pointer;
UT_hash_handle hh;
};
// print a single line
struct print_t {
// pointer to the output file (if null, print to stdout)
file_t *file;
// a linked list with the stuff to print
print_token_t *tokens;
// token separator, by default it is a tab "\t"
char *separator;
// flag to indicate if we need to send the newline char "\n" at the end
// it's called nonewline so the default is zero and the "\n" is sent
int nonewline;
// stuff to help with the SKIP_*
int last_static_step;
int last_step;
double last_time;
expr_t skip_static_step;
expr_t skip_step;
expr_t skip_time;
int header;
expr_t skip_header_step;
int last_header_step;
int header_already_printed;
print_t *next;
};
// an individual token to be PRINTed
struct print_token_t {
char *format;
char *text;
expr_t expression;
vector_t *vector;
matrix_t *matrix;
function_t *function;
print_token_t *next;
};
// printf-like instruction
struct printf_t {
// pointer to the output file (if null, print to stdout)
int all_ranks;
file_t *file;
char *format_string;
int n_args;
expr_t *expressions;
printf_t *next;
};
struct read_data_t {
file_t *file;
// TODO: several things mixed together, this is where I miss C++'s STL
var_t *variable;
vector_t *vector;
read_data_t *next;
};
struct multidim_range_t {
int dimensions;
expr_t *min;
expr_t *max;
expr_t *step;
expr_t *nsteps;
};
// print one or more functions
struct print_function_t {
file_t *file;
// linked list with the stuff to be printed
print_token_t *tokens;
// pointer to the first function (the one that defines the number of arguments
// note that this might not be the same as as token->function, that can be NULL
function_t *first_function;
// explicit range to print the function
multidim_range_t range;
// mesh and physical group that tells where to print a function
mesh_t *mesh;
physical_group_t *physical_group;
// flag to add a header explaining what the columns are
int header;
// formato de los numeritos "%e"
char *format;
// separador de cosas "\t"
char *separator;
print_function_t *next;
};
// instruccion imprimir uno o mas vectores
struct print_vector_t {
// apuntador al archivo de salida
file_t *file;
// una linked list con las cosas a imprimir
print_token_t *tokens;
// apuntador a la primera funcion que aparezca (la que tiene la cantidad posta
// de argumentos), no es igual a first_token->function porque esa puede ser NULL
vector_t *first_vector;
// stuff separator (default is tab)
char *separator;
int horizontal;
expr_t elems_per_line;
print_vector_t *next;
};
struct sort_vector_t {
int descending;
vector_t *v1;
vector_t *v2;
};
struct phase_object_t {
unsigned int offset;
unsigned int size;
int differential;
char *name;
var_t *variable;
var_t *variable_dot;
vector_t *vector;
vector_t *vector_dot;
matrix_t *matrix;
matrix_t *matrix_dot;
phase_object_t *next;
};
struct dae_t {
expr_t residual;
vector_t *vector;
matrix_t *matrix;
expr_t expr_i_min;
expr_t expr_i_max;
expr_t expr_j_min;
expr_t expr_j_max;
int i_min;
int i_max;
int j_min;
int j_max;
int equation_type;
dae_t *next;
};
// mesh-related structs -----------------------------
// node
struct node_t {
double x[3]; // spatial coordinates of the node
size_t tag; // number assigned by Gmsh
size_t index_mesh; // index within the node array
size_t *index_dof; // index within the solution vector for each DOF
double *phi; // values of the solution functions at the node
gsl_matrix *dphidx; // derivative of the m-th DOF with respect to coordinate g
// (this is a gsl_matrix to avoid having to do double mallocs and forgetting about row/col-major
// gsl_matrix *delta_dphidx; // same as above but for the standard deviations of the derivatives
double *flux; // holder of arbitrary functions evaluated at the node (e.g. sigmas and taus)
element_ll_t *element_list;
};
struct node_data_t {
char *name_in_mesh;
function_t *function;
int found;
node_data_t *next;
};
struct node_relative_t {
size_t index;
node_relative_t *next;
};
struct physical_group_t {
char *name;
// these are ints because that's what we read from a .msh
int tag;
int dimension;
material_t *material; // pointer to single material
size_t n_bcs;
bc_t **bc; // array of pointers to bc_t
// volume (or area or length depending on the dim, sometimes called mass)
double volume;
double cog[3];
var_t *var_volume;
vector_t *vector_cog;
// a linked list seems to be too expensive
size_t n_elements;
size_t i_element;
size_t *element;
UT_hash_handle hh;
UT_hash_handle hh_tag[4];
};
struct geometrical_entity_t {
int dim;
int tag;
int parent_dim;
int parent_tag;
double boxMinX, boxMinY, boxMinZ, boxMaxX, boxMaxY, boxMaxZ;
size_t num_partitions;
int *partition;
size_t num_physicals;
int *physical;
size_t num_bounding;
int *bounding;
UT_hash_handle hh[4];
};
struct elementary_entity_t {
size_t id;
elementary_entity_t *next;
};
struct gauss_t {
unsigned int Q; // number of points (q=1,2,...,Q )
double *w; // weights (w[q] is the weight of the v-th point)
double **xi; // coordinates (xi[q][d] is the coordinate of the q-th point in dimension d)
// one matrix for each gauss point q
gsl_matrix **H_c; // H(1,j) = h_j(xi_q)
gsl_matrix **B_c; // B(d,j) = d(h_j)/d(xi_d) at xi_q
gsl_matrix *extrap; // matrix to extrapolate the values from the gauss points to the nodes
};
// constant structure with the types of elements
// this includes the pointers to the shape functions
// the numbering is Gmsh-based
struct element_type_t {
unsigned int id; // as of Gmsh
unsigned int dim;
unsigned int order;
unsigned int nodes; // total, i.e. 10 for tet10
unsigned int vertices; // the corner nodes, i.e 4 for tet10
unsigned int faces; // faces == number of neighbors
unsigned int nodes_per_face; // (max) number of nodes per face
double *barycenter_coords;
double **node_coords;
node_relative_t **node_parents;
// virtual (sic) methods!
// shape functions and derivatives in the local coords
double (*h)(int j, double *xi);
double (*dhdxi)(int j, int d, double *xi);
// G-aware canonical matrices
gsl_matrix **H_Gc;
gsl_matrix **B_Gc;
// convenience methods
int (*point_inside)(element_t *e, const double *x);
double (*volume)(element_t *e);
double (*area)(element_t *e);
double (*size)(element_t *e);
gauss_t gauss[2]; // sets of gauss points
// 0 - full integration
// 1 - reduced integration
// for doc only
// TODO: move somewhere else?
char *name;
char *desc;
char *ascii_art;
int doc_n_edges;
int (*doc_edges)[2];
int doc_n_faces;
int (*doc_faces)[8];
char *(*h_latex)(int j);
};
struct element_t {
size_t index;
size_t tag;
double quality;
double volume;
double area;
double size;
double gradient_weight; // this weight is used to average the contribution of this element to nodal gradients
double *w; // weights of the gauss points time determinant of the jacobian
double **x; // coordinates fo the gauss points
double *normal; // outward normal direction (only for 2d elements)
// matrix with the coordinates (to compute the jacobian)
gsl_matrix *C;
// these are pointers to arrays of matrices are evaluated at the gauss points
gsl_matrix **B;
gsl_matrix **B_G;
gsl_matrix **J; // d(x)/d(xi)
gsl_matrix **invJ; // d(xi)/d(x)
gsl_matrix **dphidx_gauss; // spatial derivatives of the DOFs at the gauss points
gsl_matrix **dphidx_node; // spatial derivatives of the DOFs at the nodes (extrapoladed or evaluated)
double **property_at_node; // 2d array [j][N] of property N evaluated at node j
element_type_t *type; // pointer to the element type
physical_group_t *physical_group; // pointer to the physical group this element belongs to
geometrical_entity_t *geometrical_entity;
node_t **node; // pointer to the nodes, node[j] points to the j-th local node
cell_t *cell; // pointer to the associated cell (only for FVM)
};
struct element_ll_t {
element_t *element;
element_ll_t *next;
};
struct cell_t {
size_t id;
element_t *element;
unsigned int n_neighbors;
size_t *ineighbor; // array with ids of neighboring elements
size_t **ifaces; // array of arrays of ids making up the faces
neighbor_t *neighbor; // array of neighbors
double x[3]; // coordenadas espaciales del baricentro de la celda
size_t *index; // indice del vector incognita para cada uno de los grados de libertad
double volume;
};
struct neighbor_t {
cell_t *cell;
element_t *element;
double **face_coord;
double x_ij[3];
double n_ij[3];
double S_ij;
};
struct material_t {
char *name;
mesh_t *mesh;
property_data_t *property_datums;
char *model;
void *ctx;
UT_hash_handle hh;
};
struct material_ll_t {
material_t *material;
material_ll_t *next;
};
struct property_t {
char *name;
property_data_t *property_datums;
UT_hash_handle hh;
};
struct property_data_t {
property_t *property;
material_t *material;
expr_t expr;
UT_hash_handle hh;
};
struct distribution_t {
char *name;
int defined; // true or false if is defined at least in one group
int *defined_per_group; // true or false if is defined for each group
int full; // true if all the groups have the property
property_t *property;
function_t *function;
var_t *variable;
// caches
material_t *last_material;
property_data_t *last_property_data;
expr_t *expr;
double value;
// dependencies
var_ll_t *dependency_variables;
function_ll_t *dependency_functions;
// is this distribution uniform? (i.e. does not depend on space)
int non_uniform;
// is this distribution constant? (i.e. does not depend on time)
int constant;
// does this distribution depend on the solution itself?
int non_linear;
// virtual method to evaluate at a point
double (*eval)(distribution_t *, const double *x, material_t *material);
};
// nice but not needed
/*
struct name_item_t {
char *name;
name_item_t *next;
};
*/
struct bc_t {
char *name;
mesh_t *mesh;
// name_item_t *groups;
bc_data_t *bc_datums;
UT_hash_handle hh; // for the hashed list mesh.bcs
};
struct bc_data_t {
char *string;
enum {
bc_type_math_undefined,
bc_type_math_dirichlet,
bc_type_math_neumann,
bc_type_math_robin,
bc_type_math_multifreedom
} type_math;
int type_phys; // problem-based flag that tells which type of BC this is
// boolean flags
int space_dependent;
int nonlinear;
int disabled;
int fills_matrix;
unsigned int dof; // -1 means "all" dofs
expr_t expr;
expr_t condition; // if it is not null the BC only applies if this evaluates to non-zero
int (*set_essential)(bc_data_t *, element_t *, size_t j_global);
int (*set_natural)(bc_data_t *, element_t *, unsigned int q);
bc_data_t *prev, *next; // doubly-linked list in ech bc_t
};
// hash map entry for sparse node ids
typedef struct {
size_t gmsh_tag; // Gmsh node tag (key)
size_t vtk_idx; // VTK point index (value)
UT_hash_handle hh;
} tag_index_hash_t;
// struct to encapsulate either mapping
typedef struct {
int use_array; // 1 for array, 0 for hashmap
size_t min_id, max_id;
size_t*array; // if use_array
tag_index_hash_t *hash; // if !use_array
} tag_index_map_t;
// unstructured mesh
struct mesh_t {
file_t *file;
unsigned int dim;
unsigned int dim_topo;
size_t n_nodes;
size_t n_elements;
size_t n_elements_per_dim[4];
size_t n_cells; // a cell is an element with the topological dimension of the mesh
int n_partitions;
int degrees_of_freedom; // per unknown
unsigned int order;
physical_group_t *physical_groups; // global hash table
physical_group_t *physical_groups_by_tag[4]; // 4 hash tables one per tag
int physical_tag_max; // the higher tag of the entities
int n_groups;
// number of geometric entities of each dimension
size_t points, curves, surfaces, volumes;
geometrical_entity_t *geometrical_entities[4]; // 4 hash tables, one for each dimension
// partition data
size_t num_partitions;
size_t num_ghost_entitites;
size_t partitioned_points, partitioned_curves, partitioned_surfaces, partitioned_volumes;
int sparse; // flag that indicates if the nodes are sparse
size_t *tag2index; // array to map tags to indexes (we need a -1)
// pointer to tag_min entries before so we can use the tag as an offset
size_t *tag2index_from_tag_min;
size_t node_tag_min;
size_t node_tag_max;
// TODO: we can have a hash map to handle very sparse indexing but I'm not sure it is worth
enum {
data_type_element,
data_type_node,
} data_type;
enum {
integration_full,
integration_reduced
} integration;
enum {
mpi_matches_partitions_no,
mpi_matches_partitions_serial,
mpi_matches_partitions_one_to_one,
mpi_matches_partitions_one_to_many,
} mpi_matches_partitions;
// this is for mpi_matches_partitions_no
size_t first_element;
size_t last_element;
int update_each_step;
expr_t scale_factor; // scale factor when reading the coordinates of the nodes
expr_t offset_x; // offset en nodos
expr_t offset_y; // offset en nodos
expr_t offset_z; // offset en nodos
gsl_vector **nodes_argument;
gsl_vector **cells_argument;
node_data_t *node_datas;
int n_physical_names;
node_t *node;
element_t *element;
cell_t *cell;
node_t bounding_box_max;
node_t bounding_box_min;
unsigned int max_nodes_per_element;
unsigned int max_faces_per_element;
unsigned int max_first_neighbor_nodes; // to estimate matrix bandwidth
// kd-trees to make efficient searches
void *kd_nodes;
void *kd_cells;
element_t *last_chosen_element; // interpolation cache
// virtual method for format-dependet reader
int (*reader)(mesh_t *);
int initialized;
UT_hash_handle hh;
};
typedef enum {
field_location_default,
field_location_nodes,
field_location_cells,
field_location_gauss
} field_location_t;
struct mesh_write_dist_t {
char *name;
unsigned int size; // TODO: rename to num_of_components
function_t **field;
field_location_t field_location;
char *printf_format;
mesh_write_dist_t *next;
};
struct mesh_write_t {
mesh_t *mesh;
file_t *file;
file_t *file_pvd;
int no_mesh;
enum {
post_format_fromextension,
post_format_gmsh,
post_format_vtu,
post_format_vtk,
} post_format;
int no_physical_names;
size_t base_extension_offset;
char *base_extension;
field_location_t field_location;
char *printf_format;
int (*write_header)(mesh_t *mesh, FILE *file);
int (*write_mesh)(mesh_t *mesh, FILE *file, int no_physical_names);
int (*write_data)(mesh_write_t *this, mesh_write_dist_t *dist);
int (*write_footer)(mesh_write_t *this);
// these two are to know if we have to change the type in VTK
int point_init;
int cell_init;
// this is to know if we already wrote LOOKUP_TABLE
int lookup_table_init;
mesh_write_dist_t *mesh_write_dists;
mesh_write_t *next;
};
struct mesh_integrate_t {
mesh_t *mesh;
function_t *function;
expr_t expr;
physical_group_t *physical_group;
field_location_t field_location;
unsigned int gauss_points;
var_t *result;
mesh_integrate_t *next;
};
struct mesh_find_extrema_t {
mesh_t *mesh;
physical_group_t *physical_group;
function_t *function;
expr_t expr;
field_location_t field_location;
var_t *min;
var_t *i_min;
var_t *x_min;
var_t *y_min;
var_t *z_min;
var_t *max;
var_t *i_max;
var_t *x_max;
var_t *y_max;
var_t *z_max;
mesh_find_extrema_t *next;
};
// fit an algebraic function to a pointwise-defined function
struct fit_t {
unsigned int max_iter;
int verbose;
// number of parameters to fit (i.e. a & b -> 2)
unsigned int n_via;
// number of experimental data to fit (order 1,000)
size_t n_data;
// algebraic function whose parameters we have to fit
function_t *function;
// point-wise function with the experimental data
function_t *data;
// pointers to the variables acting as parameters
var_t **via;
// and their statistical uncertainties
var_t **sigma;
// array of size n_params with the analytical derivatives of the function with respect to the params
// if it is NULL we have to compute it numerically
expr_t *gradient;
// same thing for the initial guess
expr_t *guess;
// range where to fit
multidim_range_t range;
//expr_t tol_abs;
//expr_t tol_rel;
// working pointers
double *x;
double *range_min;
double *range_max;
double *y_plus;
double *y_minus;
fit_t *next;
};
struct solve_t {
size_t n_unknowns;
var_t **unknown;
expr_t *residual;
expr_t *guess;
expr_t epsabs;
expr_t epsrel;
int max_iter;
int verbose;
const gsl_multiroot_fsolver_type *type;
solve_t *next;
};
struct dump_t {
enum {
dump_format_default,
dump_format_binary,
dump_format_ascii,
dump_format_octave,
} format;
int K;
int K_bc;
int b;
int b_bc;
int M;
int M_bc;
dump_t *next;
};
struct reaction_t {
physical_group_t *physical_group;
var_t *scalar;
vector_t *vector;
int order;
expr_t x0[3];
reaction_t *next;
};
// global FeenoX singleton structure
struct feenox_t {
int argc;
char **argv;
char **argv_orig;
int optind;
char *main_input_filepath;
char *main_input_dirname;
#ifdef HAVE_CLOCK_GETTIME
struct timespec tp0;
#endif
int check;
// TODO
// int debug;
int mpi_rank;
int mpi_size;
char **error;
int error_level;
// if this is not null then a conditional is wanting us to branch
instruction_t *next_instruction;
expr_t *time_paths;
expr_t *time_path_current;
instruction_t *instructions;
instruction_t *last_defined_instruction; // TODO: see if we can put this somewhere else
conditional_block_t *conditional_blocks;
conditional_block_t *active_conditional_block;
var_t *vars;
vector_t *vectors;
matrix_t *matrices;
alias_t *aliases;
function_t *functions;
assignment_t *assignments;
file_t *files;
print_t *prints;
printf_t *printfs;
print_function_t *print_functions;
print_vector_t *print_vectors;
fit_t *fits;
solve_t *solves;
struct {
var_t *done;
var_t *done_static;
var_t *done_transient;
var_t *step_static;
var_t *step_transient;
var_t *in_static;
var_t *in_static_first;
var_t *in_static_last;
var_t *in_transient;
var_t *in_transient_first;
var_t *in_transient_last;
var_t *in_time_path;
var_t *static_steps;
var_t *end_time;
var_t *t;
var_t *dt;
var_t *dae_rtol;
var_t *min_dt;
var_t *max_dt;
var_t *i;
var_t *j;
var_t *pi;
var_t *zero;
var_t *infinite;
var_t *pid;
var_t *mpi_size;
var_t *mpi_rank;
var_t *on_nan;
var_t *on_gsl_error;
var_t *on_ida_error;
// var_t *realtime_scale;
} special_vars;
struct {
vector_t *abs_error;
} special_vectors;
struct {
file_t *_stdin;
file_t *_stdout;
file_t *_stderr;
} special_files;
struct {
int need_cells;
mesh_t *meshes;
mesh_t *mesh_main;
material_t *materials;
property_t *properties;
bc_t *bcs;
mesh_write_t *mesh_writes;
mesh_integrate_t *integrates;
mesh_find_extrema_t *find_extremas;
field_location_t default_field_location;
element_type_t *element_types;
// estas tres variables estan reallocadas para apuntar a vec_x
struct {
var_t *x;
var_t *y;
var_t *z;
var_t *arr_x[3]; // x, y y z en un array de tamanio 3
vector_t *vec_x;
var_t *nx;
var_t *ny;
var_t *nz;
var_t *arr_n[3];
vector_t *vec_n;
var_t *eps;
var_t *nodes;
var_t *cells;
var_t *elements;
vector_t *bbox_min;
vector_t *bbox_max;
var_t *mesh_failed_interpolation_factor;
} vars;
} mesh;
struct {
unsigned int dimension;
int reading_daes;
double **phase_value;
double **phase_derivative;
phase_object_t *phase_objects;
enum {
initial_conditions_as_provided,
initial_conditions_from_variables,
initial_conditions_from_derivatives,
} initial_conditions_mode;
#ifdef HAVE_SUNDIALS
N_Vector x;
N_Vector dxdt;
N_Vector id;
N_Vector abs_error;
SUNMatrix A;
SUNLinearSolver LS;
#if SUNDIALS_VERSION_MAJOR >= 6
SUNContext ctx;
#endif
#endif
dae_t *daes;
void *system;
instruction_t *instruction;
} dae;
struct {
enum {
symmetry_axis_none,
symmetry_axis_x,
symmetry_axis_y
} symmetry_axis;
enum {
hanging_nodes_nothing,
hanging_nodes_detect,
hanging_nodes_handle
} hanging_nodes;
enum {
unresolved_bcs_detect,
unresolved_bcs_allow
} unresolved_bcs;
// these can be read from the input but also we can figure them out
enum {
transient_type_undefined,
transient_type_transient, // real transient
transient_type_quasistatic, // a TS without mass
transient_type_quasistatic_dumb // several KSPs/SNESes one after the other
} transient_type;
enum {
math_type_automatic,
math_type_linear,
math_type_nonlinear,
math_type_nonlinear_pseudo,
math_type_eigen,
} math_type;
enum {
eigen_formulation_undefined,
eigen_formulation_lambda,
eigen_formulation_omega
} eigen_formulation;
enum {
eigen_dirichlet_zero_M,
eigen_dirichlet_zero_K
} eigen_dirichlet_zero;
unsigned int dim; // spatial dimension of the problem (currently, equal to the topological dimension)
unsigned int dofs; // DoFs per node/cell
size_t width; // number of expected non-zeros per row
size_t spatial_unknowns; // number of spatial unknowns (nodes in fem, cells in fvm)
size_t size_global; // total number of DoFs
int do_not_solve; // flag to skip solves in particular cases (e.g. convert to other format)
int compute_gradients; // do we need to compute gradients?
int problem_solved; // status to detect implicit SOLVE_PROBLEMs
void *missed_dump;
// gsl_matrix *m2;
int rough; // keep each element's contribution to the gradient?
int roughish; // average only on the same physical group?
mesh_t *mesh;
mesh_t *mesh_rough; // in this mesh each elements has unique nodes (they are duplicated)
// problem-specific virtual methods
// parse
int (*parse_problem)(const char *token);
int (*parse_write_results)(mesh_write_t *mesh_write, const char *token);
int (*parse_bc)(bc_data_t *bc_data, const char *lhs, char *rhs);
// init
int (*init_before_run)(void);
#ifdef HAVE_PETSC
int (*setup_pc)(PC pc);
int (*setup_ksp)(KSP ksp);
int (*setup_snes)(SNES snes);
#ifdef HAVE_SLEPC
int (*setup_eps)(EPS eps);
#endif
int (*setup_ts)(TS ksp);
#endif
// build
int (*element_build_allocate_aux)(unsigned int J);
int (*element_build_volumetric)(element_t *e);
int (*element_build_volumetric_at_gauss)(element_t *e, unsigned int q);
// solve
int (*solve)(void);
// post
int (*solve_post)(void);
int (*gradient_fill)(void);
int (*gradient_nodal_properties)(element_t *e, mesh_t *mesh);
int (*gradient_alloc_nodal_fluxes)(node_t *node);
int (*gradient_add_elemental_contribution_to_node)(node_t *node, element_t *e, unsigned int j, double rel_weight);
int (*gradient_fill_fluxes)(mesh_t *mesh, size_t j_global);
// instruction pointer to know before/after transient PDE
instruction_t *instruction;
function_t *initial_guess;
function_t *initial_condition;
dump_t *dumps;
reaction_t *reactions;
struct {
var_t *ksp_atol;
var_t *ksp_rtol;
var_t *ksp_divtol;
var_t *ksp_max_it;
var_t *snes_atol;
var_t *snes_rtol;
var_t *snes_stol;
var_t *snes_max_it;
var_t *ts_atol;
var_t *ts_rtol;
var_t *eps_tol;
var_t *eps_max_it;
var_t *eps_st_sigma;
var_t *eps_st_nu;
var_t *mumps_cntl_1;
var_t *mumps_icntl_14;
var_t *mumps_icntl_24;
var_t *gamg_threshold;
var_t *penalty_weight;
var_t *nodes_rough;
var_t *total_dofs;
var_t *memory_available;
} vars;
// vectors
struct {
vector_t **phi;
} vectors;
char **unknown_name; // one for each DOF
// the functions with the solutions (one for each DOF)
function_t **solution;
// derivatives of solutions with respect to space (DOFs x dims)
function_t ***gradient;
// uncertainty (i.e standard deviation of the contribution of each element)
function_t ***delta_gradient;
// solutions for eigenproblems
function_t ***mode;
enum {
gradient_gauss_extrapolated,
gradient_at_nodes,
gradient_none
} gradient_evaluation;
enum {
gradient_weight_volume,
gradient_weight_quality,
gradient_weight_volume_times_quality,
gradient_weight_flat,
} gradient_element_weight;
enum {
gradient_average,
gradient_actual
} gradient_highorder_nodes;
int has_stiffness;
int has_mass;
int has_rhs;
int has_internal_fluxes;
int has_jacobian;
int has_jacobian_K;
int has_jacobian_M;
int has_jacobian_b;
int symmetric_K;
int symmetric_M;
#ifdef HAVE_PETSC
char *petsc_options;
PetscBool pre_allocate; // preallocate? only works for petsc >= 3.19
PetscBool allow_new_nonzeros; // flag to set MAT_NEW_NONZERO_ALLOCATION_ERR to false, needed in some rare cases
PetscBool petscinit_called; // flag
// stuff for mpi parallelization
PetscInt nodes_local, size_local;
PetscInt first_row, last_row;
PetscInt first_node, last_node;
// dirichlet BC scaling factor
PetscScalar dirichlet_scale;
PetscScalar dirichlet_scale_fraction;
// global objects
Vec phi; // the unknown (solution) vector
Vec phi_bc; // the unknown (solution) vector with dirichlet BCs
Vec b; // the right-hand side vector without dirichlet BCs
Vec b_bc; // idem with dirichlet BCs (for KSP)
Vec f; // internal fluxes (forces) for non-linear problems
Vec r; // residual vector for SNES and TS
Mat K; // stiffness matrix without dirichlet BCs
Mat K_bc; // stiffness matrix with dirichlet BCs (for KSP)
Mat M; // mass matrix (rho for elastic, rho*cp for heat)
Mat M_bc; // mass matrix with dirichlet BCs (for EPS)
Mat JK; // jacobian for stiffness matrix = K'*phi
Mat JM; // jacobian for mass matrix = M'*phi_dot
Mat Jb; // jacobian for rhs vector = dq/dT for both volumetric and BCs
Mat J_snes; // jacobian for SNES
Mat J_ts; // jacobian for TS
PetscScalar *eigenvalue; // eigenvalue vector
Vec *eigenvector; // eivenvectors vector
// internal storage of evaluated dirichlet conditions
size_t *dirichlet_nodes;
unsigned int *dirichlet_dofs;
PetscInt *dirichlet_indexes;
PetscScalar *dirichlet_values;
PetscScalar *dirichlet_derivatives;
size_t dirichlet_k;
// reusable number of dirichlet rows to know how much memory to allocate
size_t dirichlet_rows;
// internal storage of multi-freedom conditions
PetscInt **multifreedom_indexes;
gsl_matrix **multifreedom_coefficients;
size_t multifreedom_k;
size_t multifreedom_nodes;
// PETSc's solvers
TS ts;
SNES snes;
KSP ksp;
// strings with types
PCType pc_type;
KSPType ksp_type;
SNESType snes_type;
SNESLineSearchType ls_type;
TSType ts_type;
TSAdaptType ts_adapt_type;
PetscInt nev; // number of requested modes
#ifdef HAVE_SLEPC
EPSType eps_type;
STType st_type;
EPS eps;
#endif
PetscBool progress_ascii;
PetscReal progress_r0;
PetscReal progress_last;
PetscLogStage stage_init;
PetscLogStage stage_build;
PetscLogStage stage_solve;
PetscLogStage stage_post;
expr_t eps_ncv;
expr_t st_shift;
expr_t st_anti_shift;
#endif // HAVE_PETSC
} pde;
struct {
// TODO: this is not thread safe! we stick to MPI anyway...
size_t current_gauss_element_tag;
element_type_t *current_gauss_type;
unsigned int current_GJ;
element_type_t *current_elemental_type;
element_type_t *current_jacobian_type;
size_t current_weight_element_tag;
size_t current_jacobian_element_tag;
unsigned int current_weight_gauss_point;
unsigned int current_jacobian_gauss_point;
double *w;
double **x;
gsl_matrix *C;
gsl_matrix **Ji;
gsl_matrix **invJi;
gsl_matrix **Bi;
gsl_matrix **B_Gi;
// elemental (local) objects
gsl_matrix *Ki; // elementary stiffness matrix
gsl_matrix *Mi; // elementary mass matrix
gsl_matrix *JKi; // elementary jacobian for stiffness matrix
gsl_matrix *Jbi; // elementary jacobian for RHS vector
gsl_vector *bi; // elementary right-hand side vector
gsl_vector *fi; // elementary non-linear internal "force" vector
gsl_vector *phii; // elementary solution vector
gsl_vector *vec_f; // temporary vector for rhs things like H'*f
int cache_J;
int cache_B;
#ifdef HAVE_PETSC
PetscInt *l; // node-major-ordered vector with the global indexes of the DOFs in the element
#endif
} fem;
};
extern feenox_t feenox;
// function declarations
// run.c
extern int feenox_run(void);
extern void feenox_limit_time_step(void);
// step.c
extern int feenox_step(instruction_t *first, instruction_t *last);
// init.c
extern int feenox_initialize(int argc, char **argv);
extern int feenox_init_special_objects(void);
extern int feenox_init_after_parser(void);
// mesh's init.c
extern int feenox_mesh_init_special_objects(void);
// version.c
extern void feenox_show_help(const char *progname, int extra);
extern void feenox_show_version(int version);
extern void feenox_copyright(void);
extern void feenox_shortversion(void);
extern void feenox_longversion(void);
// error.c
void feenox_push_error_message(const char *fmt, ...);
void feenox_pop_error_message(void);
void feenox_pop_errors(void);
void feenox_runtime_error(void);
void feenox_nan_error(void);
void feenox_gsl_handler (const char *reason, const char *file_ptr, int line, int gsl_errno);
void feenox_signal_handler(int sig_num);
// cleanup.c
void feenox_polite_exit(int error);
void feenox_finalize(void);
// parser.c
extern int feenox_parse_main_input_file(const char *filepath);
extern char *feenox_ends_in_init(const char *name);
extern char *feenox_ends_in_zero(const char *name);
extern int feenox_count_arguments(char *string, size_t *);
extern int feenox_read_arguments(char *string, int n_arguments, char ***arg, size_t *n_chars);
// file.c
char *feenox_evaluate_string(const char *restrict format, int n_args, expr_t *arg);
extern int feenox_instruction_file(void *arg);
FILE *feenox_fopen(const char *filepath, const char *mode);
extern int feenox_instruction_file_open(void *arg);
extern int feenox_instruction_file_close(void *arg);
// read.c
extern int feenox_instruction_read_data(void *arg);
// abort.c
extern int feenox_instruction_abort(void *arg);
// expressions.c
extern int feenox_expression_parse(expr_t *, const char *string);
extern expr_item_t *feenox_expression_parse_item(const char *string);
extern int feenox_parse_range(char *string, const char left_delim, const char middle_delim, const char right_delim, expr_t *a, expr_t *b);
extern double feenox_expression_eval(expr_t *);
extern double feenox_expression_evaluate_in_string(const char *string);
extern int feenox_pull_dependencies_variables(var_ll_t **to, var_ll_t *from);
extern int feenox_pull_dependencies_functions(function_ll_t **to, function_ll_t *from);
double feenox_expression_derivative_wrt_function_gsl_function(double x, void *params);
double feenox_expression_derivative_wrt_function(expr_t *expr, function_t *function, double x);
double feenox_expression_derivative_wrt_variable_gsl_function(double x, void *params);
double feenox_expression_derivative_wrt_variable(expr_t *expr, var_t *variable, double x);
// dae.c
extern int feenox_add_time_path(const char *token);
extern int feenox_phase_space_add_object(const char *token, int differential);
extern char *feenox_find_first_dot(const char *s);
extern int feenox_add_dae(const char *lhs, const char *rhs);
extern int feenox_dae_init(void);
extern int feenox_dae_ic(void);
#ifdef HAVE_SUNDIALS
extern int feenox_ida_dae(sunrealtype t, N_Vector yy, N_Vector yp, N_Vector rr, void *params);
#else
extern int feenox_ida_dae(void);
#endif
extern int feenox_instruction_dae(void *arg);
// instruction.c
extern instruction_t *feenox_add_instruction_and_get_ptr(int (*routine)(void *), void *argument);
extern int feenox_add_instruction(int (*routine)(void *), void *argument);
// define.c
extern int feenox_check_name(const char *name);
extern int feenox_define_variable(const char *name);
extern int feenox_define_alias(const char *new_name, const char *existing_object, const char *row, const char *col);
extern int feenox_define_vector(const char *name, const char *size);
//extern int feenox_vector_attach_function(const char *name, const char *function_data);
extern int feenox_vector_attach_data(const char *name, expr_t *datas);
extern int feenox_define_matrix(const char *name, const char *rows, const char *cols);
extern int feenox_matrix_attach_data(const char *name, expr_t *datas);
extern int feenox_define_function(const char *name, unsigned int n_arguments);
extern function_t *feenox_define_function_get_ptr(const char *name, int n_arguments);
extern int feenox_define_file(const char *name, const char *format, int n_args, const char *mode);
extern int feenox_file_set_path_argument(const char *name, int i, const char *expression);
extern file_t *feenox_get_or_define_file_get_ptr(const char *name);
extern var_t *feenox_get_or_define_variable_get_ptr(const char *name);
extern var_t *feenox_define_variable_get_ptr(const char *name);
extern vector_t *feenox_define_vector_get_ptr(const char *name, size_t size);
extern int feenox_realloc_variable_ptr(var_t *, double *newptr, int copy_contents);
extern int feenox_realloc_vector_ptr(vector_t *, double *newptr, int copy_contents);
// getptr.c
extern var_t *feenox_get_variable_ptr(const char *name);
extern vector_t *feenox_get_vector_ptr(const char *name);
extern matrix_t *feenox_get_matrix_ptr(const char *name);
extern function_t *feenox_get_function_ptr(const char *name);
extern builtin_function_t *feenox_get_builtin_function_ptr(const char *name);
extern builtin_vectorfunction_t *feenox_get_builtin_vectorfunction_ptr(const char *name);
extern builtin_functional_t *feenox_get_builtin_functional_ptr(const char *name);
extern vector_t *feenox_get_first_vector(const char *s);
extern file_t *feenox_get_file_ptr(const char *name);
extern mesh_t *feenox_get_mesh_ptr(const char *name);
extern physical_group_t *feenox_get_physical_group_ptr(const char *name, mesh_t *mesh);
// assignment.c
extern int feenox_add_assignment(const char *left_hand, const char *right_hand);
extern int feenox_assign_single(assignment_t *assignment, unsigned int row, unsigned int col);
extern int feenox_instruction_assignment_scalar(void *arg);
extern int feenox_instruction_assignment_vector(void *arg);
extern int feenox_instruction_assignment_matrix(void *arg);
extern int feenox_get_assignment_rowcol(assignment_t *assignment, size_t i, size_t j, size_t *row, size_t *col);
// auxiliary.c
extern int feenox_strip_blanks(char *string);
extern int feenox_strip_comments(char *line);
// alias.c
extern int feenox_instruction_alias(void *arg);
// fit.c
extern int feenox_instruction_fit(void *arg);
// solve.c
extern int feenox_instruction_solve(void *arg);
// dump.c
extern int feenox_instruction_dump(void *arg);
#ifdef HAVE_PETSC
extern int feenox_dump_open_viewer(dump_t *, const char *name, PetscViewer *viewer);
#endif
// reaction.c
extern int feenox_instruction_reaction(void *arg);
// matrix.c
extern int feenox_matrix_init(matrix_t *);
// vector.c
extern int feenox_create_pointwise_function_vectors(function_t *function);
extern int feenox_vector_init(vector_t *, int no_initial);
extern int feenox_instruction_sort_vector(void *arg);
extern double feenox_vector_get(vector_t *, const size_t i);
extern double feenox_vector_get_initial_static(vector_t *, const size_t i);
extern double feenox_vector_get_initial_transient(vector_t *, const size_t i);
extern int feenox_vector_set(vector_t *, const size_t i, double value);
extern int feenox_vector_add(vector_t *, const size_t i, double value);
extern int feenox_vector_set_size(vector_t *, const size_t size);
extern size_t feenox_vector_get_size(vector_t *);
// function.c
extern int feenox_function_init(function_t *);
extern int feenox_function_set_args(function_t *, double *x);
extern int feenox_function_set_argument_variable(const char *name, unsigned int i, const char *variable_name);
extern int feenox_function_set_expression(const char *name, const char *expression);
extern int feenox_function_set_interpolation(const char *name, const char *type);
extern int feenox_function_set_file(const char *name, file_t *file, unsigned int *columns);
extern int function_set_buffered_data(function_t *function, double *buffer, size_t n_data, unsigned int n_columns, unsigned int *columns);
size_t feenox_structured_scalar_index(unsigned int n_dims, size_t *size, size_t *index, int x_increases_first);
extern double feenox_function_eval(function_t *, const double *x);
extern double feenox_factor_function_eval(expr_item_t *);
extern int feenox_function_is_structured_grid_2d(double *x, double *y, size_t n, size_t *nx, size_t *ny);
extern int feenox_function_is_structured_grid_3d(double *x, double *y, double *z, size_t n, size_t *nx, size_t *ny, size_t *nz);
// print.c
extern int feenox_instruction_print(void *arg);
extern int feenox_instruction_printf(void *arg);
extern int feenox_instruction_print_function(void *arg);
extern int feenox_instruction_print_vector(void *arg);
extern char *feenox_print_vector_current_format_reset(print_vector_t *);
extern int feenox_debug_print_gsl_vector(const gsl_vector *b, FILE *file);
extern int feenox_debug_print_gsl_matrix(const gsl_matrix *A, FILE *file);
// conditional.c
extern int feenox_instruction_if(void *arg);
extern int feenox_instruction_else(void *arg);
extern int feenox_instruction_endif(void *arg);
// functionals.c
extern double feenox_gsl_function(double x, void *params);
// mesh.c
extern int feenox_instruction_mesh_read(void *arg);
extern int feenox_mesh_create_nodes_argument(mesh_t *);
extern int feenox_mesh_create_index2tag(mesh_t *this);
extern int feenox_mesh_free(mesh_t *);
extern int feenox_mesh_read_vtk(mesh_t *);
extern int feenox_mesh_read_frd(mesh_t *);
extern node_t *feenox_mesh_find_nearest_node(mesh_t *, const double *x);
extern element_t *feenox_mesh_find_element(mesh_t *, node_t *nearest_node, const double *x);
// interpolate.c
extern double feenox_function_property_eval(struct function_t *function, const double *x);
extern int feenox_mesh_interp_solve_for_r(element_t *, const double *x, double *r) ;
extern int feenox_mesh_interp_residual(const gsl_vector *test, void *params, gsl_vector *residual);
extern int feenox_mesh_interp_jacob(const gsl_vector *test, void *params, gsl_matrix *J);
extern int feenox_mesh_interp_residual_jacob(const gsl_vector *test, void *params, gsl_vector *residual, gsl_matrix * J);
extern double feenox_mesh_interpolate_function_node(struct function_t *function, const double *x);
extern int feenox_mesh_compute_r_tetrahedron(element_t *, const double *x, double *r);
// gmsh.c
extern int feenox_mesh_read_gmsh(mesh_t *mesh);
extern int feenox_mesh_tag2index_alloc(mesh_t *mesh, size_t, size_t );
extern int feenox_mesh_update_function_gmsh(function_t *function, double t, double dt);
extern int feenox_mesh_write_header_gmsh(mesh_t *mesh, FILE *file);
extern int feenox_mesh_write_mesh_gmsh(mesh_t *mesh, FILE *file, int no_physical_names);
extern int feenox_mesh_write_data_gmsh(mesh_write_t *, mesh_write_dist_t *dist);
extern int feenox_gmsh_read_data_int(mesh_t *, size_t n, int *data, int binary);
extern int feenox_gmsh_read_data_size_t(mesh_t *, size_t n, size_t *data, int binary);
extern int feenox_gmsh_read_data_double(mesh_t *, size_t n, double *data, int binary);
// write.c
extern int feenox_instruction_mesh_write(void *arg);
// integrate.c
extern int feenox_instruction_mesh_integrate(void *arg);
extern double feenox_mesh_integral_over_element(element_t *, mesh_t *mesh, function_t *function);
extern double feenox_mesh_integral_function_cell_cell(function_t *function, mesh_t *mesh, physical_group_t *physical_group);
extern double feenox_mesh_integral_function_general_cell(function_t *function, mesh_t *mesh, physical_group_t *physical_group);
extern double feenox_mesh_integral_function_node_gauss(function_t *function, mesh_t *mesh, physical_group_t *physical_group);
extern double feenox_mesh_integral_function_general_gauss(function_t *function, mesh_t *mesh, physical_group_t *physical_group);
extern double feenox_mesh_integral_expression_cell(expr_t *expr, mesh_t *mesh, physical_group_t *physical_group);
extern double feenox_mesh_integral_expression_gauss(expr_t *expr, mesh_t *mesh, physical_group_t *physical_group);
// extrema.c
extern int feenox_instruction_mesh_find_extrema(void *arg);
// physical_group.c
extern int feenox_define_physical_group(const char *name, const char *mesh_name, int dimension, int tag);
extern physical_group_t *feenox_define_physical_group_get_ptr(const char *name, mesh_t *mesh, int dimension, int tag);
extern physical_group_t *feenox_get_or_define_physical_group_get_ptr(const char *name, mesh_t *mesh, int dimension, int tag);
extern int feenox_physical_group_set_material(const char *group_name, const char *material_name, mesh_t *mesh);
extern int feenox_physical_group_compute_volume(physical_group_t *, const mesh_t *mesh);
// material.c
extern material_t *feenox_get_material_ptr(const char *name);
extern int feenox_define_material(const char *material_name, const char *mesh_name);
extern material_t *feenox_define_material_get_ptr(const char *name, mesh_t *mesh);
extern int feenox_define_property(const char *name, const char *mesh_name);
extern property_t *feenox_define_property_get_ptr(const char *name, mesh_t *mesh);
extern int feenox_define_property_data(const char *property_name, const char *material_name, const char *expr_string);
extern property_data_t *feenox_define_property_data_get_ptr(property_t *property, material_t *material, const char *expr_string);
// boundary_condition.c
extern bc_t *feenox_get_bc_ptr(const char *name);
extern int feenox_define_bc(const char *bc_name, const char *mesh_name);
extern bc_t *feenox_define_bc_get_ptr(const char *name, mesh_t *mesh);
extern int feenox_add_bc_data(const char *bc_name, const char *string);
extern bc_data_t *feenox_add_bc_data_get_ptr(bc_t *bc, const char *string);
// init.c
extern int feenox_mesh_element_types_init(void);
extern int feenox_mesh_elements_info(void);
extern int feenox_mesh_elements_info_geo(element_type_t *element_type);
// geom.c
extern void feenox_mesh_subtract(const double *a, const double *b, double *c);
extern void feenox_mesh_cross(const double *a, const double *b, double *c);
extern void feenox_mesh_normalized_cross(const double *a, const double *b, double *c);
extern double feenox_mesh_cross_dot(const double *a, const double *b, const double *c);
extern double feenox_mesh_subtract_cross_2d(const double *a, const double *b, const double *c);
extern double feenox_mesh_dot(const double *a, const double *b);
extern double feenox_mesh_subtract_dot(const double *b, const double *a, const double *c);
extern double feenox_mesh_subtract_module(const double *b, const double *a);
#define feenox_mesh_distance(a,b) feenox_mesh_subtract_module((a),(b))
extern double feenox_mesh_subtract_squared_module(const double *b, const double *a);
extern double feenox_mesh_subtract_squared_module2d(const double *b, const double *a);
extern int feenox_mesh_compute_outward_normal(element_t *element, double n[3]) __attribute__((noinline));
// element.c
extern int feenox_mesh_compute_normal_2d(element_t *e);
extern int feenox_mesh_add_element_to_list(element_ll_t **list, element_t *e);
extern int feenox_mesh_compute_element_barycenter(element_t *e, double barycenter[]);
extern int feenox_mesh_init_nodal_indexes(mesh_t *, int dofs);
// cell.c
extern int feenox_mesh_element2cell(mesh_t *);
// tag_index_map.c
/*
extern int tag_index_map_init(tag_index_map_t *map, size_t min_id, size_t max_id, size_t n_nodes, double threshold);
extern int tag_index_map_insert(tag_index_map_t *map, size_t gmsh_id, size_t vtk_idx);
extern size_t tag_index_map_lookup(tag_index_map_t *map, size_t gmsh_id);
extern int tag_index_map_free(tag_index_map_t *map);
*/
// vtk.c
extern int feenox_mesh_read_vtk_field_node(mesh_t *mesh, FILE *fp, const char *name, unsigned int size);
extern int feenox_mesh_write_unstructured_mesh_vtk(mesh_t *mesh, FILE *file);
extern int feenox_mesh_write_header_vtk(mesh_t *mesh, FILE *file);
extern int feenox_mesh_write_vtk_cells(mesh_t *mesh, FILE * file, int with_size);
extern int feenox_mesh_write_vtk_types(mesh_t *mesh, FILE * file);
extern int feenox_mesh_write_mesh_vtk(mesh_t *mesh, FILE *file, int dummy);
extern int feenox_mesh_write_data_vtk(mesh_write_t *this, mesh_write_dist_t *dist);
// vtu.c
extern int feenox_mesh_write_header_vtu(mesh_t *mesh, FILE *file);
extern int feenox_mesh_write_mesh_vtu(mesh_t *, FILE *file, int dummy);
extern int feenox_mesh_write_data_vtu(mesh_write_t *this, mesh_write_dist_t *dist);
extern int feenox_mesh_write_footer_vtu(mesh_write_t *this);
// neighbors.c
extern element_t *feenox_mesh_find_element_volumetric_neighbor(element_t *e) __attribute__((noinline));
extern int feenox_mesh_count_element_volumetric_neighbors(element_t *e) __attribute__((noinline));
// init.c
extern int feenox_problem_parse_time_init(void);
extern int feenox_problem_init_runtime_general(void);
extern int feenox_problem_define_solutions(void);
extern int feenox_problem_define_solution_function(const char *name, function_t **function, int is_gradient);
extern int feenox_problem_fill_aux_solution(function_t *function);
#ifdef HAVE_PETSC
extern Mat feenox_problem_create_matrix(const char *name);
extern Vec feenox_problem_create_vector(const char *name);
#endif
extern int feenox_compute_first_last_element(mesh_t *mesh);
// bulk.c
extern int feenox_problem_build(void);
// solve.c
extern int feenox_instruction_solve_problem(void *arg);
#ifdef HAVE_PETSC
// solve.c
extern int feenox_function_to_phi(function_t *function, Vec phi);
extern int feenox_problem_phi_to_solution(Vec phi, int gradients);
// petsc_ksp.c
extern int feenox_problem_solve_petsc_linear(void);
extern PetscErrorCode feenox_problem_ksp_monitor(KSP ksp, PetscInt n, PetscReal rnorm, void *dummy);
extern int feenox_problem_setup_ksp(KSP ksp);
extern int feenox_problem_setup_pc(PC pc);
// petsc_snes.c
extern int feenox_problem_solve_petsc_nonlinear(void);
extern int feenox_problem_setup_snes(SNES snes);
extern PetscErrorCode feenox_snes_residual(SNES snes, Vec phi, Vec r, void *ctx);
extern PetscErrorCode feenox_snes_jacobian(SNES snes,Vec phi, Mat J, Mat P, void *ctx);
extern PetscErrorCode feenox_snes_monitor(SNES snes, PetscInt n, PetscReal rnorm, void *dummy);
// petsc_ts.c
extern int feenox_problem_solve_petsc_transient(void);
extern int feenox_problem_setup_ts(TS ts);
extern PetscErrorCode feenox_ts_residual(TS ts, PetscReal t, Vec phi, Vec phi_dot, Vec r, void *ctx);
extern PetscErrorCode feenox_ts_jacobian(TS ts, PetscReal t, Vec T, Vec T_dot, PetscReal s, Mat J, Mat P,void *ctx);
// slepc_eps.c
extern int feenox_problem_solve_slepc_eigen(void);
// dirichlet.c
extern int feenox_problem_dirichlet_add(size_t j_global, unsigned int g, double value);
extern int feenox_problem_multifreedom_add(size_t index, double *coefficients);
extern int feenox_problem_mimicked_add(size_t index_guide, size_t index_follower, double coefficient_follower);
extern int feenox_problem_dirichlet_eval(void);
extern int feenox_problem_dirichlet_set_K(void);
extern int feenox_problem_dirichlet_set_M(void);
extern int feenox_problem_dirichlet_set_J(Mat J);
extern int feenox_problem_dirichlet_set_r(Vec r, Vec phi);
extern int feenox_problem_dirichlet_set_phi(Vec phi);
extern int feenox_problem_dirichlet_set_phi_dot(Vec phi_dot);
extern int feenox_problem_dirichlet_compute_scale(void);
#endif
// fem.c
extern int feenox_fem_elemental_caches_reset(void);
extern material_t *feenox_fem_get_material(element_t *e);
extern double *feenox_fem_compute_x_at_gauss(element_t *e, unsigned int q, int integration);
extern double *feenox_fem_compute_x_at_gauss_if_needed(element_t *e, unsigned int q, int integration, int condition);
extern double *feenox_fem_compute_x_at_gauss_if_needed_and_update_var(element_t *e, unsigned int q, int integration, int condition);
extern double *feenox_fem_compute_x_at_gauss_and_update_var(element_t *e, unsigned int q, int integration);
extern double feenox_fem_determinant(const gsl_matrix *);
extern gsl_matrix *feenox_fem_matrix_invert(const gsl_matrix *direct, gsl_matrix *inverse);
extern double feenox_fem_compute_w_det_at_gauss_integration(element_t *e, unsigned int q, int integration);
#define feenox_fem_compute_w_det_at_gauss(e, q) feenox_fem_compute_w_det_at_gauss_integration((e), (q), feenox.pde.mesh->integration)
extern gsl_matrix *feenox_fem_compute_C(element_t *e);
extern gsl_matrix *feenox_fem_compute_H_c_at_gauss(element_t *e, unsigned int q, int integration);
extern gsl_matrix *feenox_fem_compute_H_Gc_at_gauss(element_t *e, unsigned int q, int integration);
extern gsl_matrix *feenox_fem_compute_invJ_at_gauss(element_t *e, unsigned int q, int integration);
extern gsl_matrix *feenox_fem_compute_J(element_t *e, double *xi);
extern gsl_matrix *feenox_fem_compute_J_at_gauss(element_t *e, unsigned int q, int integration);
extern gsl_matrix *feenox_fem_compute_J_at_gauss_1d(element_t *e, unsigned int q, int integration, gsl_matrix *J);
extern gsl_matrix *feenox_fem_compute_J_at_gauss_2d(element_t *e, unsigned int q, int integration, gsl_matrix *J);
extern gsl_matrix *feenox_fem_compute_J_square_at_gauss(element_t *e, unsigned int q, int integration, gsl_matrix *J);
extern gsl_matrix *feenox_fem_compute_B_c(element_t *e, double *xi);
extern gsl_matrix *feenox_fem_compute_B(element_t *e, double *xi);
extern gsl_matrix *feenox_fem_compute_B_at_gauss_integration(element_t *e, unsigned int q, int integration);
#define feenox_fem_compute_B_at_gauss(e, q) feenox_fem_compute_B_at_gauss_integration((e), (q), feenox.pde.mesh->integration)
extern gsl_matrix *feenox_fem_compute_B_Gc_at_gauss(element_t *e, unsigned int q, int integration);
extern gsl_matrix *feenox_fem_compute_B_G_at_gauss(element_t *e, unsigned int q, int integration);
#ifdef HAVE_PETSC
extern PetscInt *feenox_fem_compute_dof_indices(element_t *e, int G);
#endif
#define feenox_fem_update_coord_vars(val) {\
feenox_var_value(feenox.mesh.vars.x) = val[0];\
feenox_var_value(feenox.mesh.vars.y) = val[1];\
feenox_var_value(feenox.mesh.vars.z) = val[2];\
}
// blas.c
extern int feenox_blas_Ab(const gsl_matrix *A, const gsl_vector *b, const double alpha, gsl_vector *c);
extern int feenox_blas_Atb(const gsl_matrix *A, const gsl_vector *b, const double alpha, gsl_vector *c);
extern int feenox_blas_Ab_accum(const gsl_matrix *A, const gsl_vector *b, const double alpha, gsl_vector *c);
extern int feenox_blas_Atb_accum(const gsl_matrix *A, const gsl_vector *b, const double alpha, gsl_vector *c);
extern int feenox_blas_BtB_accum(const gsl_matrix *B, double alpha, gsl_matrix *R);
extern int feenox_blas_BtB(const gsl_matrix *B, double alpha, gsl_matrix *R);
extern int feenox_blas_ABt(const gsl_matrix *A, const gsl_matrix *B, const double alpha, gsl_matrix *R);
extern int feenox_blas_ABt(const gsl_matrix *A, const gsl_matrix *B, const double alpha, gsl_matrix *R);
extern int feenox_blas_BtCB(const gsl_matrix *B, const gsl_matrix *C, gsl_matrix *CB, const double alpha, gsl_matrix *R);
extern int feenox_blas_BtCB_accum(const gsl_matrix *B, const gsl_matrix *C, gsl_matrix *CB, const double alpha, gsl_matrix *R);
extern int feenox_blas_BCBt(const gsl_matrix *B, const gsl_matrix *C, gsl_matrix *CB, const double alpha, gsl_matrix *R);
extern int feenox_blas_PtCB_accum(const gsl_matrix *P, const gsl_matrix *C, const gsl_matrix *B, gsl_matrix *CB, const double alpha, gsl_matrix *R);
extern int feenox_blas_PtCB(const gsl_matrix *P, const gsl_matrix *C, const gsl_matrix *B, gsl_matrix *CB, const double alpha, gsl_matrix *R);
// distribution.c
extern int feenox_distribution_init(distribution_t *, const char *name);
extern double feenox_distribution_eval(distribution_t *, const double *x, material_t *material);
extern double feenox_distribution_eval_property(distribution_t *, const double *x, material_t *material);
extern double feenox_distribution_eval_function_global(distribution_t *, const double *x, material_t *material);
extern double feenox_distribution_eval_function_local(distribution_t *, const double *x, material_t *material);
extern double feenox_distribution_eval_variable_global(distribution_t *, const double *x, material_t *material);
extern double feenox_distribution_eval_variable_local(distribution_t *, const double *x, material_t *material);
extern int feenox_pull_dependencies_variables_function(var_ll_t **to, function_t *function);
extern int feenox_pull_dependencies_functions_function(function_ll_t **to, function_t *function);
extern int feenox_depends_on_space(var_ll_t *variables);
extern int feenox_depends_on_normal(var_ll_t *variables);
extern int feenox_depends_on_time(var_ll_t *variables);
extern int feenox_depends_on_function(function_ll_t *functions, function_t *function);
extern int feenox_expression_depends_on_space(expr_t *expr);
extern int feenox_expression_depends_on_normal(expr_t *expr);
// build.c
extern int feenox_problem_build(void);
extern int feenox_problem_build_element_volumetric(element_t *);
extern int feenox_problem_build_element_natural_bc(element_t *, bc_data_t *bc_data);
extern int feenox_problem_build_allocate_elemental_objects(element_t *);
extern int feenox_problem_build_element_volumetric_gauss_point(element_t *, unsigned int q);
extern int feenox_problem_build_elemental_objects_allocate(element_t *);
extern int feenox_problem_build_elemental_objects_free(void);
extern int feenox_problem_build_assemble(void);
extern int feenox_problem_rhs_add(element_t *e, unsigned int q, double *value);
extern int feenox_problem_stiffness_add(element_t *e, unsigned int q, gsl_matrix *Kiq);
// gradient.c
extern int feenox_problem_gradient_compute(void);
extern int feenox_problem_gradient_compute_at_element(element_t *, mesh_t *mesh);
extern int feenox_problem_gradient_smooth_at_node(node_t *node);
// pdes/parse.c
extern int feenox_pde_parse_problem_type(const char *token);
// cleanup.c
extern void feenox_expression_destroy(expr_t *expr);
// include problem-dependent virtual methods
#include "pdes/methods.h"
#endif /* FEENOX_H */
feenox-1.2/src/feenox.c 0000664 0001750 0001750 00000002355 15055303016 010545 /*------------ -------------- -------- --- ----- --- -- - -
* FeenoX main function
*
* Copyright (C) 2009--2021 Jeremy Theler
*
* This file is part of FeenoX.
*
* FeenoX is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
feenox_t feenox;
#include
int main(int argc, char **argv) {
if (feenox_initialize(argc, argv) != FEENOX_OK) {
feenox_pop_errors();
exit(EXIT_FAILURE);
}
if (feenox.check == 0 && feenox_run() != FEENOX_OK) {
feenox_runtime_error();
exit(EXIT_FAILURE);
}
feenox_finalize();
return 0;
}
feenox-1.2/src/Makefile.in 0000664 0001750 0001750 00001251557 15055303022 011172 # Makefile.in generated by automake 1.17 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2024 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
# PARTICULAR PURPOSE.
@SET_MAKE@
VPATH = @srcdir@
am__is_gnu_make = { \
if test -z '$(MAKELEVEL)'; then \
false; \
elif test -n '$(MAKE_HOST)'; then \
true; \
elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
true; \
else \
false; \
fi; \
}
am__make_running_with_option = \
case $${target_option-} in \
?) ;; \
*) echo "am__make_running_with_option: internal error: invalid" \
"target option '$${target_option-}' specified" >&2; \
exit 1;; \
esac; \
has_opt=no; \
sane_makeflags=$$MAKEFLAGS; \
if $(am__is_gnu_make); then \
sane_makeflags=$$MFLAGS; \
else \
case $$MAKEFLAGS in \
*\\[\ \ ]*) \
bs=\\; \
sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
| sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
esac; \
fi; \
skip_next=no; \
strip_trailopt () \
{ \
flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
}; \
for flg in $$sane_makeflags; do \
test $$skip_next = yes && { skip_next=no; continue; }; \
case $$flg in \
*=*|--*) continue;; \
-*I) strip_trailopt 'I'; skip_next=yes;; \
-*I?*) strip_trailopt 'I';; \
-*O) strip_trailopt 'O'; skip_next=yes;; \
-*O?*) strip_trailopt 'O';; \
-*l) strip_trailopt 'l'; skip_next=yes;; \
-*l?*) strip_trailopt 'l';; \
-[dEDm]) skip_next=yes;; \
-[JT]) skip_next=yes;; \
esac; \
case $$flg in \
*$$target_option*) has_opt=yes; break;; \
esac; \
done; \
test $$has_opt = yes
am__make_dryrun = (target_option=n; $(am__make_running_with_option))
am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
am__rm_f = rm -f $(am__rm_f_notfound)
am__rm_rf = rm -rf $(am__rm_f_notfound)
pkgdatadir = $(datadir)/@PACKAGE@
pkgincludedir = $(includedir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
pkglibexecdir = $(libexecdir)/@PACKAGE@
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
install_sh_DATA = $(install_sh) -c -m 644
install_sh_PROGRAM = $(install_sh) -c
install_sh_SCRIPT = $(install_sh) -c
INSTALL_HEADER = $(INSTALL_DATA)
transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
build_triplet = @build@
host_triplet = @host@
bin_PROGRAMS = feenox$(EXEEXT)
subdir = src
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/version.m4 \
$(top_srcdir)/ax_gcc_builtin.m4 $(top_srcdir)/versiongit.m4 \
$(top_srcdir)/auto_links.m4 $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = $(top_builddir)/config.h
CONFIG_CLEAN_FILES =
CONFIG_CLEAN_VPATH_FILES =
am__installdirs = "$(DESTDIR)$(bindir)"
PROGRAMS = $(bin_PROGRAMS)
am__dirstamp = $(am__leading_dot)dirstamp
am_feenox_OBJECTS = ./feenox-feenox.$(OBJEXT) \
./feenox-version.$(OBJEXT) ./contrib/feenox-kdtree.$(OBJEXT) \
./flow/feenox-init.$(OBJEXT) ./flow/feenox-abort.$(OBJEXT) \
./flow/feenox-conditional.$(OBJEXT) \
./flow/feenox-error.$(OBJEXT) ./flow/feenox-define.$(OBJEXT) \
./flow/feenox-getptr.$(OBJEXT) ./flow/feenox-cleanup.$(OBJEXT) \
./flow/feenox-instruction.$(OBJEXT) \
./flow/feenox-step.$(OBJEXT) ./flow/feenox-run.$(OBJEXT) \
./parser/feenox-parser.$(OBJEXT) \
./parser/feenox-auxiliary.$(OBJEXT) ./io/feenox-file.$(OBJEXT) \
./io/feenox-read.$(OBJEXT) ./io/feenox-print.$(OBJEXT) \
./io/feenox-printf.$(OBJEXT) ./math/feenox-alias.$(OBJEXT) \
./math/feenox-assignment.$(OBJEXT) \
./math/feenox-builtin_functions.$(OBJEXT) \
./math/feenox-builtin_functionals.$(OBJEXT) \
./math/feenox-builtin_vectorfunctions.$(OBJEXT) \
./math/feenox-dae.$(OBJEXT) \
./math/feenox-expressions.$(OBJEXT) \
./math/feenox-fit.$(OBJEXT) ./math/feenox-function.$(OBJEXT) \
./math/feenox-matrix.$(OBJEXT) ./math/feenox-solve.$(OBJEXT) \
./math/feenox-vector.$(OBJEXT) ./mesh/feenox-init.$(OBJEXT) \
./mesh/feenox-geometry.$(OBJEXT) \
./mesh/feenox-neighbors.$(OBJEXT) \
./mesh/feenox-boundary_condition.$(OBJEXT) \
./mesh/feenox-physical_group.$(OBJEXT) \
./mesh/feenox-interpolate.$(OBJEXT) \
./mesh/feenox-material.$(OBJEXT) \
./mesh/feenox-element.$(OBJEXT) ./mesh/feenox-cell.$(OBJEXT) \
./mesh/feenox-write.$(OBJEXT) \
./mesh/feenox-integrate.$(OBJEXT) \
./mesh/feenox-extrema.$(OBJEXT) ./mesh/feenox-mesh.$(OBJEXT) \
./mesh/feenox-gmsh.$(OBJEXT) ./mesh/feenox-calculix.$(OBJEXT) \
./mesh/feenox-vtk.$(OBJEXT) ./mesh/feenox-vtu.$(OBJEXT) \
./mesh/feenox-tag_index_map.$(OBJEXT) \
./mesh/elements/feenox-line2.$(OBJEXT) \
./mesh/elements/feenox-line3.$(OBJEXT) \
./mesh/elements/feenox-triang3.$(OBJEXT) \
./mesh/elements/feenox-triang6.$(OBJEXT) \
./mesh/elements/feenox-quad4.$(OBJEXT) \
./mesh/elements/feenox-quad8.$(OBJEXT) \
./mesh/elements/feenox-quad9.$(OBJEXT) \
./mesh/elements/feenox-tet4.$(OBJEXT) \
./mesh/elements/feenox-tet10.$(OBJEXT) \
./mesh/elements/feenox-hexa8.$(OBJEXT) \
./mesh/elements/feenox-hexa20.$(OBJEXT) \
./mesh/elements/feenox-hexa27.$(OBJEXT) \
./mesh/elements/feenox-prism6.$(OBJEXT) \
./mesh/elements/feenox-prism15.$(OBJEXT) \
./mesh/elements/feenox-point.$(OBJEXT) \
pdes/feenox-parse.$(OBJEXT) pdes/thermal/feenox-post.$(OBJEXT) \
pdes/thermal/feenox-parser.$(OBJEXT) \
pdes/thermal/feenox-init.$(OBJEXT) \
pdes/thermal/feenox-heatflux.$(OBJEXT) \
pdes/thermal/feenox-bulk.$(OBJEXT) \
pdes/thermal/feenox-bc.$(OBJEXT) pdes/feenox-solve.$(OBJEXT) \
pdes/feenox-slepc_eps.$(OBJEXT) pdes/feenox-reaction.$(OBJEXT) \
pdes/feenox-petsc_ts.$(OBJEXT) \
pdes/feenox-petsc_snes.$(OBJEXT) \
pdes/feenox-petsc_ksp.$(OBJEXT) \
pdes/neutron_sn/feenox-post.$(OBJEXT) \
pdes/neutron_sn/feenox-parser.$(OBJEXT) \
pdes/neutron_sn/feenox-init.$(OBJEXT) \
pdes/neutron_sn/feenox-bulk.$(OBJEXT) \
pdes/neutron_sn/feenox-bc.$(OBJEXT) \
pdes/neutron_diffusion/feenox-post.$(OBJEXT) \
pdes/neutron_diffusion/feenox-parser.$(OBJEXT) \
pdes/neutron_diffusion/feenox-init.$(OBJEXT) \
pdes/neutron_diffusion/feenox-currents.$(OBJEXT) \
pdes/neutron_diffusion/feenox-bulk.$(OBJEXT) \
pdes/neutron_diffusion/feenox-bc.$(OBJEXT) \
pdes/modal/feenox-post.$(OBJEXT) \
pdes/modal/feenox-parser.$(OBJEXT) \
pdes/modal/feenox-init.$(OBJEXT) \
pdes/modal/feenox-elastic-plane-stress.$(OBJEXT) \
pdes/modal/feenox-elastic-plane-strain.$(OBJEXT) \
pdes/modal/feenox-elastic-orthotropic.$(OBJEXT) \
pdes/modal/feenox-elastic-isotropic.$(OBJEXT) \
pdes/modal/feenox-bulk.$(OBJEXT) \
pdes/modal/feenox-bc.$(OBJEXT) \
pdes/mechanical/feenox-stress.$(OBJEXT) \
pdes/mechanical/feenox-strain.$(OBJEXT) \
pdes/mechanical/feenox-post.$(OBJEXT) \
pdes/mechanical/feenox-parser.$(OBJEXT) \
pdes/mechanical/materials/feenox-saint_venant-kirchoff.$(OBJEXT) \
pdes/mechanical/materials/feenox-neohookean.$(OBJEXT) \
pdes/mechanical/materials/feenox-mooney-rivlin.$(OBJEXT) \
pdes/mechanical/materials/feenox-linear-orthotropic.$(OBJEXT) \
pdes/mechanical/materials/feenox-linear-isotropic.$(OBJEXT) \
pdes/mechanical/materials/feenox-hencky.$(OBJEXT) \
pdes/mechanical/materials/feenox-expansion-orthotropic.$(OBJEXT) \
pdes/mechanical/materials/feenox-expansion-isotropic.$(OBJEXT) \
pdes/mechanical/materials/feenox-elastic-plane-stress.$(OBJEXT) \
pdes/mechanical/materials/feenox-elastic-plane-strain.$(OBJEXT) \
pdes/mechanical/feenox-linearize.$(OBJEXT) \
pdes/mechanical/feenox-init.$(OBJEXT) \
pdes/mechanical/feenox-gradient.$(OBJEXT) \
pdes/mechanical/feenox-bulk.$(OBJEXT) \
pdes/mechanical/feenox-bc.$(OBJEXT) \
pdes/laplace/feenox-parser.$(OBJEXT) \
pdes/laplace/feenox-init.$(OBJEXT) \
pdes/laplace/feenox-bulk.$(OBJEXT) \
pdes/laplace/feenox-bc.$(OBJEXT) pdes/feenox-init.$(OBJEXT) \
pdes/feenox-gradient.$(OBJEXT) pdes/feenox-fem.$(OBJEXT) \
pdes/feenox-dump.$(OBJEXT) pdes/feenox-distribution.$(OBJEXT) \
pdes/feenox-dirichlet.$(OBJEXT) pdes/feenox-build.$(OBJEXT) \
pdes/feenox-blas.$(OBJEXT)
feenox_OBJECTS = $(am_feenox_OBJECTS)
am__DEPENDENCIES_1 =
feenox_DEPENDENCIES = $(am__DEPENDENCIES_1)
feenox_LINK = $(CCLD) $(feenox_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
$(LDFLAGS) -o $@
AM_V_P = $(am__v_P_@AM_V@)
am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
am__v_P_0 = false
am__v_P_1 = :
AM_V_GEN = $(am__v_GEN_@AM_V@)
am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
am__v_GEN_0 = @echo " GEN " $@;
am__v_GEN_1 =
AM_V_at = $(am__v_at_@AM_V@)
am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
am__v_at_0 = @
am__v_at_1 =
DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__maybe_remake_depfiles = depfiles
am__depfiles_remade = ./$(DEPDIR)/feenox-feenox.Po \
./$(DEPDIR)/feenox-version.Po \
./contrib/$(DEPDIR)/feenox-kdtree.Po \
./flow/$(DEPDIR)/feenox-abort.Po \
./flow/$(DEPDIR)/feenox-cleanup.Po \
./flow/$(DEPDIR)/feenox-conditional.Po \
./flow/$(DEPDIR)/feenox-define.Po \
./flow/$(DEPDIR)/feenox-error.Po \
./flow/$(DEPDIR)/feenox-getptr.Po \
./flow/$(DEPDIR)/feenox-init.Po \
./flow/$(DEPDIR)/feenox-instruction.Po \
./flow/$(DEPDIR)/feenox-run.Po ./flow/$(DEPDIR)/feenox-step.Po \
./io/$(DEPDIR)/feenox-file.Po ./io/$(DEPDIR)/feenox-print.Po \
./io/$(DEPDIR)/feenox-printf.Po ./io/$(DEPDIR)/feenox-read.Po \
./math/$(DEPDIR)/feenox-alias.Po \
./math/$(DEPDIR)/feenox-assignment.Po \
./math/$(DEPDIR)/feenox-builtin_functionals.Po \
./math/$(DEPDIR)/feenox-builtin_functions.Po \
./math/$(DEPDIR)/feenox-builtin_vectorfunctions.Po \
./math/$(DEPDIR)/feenox-dae.Po \
./math/$(DEPDIR)/feenox-expressions.Po \
./math/$(DEPDIR)/feenox-fit.Po \
./math/$(DEPDIR)/feenox-function.Po \
./math/$(DEPDIR)/feenox-matrix.Po \
./math/$(DEPDIR)/feenox-solve.Po \
./math/$(DEPDIR)/feenox-vector.Po \
./mesh/$(DEPDIR)/feenox-boundary_condition.Po \
./mesh/$(DEPDIR)/feenox-calculix.Po \
./mesh/$(DEPDIR)/feenox-cell.Po \
./mesh/$(DEPDIR)/feenox-element.Po \
./mesh/$(DEPDIR)/feenox-extrema.Po \
./mesh/$(DEPDIR)/feenox-geometry.Po \
./mesh/$(DEPDIR)/feenox-gmsh.Po \
./mesh/$(DEPDIR)/feenox-init.Po \
./mesh/$(DEPDIR)/feenox-integrate.Po \
./mesh/$(DEPDIR)/feenox-interpolate.Po \
./mesh/$(DEPDIR)/feenox-material.Po \
./mesh/$(DEPDIR)/feenox-mesh.Po \
./mesh/$(DEPDIR)/feenox-neighbors.Po \
./mesh/$(DEPDIR)/feenox-physical_group.Po \
./mesh/$(DEPDIR)/feenox-tag_index_map.Po \
./mesh/$(DEPDIR)/feenox-vtk.Po ./mesh/$(DEPDIR)/feenox-vtu.Po \
./mesh/$(DEPDIR)/feenox-write.Po \
./mesh/elements/$(DEPDIR)/feenox-hexa20.Po \
./mesh/elements/$(DEPDIR)/feenox-hexa27.Po \
./mesh/elements/$(DEPDIR)/feenox-hexa8.Po \
./mesh/elements/$(DEPDIR)/feenox-line2.Po \
./mesh/elements/$(DEPDIR)/feenox-line3.Po \
./mesh/elements/$(DEPDIR)/feenox-point.Po \
./mesh/elements/$(DEPDIR)/feenox-prism15.Po \
./mesh/elements/$(DEPDIR)/feenox-prism6.Po \
./mesh/elements/$(DEPDIR)/feenox-quad4.Po \
./mesh/elements/$(DEPDIR)/feenox-quad8.Po \
./mesh/elements/$(DEPDIR)/feenox-quad9.Po \
./mesh/elements/$(DEPDIR)/feenox-tet10.Po \
./mesh/elements/$(DEPDIR)/feenox-tet4.Po \
./mesh/elements/$(DEPDIR)/feenox-triang3.Po \
./mesh/elements/$(DEPDIR)/feenox-triang6.Po \
./parser/$(DEPDIR)/feenox-auxiliary.Po \
./parser/$(DEPDIR)/feenox-parser.Po \
pdes/$(DEPDIR)/feenox-blas.Po pdes/$(DEPDIR)/feenox-build.Po \
pdes/$(DEPDIR)/feenox-dirichlet.Po \
pdes/$(DEPDIR)/feenox-distribution.Po \
pdes/$(DEPDIR)/feenox-dump.Po pdes/$(DEPDIR)/feenox-fem.Po \
pdes/$(DEPDIR)/feenox-gradient.Po \
pdes/$(DEPDIR)/feenox-init.Po pdes/$(DEPDIR)/feenox-parse.Po \
pdes/$(DEPDIR)/feenox-petsc_ksp.Po \
pdes/$(DEPDIR)/feenox-petsc_snes.Po \
pdes/$(DEPDIR)/feenox-petsc_ts.Po \
pdes/$(DEPDIR)/feenox-reaction.Po \
pdes/$(DEPDIR)/feenox-slepc_eps.Po \
pdes/$(DEPDIR)/feenox-solve.Po \
pdes/laplace/$(DEPDIR)/feenox-bc.Po \
pdes/laplace/$(DEPDIR)/feenox-bulk.Po \
pdes/laplace/$(DEPDIR)/feenox-init.Po \
pdes/laplace/$(DEPDIR)/feenox-parser.Po \
pdes/mechanical/$(DEPDIR)/feenox-bc.Po \
pdes/mechanical/$(DEPDIR)/feenox-bulk.Po \
pdes/mechanical/$(DEPDIR)/feenox-gradient.Po \
pdes/mechanical/$(DEPDIR)/feenox-init.Po \
pdes/mechanical/$(DEPDIR)/feenox-linearize.Po \
pdes/mechanical/$(DEPDIR)/feenox-parser.Po \
pdes/mechanical/$(DEPDIR)/feenox-post.Po \
pdes/mechanical/$(DEPDIR)/feenox-strain.Po \
pdes/mechanical/$(DEPDIR)/feenox-stress.Po \
pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-strain.Po \
pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-stress.Po \
pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-isotropic.Po \
pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-orthotropic.Po \
pdes/mechanical/materials/$(DEPDIR)/feenox-hencky.Po \
pdes/mechanical/materials/$(DEPDIR)/feenox-linear-isotropic.Po \
pdes/mechanical/materials/$(DEPDIR)/feenox-linear-orthotropic.Po \
pdes/mechanical/materials/$(DEPDIR)/feenox-mooney-rivlin.Po \
pdes/mechanical/materials/$(DEPDIR)/feenox-neohookean.Po \
pdes/mechanical/materials/$(DEPDIR)/feenox-saint_venant-kirchoff.Po \
pdes/modal/$(DEPDIR)/feenox-bc.Po \
pdes/modal/$(DEPDIR)/feenox-bulk.Po \
pdes/modal/$(DEPDIR)/feenox-elastic-isotropic.Po \
pdes/modal/$(DEPDIR)/feenox-elastic-orthotropic.Po \
pdes/modal/$(DEPDIR)/feenox-elastic-plane-strain.Po \
pdes/modal/$(DEPDIR)/feenox-elastic-plane-stress.Po \
pdes/modal/$(DEPDIR)/feenox-init.Po \
pdes/modal/$(DEPDIR)/feenox-parser.Po \
pdes/modal/$(DEPDIR)/feenox-post.Po \
pdes/neutron_diffusion/$(DEPDIR)/feenox-bc.Po \
pdes/neutron_diffusion/$(DEPDIR)/feenox-bulk.Po \
pdes/neutron_diffusion/$(DEPDIR)/feenox-currents.Po \
pdes/neutron_diffusion/$(DEPDIR)/feenox-init.Po \
pdes/neutron_diffusion/$(DEPDIR)/feenox-parser.Po \
pdes/neutron_diffusion/$(DEPDIR)/feenox-post.Po \
pdes/neutron_sn/$(DEPDIR)/feenox-bc.Po \
pdes/neutron_sn/$(DEPDIR)/feenox-bulk.Po \
pdes/neutron_sn/$(DEPDIR)/feenox-init.Po \
pdes/neutron_sn/$(DEPDIR)/feenox-parser.Po \
pdes/neutron_sn/$(DEPDIR)/feenox-post.Po \
pdes/thermal/$(DEPDIR)/feenox-bc.Po \
pdes/thermal/$(DEPDIR)/feenox-bulk.Po \
pdes/thermal/$(DEPDIR)/feenox-heatflux.Po \
pdes/thermal/$(DEPDIR)/feenox-init.Po \
pdes/thermal/$(DEPDIR)/feenox-parser.Po \
pdes/thermal/$(DEPDIR)/feenox-post.Po
am__mv = mv -f
AM_V_lt = $(am__v_lt_@AM_V@)
am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
am__v_lt_0 = --silent
am__v_lt_1 =
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
AM_V_CC = $(am__v_CC_@AM_V@)
am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
am__v_CC_0 = @echo " CC " $@;
am__v_CC_1 =
CCLD = $(CC)
LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
AM_V_CCLD = $(am__v_CCLD_@AM_V@)
am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
am__v_CCLD_0 = @echo " CCLD " $@;
am__v_CCLD_1 =
SOURCES = $(feenox_SOURCES)
DIST_SOURCES = $(feenox_SOURCES)
am__can_run_installinfo = \
case $$AM_UPDATE_INFO_DIR in \
n|no|NO) false;; \
*) (install-info --version) >/dev/null 2>&1;; \
esac
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
# Read a list of newline-separated strings from the standard input,
# and print each of them once, without duplicates. Input order is
# *not* preserved.
am__uniquify_input = $(AWK) '\
BEGIN { nonempty = 0; } \
{ items[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in items) print i; }; } \
'
# Make sure the list of sources is unique. This is necessary because,
# e.g., the same source file might be shared among _SOURCES variables
# for different programs/libraries.
am__define_uniq_tagged_files = \
list='$(am__tagged_files)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | $(am__uniquify_input)`
am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
ACLOCAL = @ACLOCAL@
AMTAR = @AMTAR@
AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
AUTOCONF = @AUTOCONF@
AUTOHEADER = @AUTOHEADER@
AUTOMAKE = @AUTOMAKE@
AWK = @AWK@
CC = @CC@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
CPPFLAGS = @CPPFLAGS@
CSCOPE = @CSCOPE@
CTAGS = @CTAGS@
CYGPATH_W = @CYGPATH_W@
DEFS = @DEFS@
DEPDIR = @DEPDIR@
DOWNLOADED_GSL_INCLUDES = @DOWNLOADED_GSL_INCLUDES@
DOWNLOADED_GSL_LIBS = @DOWNLOADED_GSL_LIBS@
ECHO_C = @ECHO_C@
ECHO_N = @ECHO_N@
ECHO_T = @ECHO_T@
ETAGS = @ETAGS@
EXEEXT = @EXEEXT@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
LDFLAGS = @LDFLAGS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LTLIBOBJS = @LTLIBOBJS@
MAKEINFO = @MAKEINFO@
MKDIR_P = @MKDIR_P@
OBJEXT = @OBJEXT@
PACKAGE = @PACKAGE@
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
PACKAGE_NAME = @PACKAGE_NAME@
PACKAGE_STRING = @PACKAGE_STRING@
PACKAGE_TARNAME = @PACKAGE_TARNAME@
PACKAGE_URL = @PACKAGE_URL@
PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@
PETSC_ARCH = @PETSC_ARCH@
PETSC_DIR = @PETSC_DIR@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SLEPC_DIR = @SLEPC_DIR@
STRIP = @STRIP@
VERSION = @VERSION@
abs_builddir = @abs_builddir@
abs_srcdir = @abs_srcdir@
abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
ac_ct_CC = @ac_ct_CC@
am__include = @am__include@
am__leading_dot = @am__leading_dot@
am__quote = @am__quote@
am__rm_f_notfound = @am__rm_f_notfound@
am__tar = @am__tar@
am__untar = @am__untar@
am__xargs_n = @am__xargs_n@
bindir = @bindir@
build = @build@
build_alias = @build_alias@
build_cpu = @build_cpu@
build_os = @build_os@
build_vendor = @build_vendor@
builddir = @builddir@
datadir = @datadir@
datarootdir = @datarootdir@
docdir = @docdir@
dvidir = @dvidir@
exec_prefix = @exec_prefix@
host = @host@
host_alias = @host_alias@
host_cpu = @host_cpu@
host_os = @host_os@
host_vendor = @host_vendor@
htmldir = @htmldir@
includedir = @includedir@
infodir = @infodir@
install_sh = @install_sh@
libdir = @libdir@
libexecdir = @libexecdir@
localedir = @localedir@
localstatedir = @localstatedir@
mandir = @mandir@
mkdir_p = @mkdir_p@
oldincludedir = @oldincludedir@
pdfdir = @pdfdir@
prefix = @prefix@
program_transform_name = @program_transform_name@
psdir = @psdir@
runstatedir = @runstatedir@
sbindir = @sbindir@
sharedstatedir = @sharedstatedir@
srcdir = @srcdir@
sysconfdir = @sysconfdir@
target_alias = @target_alias@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
# include $(top_srcdir)/aminclude_static.am
AUTOMAKE_OPTIONS = subdir-objects
ACLOCAL_AMFLAGS = $(ACLOCAL_FLAGS)
feenox_CFLAGS = $(SLEPC_CC_INCLUDES) $(PETSC_CC_INCLUDES) $(CC_INCLUDES) $(DOWNLOADED_GSL_INCLUDES) $(all_includes)
feenox_LDADD = $(SLEPC_LIB) $(PETSC_LIB) $(DOWNLOADED_GSL_LIBS) $(all_libraries)
#feenox_LIBS = $(CODE_COVERAGE_LIBS)
#feenox_LDFLAGS = -rdynamic
#feenox_sources = feenox.c feenox.h
#feenox_LDADD = libfeenox.a $(SLEPC_LIB) $(PETSC_LIB) $(DOWNLOADED_GSL_LIBS) $(all_libraries)
#libfeenox_a_SOURCES =
feenox_SOURCES = \
./feenox.c \
./feenox.h \
./version.c \
./help.h \
./contrib/kdtree.c \
./contrib/kdtree.h \
./contrib/utlist.h \
./contrib/uthash.h \
./flow/init.c \
./flow/abort.c \
./flow/conditional.c \
./flow/error.c \
./flow/define.c \
./flow/getptr.c \
./flow/cleanup.c \
./flow/instruction.c \
./flow/step.c \
./flow/run.c \
./parser/parser.c \
./parser/parser.h \
./parser/auxiliary.c \
./io/file.c \
./io/read.c \
./io/print.c \
./io/printf.c \
./math/alias.c \
./math/assignment.c \
./math/builtin_functions.c \
./math/builtin_functionals.c \
./math/builtin_vectorfunctions.c \
./math/dae.c \
./math/expressions.c \
./math/fit.c \
./math/function.c \
./math/matrix.c \
./math/solve.c \
./math/vector.c \
./mesh/init.c \
./mesh/geometry.c \
./mesh/neighbors.c \
./mesh/boundary_condition.c \
./mesh/physical_group.c \
./mesh/interpolate.c \
./mesh/material.c \
./mesh/element.c \
./mesh/element.h \
./mesh/cell.c \
./mesh/write.c \
./mesh/integrate.c \
./mesh/extrema.c \
./mesh/mesh.c \
./mesh/gmsh.c \
./mesh/calculix.c \
./mesh/vtk.c \
./mesh/vtu.c \
./mesh/tag_index_map.c \
./mesh/elements/line2.c \
./mesh/elements/line3.c \
./mesh/elements/triang3.c \
./mesh/elements/triang6.c \
./mesh/elements/quad4.c \
./mesh/elements/quad8.c \
./mesh/elements/quad9.c \
./mesh/elements/tet4.c \
./mesh/elements/tet10.c \
./mesh/elements/hexa8.c \
./mesh/elements/hexa20.c \
./mesh/elements/hexa27.c \
./mesh/elements/prism6.c \
./mesh/elements/prism15.c \
./mesh/elements/point.c \
pdes/available.h pdes/parse.c pdes/methods.h pdes/thermal/thermal.h pdes/thermal/post.c pdes/thermal/parser.c pdes/thermal/methods.h pdes/thermal/init.c pdes/thermal/heatflux.c pdes/thermal/bulk.c pdes/thermal/bc.c pdes/solve.c pdes/slepc_eps.c pdes/reaction.c pdes/petsc_ts.c pdes/petsc_snes.c pdes/petsc_ksp.c pdes/neutron_sn/post.c pdes/neutron_sn/parser.c pdes/neutron_sn/neutron_sn.h pdes/neutron_sn/methods.h pdes/neutron_sn/init.c pdes/neutron_sn/bulk.c pdes/neutron_sn/bc.c pdes/neutron_diffusion/post.c pdes/neutron_diffusion/parser.c pdes/neutron_diffusion/neutron_diffusion.h pdes/neutron_diffusion/methods.h pdes/neutron_diffusion/init.c pdes/neutron_diffusion/currents.c pdes/neutron_diffusion/bulk.c pdes/neutron_diffusion/bc.c pdes/modal/post.c pdes/modal/parser.c pdes/modal/modal.h pdes/modal/methods.h pdes/modal/init.c pdes/modal/elastic-plane-stress.c pdes/modal/elastic-plane-strain.c pdes/modal/elastic-orthotropic.c pdes/modal/elastic-isotropic.c pdes/modal/bulk.c pdes/modal/bc.c pdes/mechanical/stress.c pdes/mechanical/strain.c pdes/mechanical/post.c pdes/mechanical/parser.c pdes/mechanical/methods.h pdes/mechanical/mechanical.h pdes/mechanical/materials/saint_venant-kirchoff.c pdes/mechanical/materials/neohookean.c pdes/mechanical/materials/mooney-rivlin.c pdes/mechanical/materials/linear-orthotropic.c pdes/mechanical/materials/linear-isotropic.c pdes/mechanical/materials/hencky.c pdes/mechanical/materials/expansion-orthotropic.c pdes/mechanical/materials/expansion-isotropic.c pdes/mechanical/materials/elastic-plane-stress.c pdes/mechanical/materials/elastic-plane-strain.c pdes/mechanical/linearize.c pdes/mechanical/init.c pdes/mechanical/gradient.c pdes/mechanical/bulk.c pdes/mechanical/bc.c pdes/laplace/parser.c pdes/laplace/methods.h pdes/laplace/laplace.h pdes/laplace/init.c pdes/laplace/bulk.c pdes/laplace/bc.c pdes/init.c pdes/gradient.c pdes/fem.c pdes/dump.c pdes/distribution.c pdes/dirichlet.c pdes/build.c pdes/blas.c
all: all-am
.SUFFIXES:
.SUFFIXES: .c .o .obj
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
&& { if test -f $@; then exit 0; else break; fi; }; \
exit 1;; \
esac; \
done; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu src/Makefile'; \
$(am__cd) $(top_srcdir) && \
$(AUTOMAKE) --gnu src/Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
@case '$?' in \
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(top_srcdir)/configure: $(am__configure_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(am__aclocal_m4_deps):
install-binPROGRAMS: $(bin_PROGRAMS)
@$(NORMAL_INSTALL)
@list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
if test -n "$$list"; then \
echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \
$(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \
fi; \
for p in $$list; do echo "$$p $$p"; done | \
sed 's/$(EXEEXT)$$//' | \
while read p p1; do if test -f $$p \
; then echo "$$p"; echo "$$p"; else :; fi; \
done | \
sed -e 'p;s,.*/,,;n;h' \
-e 's|.*|.|' \
-e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \
sed 'N;N;N;s,\n, ,g' | \
$(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \
{ d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \
if ($$2 == $$4) files[d] = files[d] " " $$1; \
else { print "f", $$3 "/" $$4, $$1; } } \
END { for (d in files) print "f", d, files[d] }' | \
while read type dir files; do \
if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \
test -z "$$files" || { \
echo " $(INSTALL_PROGRAM_ENV) $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(bindir)$$dir'"; \
$(INSTALL_PROGRAM_ENV) $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \
} \
; done
uninstall-binPROGRAMS:
@$(NORMAL_UNINSTALL)
@list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
files=`for p in $$list; do echo "$$p"; done | \
sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \
-e 's/$$/$(EXEEXT)/' \
`; \
test -n "$$list" || exit 0; \
echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \
cd "$(DESTDIR)$(bindir)" && $(am__rm_f) $$files
clean-binPROGRAMS:
-$(am__rm_f) $(bin_PROGRAMS)
./$(am__dirstamp):
@$(MKDIR_P) .
@: >>./$(am__dirstamp)
$(DEPDIR)/$(am__dirstamp):
@$(MKDIR_P) ./$(DEPDIR)
@: >>$(DEPDIR)/$(am__dirstamp)
./feenox-feenox.$(OBJEXT): ./$(am__dirstamp) $(DEPDIR)/$(am__dirstamp)
./feenox-version.$(OBJEXT): ./$(am__dirstamp) \
$(DEPDIR)/$(am__dirstamp)
contrib/$(am__dirstamp):
@$(MKDIR_P) ./contrib
@: >>contrib/$(am__dirstamp)
contrib/$(DEPDIR)/$(am__dirstamp):
@$(MKDIR_P) ./contrib/$(DEPDIR)
@: >>contrib/$(DEPDIR)/$(am__dirstamp)
./contrib/feenox-kdtree.$(OBJEXT): contrib/$(am__dirstamp) \
contrib/$(DEPDIR)/$(am__dirstamp)
flow/$(am__dirstamp):
@$(MKDIR_P) ./flow
@: >>flow/$(am__dirstamp)
flow/$(DEPDIR)/$(am__dirstamp):
@$(MKDIR_P) ./flow/$(DEPDIR)
@: >>flow/$(DEPDIR)/$(am__dirstamp)
./flow/feenox-init.$(OBJEXT): flow/$(am__dirstamp) \
flow/$(DEPDIR)/$(am__dirstamp)
./flow/feenox-abort.$(OBJEXT): flow/$(am__dirstamp) \
flow/$(DEPDIR)/$(am__dirstamp)
./flow/feenox-conditional.$(OBJEXT): flow/$(am__dirstamp) \
flow/$(DEPDIR)/$(am__dirstamp)
./flow/feenox-error.$(OBJEXT): flow/$(am__dirstamp) \
flow/$(DEPDIR)/$(am__dirstamp)
./flow/feenox-define.$(OBJEXT): flow/$(am__dirstamp) \
flow/$(DEPDIR)/$(am__dirstamp)
./flow/feenox-getptr.$(OBJEXT): flow/$(am__dirstamp) \
flow/$(DEPDIR)/$(am__dirstamp)
./flow/feenox-cleanup.$(OBJEXT): flow/$(am__dirstamp) \
flow/$(DEPDIR)/$(am__dirstamp)
./flow/feenox-instruction.$(OBJEXT): flow/$(am__dirstamp) \
flow/$(DEPDIR)/$(am__dirstamp)
./flow/feenox-step.$(OBJEXT): flow/$(am__dirstamp) \
flow/$(DEPDIR)/$(am__dirstamp)
./flow/feenox-run.$(OBJEXT): flow/$(am__dirstamp) \
flow/$(DEPDIR)/$(am__dirstamp)
parser/$(am__dirstamp):
@$(MKDIR_P) ./parser
@: >>parser/$(am__dirstamp)
parser/$(DEPDIR)/$(am__dirstamp):
@$(MKDIR_P) ./parser/$(DEPDIR)
@: >>parser/$(DEPDIR)/$(am__dirstamp)
./parser/feenox-parser.$(OBJEXT): parser/$(am__dirstamp) \
parser/$(DEPDIR)/$(am__dirstamp)
./parser/feenox-auxiliary.$(OBJEXT): parser/$(am__dirstamp) \
parser/$(DEPDIR)/$(am__dirstamp)
io/$(am__dirstamp):
@$(MKDIR_P) ./io
@: >>io/$(am__dirstamp)
io/$(DEPDIR)/$(am__dirstamp):
@$(MKDIR_P) ./io/$(DEPDIR)
@: >>io/$(DEPDIR)/$(am__dirstamp)
./io/feenox-file.$(OBJEXT): io/$(am__dirstamp) \
io/$(DEPDIR)/$(am__dirstamp)
./io/feenox-read.$(OBJEXT): io/$(am__dirstamp) \
io/$(DEPDIR)/$(am__dirstamp)
./io/feenox-print.$(OBJEXT): io/$(am__dirstamp) \
io/$(DEPDIR)/$(am__dirstamp)
./io/feenox-printf.$(OBJEXT): io/$(am__dirstamp) \
io/$(DEPDIR)/$(am__dirstamp)
math/$(am__dirstamp):
@$(MKDIR_P) ./math
@: >>math/$(am__dirstamp)
math/$(DEPDIR)/$(am__dirstamp):
@$(MKDIR_P) ./math/$(DEPDIR)
@: >>math/$(DEPDIR)/$(am__dirstamp)
./math/feenox-alias.$(OBJEXT): math/$(am__dirstamp) \
math/$(DEPDIR)/$(am__dirstamp)
./math/feenox-assignment.$(OBJEXT): math/$(am__dirstamp) \
math/$(DEPDIR)/$(am__dirstamp)
./math/feenox-builtin_functions.$(OBJEXT): math/$(am__dirstamp) \
math/$(DEPDIR)/$(am__dirstamp)
./math/feenox-builtin_functionals.$(OBJEXT): math/$(am__dirstamp) \
math/$(DEPDIR)/$(am__dirstamp)
./math/feenox-builtin_vectorfunctions.$(OBJEXT): math/$(am__dirstamp) \
math/$(DEPDIR)/$(am__dirstamp)
./math/feenox-dae.$(OBJEXT): math/$(am__dirstamp) \
math/$(DEPDIR)/$(am__dirstamp)
./math/feenox-expressions.$(OBJEXT): math/$(am__dirstamp) \
math/$(DEPDIR)/$(am__dirstamp)
./math/feenox-fit.$(OBJEXT): math/$(am__dirstamp) \
math/$(DEPDIR)/$(am__dirstamp)
./math/feenox-function.$(OBJEXT): math/$(am__dirstamp) \
math/$(DEPDIR)/$(am__dirstamp)
./math/feenox-matrix.$(OBJEXT): math/$(am__dirstamp) \
math/$(DEPDIR)/$(am__dirstamp)
./math/feenox-solve.$(OBJEXT): math/$(am__dirstamp) \
math/$(DEPDIR)/$(am__dirstamp)
./math/feenox-vector.$(OBJEXT): math/$(am__dirstamp) \
math/$(DEPDIR)/$(am__dirstamp)
mesh/$(am__dirstamp):
@$(MKDIR_P) ./mesh
@: >>mesh/$(am__dirstamp)
mesh/$(DEPDIR)/$(am__dirstamp):
@$(MKDIR_P) ./mesh/$(DEPDIR)
@: >>mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-init.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-geometry.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-neighbors.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-boundary_condition.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-physical_group.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-interpolate.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-material.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-element.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-cell.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-write.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-integrate.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-extrema.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-mesh.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-gmsh.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-calculix.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-vtk.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-vtu.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
./mesh/feenox-tag_index_map.$(OBJEXT): mesh/$(am__dirstamp) \
mesh/$(DEPDIR)/$(am__dirstamp)
mesh/elements/$(am__dirstamp):
@$(MKDIR_P) ./mesh/elements
@: >>mesh/elements/$(am__dirstamp)
mesh/elements/$(DEPDIR)/$(am__dirstamp):
@$(MKDIR_P) ./mesh/elements/$(DEPDIR)
@: >>mesh/elements/$(DEPDIR)/$(am__dirstamp)
./mesh/elements/feenox-line2.$(OBJEXT): mesh/elements/$(am__dirstamp) \
mesh/elements/$(DEPDIR)/$(am__dirstamp)
./mesh/elements/feenox-line3.$(OBJEXT): mesh/elements/$(am__dirstamp) \
mesh/elements/$(DEPDIR)/$(am__dirstamp)
./mesh/elements/feenox-triang3.$(OBJEXT): \
mesh/elements/$(am__dirstamp) \
mesh/elements/$(DEPDIR)/$(am__dirstamp)
./mesh/elements/feenox-triang6.$(OBJEXT): \
mesh/elements/$(am__dirstamp) \
mesh/elements/$(DEPDIR)/$(am__dirstamp)
./mesh/elements/feenox-quad4.$(OBJEXT): mesh/elements/$(am__dirstamp) \
mesh/elements/$(DEPDIR)/$(am__dirstamp)
./mesh/elements/feenox-quad8.$(OBJEXT): mesh/elements/$(am__dirstamp) \
mesh/elements/$(DEPDIR)/$(am__dirstamp)
./mesh/elements/feenox-quad9.$(OBJEXT): mesh/elements/$(am__dirstamp) \
mesh/elements/$(DEPDIR)/$(am__dirstamp)
./mesh/elements/feenox-tet4.$(OBJEXT): mesh/elements/$(am__dirstamp) \
mesh/elements/$(DEPDIR)/$(am__dirstamp)
./mesh/elements/feenox-tet10.$(OBJEXT): mesh/elements/$(am__dirstamp) \
mesh/elements/$(DEPDIR)/$(am__dirstamp)
./mesh/elements/feenox-hexa8.$(OBJEXT): mesh/elements/$(am__dirstamp) \
mesh/elements/$(DEPDIR)/$(am__dirstamp)
./mesh/elements/feenox-hexa20.$(OBJEXT): \
mesh/elements/$(am__dirstamp) \
mesh/elements/$(DEPDIR)/$(am__dirstamp)
./mesh/elements/feenox-hexa27.$(OBJEXT): \
mesh/elements/$(am__dirstamp) \
mesh/elements/$(DEPDIR)/$(am__dirstamp)
./mesh/elements/feenox-prism6.$(OBJEXT): \
mesh/elements/$(am__dirstamp) \
mesh/elements/$(DEPDIR)/$(am__dirstamp)
./mesh/elements/feenox-prism15.$(OBJEXT): \
mesh/elements/$(am__dirstamp) \
mesh/elements/$(DEPDIR)/$(am__dirstamp)
./mesh/elements/feenox-point.$(OBJEXT): mesh/elements/$(am__dirstamp) \
mesh/elements/$(DEPDIR)/$(am__dirstamp)
pdes/$(am__dirstamp):
@$(MKDIR_P) pdes
@: >>pdes/$(am__dirstamp)
pdes/$(DEPDIR)/$(am__dirstamp):
@$(MKDIR_P) pdes/$(DEPDIR)
@: >>pdes/$(DEPDIR)/$(am__dirstamp)
pdes/feenox-parse.$(OBJEXT): pdes/$(am__dirstamp) \
pdes/$(DEPDIR)/$(am__dirstamp)
pdes/thermal/$(am__dirstamp):
@$(MKDIR_P) pdes/thermal
@: >>pdes/thermal/$(am__dirstamp)
pdes/thermal/$(DEPDIR)/$(am__dirstamp):
@$(MKDIR_P) pdes/thermal/$(DEPDIR)
@: >>pdes/thermal/$(DEPDIR)/$(am__dirstamp)
pdes/thermal/feenox-post.$(OBJEXT): pdes/thermal/$(am__dirstamp) \
pdes/thermal/$(DEPDIR)/$(am__dirstamp)
pdes/thermal/feenox-parser.$(OBJEXT): pdes/thermal/$(am__dirstamp) \
pdes/thermal/$(DEPDIR)/$(am__dirstamp)
pdes/thermal/feenox-init.$(OBJEXT): pdes/thermal/$(am__dirstamp) \
pdes/thermal/$(DEPDIR)/$(am__dirstamp)
pdes/thermal/feenox-heatflux.$(OBJEXT): pdes/thermal/$(am__dirstamp) \
pdes/thermal/$(DEPDIR)/$(am__dirstamp)
pdes/thermal/feenox-bulk.$(OBJEXT): pdes/thermal/$(am__dirstamp) \
pdes/thermal/$(DEPDIR)/$(am__dirstamp)
pdes/thermal/feenox-bc.$(OBJEXT): pdes/thermal/$(am__dirstamp) \
pdes/thermal/$(DEPDIR)/$(am__dirstamp)
pdes/feenox-solve.$(OBJEXT): pdes/$(am__dirstamp) \
pdes/$(DEPDIR)/$(am__dirstamp)
pdes/feenox-slepc_eps.$(OBJEXT): pdes/$(am__dirstamp) \
pdes/$(DEPDIR)/$(am__dirstamp)
pdes/feenox-reaction.$(OBJEXT): pdes/$(am__dirstamp) \
pdes/$(DEPDIR)/$(am__dirstamp)
pdes/feenox-petsc_ts.$(OBJEXT): pdes/$(am__dirstamp) \
pdes/$(DEPDIR)/$(am__dirstamp)
pdes/feenox-petsc_snes.$(OBJEXT): pdes/$(am__dirstamp) \
pdes/$(DEPDIR)/$(am__dirstamp)
pdes/feenox-petsc_ksp.$(OBJEXT): pdes/$(am__dirstamp) \
pdes/$(DEPDIR)/$(am__dirstamp)
pdes/neutron_sn/$(am__dirstamp):
@$(MKDIR_P) pdes/neutron_sn
@: >>pdes/neutron_sn/$(am__dirstamp)
pdes/neutron_sn/$(DEPDIR)/$(am__dirstamp):
@$(MKDIR_P) pdes/neutron_sn/$(DEPDIR)
@: >>pdes/neutron_sn/$(DEPDIR)/$(am__dirstamp)
pdes/neutron_sn/feenox-post.$(OBJEXT): \
pdes/neutron_sn/$(am__dirstamp) \
pdes/neutron_sn/$(DEPDIR)/$(am__dirstamp)
pdes/neutron_sn/feenox-parser.$(OBJEXT): \
pdes/neutron_sn/$(am__dirstamp) \
pdes/neutron_sn/$(DEPDIR)/$(am__dirstamp)
pdes/neutron_sn/feenox-init.$(OBJEXT): \
pdes/neutron_sn/$(am__dirstamp) \
pdes/neutron_sn/$(DEPDIR)/$(am__dirstamp)
pdes/neutron_sn/feenox-bulk.$(OBJEXT): \
pdes/neutron_sn/$(am__dirstamp) \
pdes/neutron_sn/$(DEPDIR)/$(am__dirstamp)
pdes/neutron_sn/feenox-bc.$(OBJEXT): pdes/neutron_sn/$(am__dirstamp) \
pdes/neutron_sn/$(DEPDIR)/$(am__dirstamp)
pdes/neutron_diffusion/$(am__dirstamp):
@$(MKDIR_P) pdes/neutron_diffusion
@: >>pdes/neutron_diffusion/$(am__dirstamp)
pdes/neutron_diffusion/$(DEPDIR)/$(am__dirstamp):
@$(MKDIR_P) pdes/neutron_diffusion/$(DEPDIR)
@: >>pdes/neutron_diffusion/$(DEPDIR)/$(am__dirstamp)
pdes/neutron_diffusion/feenox-post.$(OBJEXT): \
pdes/neutron_diffusion/$(am__dirstamp) \
pdes/neutron_diffusion/$(DEPDIR)/$(am__dirstamp)
pdes/neutron_diffusion/feenox-parser.$(OBJEXT): \
pdes/neutron_diffusion/$(am__dirstamp) \
pdes/neutron_diffusion/$(DEPDIR)/$(am__dirstamp)
pdes/neutron_diffusion/feenox-init.$(OBJEXT): \
pdes/neutron_diffusion/$(am__dirstamp) \
pdes/neutron_diffusion/$(DEPDIR)/$(am__dirstamp)
pdes/neutron_diffusion/feenox-currents.$(OBJEXT): \
pdes/neutron_diffusion/$(am__dirstamp) \
pdes/neutron_diffusion/$(DEPDIR)/$(am__dirstamp)
pdes/neutron_diffusion/feenox-bulk.$(OBJEXT): \
pdes/neutron_diffusion/$(am__dirstamp) \
pdes/neutron_diffusion/$(DEPDIR)/$(am__dirstamp)
pdes/neutron_diffusion/feenox-bc.$(OBJEXT): \
pdes/neutron_diffusion/$(am__dirstamp) \
pdes/neutron_diffusion/$(DEPDIR)/$(am__dirstamp)
pdes/modal/$(am__dirstamp):
@$(MKDIR_P) pdes/modal
@: >>pdes/modal/$(am__dirstamp)
pdes/modal/$(DEPDIR)/$(am__dirstamp):
@$(MKDIR_P) pdes/modal/$(DEPDIR)
@: >>pdes/modal/$(DEPDIR)/$(am__dirstamp)
pdes/modal/feenox-post.$(OBJEXT): pdes/modal/$(am__dirstamp) \
pdes/modal/$(DEPDIR)/$(am__dirstamp)
pdes/modal/feenox-parser.$(OBJEXT): pdes/modal/$(am__dirstamp) \
pdes/modal/$(DEPDIR)/$(am__dirstamp)
pdes/modal/feenox-init.$(OBJEXT): pdes/modal/$(am__dirstamp) \
pdes/modal/$(DEPDIR)/$(am__dirstamp)
pdes/modal/feenox-elastic-plane-stress.$(OBJEXT): \
pdes/modal/$(am__dirstamp) \
pdes/modal/$(DEPDIR)/$(am__dirstamp)
pdes/modal/feenox-elastic-plane-strain.$(OBJEXT): \
pdes/modal/$(am__dirstamp) \
pdes/modal/$(DEPDIR)/$(am__dirstamp)
pdes/modal/feenox-elastic-orthotropic.$(OBJEXT): \
pdes/modal/$(am__dirstamp) \
pdes/modal/$(DEPDIR)/$(am__dirstamp)
pdes/modal/feenox-elastic-isotropic.$(OBJEXT): \
pdes/modal/$(am__dirstamp) \
pdes/modal/$(DEPDIR)/$(am__dirstamp)
pdes/modal/feenox-bulk.$(OBJEXT): pdes/modal/$(am__dirstamp) \
pdes/modal/$(DEPDIR)/$(am__dirstamp)
pdes/modal/feenox-bc.$(OBJEXT): pdes/modal/$(am__dirstamp) \
pdes/modal/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/$(am__dirstamp):
@$(MKDIR_P) pdes/mechanical
@: >>pdes/mechanical/$(am__dirstamp)
pdes/mechanical/$(DEPDIR)/$(am__dirstamp):
@$(MKDIR_P) pdes/mechanical/$(DEPDIR)
@: >>pdes/mechanical/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/feenox-stress.$(OBJEXT): \
pdes/mechanical/$(am__dirstamp) \
pdes/mechanical/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/feenox-strain.$(OBJEXT): \
pdes/mechanical/$(am__dirstamp) \
pdes/mechanical/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/feenox-post.$(OBJEXT): \
pdes/mechanical/$(am__dirstamp) \
pdes/mechanical/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/feenox-parser.$(OBJEXT): \
pdes/mechanical/$(am__dirstamp) \
pdes/mechanical/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/materials/$(am__dirstamp):
@$(MKDIR_P) pdes/mechanical/materials
@: >>pdes/mechanical/materials/$(am__dirstamp)
pdes/mechanical/materials/$(DEPDIR)/$(am__dirstamp):
@$(MKDIR_P) pdes/mechanical/materials/$(DEPDIR)
@: >>pdes/mechanical/materials/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/materials/feenox-saint_venant-kirchoff.$(OBJEXT): \
pdes/mechanical/materials/$(am__dirstamp) \
pdes/mechanical/materials/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/materials/feenox-neohookean.$(OBJEXT): \
pdes/mechanical/materials/$(am__dirstamp) \
pdes/mechanical/materials/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/materials/feenox-mooney-rivlin.$(OBJEXT): \
pdes/mechanical/materials/$(am__dirstamp) \
pdes/mechanical/materials/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/materials/feenox-linear-orthotropic.$(OBJEXT): \
pdes/mechanical/materials/$(am__dirstamp) \
pdes/mechanical/materials/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/materials/feenox-linear-isotropic.$(OBJEXT): \
pdes/mechanical/materials/$(am__dirstamp) \
pdes/mechanical/materials/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/materials/feenox-hencky.$(OBJEXT): \
pdes/mechanical/materials/$(am__dirstamp) \
pdes/mechanical/materials/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/materials/feenox-expansion-orthotropic.$(OBJEXT): \
pdes/mechanical/materials/$(am__dirstamp) \
pdes/mechanical/materials/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/materials/feenox-expansion-isotropic.$(OBJEXT): \
pdes/mechanical/materials/$(am__dirstamp) \
pdes/mechanical/materials/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/materials/feenox-elastic-plane-stress.$(OBJEXT): \
pdes/mechanical/materials/$(am__dirstamp) \
pdes/mechanical/materials/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/materials/feenox-elastic-plane-strain.$(OBJEXT): \
pdes/mechanical/materials/$(am__dirstamp) \
pdes/mechanical/materials/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/feenox-linearize.$(OBJEXT): \
pdes/mechanical/$(am__dirstamp) \
pdes/mechanical/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/feenox-init.$(OBJEXT): \
pdes/mechanical/$(am__dirstamp) \
pdes/mechanical/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/feenox-gradient.$(OBJEXT): \
pdes/mechanical/$(am__dirstamp) \
pdes/mechanical/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/feenox-bulk.$(OBJEXT): \
pdes/mechanical/$(am__dirstamp) \
pdes/mechanical/$(DEPDIR)/$(am__dirstamp)
pdes/mechanical/feenox-bc.$(OBJEXT): pdes/mechanical/$(am__dirstamp) \
pdes/mechanical/$(DEPDIR)/$(am__dirstamp)
pdes/laplace/$(am__dirstamp):
@$(MKDIR_P) pdes/laplace
@: >>pdes/laplace/$(am__dirstamp)
pdes/laplace/$(DEPDIR)/$(am__dirstamp):
@$(MKDIR_P) pdes/laplace/$(DEPDIR)
@: >>pdes/laplace/$(DEPDIR)/$(am__dirstamp)
pdes/laplace/feenox-parser.$(OBJEXT): pdes/laplace/$(am__dirstamp) \
pdes/laplace/$(DEPDIR)/$(am__dirstamp)
pdes/laplace/feenox-init.$(OBJEXT): pdes/laplace/$(am__dirstamp) \
pdes/laplace/$(DEPDIR)/$(am__dirstamp)
pdes/laplace/feenox-bulk.$(OBJEXT): pdes/laplace/$(am__dirstamp) \
pdes/laplace/$(DEPDIR)/$(am__dirstamp)
pdes/laplace/feenox-bc.$(OBJEXT): pdes/laplace/$(am__dirstamp) \
pdes/laplace/$(DEPDIR)/$(am__dirstamp)
pdes/feenox-init.$(OBJEXT): pdes/$(am__dirstamp) \
pdes/$(DEPDIR)/$(am__dirstamp)
pdes/feenox-gradient.$(OBJEXT): pdes/$(am__dirstamp) \
pdes/$(DEPDIR)/$(am__dirstamp)
pdes/feenox-fem.$(OBJEXT): pdes/$(am__dirstamp) \
pdes/$(DEPDIR)/$(am__dirstamp)
pdes/feenox-dump.$(OBJEXT): pdes/$(am__dirstamp) \
pdes/$(DEPDIR)/$(am__dirstamp)
pdes/feenox-distribution.$(OBJEXT): pdes/$(am__dirstamp) \
pdes/$(DEPDIR)/$(am__dirstamp)
pdes/feenox-dirichlet.$(OBJEXT): pdes/$(am__dirstamp) \
pdes/$(DEPDIR)/$(am__dirstamp)
pdes/feenox-build.$(OBJEXT): pdes/$(am__dirstamp) \
pdes/$(DEPDIR)/$(am__dirstamp)
pdes/feenox-blas.$(OBJEXT): pdes/$(am__dirstamp) \
pdes/$(DEPDIR)/$(am__dirstamp)
feenox$(EXEEXT): $(feenox_OBJECTS) $(feenox_DEPENDENCIES) $(EXTRA_feenox_DEPENDENCIES)
@rm -f feenox$(EXEEXT)
$(AM_V_CCLD)$(feenox_LINK) $(feenox_OBJECTS) $(feenox_LDADD) $(LIBS)
mostlyclean-compile:
-rm -f *.$(OBJEXT)
-rm -f ./*.$(OBJEXT)
-rm -f ./contrib/*.$(OBJEXT)
-rm -f ./flow/*.$(OBJEXT)
-rm -f ./io/*.$(OBJEXT)
-rm -f ./math/*.$(OBJEXT)
-rm -f ./mesh/*.$(OBJEXT)
-rm -f ./mesh/elements/*.$(OBJEXT)
-rm -f ./parser/*.$(OBJEXT)
-rm -f pdes/*.$(OBJEXT)
-rm -f pdes/laplace/*.$(OBJEXT)
-rm -f pdes/mechanical/*.$(OBJEXT)
-rm -f pdes/mechanical/materials/*.$(OBJEXT)
-rm -f pdes/modal/*.$(OBJEXT)
-rm -f pdes/neutron_diffusion/*.$(OBJEXT)
-rm -f pdes/neutron_sn/*.$(OBJEXT)
-rm -f pdes/thermal/*.$(OBJEXT)
distclean-compile:
-rm -f *.tab.c
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/feenox-feenox.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/feenox-version.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./contrib/$(DEPDIR)/feenox-kdtree.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./flow/$(DEPDIR)/feenox-abort.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./flow/$(DEPDIR)/feenox-cleanup.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./flow/$(DEPDIR)/feenox-conditional.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./flow/$(DEPDIR)/feenox-define.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./flow/$(DEPDIR)/feenox-error.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./flow/$(DEPDIR)/feenox-getptr.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./flow/$(DEPDIR)/feenox-init.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./flow/$(DEPDIR)/feenox-instruction.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./flow/$(DEPDIR)/feenox-run.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./flow/$(DEPDIR)/feenox-step.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./io/$(DEPDIR)/feenox-file.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./io/$(DEPDIR)/feenox-print.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./io/$(DEPDIR)/feenox-printf.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./io/$(DEPDIR)/feenox-read.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./math/$(DEPDIR)/feenox-alias.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./math/$(DEPDIR)/feenox-assignment.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./math/$(DEPDIR)/feenox-builtin_functionals.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./math/$(DEPDIR)/feenox-builtin_functions.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./math/$(DEPDIR)/feenox-builtin_vectorfunctions.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./math/$(DEPDIR)/feenox-dae.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./math/$(DEPDIR)/feenox-expressions.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./math/$(DEPDIR)/feenox-fit.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./math/$(DEPDIR)/feenox-function.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./math/$(DEPDIR)/feenox-matrix.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./math/$(DEPDIR)/feenox-solve.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./math/$(DEPDIR)/feenox-vector.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-boundary_condition.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-calculix.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-cell.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-element.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-extrema.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-geometry.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-gmsh.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-init.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-integrate.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-interpolate.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-material.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-mesh.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-neighbors.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-physical_group.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-tag_index_map.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-vtk.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-vtu.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/$(DEPDIR)/feenox-write.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/elements/$(DEPDIR)/feenox-hexa20.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/elements/$(DEPDIR)/feenox-hexa27.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/elements/$(DEPDIR)/feenox-hexa8.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/elements/$(DEPDIR)/feenox-line2.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/elements/$(DEPDIR)/feenox-line3.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/elements/$(DEPDIR)/feenox-point.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/elements/$(DEPDIR)/feenox-prism15.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/elements/$(DEPDIR)/feenox-prism6.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/elements/$(DEPDIR)/feenox-quad4.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/elements/$(DEPDIR)/feenox-quad8.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/elements/$(DEPDIR)/feenox-quad9.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/elements/$(DEPDIR)/feenox-tet10.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/elements/$(DEPDIR)/feenox-tet4.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/elements/$(DEPDIR)/feenox-triang3.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./mesh/elements/$(DEPDIR)/feenox-triang6.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./parser/$(DEPDIR)/feenox-auxiliary.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./parser/$(DEPDIR)/feenox-parser.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/$(DEPDIR)/feenox-blas.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/$(DEPDIR)/feenox-build.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/$(DEPDIR)/feenox-dirichlet.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/$(DEPDIR)/feenox-distribution.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/$(DEPDIR)/feenox-dump.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/$(DEPDIR)/feenox-fem.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/$(DEPDIR)/feenox-gradient.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/$(DEPDIR)/feenox-init.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/$(DEPDIR)/feenox-parse.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/$(DEPDIR)/feenox-petsc_ksp.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/$(DEPDIR)/feenox-petsc_snes.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/$(DEPDIR)/feenox-petsc_ts.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/$(DEPDIR)/feenox-reaction.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/$(DEPDIR)/feenox-slepc_eps.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/$(DEPDIR)/feenox-solve.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/laplace/$(DEPDIR)/feenox-bc.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/laplace/$(DEPDIR)/feenox-bulk.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/laplace/$(DEPDIR)/feenox-init.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/laplace/$(DEPDIR)/feenox-parser.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/$(DEPDIR)/feenox-bc.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/$(DEPDIR)/feenox-bulk.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/$(DEPDIR)/feenox-gradient.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/$(DEPDIR)/feenox-init.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/$(DEPDIR)/feenox-linearize.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/$(DEPDIR)/feenox-parser.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/$(DEPDIR)/feenox-post.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/$(DEPDIR)/feenox-strain.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/$(DEPDIR)/feenox-stress.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-strain.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-stress.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-isotropic.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-orthotropic.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/materials/$(DEPDIR)/feenox-hencky.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/materials/$(DEPDIR)/feenox-linear-isotropic.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/materials/$(DEPDIR)/feenox-linear-orthotropic.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/materials/$(DEPDIR)/feenox-mooney-rivlin.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/materials/$(DEPDIR)/feenox-neohookean.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/mechanical/materials/$(DEPDIR)/feenox-saint_venant-kirchoff.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/modal/$(DEPDIR)/feenox-bc.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/modal/$(DEPDIR)/feenox-bulk.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/modal/$(DEPDIR)/feenox-elastic-isotropic.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/modal/$(DEPDIR)/feenox-elastic-orthotropic.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/modal/$(DEPDIR)/feenox-elastic-plane-strain.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/modal/$(DEPDIR)/feenox-elastic-plane-stress.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/modal/$(DEPDIR)/feenox-init.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/modal/$(DEPDIR)/feenox-parser.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/modal/$(DEPDIR)/feenox-post.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/neutron_diffusion/$(DEPDIR)/feenox-bc.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/neutron_diffusion/$(DEPDIR)/feenox-bulk.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/neutron_diffusion/$(DEPDIR)/feenox-currents.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/neutron_diffusion/$(DEPDIR)/feenox-init.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/neutron_diffusion/$(DEPDIR)/feenox-parser.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/neutron_diffusion/$(DEPDIR)/feenox-post.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/neutron_sn/$(DEPDIR)/feenox-bc.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/neutron_sn/$(DEPDIR)/feenox-bulk.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/neutron_sn/$(DEPDIR)/feenox-init.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/neutron_sn/$(DEPDIR)/feenox-parser.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/neutron_sn/$(DEPDIR)/feenox-post.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/thermal/$(DEPDIR)/feenox-bc.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/thermal/$(DEPDIR)/feenox-bulk.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/thermal/$(DEPDIR)/feenox-heatflux.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/thermal/$(DEPDIR)/feenox-init.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/thermal/$(DEPDIR)/feenox-parser.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@pdes/thermal/$(DEPDIR)/feenox-post.Po@am__quote@ # am--include-marker
$(am__depfiles_remade):
@$(MKDIR_P) $(@D)
@: >>$@
am--depfiles: $(am__depfiles_remade)
.c.o:
@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\
@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\
@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $<
.c.obj:
@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.obj$$||'`;\
@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ `$(CYGPATH_W) '$<'` &&\
@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
./feenox-feenox.o: ./feenox.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./feenox-feenox.o -MD -MP -MF $(DEPDIR)/feenox-feenox.Tpo -c -o ./feenox-feenox.o `test -f './feenox.c' || echo '$(srcdir)/'`./feenox.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/feenox-feenox.Tpo $(DEPDIR)/feenox-feenox.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./feenox.c' object='./feenox-feenox.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./feenox-feenox.o `test -f './feenox.c' || echo '$(srcdir)/'`./feenox.c
./feenox-feenox.obj: ./feenox.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./feenox-feenox.obj -MD -MP -MF $(DEPDIR)/feenox-feenox.Tpo -c -o ./feenox-feenox.obj `if test -f './feenox.c'; then $(CYGPATH_W) './feenox.c'; else $(CYGPATH_W) '$(srcdir)/./feenox.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/feenox-feenox.Tpo $(DEPDIR)/feenox-feenox.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./feenox.c' object='./feenox-feenox.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./feenox-feenox.obj `if test -f './feenox.c'; then $(CYGPATH_W) './feenox.c'; else $(CYGPATH_W) '$(srcdir)/./feenox.c'; fi`
./feenox-version.o: ./version.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./feenox-version.o -MD -MP -MF $(DEPDIR)/feenox-version.Tpo -c -o ./feenox-version.o `test -f './version.c' || echo '$(srcdir)/'`./version.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/feenox-version.Tpo $(DEPDIR)/feenox-version.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./version.c' object='./feenox-version.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./feenox-version.o `test -f './version.c' || echo '$(srcdir)/'`./version.c
./feenox-version.obj: ./version.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./feenox-version.obj -MD -MP -MF $(DEPDIR)/feenox-version.Tpo -c -o ./feenox-version.obj `if test -f './version.c'; then $(CYGPATH_W) './version.c'; else $(CYGPATH_W) '$(srcdir)/./version.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/feenox-version.Tpo $(DEPDIR)/feenox-version.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./version.c' object='./feenox-version.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./feenox-version.obj `if test -f './version.c'; then $(CYGPATH_W) './version.c'; else $(CYGPATH_W) '$(srcdir)/./version.c'; fi`
./contrib/feenox-kdtree.o: ./contrib/kdtree.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./contrib/feenox-kdtree.o -MD -MP -MF ./contrib/$(DEPDIR)/feenox-kdtree.Tpo -c -o ./contrib/feenox-kdtree.o `test -f './contrib/kdtree.c' || echo '$(srcdir)/'`./contrib/kdtree.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./contrib/$(DEPDIR)/feenox-kdtree.Tpo ./contrib/$(DEPDIR)/feenox-kdtree.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./contrib/kdtree.c' object='./contrib/feenox-kdtree.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./contrib/feenox-kdtree.o `test -f './contrib/kdtree.c' || echo '$(srcdir)/'`./contrib/kdtree.c
./contrib/feenox-kdtree.obj: ./contrib/kdtree.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./contrib/feenox-kdtree.obj -MD -MP -MF ./contrib/$(DEPDIR)/feenox-kdtree.Tpo -c -o ./contrib/feenox-kdtree.obj `if test -f './contrib/kdtree.c'; then $(CYGPATH_W) './contrib/kdtree.c'; else $(CYGPATH_W) '$(srcdir)/./contrib/kdtree.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./contrib/$(DEPDIR)/feenox-kdtree.Tpo ./contrib/$(DEPDIR)/feenox-kdtree.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./contrib/kdtree.c' object='./contrib/feenox-kdtree.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./contrib/feenox-kdtree.obj `if test -f './contrib/kdtree.c'; then $(CYGPATH_W) './contrib/kdtree.c'; else $(CYGPATH_W) '$(srcdir)/./contrib/kdtree.c'; fi`
./flow/feenox-init.o: ./flow/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-init.o -MD -MP -MF ./flow/$(DEPDIR)/feenox-init.Tpo -c -o ./flow/feenox-init.o `test -f './flow/init.c' || echo '$(srcdir)/'`./flow/init.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-init.Tpo ./flow/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/init.c' object='./flow/feenox-init.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-init.o `test -f './flow/init.c' || echo '$(srcdir)/'`./flow/init.c
./flow/feenox-init.obj: ./flow/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-init.obj -MD -MP -MF ./flow/$(DEPDIR)/feenox-init.Tpo -c -o ./flow/feenox-init.obj `if test -f './flow/init.c'; then $(CYGPATH_W) './flow/init.c'; else $(CYGPATH_W) '$(srcdir)/./flow/init.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-init.Tpo ./flow/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/init.c' object='./flow/feenox-init.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-init.obj `if test -f './flow/init.c'; then $(CYGPATH_W) './flow/init.c'; else $(CYGPATH_W) '$(srcdir)/./flow/init.c'; fi`
./flow/feenox-abort.o: ./flow/abort.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-abort.o -MD -MP -MF ./flow/$(DEPDIR)/feenox-abort.Tpo -c -o ./flow/feenox-abort.o `test -f './flow/abort.c' || echo '$(srcdir)/'`./flow/abort.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-abort.Tpo ./flow/$(DEPDIR)/feenox-abort.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/abort.c' object='./flow/feenox-abort.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-abort.o `test -f './flow/abort.c' || echo '$(srcdir)/'`./flow/abort.c
./flow/feenox-abort.obj: ./flow/abort.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-abort.obj -MD -MP -MF ./flow/$(DEPDIR)/feenox-abort.Tpo -c -o ./flow/feenox-abort.obj `if test -f './flow/abort.c'; then $(CYGPATH_W) './flow/abort.c'; else $(CYGPATH_W) '$(srcdir)/./flow/abort.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-abort.Tpo ./flow/$(DEPDIR)/feenox-abort.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/abort.c' object='./flow/feenox-abort.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-abort.obj `if test -f './flow/abort.c'; then $(CYGPATH_W) './flow/abort.c'; else $(CYGPATH_W) '$(srcdir)/./flow/abort.c'; fi`
./flow/feenox-conditional.o: ./flow/conditional.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-conditional.o -MD -MP -MF ./flow/$(DEPDIR)/feenox-conditional.Tpo -c -o ./flow/feenox-conditional.o `test -f './flow/conditional.c' || echo '$(srcdir)/'`./flow/conditional.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-conditional.Tpo ./flow/$(DEPDIR)/feenox-conditional.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/conditional.c' object='./flow/feenox-conditional.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-conditional.o `test -f './flow/conditional.c' || echo '$(srcdir)/'`./flow/conditional.c
./flow/feenox-conditional.obj: ./flow/conditional.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-conditional.obj -MD -MP -MF ./flow/$(DEPDIR)/feenox-conditional.Tpo -c -o ./flow/feenox-conditional.obj `if test -f './flow/conditional.c'; then $(CYGPATH_W) './flow/conditional.c'; else $(CYGPATH_W) '$(srcdir)/./flow/conditional.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-conditional.Tpo ./flow/$(DEPDIR)/feenox-conditional.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/conditional.c' object='./flow/feenox-conditional.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-conditional.obj `if test -f './flow/conditional.c'; then $(CYGPATH_W) './flow/conditional.c'; else $(CYGPATH_W) '$(srcdir)/./flow/conditional.c'; fi`
./flow/feenox-error.o: ./flow/error.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-error.o -MD -MP -MF ./flow/$(DEPDIR)/feenox-error.Tpo -c -o ./flow/feenox-error.o `test -f './flow/error.c' || echo '$(srcdir)/'`./flow/error.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-error.Tpo ./flow/$(DEPDIR)/feenox-error.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/error.c' object='./flow/feenox-error.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-error.o `test -f './flow/error.c' || echo '$(srcdir)/'`./flow/error.c
./flow/feenox-error.obj: ./flow/error.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-error.obj -MD -MP -MF ./flow/$(DEPDIR)/feenox-error.Tpo -c -o ./flow/feenox-error.obj `if test -f './flow/error.c'; then $(CYGPATH_W) './flow/error.c'; else $(CYGPATH_W) '$(srcdir)/./flow/error.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-error.Tpo ./flow/$(DEPDIR)/feenox-error.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/error.c' object='./flow/feenox-error.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-error.obj `if test -f './flow/error.c'; then $(CYGPATH_W) './flow/error.c'; else $(CYGPATH_W) '$(srcdir)/./flow/error.c'; fi`
./flow/feenox-define.o: ./flow/define.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-define.o -MD -MP -MF ./flow/$(DEPDIR)/feenox-define.Tpo -c -o ./flow/feenox-define.o `test -f './flow/define.c' || echo '$(srcdir)/'`./flow/define.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-define.Tpo ./flow/$(DEPDIR)/feenox-define.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/define.c' object='./flow/feenox-define.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-define.o `test -f './flow/define.c' || echo '$(srcdir)/'`./flow/define.c
./flow/feenox-define.obj: ./flow/define.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-define.obj -MD -MP -MF ./flow/$(DEPDIR)/feenox-define.Tpo -c -o ./flow/feenox-define.obj `if test -f './flow/define.c'; then $(CYGPATH_W) './flow/define.c'; else $(CYGPATH_W) '$(srcdir)/./flow/define.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-define.Tpo ./flow/$(DEPDIR)/feenox-define.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/define.c' object='./flow/feenox-define.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-define.obj `if test -f './flow/define.c'; then $(CYGPATH_W) './flow/define.c'; else $(CYGPATH_W) '$(srcdir)/./flow/define.c'; fi`
./flow/feenox-getptr.o: ./flow/getptr.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-getptr.o -MD -MP -MF ./flow/$(DEPDIR)/feenox-getptr.Tpo -c -o ./flow/feenox-getptr.o `test -f './flow/getptr.c' || echo '$(srcdir)/'`./flow/getptr.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-getptr.Tpo ./flow/$(DEPDIR)/feenox-getptr.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/getptr.c' object='./flow/feenox-getptr.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-getptr.o `test -f './flow/getptr.c' || echo '$(srcdir)/'`./flow/getptr.c
./flow/feenox-getptr.obj: ./flow/getptr.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-getptr.obj -MD -MP -MF ./flow/$(DEPDIR)/feenox-getptr.Tpo -c -o ./flow/feenox-getptr.obj `if test -f './flow/getptr.c'; then $(CYGPATH_W) './flow/getptr.c'; else $(CYGPATH_W) '$(srcdir)/./flow/getptr.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-getptr.Tpo ./flow/$(DEPDIR)/feenox-getptr.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/getptr.c' object='./flow/feenox-getptr.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-getptr.obj `if test -f './flow/getptr.c'; then $(CYGPATH_W) './flow/getptr.c'; else $(CYGPATH_W) '$(srcdir)/./flow/getptr.c'; fi`
./flow/feenox-cleanup.o: ./flow/cleanup.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-cleanup.o -MD -MP -MF ./flow/$(DEPDIR)/feenox-cleanup.Tpo -c -o ./flow/feenox-cleanup.o `test -f './flow/cleanup.c' || echo '$(srcdir)/'`./flow/cleanup.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-cleanup.Tpo ./flow/$(DEPDIR)/feenox-cleanup.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/cleanup.c' object='./flow/feenox-cleanup.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-cleanup.o `test -f './flow/cleanup.c' || echo '$(srcdir)/'`./flow/cleanup.c
./flow/feenox-cleanup.obj: ./flow/cleanup.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-cleanup.obj -MD -MP -MF ./flow/$(DEPDIR)/feenox-cleanup.Tpo -c -o ./flow/feenox-cleanup.obj `if test -f './flow/cleanup.c'; then $(CYGPATH_W) './flow/cleanup.c'; else $(CYGPATH_W) '$(srcdir)/./flow/cleanup.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-cleanup.Tpo ./flow/$(DEPDIR)/feenox-cleanup.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/cleanup.c' object='./flow/feenox-cleanup.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-cleanup.obj `if test -f './flow/cleanup.c'; then $(CYGPATH_W) './flow/cleanup.c'; else $(CYGPATH_W) '$(srcdir)/./flow/cleanup.c'; fi`
./flow/feenox-instruction.o: ./flow/instruction.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-instruction.o -MD -MP -MF ./flow/$(DEPDIR)/feenox-instruction.Tpo -c -o ./flow/feenox-instruction.o `test -f './flow/instruction.c' || echo '$(srcdir)/'`./flow/instruction.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-instruction.Tpo ./flow/$(DEPDIR)/feenox-instruction.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/instruction.c' object='./flow/feenox-instruction.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-instruction.o `test -f './flow/instruction.c' || echo '$(srcdir)/'`./flow/instruction.c
./flow/feenox-instruction.obj: ./flow/instruction.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-instruction.obj -MD -MP -MF ./flow/$(DEPDIR)/feenox-instruction.Tpo -c -o ./flow/feenox-instruction.obj `if test -f './flow/instruction.c'; then $(CYGPATH_W) './flow/instruction.c'; else $(CYGPATH_W) '$(srcdir)/./flow/instruction.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-instruction.Tpo ./flow/$(DEPDIR)/feenox-instruction.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/instruction.c' object='./flow/feenox-instruction.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-instruction.obj `if test -f './flow/instruction.c'; then $(CYGPATH_W) './flow/instruction.c'; else $(CYGPATH_W) '$(srcdir)/./flow/instruction.c'; fi`
./flow/feenox-step.o: ./flow/step.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-step.o -MD -MP -MF ./flow/$(DEPDIR)/feenox-step.Tpo -c -o ./flow/feenox-step.o `test -f './flow/step.c' || echo '$(srcdir)/'`./flow/step.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-step.Tpo ./flow/$(DEPDIR)/feenox-step.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/step.c' object='./flow/feenox-step.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-step.o `test -f './flow/step.c' || echo '$(srcdir)/'`./flow/step.c
./flow/feenox-step.obj: ./flow/step.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-step.obj -MD -MP -MF ./flow/$(DEPDIR)/feenox-step.Tpo -c -o ./flow/feenox-step.obj `if test -f './flow/step.c'; then $(CYGPATH_W) './flow/step.c'; else $(CYGPATH_W) '$(srcdir)/./flow/step.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-step.Tpo ./flow/$(DEPDIR)/feenox-step.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/step.c' object='./flow/feenox-step.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-step.obj `if test -f './flow/step.c'; then $(CYGPATH_W) './flow/step.c'; else $(CYGPATH_W) '$(srcdir)/./flow/step.c'; fi`
./flow/feenox-run.o: ./flow/run.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-run.o -MD -MP -MF ./flow/$(DEPDIR)/feenox-run.Tpo -c -o ./flow/feenox-run.o `test -f './flow/run.c' || echo '$(srcdir)/'`./flow/run.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-run.Tpo ./flow/$(DEPDIR)/feenox-run.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/run.c' object='./flow/feenox-run.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-run.o `test -f './flow/run.c' || echo '$(srcdir)/'`./flow/run.c
./flow/feenox-run.obj: ./flow/run.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./flow/feenox-run.obj -MD -MP -MF ./flow/$(DEPDIR)/feenox-run.Tpo -c -o ./flow/feenox-run.obj `if test -f './flow/run.c'; then $(CYGPATH_W) './flow/run.c'; else $(CYGPATH_W) '$(srcdir)/./flow/run.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./flow/$(DEPDIR)/feenox-run.Tpo ./flow/$(DEPDIR)/feenox-run.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./flow/run.c' object='./flow/feenox-run.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./flow/feenox-run.obj `if test -f './flow/run.c'; then $(CYGPATH_W) './flow/run.c'; else $(CYGPATH_W) '$(srcdir)/./flow/run.c'; fi`
./parser/feenox-parser.o: ./parser/parser.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./parser/feenox-parser.o -MD -MP -MF ./parser/$(DEPDIR)/feenox-parser.Tpo -c -o ./parser/feenox-parser.o `test -f './parser/parser.c' || echo '$(srcdir)/'`./parser/parser.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./parser/$(DEPDIR)/feenox-parser.Tpo ./parser/$(DEPDIR)/feenox-parser.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./parser/parser.c' object='./parser/feenox-parser.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./parser/feenox-parser.o `test -f './parser/parser.c' || echo '$(srcdir)/'`./parser/parser.c
./parser/feenox-parser.obj: ./parser/parser.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./parser/feenox-parser.obj -MD -MP -MF ./parser/$(DEPDIR)/feenox-parser.Tpo -c -o ./parser/feenox-parser.obj `if test -f './parser/parser.c'; then $(CYGPATH_W) './parser/parser.c'; else $(CYGPATH_W) '$(srcdir)/./parser/parser.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./parser/$(DEPDIR)/feenox-parser.Tpo ./parser/$(DEPDIR)/feenox-parser.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./parser/parser.c' object='./parser/feenox-parser.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./parser/feenox-parser.obj `if test -f './parser/parser.c'; then $(CYGPATH_W) './parser/parser.c'; else $(CYGPATH_W) '$(srcdir)/./parser/parser.c'; fi`
./parser/feenox-auxiliary.o: ./parser/auxiliary.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./parser/feenox-auxiliary.o -MD -MP -MF ./parser/$(DEPDIR)/feenox-auxiliary.Tpo -c -o ./parser/feenox-auxiliary.o `test -f './parser/auxiliary.c' || echo '$(srcdir)/'`./parser/auxiliary.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./parser/$(DEPDIR)/feenox-auxiliary.Tpo ./parser/$(DEPDIR)/feenox-auxiliary.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./parser/auxiliary.c' object='./parser/feenox-auxiliary.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./parser/feenox-auxiliary.o `test -f './parser/auxiliary.c' || echo '$(srcdir)/'`./parser/auxiliary.c
./parser/feenox-auxiliary.obj: ./parser/auxiliary.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./parser/feenox-auxiliary.obj -MD -MP -MF ./parser/$(DEPDIR)/feenox-auxiliary.Tpo -c -o ./parser/feenox-auxiliary.obj `if test -f './parser/auxiliary.c'; then $(CYGPATH_W) './parser/auxiliary.c'; else $(CYGPATH_W) '$(srcdir)/./parser/auxiliary.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./parser/$(DEPDIR)/feenox-auxiliary.Tpo ./parser/$(DEPDIR)/feenox-auxiliary.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./parser/auxiliary.c' object='./parser/feenox-auxiliary.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./parser/feenox-auxiliary.obj `if test -f './parser/auxiliary.c'; then $(CYGPATH_W) './parser/auxiliary.c'; else $(CYGPATH_W) '$(srcdir)/./parser/auxiliary.c'; fi`
./io/feenox-file.o: ./io/file.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./io/feenox-file.o -MD -MP -MF ./io/$(DEPDIR)/feenox-file.Tpo -c -o ./io/feenox-file.o `test -f './io/file.c' || echo '$(srcdir)/'`./io/file.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./io/$(DEPDIR)/feenox-file.Tpo ./io/$(DEPDIR)/feenox-file.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./io/file.c' object='./io/feenox-file.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./io/feenox-file.o `test -f './io/file.c' || echo '$(srcdir)/'`./io/file.c
./io/feenox-file.obj: ./io/file.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./io/feenox-file.obj -MD -MP -MF ./io/$(DEPDIR)/feenox-file.Tpo -c -o ./io/feenox-file.obj `if test -f './io/file.c'; then $(CYGPATH_W) './io/file.c'; else $(CYGPATH_W) '$(srcdir)/./io/file.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./io/$(DEPDIR)/feenox-file.Tpo ./io/$(DEPDIR)/feenox-file.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./io/file.c' object='./io/feenox-file.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./io/feenox-file.obj `if test -f './io/file.c'; then $(CYGPATH_W) './io/file.c'; else $(CYGPATH_W) '$(srcdir)/./io/file.c'; fi`
./io/feenox-read.o: ./io/read.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./io/feenox-read.o -MD -MP -MF ./io/$(DEPDIR)/feenox-read.Tpo -c -o ./io/feenox-read.o `test -f './io/read.c' || echo '$(srcdir)/'`./io/read.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./io/$(DEPDIR)/feenox-read.Tpo ./io/$(DEPDIR)/feenox-read.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./io/read.c' object='./io/feenox-read.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./io/feenox-read.o `test -f './io/read.c' || echo '$(srcdir)/'`./io/read.c
./io/feenox-read.obj: ./io/read.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./io/feenox-read.obj -MD -MP -MF ./io/$(DEPDIR)/feenox-read.Tpo -c -o ./io/feenox-read.obj `if test -f './io/read.c'; then $(CYGPATH_W) './io/read.c'; else $(CYGPATH_W) '$(srcdir)/./io/read.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./io/$(DEPDIR)/feenox-read.Tpo ./io/$(DEPDIR)/feenox-read.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./io/read.c' object='./io/feenox-read.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./io/feenox-read.obj `if test -f './io/read.c'; then $(CYGPATH_W) './io/read.c'; else $(CYGPATH_W) '$(srcdir)/./io/read.c'; fi`
./io/feenox-print.o: ./io/print.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./io/feenox-print.o -MD -MP -MF ./io/$(DEPDIR)/feenox-print.Tpo -c -o ./io/feenox-print.o `test -f './io/print.c' || echo '$(srcdir)/'`./io/print.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./io/$(DEPDIR)/feenox-print.Tpo ./io/$(DEPDIR)/feenox-print.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./io/print.c' object='./io/feenox-print.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./io/feenox-print.o `test -f './io/print.c' || echo '$(srcdir)/'`./io/print.c
./io/feenox-print.obj: ./io/print.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./io/feenox-print.obj -MD -MP -MF ./io/$(DEPDIR)/feenox-print.Tpo -c -o ./io/feenox-print.obj `if test -f './io/print.c'; then $(CYGPATH_W) './io/print.c'; else $(CYGPATH_W) '$(srcdir)/./io/print.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./io/$(DEPDIR)/feenox-print.Tpo ./io/$(DEPDIR)/feenox-print.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./io/print.c' object='./io/feenox-print.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./io/feenox-print.obj `if test -f './io/print.c'; then $(CYGPATH_W) './io/print.c'; else $(CYGPATH_W) '$(srcdir)/./io/print.c'; fi`
./io/feenox-printf.o: ./io/printf.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./io/feenox-printf.o -MD -MP -MF ./io/$(DEPDIR)/feenox-printf.Tpo -c -o ./io/feenox-printf.o `test -f './io/printf.c' || echo '$(srcdir)/'`./io/printf.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./io/$(DEPDIR)/feenox-printf.Tpo ./io/$(DEPDIR)/feenox-printf.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./io/printf.c' object='./io/feenox-printf.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./io/feenox-printf.o `test -f './io/printf.c' || echo '$(srcdir)/'`./io/printf.c
./io/feenox-printf.obj: ./io/printf.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./io/feenox-printf.obj -MD -MP -MF ./io/$(DEPDIR)/feenox-printf.Tpo -c -o ./io/feenox-printf.obj `if test -f './io/printf.c'; then $(CYGPATH_W) './io/printf.c'; else $(CYGPATH_W) '$(srcdir)/./io/printf.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./io/$(DEPDIR)/feenox-printf.Tpo ./io/$(DEPDIR)/feenox-printf.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./io/printf.c' object='./io/feenox-printf.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./io/feenox-printf.obj `if test -f './io/printf.c'; then $(CYGPATH_W) './io/printf.c'; else $(CYGPATH_W) '$(srcdir)/./io/printf.c'; fi`
./math/feenox-alias.o: ./math/alias.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-alias.o -MD -MP -MF ./math/$(DEPDIR)/feenox-alias.Tpo -c -o ./math/feenox-alias.o `test -f './math/alias.c' || echo '$(srcdir)/'`./math/alias.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-alias.Tpo ./math/$(DEPDIR)/feenox-alias.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/alias.c' object='./math/feenox-alias.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-alias.o `test -f './math/alias.c' || echo '$(srcdir)/'`./math/alias.c
./math/feenox-alias.obj: ./math/alias.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-alias.obj -MD -MP -MF ./math/$(DEPDIR)/feenox-alias.Tpo -c -o ./math/feenox-alias.obj `if test -f './math/alias.c'; then $(CYGPATH_W) './math/alias.c'; else $(CYGPATH_W) '$(srcdir)/./math/alias.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-alias.Tpo ./math/$(DEPDIR)/feenox-alias.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/alias.c' object='./math/feenox-alias.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-alias.obj `if test -f './math/alias.c'; then $(CYGPATH_W) './math/alias.c'; else $(CYGPATH_W) '$(srcdir)/./math/alias.c'; fi`
./math/feenox-assignment.o: ./math/assignment.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-assignment.o -MD -MP -MF ./math/$(DEPDIR)/feenox-assignment.Tpo -c -o ./math/feenox-assignment.o `test -f './math/assignment.c' || echo '$(srcdir)/'`./math/assignment.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-assignment.Tpo ./math/$(DEPDIR)/feenox-assignment.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/assignment.c' object='./math/feenox-assignment.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-assignment.o `test -f './math/assignment.c' || echo '$(srcdir)/'`./math/assignment.c
./math/feenox-assignment.obj: ./math/assignment.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-assignment.obj -MD -MP -MF ./math/$(DEPDIR)/feenox-assignment.Tpo -c -o ./math/feenox-assignment.obj `if test -f './math/assignment.c'; then $(CYGPATH_W) './math/assignment.c'; else $(CYGPATH_W) '$(srcdir)/./math/assignment.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-assignment.Tpo ./math/$(DEPDIR)/feenox-assignment.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/assignment.c' object='./math/feenox-assignment.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-assignment.obj `if test -f './math/assignment.c'; then $(CYGPATH_W) './math/assignment.c'; else $(CYGPATH_W) '$(srcdir)/./math/assignment.c'; fi`
./math/feenox-builtin_functions.o: ./math/builtin_functions.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-builtin_functions.o -MD -MP -MF ./math/$(DEPDIR)/feenox-builtin_functions.Tpo -c -o ./math/feenox-builtin_functions.o `test -f './math/builtin_functions.c' || echo '$(srcdir)/'`./math/builtin_functions.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-builtin_functions.Tpo ./math/$(DEPDIR)/feenox-builtin_functions.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/builtin_functions.c' object='./math/feenox-builtin_functions.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-builtin_functions.o `test -f './math/builtin_functions.c' || echo '$(srcdir)/'`./math/builtin_functions.c
./math/feenox-builtin_functions.obj: ./math/builtin_functions.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-builtin_functions.obj -MD -MP -MF ./math/$(DEPDIR)/feenox-builtin_functions.Tpo -c -o ./math/feenox-builtin_functions.obj `if test -f './math/builtin_functions.c'; then $(CYGPATH_W) './math/builtin_functions.c'; else $(CYGPATH_W) '$(srcdir)/./math/builtin_functions.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-builtin_functions.Tpo ./math/$(DEPDIR)/feenox-builtin_functions.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/builtin_functions.c' object='./math/feenox-builtin_functions.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-builtin_functions.obj `if test -f './math/builtin_functions.c'; then $(CYGPATH_W) './math/builtin_functions.c'; else $(CYGPATH_W) '$(srcdir)/./math/builtin_functions.c'; fi`
./math/feenox-builtin_functionals.o: ./math/builtin_functionals.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-builtin_functionals.o -MD -MP -MF ./math/$(DEPDIR)/feenox-builtin_functionals.Tpo -c -o ./math/feenox-builtin_functionals.o `test -f './math/builtin_functionals.c' || echo '$(srcdir)/'`./math/builtin_functionals.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-builtin_functionals.Tpo ./math/$(DEPDIR)/feenox-builtin_functionals.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/builtin_functionals.c' object='./math/feenox-builtin_functionals.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-builtin_functionals.o `test -f './math/builtin_functionals.c' || echo '$(srcdir)/'`./math/builtin_functionals.c
./math/feenox-builtin_functionals.obj: ./math/builtin_functionals.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-builtin_functionals.obj -MD -MP -MF ./math/$(DEPDIR)/feenox-builtin_functionals.Tpo -c -o ./math/feenox-builtin_functionals.obj `if test -f './math/builtin_functionals.c'; then $(CYGPATH_W) './math/builtin_functionals.c'; else $(CYGPATH_W) '$(srcdir)/./math/builtin_functionals.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-builtin_functionals.Tpo ./math/$(DEPDIR)/feenox-builtin_functionals.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/builtin_functionals.c' object='./math/feenox-builtin_functionals.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-builtin_functionals.obj `if test -f './math/builtin_functionals.c'; then $(CYGPATH_W) './math/builtin_functionals.c'; else $(CYGPATH_W) '$(srcdir)/./math/builtin_functionals.c'; fi`
./math/feenox-builtin_vectorfunctions.o: ./math/builtin_vectorfunctions.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-builtin_vectorfunctions.o -MD -MP -MF ./math/$(DEPDIR)/feenox-builtin_vectorfunctions.Tpo -c -o ./math/feenox-builtin_vectorfunctions.o `test -f './math/builtin_vectorfunctions.c' || echo '$(srcdir)/'`./math/builtin_vectorfunctions.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-builtin_vectorfunctions.Tpo ./math/$(DEPDIR)/feenox-builtin_vectorfunctions.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/builtin_vectorfunctions.c' object='./math/feenox-builtin_vectorfunctions.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-builtin_vectorfunctions.o `test -f './math/builtin_vectorfunctions.c' || echo '$(srcdir)/'`./math/builtin_vectorfunctions.c
./math/feenox-builtin_vectorfunctions.obj: ./math/builtin_vectorfunctions.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-builtin_vectorfunctions.obj -MD -MP -MF ./math/$(DEPDIR)/feenox-builtin_vectorfunctions.Tpo -c -o ./math/feenox-builtin_vectorfunctions.obj `if test -f './math/builtin_vectorfunctions.c'; then $(CYGPATH_W) './math/builtin_vectorfunctions.c'; else $(CYGPATH_W) '$(srcdir)/./math/builtin_vectorfunctions.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-builtin_vectorfunctions.Tpo ./math/$(DEPDIR)/feenox-builtin_vectorfunctions.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/builtin_vectorfunctions.c' object='./math/feenox-builtin_vectorfunctions.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-builtin_vectorfunctions.obj `if test -f './math/builtin_vectorfunctions.c'; then $(CYGPATH_W) './math/builtin_vectorfunctions.c'; else $(CYGPATH_W) '$(srcdir)/./math/builtin_vectorfunctions.c'; fi`
./math/feenox-dae.o: ./math/dae.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-dae.o -MD -MP -MF ./math/$(DEPDIR)/feenox-dae.Tpo -c -o ./math/feenox-dae.o `test -f './math/dae.c' || echo '$(srcdir)/'`./math/dae.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-dae.Tpo ./math/$(DEPDIR)/feenox-dae.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/dae.c' object='./math/feenox-dae.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-dae.o `test -f './math/dae.c' || echo '$(srcdir)/'`./math/dae.c
./math/feenox-dae.obj: ./math/dae.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-dae.obj -MD -MP -MF ./math/$(DEPDIR)/feenox-dae.Tpo -c -o ./math/feenox-dae.obj `if test -f './math/dae.c'; then $(CYGPATH_W) './math/dae.c'; else $(CYGPATH_W) '$(srcdir)/./math/dae.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-dae.Tpo ./math/$(DEPDIR)/feenox-dae.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/dae.c' object='./math/feenox-dae.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-dae.obj `if test -f './math/dae.c'; then $(CYGPATH_W) './math/dae.c'; else $(CYGPATH_W) '$(srcdir)/./math/dae.c'; fi`
./math/feenox-expressions.o: ./math/expressions.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-expressions.o -MD -MP -MF ./math/$(DEPDIR)/feenox-expressions.Tpo -c -o ./math/feenox-expressions.o `test -f './math/expressions.c' || echo '$(srcdir)/'`./math/expressions.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-expressions.Tpo ./math/$(DEPDIR)/feenox-expressions.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/expressions.c' object='./math/feenox-expressions.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-expressions.o `test -f './math/expressions.c' || echo '$(srcdir)/'`./math/expressions.c
./math/feenox-expressions.obj: ./math/expressions.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-expressions.obj -MD -MP -MF ./math/$(DEPDIR)/feenox-expressions.Tpo -c -o ./math/feenox-expressions.obj `if test -f './math/expressions.c'; then $(CYGPATH_W) './math/expressions.c'; else $(CYGPATH_W) '$(srcdir)/./math/expressions.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-expressions.Tpo ./math/$(DEPDIR)/feenox-expressions.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/expressions.c' object='./math/feenox-expressions.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-expressions.obj `if test -f './math/expressions.c'; then $(CYGPATH_W) './math/expressions.c'; else $(CYGPATH_W) '$(srcdir)/./math/expressions.c'; fi`
./math/feenox-fit.o: ./math/fit.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-fit.o -MD -MP -MF ./math/$(DEPDIR)/feenox-fit.Tpo -c -o ./math/feenox-fit.o `test -f './math/fit.c' || echo '$(srcdir)/'`./math/fit.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-fit.Tpo ./math/$(DEPDIR)/feenox-fit.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/fit.c' object='./math/feenox-fit.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-fit.o `test -f './math/fit.c' || echo '$(srcdir)/'`./math/fit.c
./math/feenox-fit.obj: ./math/fit.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-fit.obj -MD -MP -MF ./math/$(DEPDIR)/feenox-fit.Tpo -c -o ./math/feenox-fit.obj `if test -f './math/fit.c'; then $(CYGPATH_W) './math/fit.c'; else $(CYGPATH_W) '$(srcdir)/./math/fit.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-fit.Tpo ./math/$(DEPDIR)/feenox-fit.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/fit.c' object='./math/feenox-fit.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-fit.obj `if test -f './math/fit.c'; then $(CYGPATH_W) './math/fit.c'; else $(CYGPATH_W) '$(srcdir)/./math/fit.c'; fi`
./math/feenox-function.o: ./math/function.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-function.o -MD -MP -MF ./math/$(DEPDIR)/feenox-function.Tpo -c -o ./math/feenox-function.o `test -f './math/function.c' || echo '$(srcdir)/'`./math/function.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-function.Tpo ./math/$(DEPDIR)/feenox-function.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/function.c' object='./math/feenox-function.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-function.o `test -f './math/function.c' || echo '$(srcdir)/'`./math/function.c
./math/feenox-function.obj: ./math/function.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-function.obj -MD -MP -MF ./math/$(DEPDIR)/feenox-function.Tpo -c -o ./math/feenox-function.obj `if test -f './math/function.c'; then $(CYGPATH_W) './math/function.c'; else $(CYGPATH_W) '$(srcdir)/./math/function.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-function.Tpo ./math/$(DEPDIR)/feenox-function.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/function.c' object='./math/feenox-function.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-function.obj `if test -f './math/function.c'; then $(CYGPATH_W) './math/function.c'; else $(CYGPATH_W) '$(srcdir)/./math/function.c'; fi`
./math/feenox-matrix.o: ./math/matrix.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-matrix.o -MD -MP -MF ./math/$(DEPDIR)/feenox-matrix.Tpo -c -o ./math/feenox-matrix.o `test -f './math/matrix.c' || echo '$(srcdir)/'`./math/matrix.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-matrix.Tpo ./math/$(DEPDIR)/feenox-matrix.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/matrix.c' object='./math/feenox-matrix.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-matrix.o `test -f './math/matrix.c' || echo '$(srcdir)/'`./math/matrix.c
./math/feenox-matrix.obj: ./math/matrix.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-matrix.obj -MD -MP -MF ./math/$(DEPDIR)/feenox-matrix.Tpo -c -o ./math/feenox-matrix.obj `if test -f './math/matrix.c'; then $(CYGPATH_W) './math/matrix.c'; else $(CYGPATH_W) '$(srcdir)/./math/matrix.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-matrix.Tpo ./math/$(DEPDIR)/feenox-matrix.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/matrix.c' object='./math/feenox-matrix.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-matrix.obj `if test -f './math/matrix.c'; then $(CYGPATH_W) './math/matrix.c'; else $(CYGPATH_W) '$(srcdir)/./math/matrix.c'; fi`
./math/feenox-solve.o: ./math/solve.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-solve.o -MD -MP -MF ./math/$(DEPDIR)/feenox-solve.Tpo -c -o ./math/feenox-solve.o `test -f './math/solve.c' || echo '$(srcdir)/'`./math/solve.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-solve.Tpo ./math/$(DEPDIR)/feenox-solve.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/solve.c' object='./math/feenox-solve.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-solve.o `test -f './math/solve.c' || echo '$(srcdir)/'`./math/solve.c
./math/feenox-solve.obj: ./math/solve.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-solve.obj -MD -MP -MF ./math/$(DEPDIR)/feenox-solve.Tpo -c -o ./math/feenox-solve.obj `if test -f './math/solve.c'; then $(CYGPATH_W) './math/solve.c'; else $(CYGPATH_W) '$(srcdir)/./math/solve.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-solve.Tpo ./math/$(DEPDIR)/feenox-solve.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/solve.c' object='./math/feenox-solve.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-solve.obj `if test -f './math/solve.c'; then $(CYGPATH_W) './math/solve.c'; else $(CYGPATH_W) '$(srcdir)/./math/solve.c'; fi`
./math/feenox-vector.o: ./math/vector.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-vector.o -MD -MP -MF ./math/$(DEPDIR)/feenox-vector.Tpo -c -o ./math/feenox-vector.o `test -f './math/vector.c' || echo '$(srcdir)/'`./math/vector.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-vector.Tpo ./math/$(DEPDIR)/feenox-vector.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/vector.c' object='./math/feenox-vector.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-vector.o `test -f './math/vector.c' || echo '$(srcdir)/'`./math/vector.c
./math/feenox-vector.obj: ./math/vector.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./math/feenox-vector.obj -MD -MP -MF ./math/$(DEPDIR)/feenox-vector.Tpo -c -o ./math/feenox-vector.obj `if test -f './math/vector.c'; then $(CYGPATH_W) './math/vector.c'; else $(CYGPATH_W) '$(srcdir)/./math/vector.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./math/$(DEPDIR)/feenox-vector.Tpo ./math/$(DEPDIR)/feenox-vector.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./math/vector.c' object='./math/feenox-vector.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./math/feenox-vector.obj `if test -f './math/vector.c'; then $(CYGPATH_W) './math/vector.c'; else $(CYGPATH_W) '$(srcdir)/./math/vector.c'; fi`
./mesh/feenox-init.o: ./mesh/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-init.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-init.Tpo -c -o ./mesh/feenox-init.o `test -f './mesh/init.c' || echo '$(srcdir)/'`./mesh/init.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-init.Tpo ./mesh/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/init.c' object='./mesh/feenox-init.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-init.o `test -f './mesh/init.c' || echo '$(srcdir)/'`./mesh/init.c
./mesh/feenox-init.obj: ./mesh/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-init.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-init.Tpo -c -o ./mesh/feenox-init.obj `if test -f './mesh/init.c'; then $(CYGPATH_W) './mesh/init.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/init.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-init.Tpo ./mesh/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/init.c' object='./mesh/feenox-init.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-init.obj `if test -f './mesh/init.c'; then $(CYGPATH_W) './mesh/init.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/init.c'; fi`
./mesh/feenox-geometry.o: ./mesh/geometry.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-geometry.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-geometry.Tpo -c -o ./mesh/feenox-geometry.o `test -f './mesh/geometry.c' || echo '$(srcdir)/'`./mesh/geometry.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-geometry.Tpo ./mesh/$(DEPDIR)/feenox-geometry.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/geometry.c' object='./mesh/feenox-geometry.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-geometry.o `test -f './mesh/geometry.c' || echo '$(srcdir)/'`./mesh/geometry.c
./mesh/feenox-geometry.obj: ./mesh/geometry.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-geometry.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-geometry.Tpo -c -o ./mesh/feenox-geometry.obj `if test -f './mesh/geometry.c'; then $(CYGPATH_W) './mesh/geometry.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/geometry.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-geometry.Tpo ./mesh/$(DEPDIR)/feenox-geometry.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/geometry.c' object='./mesh/feenox-geometry.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-geometry.obj `if test -f './mesh/geometry.c'; then $(CYGPATH_W) './mesh/geometry.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/geometry.c'; fi`
./mesh/feenox-neighbors.o: ./mesh/neighbors.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-neighbors.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-neighbors.Tpo -c -o ./mesh/feenox-neighbors.o `test -f './mesh/neighbors.c' || echo '$(srcdir)/'`./mesh/neighbors.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-neighbors.Tpo ./mesh/$(DEPDIR)/feenox-neighbors.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/neighbors.c' object='./mesh/feenox-neighbors.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-neighbors.o `test -f './mesh/neighbors.c' || echo '$(srcdir)/'`./mesh/neighbors.c
./mesh/feenox-neighbors.obj: ./mesh/neighbors.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-neighbors.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-neighbors.Tpo -c -o ./mesh/feenox-neighbors.obj `if test -f './mesh/neighbors.c'; then $(CYGPATH_W) './mesh/neighbors.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/neighbors.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-neighbors.Tpo ./mesh/$(DEPDIR)/feenox-neighbors.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/neighbors.c' object='./mesh/feenox-neighbors.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-neighbors.obj `if test -f './mesh/neighbors.c'; then $(CYGPATH_W) './mesh/neighbors.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/neighbors.c'; fi`
./mesh/feenox-boundary_condition.o: ./mesh/boundary_condition.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-boundary_condition.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-boundary_condition.Tpo -c -o ./mesh/feenox-boundary_condition.o `test -f './mesh/boundary_condition.c' || echo '$(srcdir)/'`./mesh/boundary_condition.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-boundary_condition.Tpo ./mesh/$(DEPDIR)/feenox-boundary_condition.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/boundary_condition.c' object='./mesh/feenox-boundary_condition.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-boundary_condition.o `test -f './mesh/boundary_condition.c' || echo '$(srcdir)/'`./mesh/boundary_condition.c
./mesh/feenox-boundary_condition.obj: ./mesh/boundary_condition.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-boundary_condition.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-boundary_condition.Tpo -c -o ./mesh/feenox-boundary_condition.obj `if test -f './mesh/boundary_condition.c'; then $(CYGPATH_W) './mesh/boundary_condition.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/boundary_condition.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-boundary_condition.Tpo ./mesh/$(DEPDIR)/feenox-boundary_condition.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/boundary_condition.c' object='./mesh/feenox-boundary_condition.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-boundary_condition.obj `if test -f './mesh/boundary_condition.c'; then $(CYGPATH_W) './mesh/boundary_condition.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/boundary_condition.c'; fi`
./mesh/feenox-physical_group.o: ./mesh/physical_group.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-physical_group.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-physical_group.Tpo -c -o ./mesh/feenox-physical_group.o `test -f './mesh/physical_group.c' || echo '$(srcdir)/'`./mesh/physical_group.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-physical_group.Tpo ./mesh/$(DEPDIR)/feenox-physical_group.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/physical_group.c' object='./mesh/feenox-physical_group.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-physical_group.o `test -f './mesh/physical_group.c' || echo '$(srcdir)/'`./mesh/physical_group.c
./mesh/feenox-physical_group.obj: ./mesh/physical_group.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-physical_group.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-physical_group.Tpo -c -o ./mesh/feenox-physical_group.obj `if test -f './mesh/physical_group.c'; then $(CYGPATH_W) './mesh/physical_group.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/physical_group.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-physical_group.Tpo ./mesh/$(DEPDIR)/feenox-physical_group.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/physical_group.c' object='./mesh/feenox-physical_group.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-physical_group.obj `if test -f './mesh/physical_group.c'; then $(CYGPATH_W) './mesh/physical_group.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/physical_group.c'; fi`
./mesh/feenox-interpolate.o: ./mesh/interpolate.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-interpolate.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-interpolate.Tpo -c -o ./mesh/feenox-interpolate.o `test -f './mesh/interpolate.c' || echo '$(srcdir)/'`./mesh/interpolate.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-interpolate.Tpo ./mesh/$(DEPDIR)/feenox-interpolate.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/interpolate.c' object='./mesh/feenox-interpolate.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-interpolate.o `test -f './mesh/interpolate.c' || echo '$(srcdir)/'`./mesh/interpolate.c
./mesh/feenox-interpolate.obj: ./mesh/interpolate.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-interpolate.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-interpolate.Tpo -c -o ./mesh/feenox-interpolate.obj `if test -f './mesh/interpolate.c'; then $(CYGPATH_W) './mesh/interpolate.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/interpolate.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-interpolate.Tpo ./mesh/$(DEPDIR)/feenox-interpolate.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/interpolate.c' object='./mesh/feenox-interpolate.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-interpolate.obj `if test -f './mesh/interpolate.c'; then $(CYGPATH_W) './mesh/interpolate.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/interpolate.c'; fi`
./mesh/feenox-material.o: ./mesh/material.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-material.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-material.Tpo -c -o ./mesh/feenox-material.o `test -f './mesh/material.c' || echo '$(srcdir)/'`./mesh/material.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-material.Tpo ./mesh/$(DEPDIR)/feenox-material.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/material.c' object='./mesh/feenox-material.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-material.o `test -f './mesh/material.c' || echo '$(srcdir)/'`./mesh/material.c
./mesh/feenox-material.obj: ./mesh/material.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-material.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-material.Tpo -c -o ./mesh/feenox-material.obj `if test -f './mesh/material.c'; then $(CYGPATH_W) './mesh/material.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/material.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-material.Tpo ./mesh/$(DEPDIR)/feenox-material.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/material.c' object='./mesh/feenox-material.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-material.obj `if test -f './mesh/material.c'; then $(CYGPATH_W) './mesh/material.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/material.c'; fi`
./mesh/feenox-element.o: ./mesh/element.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-element.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-element.Tpo -c -o ./mesh/feenox-element.o `test -f './mesh/element.c' || echo '$(srcdir)/'`./mesh/element.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-element.Tpo ./mesh/$(DEPDIR)/feenox-element.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/element.c' object='./mesh/feenox-element.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-element.o `test -f './mesh/element.c' || echo '$(srcdir)/'`./mesh/element.c
./mesh/feenox-element.obj: ./mesh/element.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-element.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-element.Tpo -c -o ./mesh/feenox-element.obj `if test -f './mesh/element.c'; then $(CYGPATH_W) './mesh/element.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/element.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-element.Tpo ./mesh/$(DEPDIR)/feenox-element.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/element.c' object='./mesh/feenox-element.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-element.obj `if test -f './mesh/element.c'; then $(CYGPATH_W) './mesh/element.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/element.c'; fi`
./mesh/feenox-cell.o: ./mesh/cell.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-cell.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-cell.Tpo -c -o ./mesh/feenox-cell.o `test -f './mesh/cell.c' || echo '$(srcdir)/'`./mesh/cell.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-cell.Tpo ./mesh/$(DEPDIR)/feenox-cell.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/cell.c' object='./mesh/feenox-cell.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-cell.o `test -f './mesh/cell.c' || echo '$(srcdir)/'`./mesh/cell.c
./mesh/feenox-cell.obj: ./mesh/cell.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-cell.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-cell.Tpo -c -o ./mesh/feenox-cell.obj `if test -f './mesh/cell.c'; then $(CYGPATH_W) './mesh/cell.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/cell.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-cell.Tpo ./mesh/$(DEPDIR)/feenox-cell.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/cell.c' object='./mesh/feenox-cell.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-cell.obj `if test -f './mesh/cell.c'; then $(CYGPATH_W) './mesh/cell.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/cell.c'; fi`
./mesh/feenox-write.o: ./mesh/write.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-write.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-write.Tpo -c -o ./mesh/feenox-write.o `test -f './mesh/write.c' || echo '$(srcdir)/'`./mesh/write.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-write.Tpo ./mesh/$(DEPDIR)/feenox-write.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/write.c' object='./mesh/feenox-write.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-write.o `test -f './mesh/write.c' || echo '$(srcdir)/'`./mesh/write.c
./mesh/feenox-write.obj: ./mesh/write.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-write.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-write.Tpo -c -o ./mesh/feenox-write.obj `if test -f './mesh/write.c'; then $(CYGPATH_W) './mesh/write.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/write.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-write.Tpo ./mesh/$(DEPDIR)/feenox-write.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/write.c' object='./mesh/feenox-write.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-write.obj `if test -f './mesh/write.c'; then $(CYGPATH_W) './mesh/write.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/write.c'; fi`
./mesh/feenox-integrate.o: ./mesh/integrate.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-integrate.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-integrate.Tpo -c -o ./mesh/feenox-integrate.o `test -f './mesh/integrate.c' || echo '$(srcdir)/'`./mesh/integrate.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-integrate.Tpo ./mesh/$(DEPDIR)/feenox-integrate.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/integrate.c' object='./mesh/feenox-integrate.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-integrate.o `test -f './mesh/integrate.c' || echo '$(srcdir)/'`./mesh/integrate.c
./mesh/feenox-integrate.obj: ./mesh/integrate.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-integrate.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-integrate.Tpo -c -o ./mesh/feenox-integrate.obj `if test -f './mesh/integrate.c'; then $(CYGPATH_W) './mesh/integrate.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/integrate.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-integrate.Tpo ./mesh/$(DEPDIR)/feenox-integrate.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/integrate.c' object='./mesh/feenox-integrate.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-integrate.obj `if test -f './mesh/integrate.c'; then $(CYGPATH_W) './mesh/integrate.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/integrate.c'; fi`
./mesh/feenox-extrema.o: ./mesh/extrema.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-extrema.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-extrema.Tpo -c -o ./mesh/feenox-extrema.o `test -f './mesh/extrema.c' || echo '$(srcdir)/'`./mesh/extrema.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-extrema.Tpo ./mesh/$(DEPDIR)/feenox-extrema.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/extrema.c' object='./mesh/feenox-extrema.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-extrema.o `test -f './mesh/extrema.c' || echo '$(srcdir)/'`./mesh/extrema.c
./mesh/feenox-extrema.obj: ./mesh/extrema.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-extrema.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-extrema.Tpo -c -o ./mesh/feenox-extrema.obj `if test -f './mesh/extrema.c'; then $(CYGPATH_W) './mesh/extrema.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/extrema.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-extrema.Tpo ./mesh/$(DEPDIR)/feenox-extrema.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/extrema.c' object='./mesh/feenox-extrema.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-extrema.obj `if test -f './mesh/extrema.c'; then $(CYGPATH_W) './mesh/extrema.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/extrema.c'; fi`
./mesh/feenox-mesh.o: ./mesh/mesh.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-mesh.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-mesh.Tpo -c -o ./mesh/feenox-mesh.o `test -f './mesh/mesh.c' || echo '$(srcdir)/'`./mesh/mesh.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-mesh.Tpo ./mesh/$(DEPDIR)/feenox-mesh.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/mesh.c' object='./mesh/feenox-mesh.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-mesh.o `test -f './mesh/mesh.c' || echo '$(srcdir)/'`./mesh/mesh.c
./mesh/feenox-mesh.obj: ./mesh/mesh.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-mesh.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-mesh.Tpo -c -o ./mesh/feenox-mesh.obj `if test -f './mesh/mesh.c'; then $(CYGPATH_W) './mesh/mesh.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/mesh.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-mesh.Tpo ./mesh/$(DEPDIR)/feenox-mesh.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/mesh.c' object='./mesh/feenox-mesh.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-mesh.obj `if test -f './mesh/mesh.c'; then $(CYGPATH_W) './mesh/mesh.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/mesh.c'; fi`
./mesh/feenox-gmsh.o: ./mesh/gmsh.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-gmsh.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-gmsh.Tpo -c -o ./mesh/feenox-gmsh.o `test -f './mesh/gmsh.c' || echo '$(srcdir)/'`./mesh/gmsh.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-gmsh.Tpo ./mesh/$(DEPDIR)/feenox-gmsh.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/gmsh.c' object='./mesh/feenox-gmsh.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-gmsh.o `test -f './mesh/gmsh.c' || echo '$(srcdir)/'`./mesh/gmsh.c
./mesh/feenox-gmsh.obj: ./mesh/gmsh.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-gmsh.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-gmsh.Tpo -c -o ./mesh/feenox-gmsh.obj `if test -f './mesh/gmsh.c'; then $(CYGPATH_W) './mesh/gmsh.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/gmsh.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-gmsh.Tpo ./mesh/$(DEPDIR)/feenox-gmsh.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/gmsh.c' object='./mesh/feenox-gmsh.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-gmsh.obj `if test -f './mesh/gmsh.c'; then $(CYGPATH_W) './mesh/gmsh.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/gmsh.c'; fi`
./mesh/feenox-calculix.o: ./mesh/calculix.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-calculix.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-calculix.Tpo -c -o ./mesh/feenox-calculix.o `test -f './mesh/calculix.c' || echo '$(srcdir)/'`./mesh/calculix.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-calculix.Tpo ./mesh/$(DEPDIR)/feenox-calculix.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/calculix.c' object='./mesh/feenox-calculix.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-calculix.o `test -f './mesh/calculix.c' || echo '$(srcdir)/'`./mesh/calculix.c
./mesh/feenox-calculix.obj: ./mesh/calculix.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-calculix.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-calculix.Tpo -c -o ./mesh/feenox-calculix.obj `if test -f './mesh/calculix.c'; then $(CYGPATH_W) './mesh/calculix.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/calculix.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-calculix.Tpo ./mesh/$(DEPDIR)/feenox-calculix.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/calculix.c' object='./mesh/feenox-calculix.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-calculix.obj `if test -f './mesh/calculix.c'; then $(CYGPATH_W) './mesh/calculix.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/calculix.c'; fi`
./mesh/feenox-vtk.o: ./mesh/vtk.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-vtk.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-vtk.Tpo -c -o ./mesh/feenox-vtk.o `test -f './mesh/vtk.c' || echo '$(srcdir)/'`./mesh/vtk.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-vtk.Tpo ./mesh/$(DEPDIR)/feenox-vtk.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/vtk.c' object='./mesh/feenox-vtk.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-vtk.o `test -f './mesh/vtk.c' || echo '$(srcdir)/'`./mesh/vtk.c
./mesh/feenox-vtk.obj: ./mesh/vtk.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-vtk.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-vtk.Tpo -c -o ./mesh/feenox-vtk.obj `if test -f './mesh/vtk.c'; then $(CYGPATH_W) './mesh/vtk.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/vtk.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-vtk.Tpo ./mesh/$(DEPDIR)/feenox-vtk.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/vtk.c' object='./mesh/feenox-vtk.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-vtk.obj `if test -f './mesh/vtk.c'; then $(CYGPATH_W) './mesh/vtk.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/vtk.c'; fi`
./mesh/feenox-vtu.o: ./mesh/vtu.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-vtu.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-vtu.Tpo -c -o ./mesh/feenox-vtu.o `test -f './mesh/vtu.c' || echo '$(srcdir)/'`./mesh/vtu.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-vtu.Tpo ./mesh/$(DEPDIR)/feenox-vtu.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/vtu.c' object='./mesh/feenox-vtu.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-vtu.o `test -f './mesh/vtu.c' || echo '$(srcdir)/'`./mesh/vtu.c
./mesh/feenox-vtu.obj: ./mesh/vtu.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-vtu.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-vtu.Tpo -c -o ./mesh/feenox-vtu.obj `if test -f './mesh/vtu.c'; then $(CYGPATH_W) './mesh/vtu.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/vtu.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-vtu.Tpo ./mesh/$(DEPDIR)/feenox-vtu.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/vtu.c' object='./mesh/feenox-vtu.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-vtu.obj `if test -f './mesh/vtu.c'; then $(CYGPATH_W) './mesh/vtu.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/vtu.c'; fi`
./mesh/feenox-tag_index_map.o: ./mesh/tag_index_map.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-tag_index_map.o -MD -MP -MF ./mesh/$(DEPDIR)/feenox-tag_index_map.Tpo -c -o ./mesh/feenox-tag_index_map.o `test -f './mesh/tag_index_map.c' || echo '$(srcdir)/'`./mesh/tag_index_map.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-tag_index_map.Tpo ./mesh/$(DEPDIR)/feenox-tag_index_map.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/tag_index_map.c' object='./mesh/feenox-tag_index_map.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-tag_index_map.o `test -f './mesh/tag_index_map.c' || echo '$(srcdir)/'`./mesh/tag_index_map.c
./mesh/feenox-tag_index_map.obj: ./mesh/tag_index_map.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/feenox-tag_index_map.obj -MD -MP -MF ./mesh/$(DEPDIR)/feenox-tag_index_map.Tpo -c -o ./mesh/feenox-tag_index_map.obj `if test -f './mesh/tag_index_map.c'; then $(CYGPATH_W) './mesh/tag_index_map.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/tag_index_map.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/$(DEPDIR)/feenox-tag_index_map.Tpo ./mesh/$(DEPDIR)/feenox-tag_index_map.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/tag_index_map.c' object='./mesh/feenox-tag_index_map.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/feenox-tag_index_map.obj `if test -f './mesh/tag_index_map.c'; then $(CYGPATH_W) './mesh/tag_index_map.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/tag_index_map.c'; fi`
./mesh/elements/feenox-line2.o: ./mesh/elements/line2.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-line2.o -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-line2.Tpo -c -o ./mesh/elements/feenox-line2.o `test -f './mesh/elements/line2.c' || echo '$(srcdir)/'`./mesh/elements/line2.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-line2.Tpo ./mesh/elements/$(DEPDIR)/feenox-line2.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/line2.c' object='./mesh/elements/feenox-line2.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-line2.o `test -f './mesh/elements/line2.c' || echo '$(srcdir)/'`./mesh/elements/line2.c
./mesh/elements/feenox-line2.obj: ./mesh/elements/line2.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-line2.obj -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-line2.Tpo -c -o ./mesh/elements/feenox-line2.obj `if test -f './mesh/elements/line2.c'; then $(CYGPATH_W) './mesh/elements/line2.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/line2.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-line2.Tpo ./mesh/elements/$(DEPDIR)/feenox-line2.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/line2.c' object='./mesh/elements/feenox-line2.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-line2.obj `if test -f './mesh/elements/line2.c'; then $(CYGPATH_W) './mesh/elements/line2.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/line2.c'; fi`
./mesh/elements/feenox-line3.o: ./mesh/elements/line3.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-line3.o -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-line3.Tpo -c -o ./mesh/elements/feenox-line3.o `test -f './mesh/elements/line3.c' || echo '$(srcdir)/'`./mesh/elements/line3.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-line3.Tpo ./mesh/elements/$(DEPDIR)/feenox-line3.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/line3.c' object='./mesh/elements/feenox-line3.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-line3.o `test -f './mesh/elements/line3.c' || echo '$(srcdir)/'`./mesh/elements/line3.c
./mesh/elements/feenox-line3.obj: ./mesh/elements/line3.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-line3.obj -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-line3.Tpo -c -o ./mesh/elements/feenox-line3.obj `if test -f './mesh/elements/line3.c'; then $(CYGPATH_W) './mesh/elements/line3.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/line3.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-line3.Tpo ./mesh/elements/$(DEPDIR)/feenox-line3.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/line3.c' object='./mesh/elements/feenox-line3.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-line3.obj `if test -f './mesh/elements/line3.c'; then $(CYGPATH_W) './mesh/elements/line3.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/line3.c'; fi`
./mesh/elements/feenox-triang3.o: ./mesh/elements/triang3.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-triang3.o -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-triang3.Tpo -c -o ./mesh/elements/feenox-triang3.o `test -f './mesh/elements/triang3.c' || echo '$(srcdir)/'`./mesh/elements/triang3.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-triang3.Tpo ./mesh/elements/$(DEPDIR)/feenox-triang3.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/triang3.c' object='./mesh/elements/feenox-triang3.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-triang3.o `test -f './mesh/elements/triang3.c' || echo '$(srcdir)/'`./mesh/elements/triang3.c
./mesh/elements/feenox-triang3.obj: ./mesh/elements/triang3.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-triang3.obj -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-triang3.Tpo -c -o ./mesh/elements/feenox-triang3.obj `if test -f './mesh/elements/triang3.c'; then $(CYGPATH_W) './mesh/elements/triang3.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/triang3.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-triang3.Tpo ./mesh/elements/$(DEPDIR)/feenox-triang3.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/triang3.c' object='./mesh/elements/feenox-triang3.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-triang3.obj `if test -f './mesh/elements/triang3.c'; then $(CYGPATH_W) './mesh/elements/triang3.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/triang3.c'; fi`
./mesh/elements/feenox-triang6.o: ./mesh/elements/triang6.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-triang6.o -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-triang6.Tpo -c -o ./mesh/elements/feenox-triang6.o `test -f './mesh/elements/triang6.c' || echo '$(srcdir)/'`./mesh/elements/triang6.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-triang6.Tpo ./mesh/elements/$(DEPDIR)/feenox-triang6.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/triang6.c' object='./mesh/elements/feenox-triang6.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-triang6.o `test -f './mesh/elements/triang6.c' || echo '$(srcdir)/'`./mesh/elements/triang6.c
./mesh/elements/feenox-triang6.obj: ./mesh/elements/triang6.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-triang6.obj -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-triang6.Tpo -c -o ./mesh/elements/feenox-triang6.obj `if test -f './mesh/elements/triang6.c'; then $(CYGPATH_W) './mesh/elements/triang6.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/triang6.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-triang6.Tpo ./mesh/elements/$(DEPDIR)/feenox-triang6.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/triang6.c' object='./mesh/elements/feenox-triang6.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-triang6.obj `if test -f './mesh/elements/triang6.c'; then $(CYGPATH_W) './mesh/elements/triang6.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/triang6.c'; fi`
./mesh/elements/feenox-quad4.o: ./mesh/elements/quad4.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-quad4.o -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-quad4.Tpo -c -o ./mesh/elements/feenox-quad4.o `test -f './mesh/elements/quad4.c' || echo '$(srcdir)/'`./mesh/elements/quad4.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-quad4.Tpo ./mesh/elements/$(DEPDIR)/feenox-quad4.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/quad4.c' object='./mesh/elements/feenox-quad4.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-quad4.o `test -f './mesh/elements/quad4.c' || echo '$(srcdir)/'`./mesh/elements/quad4.c
./mesh/elements/feenox-quad4.obj: ./mesh/elements/quad4.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-quad4.obj -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-quad4.Tpo -c -o ./mesh/elements/feenox-quad4.obj `if test -f './mesh/elements/quad4.c'; then $(CYGPATH_W) './mesh/elements/quad4.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/quad4.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-quad4.Tpo ./mesh/elements/$(DEPDIR)/feenox-quad4.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/quad4.c' object='./mesh/elements/feenox-quad4.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-quad4.obj `if test -f './mesh/elements/quad4.c'; then $(CYGPATH_W) './mesh/elements/quad4.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/quad4.c'; fi`
./mesh/elements/feenox-quad8.o: ./mesh/elements/quad8.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-quad8.o -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-quad8.Tpo -c -o ./mesh/elements/feenox-quad8.o `test -f './mesh/elements/quad8.c' || echo '$(srcdir)/'`./mesh/elements/quad8.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-quad8.Tpo ./mesh/elements/$(DEPDIR)/feenox-quad8.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/quad8.c' object='./mesh/elements/feenox-quad8.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-quad8.o `test -f './mesh/elements/quad8.c' || echo '$(srcdir)/'`./mesh/elements/quad8.c
./mesh/elements/feenox-quad8.obj: ./mesh/elements/quad8.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-quad8.obj -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-quad8.Tpo -c -o ./mesh/elements/feenox-quad8.obj `if test -f './mesh/elements/quad8.c'; then $(CYGPATH_W) './mesh/elements/quad8.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/quad8.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-quad8.Tpo ./mesh/elements/$(DEPDIR)/feenox-quad8.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/quad8.c' object='./mesh/elements/feenox-quad8.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-quad8.obj `if test -f './mesh/elements/quad8.c'; then $(CYGPATH_W) './mesh/elements/quad8.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/quad8.c'; fi`
./mesh/elements/feenox-quad9.o: ./mesh/elements/quad9.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-quad9.o -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-quad9.Tpo -c -o ./mesh/elements/feenox-quad9.o `test -f './mesh/elements/quad9.c' || echo '$(srcdir)/'`./mesh/elements/quad9.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-quad9.Tpo ./mesh/elements/$(DEPDIR)/feenox-quad9.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/quad9.c' object='./mesh/elements/feenox-quad9.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-quad9.o `test -f './mesh/elements/quad9.c' || echo '$(srcdir)/'`./mesh/elements/quad9.c
./mesh/elements/feenox-quad9.obj: ./mesh/elements/quad9.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-quad9.obj -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-quad9.Tpo -c -o ./mesh/elements/feenox-quad9.obj `if test -f './mesh/elements/quad9.c'; then $(CYGPATH_W) './mesh/elements/quad9.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/quad9.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-quad9.Tpo ./mesh/elements/$(DEPDIR)/feenox-quad9.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/quad9.c' object='./mesh/elements/feenox-quad9.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-quad9.obj `if test -f './mesh/elements/quad9.c'; then $(CYGPATH_W) './mesh/elements/quad9.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/quad9.c'; fi`
./mesh/elements/feenox-tet4.o: ./mesh/elements/tet4.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-tet4.o -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-tet4.Tpo -c -o ./mesh/elements/feenox-tet4.o `test -f './mesh/elements/tet4.c' || echo '$(srcdir)/'`./mesh/elements/tet4.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-tet4.Tpo ./mesh/elements/$(DEPDIR)/feenox-tet4.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/tet4.c' object='./mesh/elements/feenox-tet4.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-tet4.o `test -f './mesh/elements/tet4.c' || echo '$(srcdir)/'`./mesh/elements/tet4.c
./mesh/elements/feenox-tet4.obj: ./mesh/elements/tet4.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-tet4.obj -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-tet4.Tpo -c -o ./mesh/elements/feenox-tet4.obj `if test -f './mesh/elements/tet4.c'; then $(CYGPATH_W) './mesh/elements/tet4.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/tet4.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-tet4.Tpo ./mesh/elements/$(DEPDIR)/feenox-tet4.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/tet4.c' object='./mesh/elements/feenox-tet4.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-tet4.obj `if test -f './mesh/elements/tet4.c'; then $(CYGPATH_W) './mesh/elements/tet4.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/tet4.c'; fi`
./mesh/elements/feenox-tet10.o: ./mesh/elements/tet10.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-tet10.o -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-tet10.Tpo -c -o ./mesh/elements/feenox-tet10.o `test -f './mesh/elements/tet10.c' || echo '$(srcdir)/'`./mesh/elements/tet10.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-tet10.Tpo ./mesh/elements/$(DEPDIR)/feenox-tet10.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/tet10.c' object='./mesh/elements/feenox-tet10.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-tet10.o `test -f './mesh/elements/tet10.c' || echo '$(srcdir)/'`./mesh/elements/tet10.c
./mesh/elements/feenox-tet10.obj: ./mesh/elements/tet10.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-tet10.obj -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-tet10.Tpo -c -o ./mesh/elements/feenox-tet10.obj `if test -f './mesh/elements/tet10.c'; then $(CYGPATH_W) './mesh/elements/tet10.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/tet10.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-tet10.Tpo ./mesh/elements/$(DEPDIR)/feenox-tet10.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/tet10.c' object='./mesh/elements/feenox-tet10.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-tet10.obj `if test -f './mesh/elements/tet10.c'; then $(CYGPATH_W) './mesh/elements/tet10.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/tet10.c'; fi`
./mesh/elements/feenox-hexa8.o: ./mesh/elements/hexa8.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-hexa8.o -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-hexa8.Tpo -c -o ./mesh/elements/feenox-hexa8.o `test -f './mesh/elements/hexa8.c' || echo '$(srcdir)/'`./mesh/elements/hexa8.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-hexa8.Tpo ./mesh/elements/$(DEPDIR)/feenox-hexa8.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/hexa8.c' object='./mesh/elements/feenox-hexa8.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-hexa8.o `test -f './mesh/elements/hexa8.c' || echo '$(srcdir)/'`./mesh/elements/hexa8.c
./mesh/elements/feenox-hexa8.obj: ./mesh/elements/hexa8.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-hexa8.obj -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-hexa8.Tpo -c -o ./mesh/elements/feenox-hexa8.obj `if test -f './mesh/elements/hexa8.c'; then $(CYGPATH_W) './mesh/elements/hexa8.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/hexa8.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-hexa8.Tpo ./mesh/elements/$(DEPDIR)/feenox-hexa8.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/hexa8.c' object='./mesh/elements/feenox-hexa8.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-hexa8.obj `if test -f './mesh/elements/hexa8.c'; then $(CYGPATH_W) './mesh/elements/hexa8.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/hexa8.c'; fi`
./mesh/elements/feenox-hexa20.o: ./mesh/elements/hexa20.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-hexa20.o -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-hexa20.Tpo -c -o ./mesh/elements/feenox-hexa20.o `test -f './mesh/elements/hexa20.c' || echo '$(srcdir)/'`./mesh/elements/hexa20.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-hexa20.Tpo ./mesh/elements/$(DEPDIR)/feenox-hexa20.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/hexa20.c' object='./mesh/elements/feenox-hexa20.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-hexa20.o `test -f './mesh/elements/hexa20.c' || echo '$(srcdir)/'`./mesh/elements/hexa20.c
./mesh/elements/feenox-hexa20.obj: ./mesh/elements/hexa20.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-hexa20.obj -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-hexa20.Tpo -c -o ./mesh/elements/feenox-hexa20.obj `if test -f './mesh/elements/hexa20.c'; then $(CYGPATH_W) './mesh/elements/hexa20.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/hexa20.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-hexa20.Tpo ./mesh/elements/$(DEPDIR)/feenox-hexa20.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/hexa20.c' object='./mesh/elements/feenox-hexa20.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-hexa20.obj `if test -f './mesh/elements/hexa20.c'; then $(CYGPATH_W) './mesh/elements/hexa20.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/hexa20.c'; fi`
./mesh/elements/feenox-hexa27.o: ./mesh/elements/hexa27.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-hexa27.o -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-hexa27.Tpo -c -o ./mesh/elements/feenox-hexa27.o `test -f './mesh/elements/hexa27.c' || echo '$(srcdir)/'`./mesh/elements/hexa27.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-hexa27.Tpo ./mesh/elements/$(DEPDIR)/feenox-hexa27.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/hexa27.c' object='./mesh/elements/feenox-hexa27.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-hexa27.o `test -f './mesh/elements/hexa27.c' || echo '$(srcdir)/'`./mesh/elements/hexa27.c
./mesh/elements/feenox-hexa27.obj: ./mesh/elements/hexa27.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-hexa27.obj -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-hexa27.Tpo -c -o ./mesh/elements/feenox-hexa27.obj `if test -f './mesh/elements/hexa27.c'; then $(CYGPATH_W) './mesh/elements/hexa27.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/hexa27.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-hexa27.Tpo ./mesh/elements/$(DEPDIR)/feenox-hexa27.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/hexa27.c' object='./mesh/elements/feenox-hexa27.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-hexa27.obj `if test -f './mesh/elements/hexa27.c'; then $(CYGPATH_W) './mesh/elements/hexa27.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/hexa27.c'; fi`
./mesh/elements/feenox-prism6.o: ./mesh/elements/prism6.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-prism6.o -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-prism6.Tpo -c -o ./mesh/elements/feenox-prism6.o `test -f './mesh/elements/prism6.c' || echo '$(srcdir)/'`./mesh/elements/prism6.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-prism6.Tpo ./mesh/elements/$(DEPDIR)/feenox-prism6.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/prism6.c' object='./mesh/elements/feenox-prism6.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-prism6.o `test -f './mesh/elements/prism6.c' || echo '$(srcdir)/'`./mesh/elements/prism6.c
./mesh/elements/feenox-prism6.obj: ./mesh/elements/prism6.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-prism6.obj -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-prism6.Tpo -c -o ./mesh/elements/feenox-prism6.obj `if test -f './mesh/elements/prism6.c'; then $(CYGPATH_W) './mesh/elements/prism6.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/prism6.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-prism6.Tpo ./mesh/elements/$(DEPDIR)/feenox-prism6.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/prism6.c' object='./mesh/elements/feenox-prism6.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-prism6.obj `if test -f './mesh/elements/prism6.c'; then $(CYGPATH_W) './mesh/elements/prism6.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/prism6.c'; fi`
./mesh/elements/feenox-prism15.o: ./mesh/elements/prism15.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-prism15.o -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-prism15.Tpo -c -o ./mesh/elements/feenox-prism15.o `test -f './mesh/elements/prism15.c' || echo '$(srcdir)/'`./mesh/elements/prism15.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-prism15.Tpo ./mesh/elements/$(DEPDIR)/feenox-prism15.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/prism15.c' object='./mesh/elements/feenox-prism15.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-prism15.o `test -f './mesh/elements/prism15.c' || echo '$(srcdir)/'`./mesh/elements/prism15.c
./mesh/elements/feenox-prism15.obj: ./mesh/elements/prism15.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-prism15.obj -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-prism15.Tpo -c -o ./mesh/elements/feenox-prism15.obj `if test -f './mesh/elements/prism15.c'; then $(CYGPATH_W) './mesh/elements/prism15.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/prism15.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-prism15.Tpo ./mesh/elements/$(DEPDIR)/feenox-prism15.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/prism15.c' object='./mesh/elements/feenox-prism15.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-prism15.obj `if test -f './mesh/elements/prism15.c'; then $(CYGPATH_W) './mesh/elements/prism15.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/prism15.c'; fi`
./mesh/elements/feenox-point.o: ./mesh/elements/point.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-point.o -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-point.Tpo -c -o ./mesh/elements/feenox-point.o `test -f './mesh/elements/point.c' || echo '$(srcdir)/'`./mesh/elements/point.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-point.Tpo ./mesh/elements/$(DEPDIR)/feenox-point.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/point.c' object='./mesh/elements/feenox-point.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-point.o `test -f './mesh/elements/point.c' || echo '$(srcdir)/'`./mesh/elements/point.c
./mesh/elements/feenox-point.obj: ./mesh/elements/point.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT ./mesh/elements/feenox-point.obj -MD -MP -MF ./mesh/elements/$(DEPDIR)/feenox-point.Tpo -c -o ./mesh/elements/feenox-point.obj `if test -f './mesh/elements/point.c'; then $(CYGPATH_W) './mesh/elements/point.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/point.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ./mesh/elements/$(DEPDIR)/feenox-point.Tpo ./mesh/elements/$(DEPDIR)/feenox-point.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='./mesh/elements/point.c' object='./mesh/elements/feenox-point.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o ./mesh/elements/feenox-point.obj `if test -f './mesh/elements/point.c'; then $(CYGPATH_W) './mesh/elements/point.c'; else $(CYGPATH_W) '$(srcdir)/./mesh/elements/point.c'; fi`
pdes/feenox-parse.o: pdes/parse.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-parse.o -MD -MP -MF pdes/$(DEPDIR)/feenox-parse.Tpo -c -o pdes/feenox-parse.o `test -f 'pdes/parse.c' || echo '$(srcdir)/'`pdes/parse.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-parse.Tpo pdes/$(DEPDIR)/feenox-parse.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/parse.c' object='pdes/feenox-parse.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-parse.o `test -f 'pdes/parse.c' || echo '$(srcdir)/'`pdes/parse.c
pdes/feenox-parse.obj: pdes/parse.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-parse.obj -MD -MP -MF pdes/$(DEPDIR)/feenox-parse.Tpo -c -o pdes/feenox-parse.obj `if test -f 'pdes/parse.c'; then $(CYGPATH_W) 'pdes/parse.c'; else $(CYGPATH_W) '$(srcdir)/pdes/parse.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-parse.Tpo pdes/$(DEPDIR)/feenox-parse.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/parse.c' object='pdes/feenox-parse.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-parse.obj `if test -f 'pdes/parse.c'; then $(CYGPATH_W) 'pdes/parse.c'; else $(CYGPATH_W) '$(srcdir)/pdes/parse.c'; fi`
pdes/thermal/feenox-post.o: pdes/thermal/post.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/thermal/feenox-post.o -MD -MP -MF pdes/thermal/$(DEPDIR)/feenox-post.Tpo -c -o pdes/thermal/feenox-post.o `test -f 'pdes/thermal/post.c' || echo '$(srcdir)/'`pdes/thermal/post.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/thermal/$(DEPDIR)/feenox-post.Tpo pdes/thermal/$(DEPDIR)/feenox-post.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/thermal/post.c' object='pdes/thermal/feenox-post.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/thermal/feenox-post.o `test -f 'pdes/thermal/post.c' || echo '$(srcdir)/'`pdes/thermal/post.c
pdes/thermal/feenox-post.obj: pdes/thermal/post.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/thermal/feenox-post.obj -MD -MP -MF pdes/thermal/$(DEPDIR)/feenox-post.Tpo -c -o pdes/thermal/feenox-post.obj `if test -f 'pdes/thermal/post.c'; then $(CYGPATH_W) 'pdes/thermal/post.c'; else $(CYGPATH_W) '$(srcdir)/pdes/thermal/post.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/thermal/$(DEPDIR)/feenox-post.Tpo pdes/thermal/$(DEPDIR)/feenox-post.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/thermal/post.c' object='pdes/thermal/feenox-post.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/thermal/feenox-post.obj `if test -f 'pdes/thermal/post.c'; then $(CYGPATH_W) 'pdes/thermal/post.c'; else $(CYGPATH_W) '$(srcdir)/pdes/thermal/post.c'; fi`
pdes/thermal/feenox-parser.o: pdes/thermal/parser.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/thermal/feenox-parser.o -MD -MP -MF pdes/thermal/$(DEPDIR)/feenox-parser.Tpo -c -o pdes/thermal/feenox-parser.o `test -f 'pdes/thermal/parser.c' || echo '$(srcdir)/'`pdes/thermal/parser.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/thermal/$(DEPDIR)/feenox-parser.Tpo pdes/thermal/$(DEPDIR)/feenox-parser.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/thermal/parser.c' object='pdes/thermal/feenox-parser.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/thermal/feenox-parser.o `test -f 'pdes/thermal/parser.c' || echo '$(srcdir)/'`pdes/thermal/parser.c
pdes/thermal/feenox-parser.obj: pdes/thermal/parser.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/thermal/feenox-parser.obj -MD -MP -MF pdes/thermal/$(DEPDIR)/feenox-parser.Tpo -c -o pdes/thermal/feenox-parser.obj `if test -f 'pdes/thermal/parser.c'; then $(CYGPATH_W) 'pdes/thermal/parser.c'; else $(CYGPATH_W) '$(srcdir)/pdes/thermal/parser.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/thermal/$(DEPDIR)/feenox-parser.Tpo pdes/thermal/$(DEPDIR)/feenox-parser.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/thermal/parser.c' object='pdes/thermal/feenox-parser.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/thermal/feenox-parser.obj `if test -f 'pdes/thermal/parser.c'; then $(CYGPATH_W) 'pdes/thermal/parser.c'; else $(CYGPATH_W) '$(srcdir)/pdes/thermal/parser.c'; fi`
pdes/thermal/feenox-init.o: pdes/thermal/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/thermal/feenox-init.o -MD -MP -MF pdes/thermal/$(DEPDIR)/feenox-init.Tpo -c -o pdes/thermal/feenox-init.o `test -f 'pdes/thermal/init.c' || echo '$(srcdir)/'`pdes/thermal/init.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/thermal/$(DEPDIR)/feenox-init.Tpo pdes/thermal/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/thermal/init.c' object='pdes/thermal/feenox-init.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/thermal/feenox-init.o `test -f 'pdes/thermal/init.c' || echo '$(srcdir)/'`pdes/thermal/init.c
pdes/thermal/feenox-init.obj: pdes/thermal/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/thermal/feenox-init.obj -MD -MP -MF pdes/thermal/$(DEPDIR)/feenox-init.Tpo -c -o pdes/thermal/feenox-init.obj `if test -f 'pdes/thermal/init.c'; then $(CYGPATH_W) 'pdes/thermal/init.c'; else $(CYGPATH_W) '$(srcdir)/pdes/thermal/init.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/thermal/$(DEPDIR)/feenox-init.Tpo pdes/thermal/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/thermal/init.c' object='pdes/thermal/feenox-init.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/thermal/feenox-init.obj `if test -f 'pdes/thermal/init.c'; then $(CYGPATH_W) 'pdes/thermal/init.c'; else $(CYGPATH_W) '$(srcdir)/pdes/thermal/init.c'; fi`
pdes/thermal/feenox-heatflux.o: pdes/thermal/heatflux.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/thermal/feenox-heatflux.o -MD -MP -MF pdes/thermal/$(DEPDIR)/feenox-heatflux.Tpo -c -o pdes/thermal/feenox-heatflux.o `test -f 'pdes/thermal/heatflux.c' || echo '$(srcdir)/'`pdes/thermal/heatflux.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/thermal/$(DEPDIR)/feenox-heatflux.Tpo pdes/thermal/$(DEPDIR)/feenox-heatflux.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/thermal/heatflux.c' object='pdes/thermal/feenox-heatflux.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/thermal/feenox-heatflux.o `test -f 'pdes/thermal/heatflux.c' || echo '$(srcdir)/'`pdes/thermal/heatflux.c
pdes/thermal/feenox-heatflux.obj: pdes/thermal/heatflux.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/thermal/feenox-heatflux.obj -MD -MP -MF pdes/thermal/$(DEPDIR)/feenox-heatflux.Tpo -c -o pdes/thermal/feenox-heatflux.obj `if test -f 'pdes/thermal/heatflux.c'; then $(CYGPATH_W) 'pdes/thermal/heatflux.c'; else $(CYGPATH_W) '$(srcdir)/pdes/thermal/heatflux.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/thermal/$(DEPDIR)/feenox-heatflux.Tpo pdes/thermal/$(DEPDIR)/feenox-heatflux.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/thermal/heatflux.c' object='pdes/thermal/feenox-heatflux.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/thermal/feenox-heatflux.obj `if test -f 'pdes/thermal/heatflux.c'; then $(CYGPATH_W) 'pdes/thermal/heatflux.c'; else $(CYGPATH_W) '$(srcdir)/pdes/thermal/heatflux.c'; fi`
pdes/thermal/feenox-bulk.o: pdes/thermal/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/thermal/feenox-bulk.o -MD -MP -MF pdes/thermal/$(DEPDIR)/feenox-bulk.Tpo -c -o pdes/thermal/feenox-bulk.o `test -f 'pdes/thermal/bulk.c' || echo '$(srcdir)/'`pdes/thermal/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/thermal/$(DEPDIR)/feenox-bulk.Tpo pdes/thermal/$(DEPDIR)/feenox-bulk.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/thermal/bulk.c' object='pdes/thermal/feenox-bulk.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/thermal/feenox-bulk.o `test -f 'pdes/thermal/bulk.c' || echo '$(srcdir)/'`pdes/thermal/bulk.c
pdes/thermal/feenox-bulk.obj: pdes/thermal/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/thermal/feenox-bulk.obj -MD -MP -MF pdes/thermal/$(DEPDIR)/feenox-bulk.Tpo -c -o pdes/thermal/feenox-bulk.obj `if test -f 'pdes/thermal/bulk.c'; then $(CYGPATH_W) 'pdes/thermal/bulk.c'; else $(CYGPATH_W) '$(srcdir)/pdes/thermal/bulk.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/thermal/$(DEPDIR)/feenox-bulk.Tpo pdes/thermal/$(DEPDIR)/feenox-bulk.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/thermal/bulk.c' object='pdes/thermal/feenox-bulk.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/thermal/feenox-bulk.obj `if test -f 'pdes/thermal/bulk.c'; then $(CYGPATH_W) 'pdes/thermal/bulk.c'; else $(CYGPATH_W) '$(srcdir)/pdes/thermal/bulk.c'; fi`
pdes/thermal/feenox-bc.o: pdes/thermal/bc.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/thermal/feenox-bc.o -MD -MP -MF pdes/thermal/$(DEPDIR)/feenox-bc.Tpo -c -o pdes/thermal/feenox-bc.o `test -f 'pdes/thermal/bc.c' || echo '$(srcdir)/'`pdes/thermal/bc.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/thermal/$(DEPDIR)/feenox-bc.Tpo pdes/thermal/$(DEPDIR)/feenox-bc.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/thermal/bc.c' object='pdes/thermal/feenox-bc.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/thermal/feenox-bc.o `test -f 'pdes/thermal/bc.c' || echo '$(srcdir)/'`pdes/thermal/bc.c
pdes/thermal/feenox-bc.obj: pdes/thermal/bc.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/thermal/feenox-bc.obj -MD -MP -MF pdes/thermal/$(DEPDIR)/feenox-bc.Tpo -c -o pdes/thermal/feenox-bc.obj `if test -f 'pdes/thermal/bc.c'; then $(CYGPATH_W) 'pdes/thermal/bc.c'; else $(CYGPATH_W) '$(srcdir)/pdes/thermal/bc.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/thermal/$(DEPDIR)/feenox-bc.Tpo pdes/thermal/$(DEPDIR)/feenox-bc.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/thermal/bc.c' object='pdes/thermal/feenox-bc.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/thermal/feenox-bc.obj `if test -f 'pdes/thermal/bc.c'; then $(CYGPATH_W) 'pdes/thermal/bc.c'; else $(CYGPATH_W) '$(srcdir)/pdes/thermal/bc.c'; fi`
pdes/feenox-solve.o: pdes/solve.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-solve.o -MD -MP -MF pdes/$(DEPDIR)/feenox-solve.Tpo -c -o pdes/feenox-solve.o `test -f 'pdes/solve.c' || echo '$(srcdir)/'`pdes/solve.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-solve.Tpo pdes/$(DEPDIR)/feenox-solve.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/solve.c' object='pdes/feenox-solve.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-solve.o `test -f 'pdes/solve.c' || echo '$(srcdir)/'`pdes/solve.c
pdes/feenox-solve.obj: pdes/solve.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-solve.obj -MD -MP -MF pdes/$(DEPDIR)/feenox-solve.Tpo -c -o pdes/feenox-solve.obj `if test -f 'pdes/solve.c'; then $(CYGPATH_W) 'pdes/solve.c'; else $(CYGPATH_W) '$(srcdir)/pdes/solve.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-solve.Tpo pdes/$(DEPDIR)/feenox-solve.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/solve.c' object='pdes/feenox-solve.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-solve.obj `if test -f 'pdes/solve.c'; then $(CYGPATH_W) 'pdes/solve.c'; else $(CYGPATH_W) '$(srcdir)/pdes/solve.c'; fi`
pdes/feenox-slepc_eps.o: pdes/slepc_eps.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-slepc_eps.o -MD -MP -MF pdes/$(DEPDIR)/feenox-slepc_eps.Tpo -c -o pdes/feenox-slepc_eps.o `test -f 'pdes/slepc_eps.c' || echo '$(srcdir)/'`pdes/slepc_eps.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-slepc_eps.Tpo pdes/$(DEPDIR)/feenox-slepc_eps.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/slepc_eps.c' object='pdes/feenox-slepc_eps.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-slepc_eps.o `test -f 'pdes/slepc_eps.c' || echo '$(srcdir)/'`pdes/slepc_eps.c
pdes/feenox-slepc_eps.obj: pdes/slepc_eps.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-slepc_eps.obj -MD -MP -MF pdes/$(DEPDIR)/feenox-slepc_eps.Tpo -c -o pdes/feenox-slepc_eps.obj `if test -f 'pdes/slepc_eps.c'; then $(CYGPATH_W) 'pdes/slepc_eps.c'; else $(CYGPATH_W) '$(srcdir)/pdes/slepc_eps.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-slepc_eps.Tpo pdes/$(DEPDIR)/feenox-slepc_eps.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/slepc_eps.c' object='pdes/feenox-slepc_eps.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-slepc_eps.obj `if test -f 'pdes/slepc_eps.c'; then $(CYGPATH_W) 'pdes/slepc_eps.c'; else $(CYGPATH_W) '$(srcdir)/pdes/slepc_eps.c'; fi`
pdes/feenox-reaction.o: pdes/reaction.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-reaction.o -MD -MP -MF pdes/$(DEPDIR)/feenox-reaction.Tpo -c -o pdes/feenox-reaction.o `test -f 'pdes/reaction.c' || echo '$(srcdir)/'`pdes/reaction.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-reaction.Tpo pdes/$(DEPDIR)/feenox-reaction.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/reaction.c' object='pdes/feenox-reaction.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-reaction.o `test -f 'pdes/reaction.c' || echo '$(srcdir)/'`pdes/reaction.c
pdes/feenox-reaction.obj: pdes/reaction.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-reaction.obj -MD -MP -MF pdes/$(DEPDIR)/feenox-reaction.Tpo -c -o pdes/feenox-reaction.obj `if test -f 'pdes/reaction.c'; then $(CYGPATH_W) 'pdes/reaction.c'; else $(CYGPATH_W) '$(srcdir)/pdes/reaction.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-reaction.Tpo pdes/$(DEPDIR)/feenox-reaction.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/reaction.c' object='pdes/feenox-reaction.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-reaction.obj `if test -f 'pdes/reaction.c'; then $(CYGPATH_W) 'pdes/reaction.c'; else $(CYGPATH_W) '$(srcdir)/pdes/reaction.c'; fi`
pdes/feenox-petsc_ts.o: pdes/petsc_ts.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-petsc_ts.o -MD -MP -MF pdes/$(DEPDIR)/feenox-petsc_ts.Tpo -c -o pdes/feenox-petsc_ts.o `test -f 'pdes/petsc_ts.c' || echo '$(srcdir)/'`pdes/petsc_ts.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-petsc_ts.Tpo pdes/$(DEPDIR)/feenox-petsc_ts.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/petsc_ts.c' object='pdes/feenox-petsc_ts.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-petsc_ts.o `test -f 'pdes/petsc_ts.c' || echo '$(srcdir)/'`pdes/petsc_ts.c
pdes/feenox-petsc_ts.obj: pdes/petsc_ts.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-petsc_ts.obj -MD -MP -MF pdes/$(DEPDIR)/feenox-petsc_ts.Tpo -c -o pdes/feenox-petsc_ts.obj `if test -f 'pdes/petsc_ts.c'; then $(CYGPATH_W) 'pdes/petsc_ts.c'; else $(CYGPATH_W) '$(srcdir)/pdes/petsc_ts.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-petsc_ts.Tpo pdes/$(DEPDIR)/feenox-petsc_ts.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/petsc_ts.c' object='pdes/feenox-petsc_ts.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-petsc_ts.obj `if test -f 'pdes/petsc_ts.c'; then $(CYGPATH_W) 'pdes/petsc_ts.c'; else $(CYGPATH_W) '$(srcdir)/pdes/petsc_ts.c'; fi`
pdes/feenox-petsc_snes.o: pdes/petsc_snes.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-petsc_snes.o -MD -MP -MF pdes/$(DEPDIR)/feenox-petsc_snes.Tpo -c -o pdes/feenox-petsc_snes.o `test -f 'pdes/petsc_snes.c' || echo '$(srcdir)/'`pdes/petsc_snes.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-petsc_snes.Tpo pdes/$(DEPDIR)/feenox-petsc_snes.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/petsc_snes.c' object='pdes/feenox-petsc_snes.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-petsc_snes.o `test -f 'pdes/petsc_snes.c' || echo '$(srcdir)/'`pdes/petsc_snes.c
pdes/feenox-petsc_snes.obj: pdes/petsc_snes.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-petsc_snes.obj -MD -MP -MF pdes/$(DEPDIR)/feenox-petsc_snes.Tpo -c -o pdes/feenox-petsc_snes.obj `if test -f 'pdes/petsc_snes.c'; then $(CYGPATH_W) 'pdes/petsc_snes.c'; else $(CYGPATH_W) '$(srcdir)/pdes/petsc_snes.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-petsc_snes.Tpo pdes/$(DEPDIR)/feenox-petsc_snes.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/petsc_snes.c' object='pdes/feenox-petsc_snes.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-petsc_snes.obj `if test -f 'pdes/petsc_snes.c'; then $(CYGPATH_W) 'pdes/petsc_snes.c'; else $(CYGPATH_W) '$(srcdir)/pdes/petsc_snes.c'; fi`
pdes/feenox-petsc_ksp.o: pdes/petsc_ksp.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-petsc_ksp.o -MD -MP -MF pdes/$(DEPDIR)/feenox-petsc_ksp.Tpo -c -o pdes/feenox-petsc_ksp.o `test -f 'pdes/petsc_ksp.c' || echo '$(srcdir)/'`pdes/petsc_ksp.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-petsc_ksp.Tpo pdes/$(DEPDIR)/feenox-petsc_ksp.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/petsc_ksp.c' object='pdes/feenox-petsc_ksp.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-petsc_ksp.o `test -f 'pdes/petsc_ksp.c' || echo '$(srcdir)/'`pdes/petsc_ksp.c
pdes/feenox-petsc_ksp.obj: pdes/petsc_ksp.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-petsc_ksp.obj -MD -MP -MF pdes/$(DEPDIR)/feenox-petsc_ksp.Tpo -c -o pdes/feenox-petsc_ksp.obj `if test -f 'pdes/petsc_ksp.c'; then $(CYGPATH_W) 'pdes/petsc_ksp.c'; else $(CYGPATH_W) '$(srcdir)/pdes/petsc_ksp.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-petsc_ksp.Tpo pdes/$(DEPDIR)/feenox-petsc_ksp.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/petsc_ksp.c' object='pdes/feenox-petsc_ksp.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-petsc_ksp.obj `if test -f 'pdes/petsc_ksp.c'; then $(CYGPATH_W) 'pdes/petsc_ksp.c'; else $(CYGPATH_W) '$(srcdir)/pdes/petsc_ksp.c'; fi`
pdes/neutron_sn/feenox-post.o: pdes/neutron_sn/post.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_sn/feenox-post.o -MD -MP -MF pdes/neutron_sn/$(DEPDIR)/feenox-post.Tpo -c -o pdes/neutron_sn/feenox-post.o `test -f 'pdes/neutron_sn/post.c' || echo '$(srcdir)/'`pdes/neutron_sn/post.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_sn/$(DEPDIR)/feenox-post.Tpo pdes/neutron_sn/$(DEPDIR)/feenox-post.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_sn/post.c' object='pdes/neutron_sn/feenox-post.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_sn/feenox-post.o `test -f 'pdes/neutron_sn/post.c' || echo '$(srcdir)/'`pdes/neutron_sn/post.c
pdes/neutron_sn/feenox-post.obj: pdes/neutron_sn/post.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_sn/feenox-post.obj -MD -MP -MF pdes/neutron_sn/$(DEPDIR)/feenox-post.Tpo -c -o pdes/neutron_sn/feenox-post.obj `if test -f 'pdes/neutron_sn/post.c'; then $(CYGPATH_W) 'pdes/neutron_sn/post.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_sn/post.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_sn/$(DEPDIR)/feenox-post.Tpo pdes/neutron_sn/$(DEPDIR)/feenox-post.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_sn/post.c' object='pdes/neutron_sn/feenox-post.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_sn/feenox-post.obj `if test -f 'pdes/neutron_sn/post.c'; then $(CYGPATH_W) 'pdes/neutron_sn/post.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_sn/post.c'; fi`
pdes/neutron_sn/feenox-parser.o: pdes/neutron_sn/parser.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_sn/feenox-parser.o -MD -MP -MF pdes/neutron_sn/$(DEPDIR)/feenox-parser.Tpo -c -o pdes/neutron_sn/feenox-parser.o `test -f 'pdes/neutron_sn/parser.c' || echo '$(srcdir)/'`pdes/neutron_sn/parser.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_sn/$(DEPDIR)/feenox-parser.Tpo pdes/neutron_sn/$(DEPDIR)/feenox-parser.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_sn/parser.c' object='pdes/neutron_sn/feenox-parser.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_sn/feenox-parser.o `test -f 'pdes/neutron_sn/parser.c' || echo '$(srcdir)/'`pdes/neutron_sn/parser.c
pdes/neutron_sn/feenox-parser.obj: pdes/neutron_sn/parser.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_sn/feenox-parser.obj -MD -MP -MF pdes/neutron_sn/$(DEPDIR)/feenox-parser.Tpo -c -o pdes/neutron_sn/feenox-parser.obj `if test -f 'pdes/neutron_sn/parser.c'; then $(CYGPATH_W) 'pdes/neutron_sn/parser.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_sn/parser.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_sn/$(DEPDIR)/feenox-parser.Tpo pdes/neutron_sn/$(DEPDIR)/feenox-parser.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_sn/parser.c' object='pdes/neutron_sn/feenox-parser.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_sn/feenox-parser.obj `if test -f 'pdes/neutron_sn/parser.c'; then $(CYGPATH_W) 'pdes/neutron_sn/parser.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_sn/parser.c'; fi`
pdes/neutron_sn/feenox-init.o: pdes/neutron_sn/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_sn/feenox-init.o -MD -MP -MF pdes/neutron_sn/$(DEPDIR)/feenox-init.Tpo -c -o pdes/neutron_sn/feenox-init.o `test -f 'pdes/neutron_sn/init.c' || echo '$(srcdir)/'`pdes/neutron_sn/init.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_sn/$(DEPDIR)/feenox-init.Tpo pdes/neutron_sn/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_sn/init.c' object='pdes/neutron_sn/feenox-init.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_sn/feenox-init.o `test -f 'pdes/neutron_sn/init.c' || echo '$(srcdir)/'`pdes/neutron_sn/init.c
pdes/neutron_sn/feenox-init.obj: pdes/neutron_sn/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_sn/feenox-init.obj -MD -MP -MF pdes/neutron_sn/$(DEPDIR)/feenox-init.Tpo -c -o pdes/neutron_sn/feenox-init.obj `if test -f 'pdes/neutron_sn/init.c'; then $(CYGPATH_W) 'pdes/neutron_sn/init.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_sn/init.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_sn/$(DEPDIR)/feenox-init.Tpo pdes/neutron_sn/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_sn/init.c' object='pdes/neutron_sn/feenox-init.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_sn/feenox-init.obj `if test -f 'pdes/neutron_sn/init.c'; then $(CYGPATH_W) 'pdes/neutron_sn/init.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_sn/init.c'; fi`
pdes/neutron_sn/feenox-bulk.o: pdes/neutron_sn/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_sn/feenox-bulk.o -MD -MP -MF pdes/neutron_sn/$(DEPDIR)/feenox-bulk.Tpo -c -o pdes/neutron_sn/feenox-bulk.o `test -f 'pdes/neutron_sn/bulk.c' || echo '$(srcdir)/'`pdes/neutron_sn/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_sn/$(DEPDIR)/feenox-bulk.Tpo pdes/neutron_sn/$(DEPDIR)/feenox-bulk.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_sn/bulk.c' object='pdes/neutron_sn/feenox-bulk.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_sn/feenox-bulk.o `test -f 'pdes/neutron_sn/bulk.c' || echo '$(srcdir)/'`pdes/neutron_sn/bulk.c
pdes/neutron_sn/feenox-bulk.obj: pdes/neutron_sn/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_sn/feenox-bulk.obj -MD -MP -MF pdes/neutron_sn/$(DEPDIR)/feenox-bulk.Tpo -c -o pdes/neutron_sn/feenox-bulk.obj `if test -f 'pdes/neutron_sn/bulk.c'; then $(CYGPATH_W) 'pdes/neutron_sn/bulk.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_sn/bulk.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_sn/$(DEPDIR)/feenox-bulk.Tpo pdes/neutron_sn/$(DEPDIR)/feenox-bulk.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_sn/bulk.c' object='pdes/neutron_sn/feenox-bulk.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_sn/feenox-bulk.obj `if test -f 'pdes/neutron_sn/bulk.c'; then $(CYGPATH_W) 'pdes/neutron_sn/bulk.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_sn/bulk.c'; fi`
pdes/neutron_sn/feenox-bc.o: pdes/neutron_sn/bc.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_sn/feenox-bc.o -MD -MP -MF pdes/neutron_sn/$(DEPDIR)/feenox-bc.Tpo -c -o pdes/neutron_sn/feenox-bc.o `test -f 'pdes/neutron_sn/bc.c' || echo '$(srcdir)/'`pdes/neutron_sn/bc.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_sn/$(DEPDIR)/feenox-bc.Tpo pdes/neutron_sn/$(DEPDIR)/feenox-bc.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_sn/bc.c' object='pdes/neutron_sn/feenox-bc.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_sn/feenox-bc.o `test -f 'pdes/neutron_sn/bc.c' || echo '$(srcdir)/'`pdes/neutron_sn/bc.c
pdes/neutron_sn/feenox-bc.obj: pdes/neutron_sn/bc.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_sn/feenox-bc.obj -MD -MP -MF pdes/neutron_sn/$(DEPDIR)/feenox-bc.Tpo -c -o pdes/neutron_sn/feenox-bc.obj `if test -f 'pdes/neutron_sn/bc.c'; then $(CYGPATH_W) 'pdes/neutron_sn/bc.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_sn/bc.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_sn/$(DEPDIR)/feenox-bc.Tpo pdes/neutron_sn/$(DEPDIR)/feenox-bc.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_sn/bc.c' object='pdes/neutron_sn/feenox-bc.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_sn/feenox-bc.obj `if test -f 'pdes/neutron_sn/bc.c'; then $(CYGPATH_W) 'pdes/neutron_sn/bc.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_sn/bc.c'; fi`
pdes/neutron_diffusion/feenox-post.o: pdes/neutron_diffusion/post.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_diffusion/feenox-post.o -MD -MP -MF pdes/neutron_diffusion/$(DEPDIR)/feenox-post.Tpo -c -o pdes/neutron_diffusion/feenox-post.o `test -f 'pdes/neutron_diffusion/post.c' || echo '$(srcdir)/'`pdes/neutron_diffusion/post.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_diffusion/$(DEPDIR)/feenox-post.Tpo pdes/neutron_diffusion/$(DEPDIR)/feenox-post.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_diffusion/post.c' object='pdes/neutron_diffusion/feenox-post.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_diffusion/feenox-post.o `test -f 'pdes/neutron_diffusion/post.c' || echo '$(srcdir)/'`pdes/neutron_diffusion/post.c
pdes/neutron_diffusion/feenox-post.obj: pdes/neutron_diffusion/post.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_diffusion/feenox-post.obj -MD -MP -MF pdes/neutron_diffusion/$(DEPDIR)/feenox-post.Tpo -c -o pdes/neutron_diffusion/feenox-post.obj `if test -f 'pdes/neutron_diffusion/post.c'; then $(CYGPATH_W) 'pdes/neutron_diffusion/post.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_diffusion/post.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_diffusion/$(DEPDIR)/feenox-post.Tpo pdes/neutron_diffusion/$(DEPDIR)/feenox-post.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_diffusion/post.c' object='pdes/neutron_diffusion/feenox-post.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_diffusion/feenox-post.obj `if test -f 'pdes/neutron_diffusion/post.c'; then $(CYGPATH_W) 'pdes/neutron_diffusion/post.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_diffusion/post.c'; fi`
pdes/neutron_diffusion/feenox-parser.o: pdes/neutron_diffusion/parser.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_diffusion/feenox-parser.o -MD -MP -MF pdes/neutron_diffusion/$(DEPDIR)/feenox-parser.Tpo -c -o pdes/neutron_diffusion/feenox-parser.o `test -f 'pdes/neutron_diffusion/parser.c' || echo '$(srcdir)/'`pdes/neutron_diffusion/parser.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_diffusion/$(DEPDIR)/feenox-parser.Tpo pdes/neutron_diffusion/$(DEPDIR)/feenox-parser.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_diffusion/parser.c' object='pdes/neutron_diffusion/feenox-parser.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_diffusion/feenox-parser.o `test -f 'pdes/neutron_diffusion/parser.c' || echo '$(srcdir)/'`pdes/neutron_diffusion/parser.c
pdes/neutron_diffusion/feenox-parser.obj: pdes/neutron_diffusion/parser.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_diffusion/feenox-parser.obj -MD -MP -MF pdes/neutron_diffusion/$(DEPDIR)/feenox-parser.Tpo -c -o pdes/neutron_diffusion/feenox-parser.obj `if test -f 'pdes/neutron_diffusion/parser.c'; then $(CYGPATH_W) 'pdes/neutron_diffusion/parser.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_diffusion/parser.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_diffusion/$(DEPDIR)/feenox-parser.Tpo pdes/neutron_diffusion/$(DEPDIR)/feenox-parser.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_diffusion/parser.c' object='pdes/neutron_diffusion/feenox-parser.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_diffusion/feenox-parser.obj `if test -f 'pdes/neutron_diffusion/parser.c'; then $(CYGPATH_W) 'pdes/neutron_diffusion/parser.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_diffusion/parser.c'; fi`
pdes/neutron_diffusion/feenox-init.o: pdes/neutron_diffusion/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_diffusion/feenox-init.o -MD -MP -MF pdes/neutron_diffusion/$(DEPDIR)/feenox-init.Tpo -c -o pdes/neutron_diffusion/feenox-init.o `test -f 'pdes/neutron_diffusion/init.c' || echo '$(srcdir)/'`pdes/neutron_diffusion/init.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_diffusion/$(DEPDIR)/feenox-init.Tpo pdes/neutron_diffusion/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_diffusion/init.c' object='pdes/neutron_diffusion/feenox-init.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_diffusion/feenox-init.o `test -f 'pdes/neutron_diffusion/init.c' || echo '$(srcdir)/'`pdes/neutron_diffusion/init.c
pdes/neutron_diffusion/feenox-init.obj: pdes/neutron_diffusion/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_diffusion/feenox-init.obj -MD -MP -MF pdes/neutron_diffusion/$(DEPDIR)/feenox-init.Tpo -c -o pdes/neutron_diffusion/feenox-init.obj `if test -f 'pdes/neutron_diffusion/init.c'; then $(CYGPATH_W) 'pdes/neutron_diffusion/init.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_diffusion/init.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_diffusion/$(DEPDIR)/feenox-init.Tpo pdes/neutron_diffusion/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_diffusion/init.c' object='pdes/neutron_diffusion/feenox-init.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_diffusion/feenox-init.obj `if test -f 'pdes/neutron_diffusion/init.c'; then $(CYGPATH_W) 'pdes/neutron_diffusion/init.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_diffusion/init.c'; fi`
pdes/neutron_diffusion/feenox-currents.o: pdes/neutron_diffusion/currents.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_diffusion/feenox-currents.o -MD -MP -MF pdes/neutron_diffusion/$(DEPDIR)/feenox-currents.Tpo -c -o pdes/neutron_diffusion/feenox-currents.o `test -f 'pdes/neutron_diffusion/currents.c' || echo '$(srcdir)/'`pdes/neutron_diffusion/currents.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_diffusion/$(DEPDIR)/feenox-currents.Tpo pdes/neutron_diffusion/$(DEPDIR)/feenox-currents.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_diffusion/currents.c' object='pdes/neutron_diffusion/feenox-currents.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_diffusion/feenox-currents.o `test -f 'pdes/neutron_diffusion/currents.c' || echo '$(srcdir)/'`pdes/neutron_diffusion/currents.c
pdes/neutron_diffusion/feenox-currents.obj: pdes/neutron_diffusion/currents.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_diffusion/feenox-currents.obj -MD -MP -MF pdes/neutron_diffusion/$(DEPDIR)/feenox-currents.Tpo -c -o pdes/neutron_diffusion/feenox-currents.obj `if test -f 'pdes/neutron_diffusion/currents.c'; then $(CYGPATH_W) 'pdes/neutron_diffusion/currents.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_diffusion/currents.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_diffusion/$(DEPDIR)/feenox-currents.Tpo pdes/neutron_diffusion/$(DEPDIR)/feenox-currents.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_diffusion/currents.c' object='pdes/neutron_diffusion/feenox-currents.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_diffusion/feenox-currents.obj `if test -f 'pdes/neutron_diffusion/currents.c'; then $(CYGPATH_W) 'pdes/neutron_diffusion/currents.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_diffusion/currents.c'; fi`
pdes/neutron_diffusion/feenox-bulk.o: pdes/neutron_diffusion/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_diffusion/feenox-bulk.o -MD -MP -MF pdes/neutron_diffusion/$(DEPDIR)/feenox-bulk.Tpo -c -o pdes/neutron_diffusion/feenox-bulk.o `test -f 'pdes/neutron_diffusion/bulk.c' || echo '$(srcdir)/'`pdes/neutron_diffusion/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_diffusion/$(DEPDIR)/feenox-bulk.Tpo pdes/neutron_diffusion/$(DEPDIR)/feenox-bulk.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_diffusion/bulk.c' object='pdes/neutron_diffusion/feenox-bulk.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_diffusion/feenox-bulk.o `test -f 'pdes/neutron_diffusion/bulk.c' || echo '$(srcdir)/'`pdes/neutron_diffusion/bulk.c
pdes/neutron_diffusion/feenox-bulk.obj: pdes/neutron_diffusion/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_diffusion/feenox-bulk.obj -MD -MP -MF pdes/neutron_diffusion/$(DEPDIR)/feenox-bulk.Tpo -c -o pdes/neutron_diffusion/feenox-bulk.obj `if test -f 'pdes/neutron_diffusion/bulk.c'; then $(CYGPATH_W) 'pdes/neutron_diffusion/bulk.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_diffusion/bulk.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_diffusion/$(DEPDIR)/feenox-bulk.Tpo pdes/neutron_diffusion/$(DEPDIR)/feenox-bulk.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_diffusion/bulk.c' object='pdes/neutron_diffusion/feenox-bulk.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_diffusion/feenox-bulk.obj `if test -f 'pdes/neutron_diffusion/bulk.c'; then $(CYGPATH_W) 'pdes/neutron_diffusion/bulk.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_diffusion/bulk.c'; fi`
pdes/neutron_diffusion/feenox-bc.o: pdes/neutron_diffusion/bc.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_diffusion/feenox-bc.o -MD -MP -MF pdes/neutron_diffusion/$(DEPDIR)/feenox-bc.Tpo -c -o pdes/neutron_diffusion/feenox-bc.o `test -f 'pdes/neutron_diffusion/bc.c' || echo '$(srcdir)/'`pdes/neutron_diffusion/bc.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_diffusion/$(DEPDIR)/feenox-bc.Tpo pdes/neutron_diffusion/$(DEPDIR)/feenox-bc.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_diffusion/bc.c' object='pdes/neutron_diffusion/feenox-bc.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_diffusion/feenox-bc.o `test -f 'pdes/neutron_diffusion/bc.c' || echo '$(srcdir)/'`pdes/neutron_diffusion/bc.c
pdes/neutron_diffusion/feenox-bc.obj: pdes/neutron_diffusion/bc.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/neutron_diffusion/feenox-bc.obj -MD -MP -MF pdes/neutron_diffusion/$(DEPDIR)/feenox-bc.Tpo -c -o pdes/neutron_diffusion/feenox-bc.obj `if test -f 'pdes/neutron_diffusion/bc.c'; then $(CYGPATH_W) 'pdes/neutron_diffusion/bc.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_diffusion/bc.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/neutron_diffusion/$(DEPDIR)/feenox-bc.Tpo pdes/neutron_diffusion/$(DEPDIR)/feenox-bc.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/neutron_diffusion/bc.c' object='pdes/neutron_diffusion/feenox-bc.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/neutron_diffusion/feenox-bc.obj `if test -f 'pdes/neutron_diffusion/bc.c'; then $(CYGPATH_W) 'pdes/neutron_diffusion/bc.c'; else $(CYGPATH_W) '$(srcdir)/pdes/neutron_diffusion/bc.c'; fi`
pdes/modal/feenox-post.o: pdes/modal/post.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-post.o -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-post.Tpo -c -o pdes/modal/feenox-post.o `test -f 'pdes/modal/post.c' || echo '$(srcdir)/'`pdes/modal/post.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-post.Tpo pdes/modal/$(DEPDIR)/feenox-post.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/post.c' object='pdes/modal/feenox-post.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-post.o `test -f 'pdes/modal/post.c' || echo '$(srcdir)/'`pdes/modal/post.c
pdes/modal/feenox-post.obj: pdes/modal/post.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-post.obj -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-post.Tpo -c -o pdes/modal/feenox-post.obj `if test -f 'pdes/modal/post.c'; then $(CYGPATH_W) 'pdes/modal/post.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/post.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-post.Tpo pdes/modal/$(DEPDIR)/feenox-post.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/post.c' object='pdes/modal/feenox-post.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-post.obj `if test -f 'pdes/modal/post.c'; then $(CYGPATH_W) 'pdes/modal/post.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/post.c'; fi`
pdes/modal/feenox-parser.o: pdes/modal/parser.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-parser.o -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-parser.Tpo -c -o pdes/modal/feenox-parser.o `test -f 'pdes/modal/parser.c' || echo '$(srcdir)/'`pdes/modal/parser.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-parser.Tpo pdes/modal/$(DEPDIR)/feenox-parser.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/parser.c' object='pdes/modal/feenox-parser.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-parser.o `test -f 'pdes/modal/parser.c' || echo '$(srcdir)/'`pdes/modal/parser.c
pdes/modal/feenox-parser.obj: pdes/modal/parser.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-parser.obj -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-parser.Tpo -c -o pdes/modal/feenox-parser.obj `if test -f 'pdes/modal/parser.c'; then $(CYGPATH_W) 'pdes/modal/parser.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/parser.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-parser.Tpo pdes/modal/$(DEPDIR)/feenox-parser.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/parser.c' object='pdes/modal/feenox-parser.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-parser.obj `if test -f 'pdes/modal/parser.c'; then $(CYGPATH_W) 'pdes/modal/parser.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/parser.c'; fi`
pdes/modal/feenox-init.o: pdes/modal/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-init.o -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-init.Tpo -c -o pdes/modal/feenox-init.o `test -f 'pdes/modal/init.c' || echo '$(srcdir)/'`pdes/modal/init.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-init.Tpo pdes/modal/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/init.c' object='pdes/modal/feenox-init.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-init.o `test -f 'pdes/modal/init.c' || echo '$(srcdir)/'`pdes/modal/init.c
pdes/modal/feenox-init.obj: pdes/modal/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-init.obj -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-init.Tpo -c -o pdes/modal/feenox-init.obj `if test -f 'pdes/modal/init.c'; then $(CYGPATH_W) 'pdes/modal/init.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/init.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-init.Tpo pdes/modal/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/init.c' object='pdes/modal/feenox-init.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-init.obj `if test -f 'pdes/modal/init.c'; then $(CYGPATH_W) 'pdes/modal/init.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/init.c'; fi`
pdes/modal/feenox-elastic-plane-stress.o: pdes/modal/elastic-plane-stress.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-elastic-plane-stress.o -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-elastic-plane-stress.Tpo -c -o pdes/modal/feenox-elastic-plane-stress.o `test -f 'pdes/modal/elastic-plane-stress.c' || echo '$(srcdir)/'`pdes/modal/elastic-plane-stress.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-elastic-plane-stress.Tpo pdes/modal/$(DEPDIR)/feenox-elastic-plane-stress.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/elastic-plane-stress.c' object='pdes/modal/feenox-elastic-plane-stress.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-elastic-plane-stress.o `test -f 'pdes/modal/elastic-plane-stress.c' || echo '$(srcdir)/'`pdes/modal/elastic-plane-stress.c
pdes/modal/feenox-elastic-plane-stress.obj: pdes/modal/elastic-plane-stress.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-elastic-plane-stress.obj -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-elastic-plane-stress.Tpo -c -o pdes/modal/feenox-elastic-plane-stress.obj `if test -f 'pdes/modal/elastic-plane-stress.c'; then $(CYGPATH_W) 'pdes/modal/elastic-plane-stress.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/elastic-plane-stress.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-elastic-plane-stress.Tpo pdes/modal/$(DEPDIR)/feenox-elastic-plane-stress.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/elastic-plane-stress.c' object='pdes/modal/feenox-elastic-plane-stress.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-elastic-plane-stress.obj `if test -f 'pdes/modal/elastic-plane-stress.c'; then $(CYGPATH_W) 'pdes/modal/elastic-plane-stress.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/elastic-plane-stress.c'; fi`
pdes/modal/feenox-elastic-plane-strain.o: pdes/modal/elastic-plane-strain.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-elastic-plane-strain.o -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-elastic-plane-strain.Tpo -c -o pdes/modal/feenox-elastic-plane-strain.o `test -f 'pdes/modal/elastic-plane-strain.c' || echo '$(srcdir)/'`pdes/modal/elastic-plane-strain.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-elastic-plane-strain.Tpo pdes/modal/$(DEPDIR)/feenox-elastic-plane-strain.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/elastic-plane-strain.c' object='pdes/modal/feenox-elastic-plane-strain.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-elastic-plane-strain.o `test -f 'pdes/modal/elastic-plane-strain.c' || echo '$(srcdir)/'`pdes/modal/elastic-plane-strain.c
pdes/modal/feenox-elastic-plane-strain.obj: pdes/modal/elastic-plane-strain.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-elastic-plane-strain.obj -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-elastic-plane-strain.Tpo -c -o pdes/modal/feenox-elastic-plane-strain.obj `if test -f 'pdes/modal/elastic-plane-strain.c'; then $(CYGPATH_W) 'pdes/modal/elastic-plane-strain.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/elastic-plane-strain.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-elastic-plane-strain.Tpo pdes/modal/$(DEPDIR)/feenox-elastic-plane-strain.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/elastic-plane-strain.c' object='pdes/modal/feenox-elastic-plane-strain.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-elastic-plane-strain.obj `if test -f 'pdes/modal/elastic-plane-strain.c'; then $(CYGPATH_W) 'pdes/modal/elastic-plane-strain.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/elastic-plane-strain.c'; fi`
pdes/modal/feenox-elastic-orthotropic.o: pdes/modal/elastic-orthotropic.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-elastic-orthotropic.o -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-elastic-orthotropic.Tpo -c -o pdes/modal/feenox-elastic-orthotropic.o `test -f 'pdes/modal/elastic-orthotropic.c' || echo '$(srcdir)/'`pdes/modal/elastic-orthotropic.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-elastic-orthotropic.Tpo pdes/modal/$(DEPDIR)/feenox-elastic-orthotropic.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/elastic-orthotropic.c' object='pdes/modal/feenox-elastic-orthotropic.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-elastic-orthotropic.o `test -f 'pdes/modal/elastic-orthotropic.c' || echo '$(srcdir)/'`pdes/modal/elastic-orthotropic.c
pdes/modal/feenox-elastic-orthotropic.obj: pdes/modal/elastic-orthotropic.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-elastic-orthotropic.obj -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-elastic-orthotropic.Tpo -c -o pdes/modal/feenox-elastic-orthotropic.obj `if test -f 'pdes/modal/elastic-orthotropic.c'; then $(CYGPATH_W) 'pdes/modal/elastic-orthotropic.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/elastic-orthotropic.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-elastic-orthotropic.Tpo pdes/modal/$(DEPDIR)/feenox-elastic-orthotropic.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/elastic-orthotropic.c' object='pdes/modal/feenox-elastic-orthotropic.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-elastic-orthotropic.obj `if test -f 'pdes/modal/elastic-orthotropic.c'; then $(CYGPATH_W) 'pdes/modal/elastic-orthotropic.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/elastic-orthotropic.c'; fi`
pdes/modal/feenox-elastic-isotropic.o: pdes/modal/elastic-isotropic.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-elastic-isotropic.o -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-elastic-isotropic.Tpo -c -o pdes/modal/feenox-elastic-isotropic.o `test -f 'pdes/modal/elastic-isotropic.c' || echo '$(srcdir)/'`pdes/modal/elastic-isotropic.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-elastic-isotropic.Tpo pdes/modal/$(DEPDIR)/feenox-elastic-isotropic.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/elastic-isotropic.c' object='pdes/modal/feenox-elastic-isotropic.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-elastic-isotropic.o `test -f 'pdes/modal/elastic-isotropic.c' || echo '$(srcdir)/'`pdes/modal/elastic-isotropic.c
pdes/modal/feenox-elastic-isotropic.obj: pdes/modal/elastic-isotropic.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-elastic-isotropic.obj -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-elastic-isotropic.Tpo -c -o pdes/modal/feenox-elastic-isotropic.obj `if test -f 'pdes/modal/elastic-isotropic.c'; then $(CYGPATH_W) 'pdes/modal/elastic-isotropic.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/elastic-isotropic.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-elastic-isotropic.Tpo pdes/modal/$(DEPDIR)/feenox-elastic-isotropic.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/elastic-isotropic.c' object='pdes/modal/feenox-elastic-isotropic.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-elastic-isotropic.obj `if test -f 'pdes/modal/elastic-isotropic.c'; then $(CYGPATH_W) 'pdes/modal/elastic-isotropic.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/elastic-isotropic.c'; fi`
pdes/modal/feenox-bulk.o: pdes/modal/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-bulk.o -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-bulk.Tpo -c -o pdes/modal/feenox-bulk.o `test -f 'pdes/modal/bulk.c' || echo '$(srcdir)/'`pdes/modal/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-bulk.Tpo pdes/modal/$(DEPDIR)/feenox-bulk.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/bulk.c' object='pdes/modal/feenox-bulk.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-bulk.o `test -f 'pdes/modal/bulk.c' || echo '$(srcdir)/'`pdes/modal/bulk.c
pdes/modal/feenox-bulk.obj: pdes/modal/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-bulk.obj -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-bulk.Tpo -c -o pdes/modal/feenox-bulk.obj `if test -f 'pdes/modal/bulk.c'; then $(CYGPATH_W) 'pdes/modal/bulk.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/bulk.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-bulk.Tpo pdes/modal/$(DEPDIR)/feenox-bulk.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/bulk.c' object='pdes/modal/feenox-bulk.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-bulk.obj `if test -f 'pdes/modal/bulk.c'; then $(CYGPATH_W) 'pdes/modal/bulk.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/bulk.c'; fi`
pdes/modal/feenox-bc.o: pdes/modal/bc.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-bc.o -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-bc.Tpo -c -o pdes/modal/feenox-bc.o `test -f 'pdes/modal/bc.c' || echo '$(srcdir)/'`pdes/modal/bc.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-bc.Tpo pdes/modal/$(DEPDIR)/feenox-bc.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/bc.c' object='pdes/modal/feenox-bc.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-bc.o `test -f 'pdes/modal/bc.c' || echo '$(srcdir)/'`pdes/modal/bc.c
pdes/modal/feenox-bc.obj: pdes/modal/bc.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/modal/feenox-bc.obj -MD -MP -MF pdes/modal/$(DEPDIR)/feenox-bc.Tpo -c -o pdes/modal/feenox-bc.obj `if test -f 'pdes/modal/bc.c'; then $(CYGPATH_W) 'pdes/modal/bc.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/bc.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/modal/$(DEPDIR)/feenox-bc.Tpo pdes/modal/$(DEPDIR)/feenox-bc.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/modal/bc.c' object='pdes/modal/feenox-bc.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/modal/feenox-bc.obj `if test -f 'pdes/modal/bc.c'; then $(CYGPATH_W) 'pdes/modal/bc.c'; else $(CYGPATH_W) '$(srcdir)/pdes/modal/bc.c'; fi`
pdes/mechanical/feenox-stress.o: pdes/mechanical/stress.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-stress.o -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-stress.Tpo -c -o pdes/mechanical/feenox-stress.o `test -f 'pdes/mechanical/stress.c' || echo '$(srcdir)/'`pdes/mechanical/stress.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-stress.Tpo pdes/mechanical/$(DEPDIR)/feenox-stress.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/stress.c' object='pdes/mechanical/feenox-stress.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-stress.o `test -f 'pdes/mechanical/stress.c' || echo '$(srcdir)/'`pdes/mechanical/stress.c
pdes/mechanical/feenox-stress.obj: pdes/mechanical/stress.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-stress.obj -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-stress.Tpo -c -o pdes/mechanical/feenox-stress.obj `if test -f 'pdes/mechanical/stress.c'; then $(CYGPATH_W) 'pdes/mechanical/stress.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/stress.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-stress.Tpo pdes/mechanical/$(DEPDIR)/feenox-stress.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/stress.c' object='pdes/mechanical/feenox-stress.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-stress.obj `if test -f 'pdes/mechanical/stress.c'; then $(CYGPATH_W) 'pdes/mechanical/stress.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/stress.c'; fi`
pdes/mechanical/feenox-strain.o: pdes/mechanical/strain.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-strain.o -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-strain.Tpo -c -o pdes/mechanical/feenox-strain.o `test -f 'pdes/mechanical/strain.c' || echo '$(srcdir)/'`pdes/mechanical/strain.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-strain.Tpo pdes/mechanical/$(DEPDIR)/feenox-strain.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/strain.c' object='pdes/mechanical/feenox-strain.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-strain.o `test -f 'pdes/mechanical/strain.c' || echo '$(srcdir)/'`pdes/mechanical/strain.c
pdes/mechanical/feenox-strain.obj: pdes/mechanical/strain.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-strain.obj -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-strain.Tpo -c -o pdes/mechanical/feenox-strain.obj `if test -f 'pdes/mechanical/strain.c'; then $(CYGPATH_W) 'pdes/mechanical/strain.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/strain.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-strain.Tpo pdes/mechanical/$(DEPDIR)/feenox-strain.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/strain.c' object='pdes/mechanical/feenox-strain.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-strain.obj `if test -f 'pdes/mechanical/strain.c'; then $(CYGPATH_W) 'pdes/mechanical/strain.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/strain.c'; fi`
pdes/mechanical/feenox-post.o: pdes/mechanical/post.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-post.o -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-post.Tpo -c -o pdes/mechanical/feenox-post.o `test -f 'pdes/mechanical/post.c' || echo '$(srcdir)/'`pdes/mechanical/post.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-post.Tpo pdes/mechanical/$(DEPDIR)/feenox-post.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/post.c' object='pdes/mechanical/feenox-post.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-post.o `test -f 'pdes/mechanical/post.c' || echo '$(srcdir)/'`pdes/mechanical/post.c
pdes/mechanical/feenox-post.obj: pdes/mechanical/post.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-post.obj -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-post.Tpo -c -o pdes/mechanical/feenox-post.obj `if test -f 'pdes/mechanical/post.c'; then $(CYGPATH_W) 'pdes/mechanical/post.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/post.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-post.Tpo pdes/mechanical/$(DEPDIR)/feenox-post.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/post.c' object='pdes/mechanical/feenox-post.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-post.obj `if test -f 'pdes/mechanical/post.c'; then $(CYGPATH_W) 'pdes/mechanical/post.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/post.c'; fi`
pdes/mechanical/feenox-parser.o: pdes/mechanical/parser.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-parser.o -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-parser.Tpo -c -o pdes/mechanical/feenox-parser.o `test -f 'pdes/mechanical/parser.c' || echo '$(srcdir)/'`pdes/mechanical/parser.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-parser.Tpo pdes/mechanical/$(DEPDIR)/feenox-parser.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/parser.c' object='pdes/mechanical/feenox-parser.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-parser.o `test -f 'pdes/mechanical/parser.c' || echo '$(srcdir)/'`pdes/mechanical/parser.c
pdes/mechanical/feenox-parser.obj: pdes/mechanical/parser.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-parser.obj -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-parser.Tpo -c -o pdes/mechanical/feenox-parser.obj `if test -f 'pdes/mechanical/parser.c'; then $(CYGPATH_W) 'pdes/mechanical/parser.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/parser.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-parser.Tpo pdes/mechanical/$(DEPDIR)/feenox-parser.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/parser.c' object='pdes/mechanical/feenox-parser.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-parser.obj `if test -f 'pdes/mechanical/parser.c'; then $(CYGPATH_W) 'pdes/mechanical/parser.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/parser.c'; fi`
pdes/mechanical/materials/feenox-saint_venant-kirchoff.o: pdes/mechanical/materials/saint_venant-kirchoff.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-saint_venant-kirchoff.o -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-saint_venant-kirchoff.Tpo -c -o pdes/mechanical/materials/feenox-saint_venant-kirchoff.o `test -f 'pdes/mechanical/materials/saint_venant-kirchoff.c' || echo '$(srcdir)/'`pdes/mechanical/materials/saint_venant-kirchoff.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-saint_venant-kirchoff.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-saint_venant-kirchoff.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/saint_venant-kirchoff.c' object='pdes/mechanical/materials/feenox-saint_venant-kirchoff.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-saint_venant-kirchoff.o `test -f 'pdes/mechanical/materials/saint_venant-kirchoff.c' || echo '$(srcdir)/'`pdes/mechanical/materials/saint_venant-kirchoff.c
pdes/mechanical/materials/feenox-saint_venant-kirchoff.obj: pdes/mechanical/materials/saint_venant-kirchoff.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-saint_venant-kirchoff.obj -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-saint_venant-kirchoff.Tpo -c -o pdes/mechanical/materials/feenox-saint_venant-kirchoff.obj `if test -f 'pdes/mechanical/materials/saint_venant-kirchoff.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/saint_venant-kirchoff.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/saint_venant-kirchoff.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-saint_venant-kirchoff.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-saint_venant-kirchoff.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/saint_venant-kirchoff.c' object='pdes/mechanical/materials/feenox-saint_venant-kirchoff.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-saint_venant-kirchoff.obj `if test -f 'pdes/mechanical/materials/saint_venant-kirchoff.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/saint_venant-kirchoff.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/saint_venant-kirchoff.c'; fi`
pdes/mechanical/materials/feenox-neohookean.o: pdes/mechanical/materials/neohookean.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-neohookean.o -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-neohookean.Tpo -c -o pdes/mechanical/materials/feenox-neohookean.o `test -f 'pdes/mechanical/materials/neohookean.c' || echo '$(srcdir)/'`pdes/mechanical/materials/neohookean.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-neohookean.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-neohookean.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/neohookean.c' object='pdes/mechanical/materials/feenox-neohookean.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-neohookean.o `test -f 'pdes/mechanical/materials/neohookean.c' || echo '$(srcdir)/'`pdes/mechanical/materials/neohookean.c
pdes/mechanical/materials/feenox-neohookean.obj: pdes/mechanical/materials/neohookean.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-neohookean.obj -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-neohookean.Tpo -c -o pdes/mechanical/materials/feenox-neohookean.obj `if test -f 'pdes/mechanical/materials/neohookean.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/neohookean.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/neohookean.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-neohookean.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-neohookean.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/neohookean.c' object='pdes/mechanical/materials/feenox-neohookean.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-neohookean.obj `if test -f 'pdes/mechanical/materials/neohookean.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/neohookean.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/neohookean.c'; fi`
pdes/mechanical/materials/feenox-mooney-rivlin.o: pdes/mechanical/materials/mooney-rivlin.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-mooney-rivlin.o -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-mooney-rivlin.Tpo -c -o pdes/mechanical/materials/feenox-mooney-rivlin.o `test -f 'pdes/mechanical/materials/mooney-rivlin.c' || echo '$(srcdir)/'`pdes/mechanical/materials/mooney-rivlin.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-mooney-rivlin.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-mooney-rivlin.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/mooney-rivlin.c' object='pdes/mechanical/materials/feenox-mooney-rivlin.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-mooney-rivlin.o `test -f 'pdes/mechanical/materials/mooney-rivlin.c' || echo '$(srcdir)/'`pdes/mechanical/materials/mooney-rivlin.c
pdes/mechanical/materials/feenox-mooney-rivlin.obj: pdes/mechanical/materials/mooney-rivlin.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-mooney-rivlin.obj -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-mooney-rivlin.Tpo -c -o pdes/mechanical/materials/feenox-mooney-rivlin.obj `if test -f 'pdes/mechanical/materials/mooney-rivlin.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/mooney-rivlin.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/mooney-rivlin.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-mooney-rivlin.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-mooney-rivlin.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/mooney-rivlin.c' object='pdes/mechanical/materials/feenox-mooney-rivlin.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-mooney-rivlin.obj `if test -f 'pdes/mechanical/materials/mooney-rivlin.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/mooney-rivlin.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/mooney-rivlin.c'; fi`
pdes/mechanical/materials/feenox-linear-orthotropic.o: pdes/mechanical/materials/linear-orthotropic.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-linear-orthotropic.o -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-linear-orthotropic.Tpo -c -o pdes/mechanical/materials/feenox-linear-orthotropic.o `test -f 'pdes/mechanical/materials/linear-orthotropic.c' || echo '$(srcdir)/'`pdes/mechanical/materials/linear-orthotropic.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-linear-orthotropic.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-linear-orthotropic.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/linear-orthotropic.c' object='pdes/mechanical/materials/feenox-linear-orthotropic.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-linear-orthotropic.o `test -f 'pdes/mechanical/materials/linear-orthotropic.c' || echo '$(srcdir)/'`pdes/mechanical/materials/linear-orthotropic.c
pdes/mechanical/materials/feenox-linear-orthotropic.obj: pdes/mechanical/materials/linear-orthotropic.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-linear-orthotropic.obj -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-linear-orthotropic.Tpo -c -o pdes/mechanical/materials/feenox-linear-orthotropic.obj `if test -f 'pdes/mechanical/materials/linear-orthotropic.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/linear-orthotropic.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/linear-orthotropic.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-linear-orthotropic.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-linear-orthotropic.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/linear-orthotropic.c' object='pdes/mechanical/materials/feenox-linear-orthotropic.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-linear-orthotropic.obj `if test -f 'pdes/mechanical/materials/linear-orthotropic.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/linear-orthotropic.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/linear-orthotropic.c'; fi`
pdes/mechanical/materials/feenox-linear-isotropic.o: pdes/mechanical/materials/linear-isotropic.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-linear-isotropic.o -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-linear-isotropic.Tpo -c -o pdes/mechanical/materials/feenox-linear-isotropic.o `test -f 'pdes/mechanical/materials/linear-isotropic.c' || echo '$(srcdir)/'`pdes/mechanical/materials/linear-isotropic.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-linear-isotropic.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-linear-isotropic.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/linear-isotropic.c' object='pdes/mechanical/materials/feenox-linear-isotropic.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-linear-isotropic.o `test -f 'pdes/mechanical/materials/linear-isotropic.c' || echo '$(srcdir)/'`pdes/mechanical/materials/linear-isotropic.c
pdes/mechanical/materials/feenox-linear-isotropic.obj: pdes/mechanical/materials/linear-isotropic.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-linear-isotropic.obj -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-linear-isotropic.Tpo -c -o pdes/mechanical/materials/feenox-linear-isotropic.obj `if test -f 'pdes/mechanical/materials/linear-isotropic.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/linear-isotropic.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/linear-isotropic.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-linear-isotropic.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-linear-isotropic.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/linear-isotropic.c' object='pdes/mechanical/materials/feenox-linear-isotropic.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-linear-isotropic.obj `if test -f 'pdes/mechanical/materials/linear-isotropic.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/linear-isotropic.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/linear-isotropic.c'; fi`
pdes/mechanical/materials/feenox-hencky.o: pdes/mechanical/materials/hencky.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-hencky.o -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-hencky.Tpo -c -o pdes/mechanical/materials/feenox-hencky.o `test -f 'pdes/mechanical/materials/hencky.c' || echo '$(srcdir)/'`pdes/mechanical/materials/hencky.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-hencky.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-hencky.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/hencky.c' object='pdes/mechanical/materials/feenox-hencky.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-hencky.o `test -f 'pdes/mechanical/materials/hencky.c' || echo '$(srcdir)/'`pdes/mechanical/materials/hencky.c
pdes/mechanical/materials/feenox-hencky.obj: pdes/mechanical/materials/hencky.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-hencky.obj -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-hencky.Tpo -c -o pdes/mechanical/materials/feenox-hencky.obj `if test -f 'pdes/mechanical/materials/hencky.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/hencky.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/hencky.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-hencky.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-hencky.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/hencky.c' object='pdes/mechanical/materials/feenox-hencky.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-hencky.obj `if test -f 'pdes/mechanical/materials/hencky.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/hencky.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/hencky.c'; fi`
pdes/mechanical/materials/feenox-expansion-orthotropic.o: pdes/mechanical/materials/expansion-orthotropic.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-expansion-orthotropic.o -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-orthotropic.Tpo -c -o pdes/mechanical/materials/feenox-expansion-orthotropic.o `test -f 'pdes/mechanical/materials/expansion-orthotropic.c' || echo '$(srcdir)/'`pdes/mechanical/materials/expansion-orthotropic.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-orthotropic.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-orthotropic.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/expansion-orthotropic.c' object='pdes/mechanical/materials/feenox-expansion-orthotropic.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-expansion-orthotropic.o `test -f 'pdes/mechanical/materials/expansion-orthotropic.c' || echo '$(srcdir)/'`pdes/mechanical/materials/expansion-orthotropic.c
pdes/mechanical/materials/feenox-expansion-orthotropic.obj: pdes/mechanical/materials/expansion-orthotropic.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-expansion-orthotropic.obj -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-orthotropic.Tpo -c -o pdes/mechanical/materials/feenox-expansion-orthotropic.obj `if test -f 'pdes/mechanical/materials/expansion-orthotropic.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/expansion-orthotropic.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/expansion-orthotropic.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-orthotropic.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-orthotropic.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/expansion-orthotropic.c' object='pdes/mechanical/materials/feenox-expansion-orthotropic.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-expansion-orthotropic.obj `if test -f 'pdes/mechanical/materials/expansion-orthotropic.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/expansion-orthotropic.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/expansion-orthotropic.c'; fi`
pdes/mechanical/materials/feenox-expansion-isotropic.o: pdes/mechanical/materials/expansion-isotropic.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-expansion-isotropic.o -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-isotropic.Tpo -c -o pdes/mechanical/materials/feenox-expansion-isotropic.o `test -f 'pdes/mechanical/materials/expansion-isotropic.c' || echo '$(srcdir)/'`pdes/mechanical/materials/expansion-isotropic.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-isotropic.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-isotropic.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/expansion-isotropic.c' object='pdes/mechanical/materials/feenox-expansion-isotropic.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-expansion-isotropic.o `test -f 'pdes/mechanical/materials/expansion-isotropic.c' || echo '$(srcdir)/'`pdes/mechanical/materials/expansion-isotropic.c
pdes/mechanical/materials/feenox-expansion-isotropic.obj: pdes/mechanical/materials/expansion-isotropic.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-expansion-isotropic.obj -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-isotropic.Tpo -c -o pdes/mechanical/materials/feenox-expansion-isotropic.obj `if test -f 'pdes/mechanical/materials/expansion-isotropic.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/expansion-isotropic.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/expansion-isotropic.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-isotropic.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-isotropic.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/expansion-isotropic.c' object='pdes/mechanical/materials/feenox-expansion-isotropic.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-expansion-isotropic.obj `if test -f 'pdes/mechanical/materials/expansion-isotropic.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/expansion-isotropic.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/expansion-isotropic.c'; fi`
pdes/mechanical/materials/feenox-elastic-plane-stress.o: pdes/mechanical/materials/elastic-plane-stress.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-elastic-plane-stress.o -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-stress.Tpo -c -o pdes/mechanical/materials/feenox-elastic-plane-stress.o `test -f 'pdes/mechanical/materials/elastic-plane-stress.c' || echo '$(srcdir)/'`pdes/mechanical/materials/elastic-plane-stress.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-stress.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-stress.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/elastic-plane-stress.c' object='pdes/mechanical/materials/feenox-elastic-plane-stress.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-elastic-plane-stress.o `test -f 'pdes/mechanical/materials/elastic-plane-stress.c' || echo '$(srcdir)/'`pdes/mechanical/materials/elastic-plane-stress.c
pdes/mechanical/materials/feenox-elastic-plane-stress.obj: pdes/mechanical/materials/elastic-plane-stress.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-elastic-plane-stress.obj -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-stress.Tpo -c -o pdes/mechanical/materials/feenox-elastic-plane-stress.obj `if test -f 'pdes/mechanical/materials/elastic-plane-stress.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/elastic-plane-stress.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/elastic-plane-stress.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-stress.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-stress.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/elastic-plane-stress.c' object='pdes/mechanical/materials/feenox-elastic-plane-stress.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-elastic-plane-stress.obj `if test -f 'pdes/mechanical/materials/elastic-plane-stress.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/elastic-plane-stress.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/elastic-plane-stress.c'; fi`
pdes/mechanical/materials/feenox-elastic-plane-strain.o: pdes/mechanical/materials/elastic-plane-strain.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-elastic-plane-strain.o -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-strain.Tpo -c -o pdes/mechanical/materials/feenox-elastic-plane-strain.o `test -f 'pdes/mechanical/materials/elastic-plane-strain.c' || echo '$(srcdir)/'`pdes/mechanical/materials/elastic-plane-strain.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-strain.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-strain.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/elastic-plane-strain.c' object='pdes/mechanical/materials/feenox-elastic-plane-strain.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-elastic-plane-strain.o `test -f 'pdes/mechanical/materials/elastic-plane-strain.c' || echo '$(srcdir)/'`pdes/mechanical/materials/elastic-plane-strain.c
pdes/mechanical/materials/feenox-elastic-plane-strain.obj: pdes/mechanical/materials/elastic-plane-strain.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/materials/feenox-elastic-plane-strain.obj -MD -MP -MF pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-strain.Tpo -c -o pdes/mechanical/materials/feenox-elastic-plane-strain.obj `if test -f 'pdes/mechanical/materials/elastic-plane-strain.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/elastic-plane-strain.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/elastic-plane-strain.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-strain.Tpo pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-strain.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/materials/elastic-plane-strain.c' object='pdes/mechanical/materials/feenox-elastic-plane-strain.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/materials/feenox-elastic-plane-strain.obj `if test -f 'pdes/mechanical/materials/elastic-plane-strain.c'; then $(CYGPATH_W) 'pdes/mechanical/materials/elastic-plane-strain.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/materials/elastic-plane-strain.c'; fi`
pdes/mechanical/feenox-linearize.o: pdes/mechanical/linearize.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-linearize.o -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-linearize.Tpo -c -o pdes/mechanical/feenox-linearize.o `test -f 'pdes/mechanical/linearize.c' || echo '$(srcdir)/'`pdes/mechanical/linearize.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-linearize.Tpo pdes/mechanical/$(DEPDIR)/feenox-linearize.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/linearize.c' object='pdes/mechanical/feenox-linearize.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-linearize.o `test -f 'pdes/mechanical/linearize.c' || echo '$(srcdir)/'`pdes/mechanical/linearize.c
pdes/mechanical/feenox-linearize.obj: pdes/mechanical/linearize.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-linearize.obj -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-linearize.Tpo -c -o pdes/mechanical/feenox-linearize.obj `if test -f 'pdes/mechanical/linearize.c'; then $(CYGPATH_W) 'pdes/mechanical/linearize.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/linearize.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-linearize.Tpo pdes/mechanical/$(DEPDIR)/feenox-linearize.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/linearize.c' object='pdes/mechanical/feenox-linearize.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-linearize.obj `if test -f 'pdes/mechanical/linearize.c'; then $(CYGPATH_W) 'pdes/mechanical/linearize.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/linearize.c'; fi`
pdes/mechanical/feenox-init.o: pdes/mechanical/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-init.o -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-init.Tpo -c -o pdes/mechanical/feenox-init.o `test -f 'pdes/mechanical/init.c' || echo '$(srcdir)/'`pdes/mechanical/init.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-init.Tpo pdes/mechanical/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/init.c' object='pdes/mechanical/feenox-init.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-init.o `test -f 'pdes/mechanical/init.c' || echo '$(srcdir)/'`pdes/mechanical/init.c
pdes/mechanical/feenox-init.obj: pdes/mechanical/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-init.obj -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-init.Tpo -c -o pdes/mechanical/feenox-init.obj `if test -f 'pdes/mechanical/init.c'; then $(CYGPATH_W) 'pdes/mechanical/init.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/init.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-init.Tpo pdes/mechanical/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/init.c' object='pdes/mechanical/feenox-init.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-init.obj `if test -f 'pdes/mechanical/init.c'; then $(CYGPATH_W) 'pdes/mechanical/init.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/init.c'; fi`
pdes/mechanical/feenox-gradient.o: pdes/mechanical/gradient.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-gradient.o -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-gradient.Tpo -c -o pdes/mechanical/feenox-gradient.o `test -f 'pdes/mechanical/gradient.c' || echo '$(srcdir)/'`pdes/mechanical/gradient.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-gradient.Tpo pdes/mechanical/$(DEPDIR)/feenox-gradient.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/gradient.c' object='pdes/mechanical/feenox-gradient.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-gradient.o `test -f 'pdes/mechanical/gradient.c' || echo '$(srcdir)/'`pdes/mechanical/gradient.c
pdes/mechanical/feenox-gradient.obj: pdes/mechanical/gradient.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-gradient.obj -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-gradient.Tpo -c -o pdes/mechanical/feenox-gradient.obj `if test -f 'pdes/mechanical/gradient.c'; then $(CYGPATH_W) 'pdes/mechanical/gradient.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/gradient.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-gradient.Tpo pdes/mechanical/$(DEPDIR)/feenox-gradient.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/gradient.c' object='pdes/mechanical/feenox-gradient.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-gradient.obj `if test -f 'pdes/mechanical/gradient.c'; then $(CYGPATH_W) 'pdes/mechanical/gradient.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/gradient.c'; fi`
pdes/mechanical/feenox-bulk.o: pdes/mechanical/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-bulk.o -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-bulk.Tpo -c -o pdes/mechanical/feenox-bulk.o `test -f 'pdes/mechanical/bulk.c' || echo '$(srcdir)/'`pdes/mechanical/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-bulk.Tpo pdes/mechanical/$(DEPDIR)/feenox-bulk.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/bulk.c' object='pdes/mechanical/feenox-bulk.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-bulk.o `test -f 'pdes/mechanical/bulk.c' || echo '$(srcdir)/'`pdes/mechanical/bulk.c
pdes/mechanical/feenox-bulk.obj: pdes/mechanical/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-bulk.obj -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-bulk.Tpo -c -o pdes/mechanical/feenox-bulk.obj `if test -f 'pdes/mechanical/bulk.c'; then $(CYGPATH_W) 'pdes/mechanical/bulk.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/bulk.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-bulk.Tpo pdes/mechanical/$(DEPDIR)/feenox-bulk.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/bulk.c' object='pdes/mechanical/feenox-bulk.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-bulk.obj `if test -f 'pdes/mechanical/bulk.c'; then $(CYGPATH_W) 'pdes/mechanical/bulk.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/bulk.c'; fi`
pdes/mechanical/feenox-bc.o: pdes/mechanical/bc.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-bc.o -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-bc.Tpo -c -o pdes/mechanical/feenox-bc.o `test -f 'pdes/mechanical/bc.c' || echo '$(srcdir)/'`pdes/mechanical/bc.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-bc.Tpo pdes/mechanical/$(DEPDIR)/feenox-bc.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/bc.c' object='pdes/mechanical/feenox-bc.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-bc.o `test -f 'pdes/mechanical/bc.c' || echo '$(srcdir)/'`pdes/mechanical/bc.c
pdes/mechanical/feenox-bc.obj: pdes/mechanical/bc.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/mechanical/feenox-bc.obj -MD -MP -MF pdes/mechanical/$(DEPDIR)/feenox-bc.Tpo -c -o pdes/mechanical/feenox-bc.obj `if test -f 'pdes/mechanical/bc.c'; then $(CYGPATH_W) 'pdes/mechanical/bc.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/bc.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/mechanical/$(DEPDIR)/feenox-bc.Tpo pdes/mechanical/$(DEPDIR)/feenox-bc.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/mechanical/bc.c' object='pdes/mechanical/feenox-bc.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/mechanical/feenox-bc.obj `if test -f 'pdes/mechanical/bc.c'; then $(CYGPATH_W) 'pdes/mechanical/bc.c'; else $(CYGPATH_W) '$(srcdir)/pdes/mechanical/bc.c'; fi`
pdes/laplace/feenox-parser.o: pdes/laplace/parser.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/laplace/feenox-parser.o -MD -MP -MF pdes/laplace/$(DEPDIR)/feenox-parser.Tpo -c -o pdes/laplace/feenox-parser.o `test -f 'pdes/laplace/parser.c' || echo '$(srcdir)/'`pdes/laplace/parser.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/laplace/$(DEPDIR)/feenox-parser.Tpo pdes/laplace/$(DEPDIR)/feenox-parser.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/laplace/parser.c' object='pdes/laplace/feenox-parser.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/laplace/feenox-parser.o `test -f 'pdes/laplace/parser.c' || echo '$(srcdir)/'`pdes/laplace/parser.c
pdes/laplace/feenox-parser.obj: pdes/laplace/parser.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/laplace/feenox-parser.obj -MD -MP -MF pdes/laplace/$(DEPDIR)/feenox-parser.Tpo -c -o pdes/laplace/feenox-parser.obj `if test -f 'pdes/laplace/parser.c'; then $(CYGPATH_W) 'pdes/laplace/parser.c'; else $(CYGPATH_W) '$(srcdir)/pdes/laplace/parser.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/laplace/$(DEPDIR)/feenox-parser.Tpo pdes/laplace/$(DEPDIR)/feenox-parser.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/laplace/parser.c' object='pdes/laplace/feenox-parser.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/laplace/feenox-parser.obj `if test -f 'pdes/laplace/parser.c'; then $(CYGPATH_W) 'pdes/laplace/parser.c'; else $(CYGPATH_W) '$(srcdir)/pdes/laplace/parser.c'; fi`
pdes/laplace/feenox-init.o: pdes/laplace/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/laplace/feenox-init.o -MD -MP -MF pdes/laplace/$(DEPDIR)/feenox-init.Tpo -c -o pdes/laplace/feenox-init.o `test -f 'pdes/laplace/init.c' || echo '$(srcdir)/'`pdes/laplace/init.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/laplace/$(DEPDIR)/feenox-init.Tpo pdes/laplace/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/laplace/init.c' object='pdes/laplace/feenox-init.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/laplace/feenox-init.o `test -f 'pdes/laplace/init.c' || echo '$(srcdir)/'`pdes/laplace/init.c
pdes/laplace/feenox-init.obj: pdes/laplace/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/laplace/feenox-init.obj -MD -MP -MF pdes/laplace/$(DEPDIR)/feenox-init.Tpo -c -o pdes/laplace/feenox-init.obj `if test -f 'pdes/laplace/init.c'; then $(CYGPATH_W) 'pdes/laplace/init.c'; else $(CYGPATH_W) '$(srcdir)/pdes/laplace/init.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/laplace/$(DEPDIR)/feenox-init.Tpo pdes/laplace/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/laplace/init.c' object='pdes/laplace/feenox-init.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/laplace/feenox-init.obj `if test -f 'pdes/laplace/init.c'; then $(CYGPATH_W) 'pdes/laplace/init.c'; else $(CYGPATH_W) '$(srcdir)/pdes/laplace/init.c'; fi`
pdes/laplace/feenox-bulk.o: pdes/laplace/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/laplace/feenox-bulk.o -MD -MP -MF pdes/laplace/$(DEPDIR)/feenox-bulk.Tpo -c -o pdes/laplace/feenox-bulk.o `test -f 'pdes/laplace/bulk.c' || echo '$(srcdir)/'`pdes/laplace/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/laplace/$(DEPDIR)/feenox-bulk.Tpo pdes/laplace/$(DEPDIR)/feenox-bulk.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/laplace/bulk.c' object='pdes/laplace/feenox-bulk.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/laplace/feenox-bulk.o `test -f 'pdes/laplace/bulk.c' || echo '$(srcdir)/'`pdes/laplace/bulk.c
pdes/laplace/feenox-bulk.obj: pdes/laplace/bulk.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/laplace/feenox-bulk.obj -MD -MP -MF pdes/laplace/$(DEPDIR)/feenox-bulk.Tpo -c -o pdes/laplace/feenox-bulk.obj `if test -f 'pdes/laplace/bulk.c'; then $(CYGPATH_W) 'pdes/laplace/bulk.c'; else $(CYGPATH_W) '$(srcdir)/pdes/laplace/bulk.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/laplace/$(DEPDIR)/feenox-bulk.Tpo pdes/laplace/$(DEPDIR)/feenox-bulk.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/laplace/bulk.c' object='pdes/laplace/feenox-bulk.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/laplace/feenox-bulk.obj `if test -f 'pdes/laplace/bulk.c'; then $(CYGPATH_W) 'pdes/laplace/bulk.c'; else $(CYGPATH_W) '$(srcdir)/pdes/laplace/bulk.c'; fi`
pdes/laplace/feenox-bc.o: pdes/laplace/bc.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/laplace/feenox-bc.o -MD -MP -MF pdes/laplace/$(DEPDIR)/feenox-bc.Tpo -c -o pdes/laplace/feenox-bc.o `test -f 'pdes/laplace/bc.c' || echo '$(srcdir)/'`pdes/laplace/bc.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/laplace/$(DEPDIR)/feenox-bc.Tpo pdes/laplace/$(DEPDIR)/feenox-bc.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/laplace/bc.c' object='pdes/laplace/feenox-bc.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/laplace/feenox-bc.o `test -f 'pdes/laplace/bc.c' || echo '$(srcdir)/'`pdes/laplace/bc.c
pdes/laplace/feenox-bc.obj: pdes/laplace/bc.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/laplace/feenox-bc.obj -MD -MP -MF pdes/laplace/$(DEPDIR)/feenox-bc.Tpo -c -o pdes/laplace/feenox-bc.obj `if test -f 'pdes/laplace/bc.c'; then $(CYGPATH_W) 'pdes/laplace/bc.c'; else $(CYGPATH_W) '$(srcdir)/pdes/laplace/bc.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/laplace/$(DEPDIR)/feenox-bc.Tpo pdes/laplace/$(DEPDIR)/feenox-bc.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/laplace/bc.c' object='pdes/laplace/feenox-bc.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/laplace/feenox-bc.obj `if test -f 'pdes/laplace/bc.c'; then $(CYGPATH_W) 'pdes/laplace/bc.c'; else $(CYGPATH_W) '$(srcdir)/pdes/laplace/bc.c'; fi`
pdes/feenox-init.o: pdes/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-init.o -MD -MP -MF pdes/$(DEPDIR)/feenox-init.Tpo -c -o pdes/feenox-init.o `test -f 'pdes/init.c' || echo '$(srcdir)/'`pdes/init.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-init.Tpo pdes/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/init.c' object='pdes/feenox-init.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-init.o `test -f 'pdes/init.c' || echo '$(srcdir)/'`pdes/init.c
pdes/feenox-init.obj: pdes/init.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-init.obj -MD -MP -MF pdes/$(DEPDIR)/feenox-init.Tpo -c -o pdes/feenox-init.obj `if test -f 'pdes/init.c'; then $(CYGPATH_W) 'pdes/init.c'; else $(CYGPATH_W) '$(srcdir)/pdes/init.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-init.Tpo pdes/$(DEPDIR)/feenox-init.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/init.c' object='pdes/feenox-init.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-init.obj `if test -f 'pdes/init.c'; then $(CYGPATH_W) 'pdes/init.c'; else $(CYGPATH_W) '$(srcdir)/pdes/init.c'; fi`
pdes/feenox-gradient.o: pdes/gradient.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-gradient.o -MD -MP -MF pdes/$(DEPDIR)/feenox-gradient.Tpo -c -o pdes/feenox-gradient.o `test -f 'pdes/gradient.c' || echo '$(srcdir)/'`pdes/gradient.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-gradient.Tpo pdes/$(DEPDIR)/feenox-gradient.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/gradient.c' object='pdes/feenox-gradient.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-gradient.o `test -f 'pdes/gradient.c' || echo '$(srcdir)/'`pdes/gradient.c
pdes/feenox-gradient.obj: pdes/gradient.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-gradient.obj -MD -MP -MF pdes/$(DEPDIR)/feenox-gradient.Tpo -c -o pdes/feenox-gradient.obj `if test -f 'pdes/gradient.c'; then $(CYGPATH_W) 'pdes/gradient.c'; else $(CYGPATH_W) '$(srcdir)/pdes/gradient.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-gradient.Tpo pdes/$(DEPDIR)/feenox-gradient.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/gradient.c' object='pdes/feenox-gradient.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-gradient.obj `if test -f 'pdes/gradient.c'; then $(CYGPATH_W) 'pdes/gradient.c'; else $(CYGPATH_W) '$(srcdir)/pdes/gradient.c'; fi`
pdes/feenox-fem.o: pdes/fem.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-fem.o -MD -MP -MF pdes/$(DEPDIR)/feenox-fem.Tpo -c -o pdes/feenox-fem.o `test -f 'pdes/fem.c' || echo '$(srcdir)/'`pdes/fem.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-fem.Tpo pdes/$(DEPDIR)/feenox-fem.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/fem.c' object='pdes/feenox-fem.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-fem.o `test -f 'pdes/fem.c' || echo '$(srcdir)/'`pdes/fem.c
pdes/feenox-fem.obj: pdes/fem.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-fem.obj -MD -MP -MF pdes/$(DEPDIR)/feenox-fem.Tpo -c -o pdes/feenox-fem.obj `if test -f 'pdes/fem.c'; then $(CYGPATH_W) 'pdes/fem.c'; else $(CYGPATH_W) '$(srcdir)/pdes/fem.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-fem.Tpo pdes/$(DEPDIR)/feenox-fem.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/fem.c' object='pdes/feenox-fem.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-fem.obj `if test -f 'pdes/fem.c'; then $(CYGPATH_W) 'pdes/fem.c'; else $(CYGPATH_W) '$(srcdir)/pdes/fem.c'; fi`
pdes/feenox-dump.o: pdes/dump.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-dump.o -MD -MP -MF pdes/$(DEPDIR)/feenox-dump.Tpo -c -o pdes/feenox-dump.o `test -f 'pdes/dump.c' || echo '$(srcdir)/'`pdes/dump.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-dump.Tpo pdes/$(DEPDIR)/feenox-dump.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/dump.c' object='pdes/feenox-dump.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-dump.o `test -f 'pdes/dump.c' || echo '$(srcdir)/'`pdes/dump.c
pdes/feenox-dump.obj: pdes/dump.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-dump.obj -MD -MP -MF pdes/$(DEPDIR)/feenox-dump.Tpo -c -o pdes/feenox-dump.obj `if test -f 'pdes/dump.c'; then $(CYGPATH_W) 'pdes/dump.c'; else $(CYGPATH_W) '$(srcdir)/pdes/dump.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-dump.Tpo pdes/$(DEPDIR)/feenox-dump.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/dump.c' object='pdes/feenox-dump.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-dump.obj `if test -f 'pdes/dump.c'; then $(CYGPATH_W) 'pdes/dump.c'; else $(CYGPATH_W) '$(srcdir)/pdes/dump.c'; fi`
pdes/feenox-distribution.o: pdes/distribution.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-distribution.o -MD -MP -MF pdes/$(DEPDIR)/feenox-distribution.Tpo -c -o pdes/feenox-distribution.o `test -f 'pdes/distribution.c' || echo '$(srcdir)/'`pdes/distribution.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-distribution.Tpo pdes/$(DEPDIR)/feenox-distribution.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/distribution.c' object='pdes/feenox-distribution.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-distribution.o `test -f 'pdes/distribution.c' || echo '$(srcdir)/'`pdes/distribution.c
pdes/feenox-distribution.obj: pdes/distribution.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-distribution.obj -MD -MP -MF pdes/$(DEPDIR)/feenox-distribution.Tpo -c -o pdes/feenox-distribution.obj `if test -f 'pdes/distribution.c'; then $(CYGPATH_W) 'pdes/distribution.c'; else $(CYGPATH_W) '$(srcdir)/pdes/distribution.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-distribution.Tpo pdes/$(DEPDIR)/feenox-distribution.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/distribution.c' object='pdes/feenox-distribution.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-distribution.obj `if test -f 'pdes/distribution.c'; then $(CYGPATH_W) 'pdes/distribution.c'; else $(CYGPATH_W) '$(srcdir)/pdes/distribution.c'; fi`
pdes/feenox-dirichlet.o: pdes/dirichlet.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-dirichlet.o -MD -MP -MF pdes/$(DEPDIR)/feenox-dirichlet.Tpo -c -o pdes/feenox-dirichlet.o `test -f 'pdes/dirichlet.c' || echo '$(srcdir)/'`pdes/dirichlet.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-dirichlet.Tpo pdes/$(DEPDIR)/feenox-dirichlet.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/dirichlet.c' object='pdes/feenox-dirichlet.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-dirichlet.o `test -f 'pdes/dirichlet.c' || echo '$(srcdir)/'`pdes/dirichlet.c
pdes/feenox-dirichlet.obj: pdes/dirichlet.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-dirichlet.obj -MD -MP -MF pdes/$(DEPDIR)/feenox-dirichlet.Tpo -c -o pdes/feenox-dirichlet.obj `if test -f 'pdes/dirichlet.c'; then $(CYGPATH_W) 'pdes/dirichlet.c'; else $(CYGPATH_W) '$(srcdir)/pdes/dirichlet.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-dirichlet.Tpo pdes/$(DEPDIR)/feenox-dirichlet.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/dirichlet.c' object='pdes/feenox-dirichlet.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-dirichlet.obj `if test -f 'pdes/dirichlet.c'; then $(CYGPATH_W) 'pdes/dirichlet.c'; else $(CYGPATH_W) '$(srcdir)/pdes/dirichlet.c'; fi`
pdes/feenox-build.o: pdes/build.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-build.o -MD -MP -MF pdes/$(DEPDIR)/feenox-build.Tpo -c -o pdes/feenox-build.o `test -f 'pdes/build.c' || echo '$(srcdir)/'`pdes/build.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-build.Tpo pdes/$(DEPDIR)/feenox-build.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/build.c' object='pdes/feenox-build.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-build.o `test -f 'pdes/build.c' || echo '$(srcdir)/'`pdes/build.c
pdes/feenox-build.obj: pdes/build.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-build.obj -MD -MP -MF pdes/$(DEPDIR)/feenox-build.Tpo -c -o pdes/feenox-build.obj `if test -f 'pdes/build.c'; then $(CYGPATH_W) 'pdes/build.c'; else $(CYGPATH_W) '$(srcdir)/pdes/build.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-build.Tpo pdes/$(DEPDIR)/feenox-build.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/build.c' object='pdes/feenox-build.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-build.obj `if test -f 'pdes/build.c'; then $(CYGPATH_W) 'pdes/build.c'; else $(CYGPATH_W) '$(srcdir)/pdes/build.c'; fi`
pdes/feenox-blas.o: pdes/blas.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-blas.o -MD -MP -MF pdes/$(DEPDIR)/feenox-blas.Tpo -c -o pdes/feenox-blas.o `test -f 'pdes/blas.c' || echo '$(srcdir)/'`pdes/blas.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-blas.Tpo pdes/$(DEPDIR)/feenox-blas.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/blas.c' object='pdes/feenox-blas.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-blas.o `test -f 'pdes/blas.c' || echo '$(srcdir)/'`pdes/blas.c
pdes/feenox-blas.obj: pdes/blas.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -MT pdes/feenox-blas.obj -MD -MP -MF pdes/$(DEPDIR)/feenox-blas.Tpo -c -o pdes/feenox-blas.obj `if test -f 'pdes/blas.c'; then $(CYGPATH_W) 'pdes/blas.c'; else $(CYGPATH_W) '$(srcdir)/pdes/blas.c'; fi`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) pdes/$(DEPDIR)/feenox-blas.Tpo pdes/$(DEPDIR)/feenox-blas.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='pdes/blas.c' object='pdes/feenox-blas.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(feenox_CFLAGS) $(CFLAGS) -c -o pdes/feenox-blas.obj `if test -f 'pdes/blas.c'; then $(CYGPATH_W) 'pdes/blas.c'; else $(CYGPATH_W) '$(srcdir)/pdes/blas.c'; fi`
ID: $(am__tagged_files)
$(am__define_uniq_tagged_files); mkid -fID $$unique
tags: tags-am
TAGS: tags
tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
set x; \
here=`pwd`; \
$(am__define_uniq_tagged_files); \
shift; \
if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
test -n "$$unique" || unique=$$empty_fix; \
if test $$# -gt 0; then \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
"$$@" $$unique; \
else \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
$$unique; \
fi; \
fi
ctags: ctags-am
CTAGS: ctags
ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
$(am__define_uniq_tagged_files); \
test -z "$(CTAGS_ARGS)$$unique" \
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
$$unique
GTAGS:
here=`$(am__cd) $(top_builddir) && pwd` \
&& $(am__cd) $(top_srcdir) \
&& gtags -i $(GTAGS_ARGS) "$$here"
cscopelist: cscopelist-am
cscopelist-am: $(am__tagged_files)
list='$(am__tagged_files)'; \
case "$(srcdir)" in \
[\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
*) sdir=$(subdir)/$(srcdir) ;; \
esac; \
for i in $$list; do \
if test -f "$$i"; then \
echo "$(subdir)/$$i"; \
else \
echo "$$sdir/$$i"; \
fi; \
done >> $(top_builddir)/cscope.files
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
distdir-am: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
dist_files=`for file in $$list; do echo $$file; done | \
sed -e "s|^$$srcdirstrip/||;t" \
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
case $$dist_files in \
*/*) $(MKDIR_P) `echo "$$dist_files" | \
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
sort -u` ;; \
esac; \
for file in $$dist_files; do \
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
if test -d "$(distdir)/$$file"; then \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
|| exit 1; \
fi; \
done
check-am: all-am
check: check-am
all-am: Makefile $(PROGRAMS)
installdirs:
for dir in "$(DESTDIR)$(bindir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: install-am
install-exec: install-exec-am
install-data: install-data-am
uninstall: uninstall-am
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
installcheck: installcheck-am
install-strip:
if test -z '$(STRIP)'; then \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
install; \
else \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
"INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
fi
mostlyclean-generic:
clean-generic:
distclean-generic:
-$(am__rm_f) $(CONFIG_CLEAN_FILES)
-test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES)
-$(am__rm_f) $(DEPDIR)/$(am__dirstamp)
-$(am__rm_f) ./$(am__dirstamp)
-$(am__rm_f) contrib/$(DEPDIR)/$(am__dirstamp)
-$(am__rm_f) contrib/$(am__dirstamp)
-$(am__rm_f) flow/$(DEPDIR)/$(am__dirstamp)
-$(am__rm_f) flow/$(am__dirstamp)
-$(am__rm_f) io/$(DEPDIR)/$(am__dirstamp)
-$(am__rm_f) io/$(am__dirstamp)
-$(am__rm_f) math/$(DEPDIR)/$(am__dirstamp)
-$(am__rm_f) math/$(am__dirstamp)
-$(am__rm_f) mesh/$(DEPDIR)/$(am__dirstamp)
-$(am__rm_f) mesh/$(am__dirstamp)
-$(am__rm_f) mesh/elements/$(DEPDIR)/$(am__dirstamp)
-$(am__rm_f) mesh/elements/$(am__dirstamp)
-$(am__rm_f) parser/$(DEPDIR)/$(am__dirstamp)
-$(am__rm_f) parser/$(am__dirstamp)
-$(am__rm_f) pdes/$(DEPDIR)/$(am__dirstamp)
-$(am__rm_f) pdes/$(am__dirstamp)
-$(am__rm_f) pdes/laplace/$(DEPDIR)/$(am__dirstamp)
-$(am__rm_f) pdes/laplace/$(am__dirstamp)
-$(am__rm_f) pdes/mechanical/$(DEPDIR)/$(am__dirstamp)
-$(am__rm_f) pdes/mechanical/$(am__dirstamp)
-$(am__rm_f) pdes/mechanical/materials/$(DEPDIR)/$(am__dirstamp)
-$(am__rm_f) pdes/mechanical/materials/$(am__dirstamp)
-$(am__rm_f) pdes/modal/$(DEPDIR)/$(am__dirstamp)
-$(am__rm_f) pdes/modal/$(am__dirstamp)
-$(am__rm_f) pdes/neutron_diffusion/$(DEPDIR)/$(am__dirstamp)
-$(am__rm_f) pdes/neutron_diffusion/$(am__dirstamp)
-$(am__rm_f) pdes/neutron_sn/$(DEPDIR)/$(am__dirstamp)
-$(am__rm_f) pdes/neutron_sn/$(am__dirstamp)
-$(am__rm_f) pdes/thermal/$(DEPDIR)/$(am__dirstamp)
-$(am__rm_f) pdes/thermal/$(am__dirstamp)
maintainer-clean-generic:
@echo "This command is intended for maintainers to use"
@echo "it deletes files that may require special tools to rebuild."
clean: clean-am
clean-am: clean-binPROGRAMS clean-generic mostlyclean-am
distclean: distclean-am
-rm -f ./$(DEPDIR)/feenox-feenox.Po
-rm -f ./$(DEPDIR)/feenox-version.Po
-rm -f ./contrib/$(DEPDIR)/feenox-kdtree.Po
-rm -f ./flow/$(DEPDIR)/feenox-abort.Po
-rm -f ./flow/$(DEPDIR)/feenox-cleanup.Po
-rm -f ./flow/$(DEPDIR)/feenox-conditional.Po
-rm -f ./flow/$(DEPDIR)/feenox-define.Po
-rm -f ./flow/$(DEPDIR)/feenox-error.Po
-rm -f ./flow/$(DEPDIR)/feenox-getptr.Po
-rm -f ./flow/$(DEPDIR)/feenox-init.Po
-rm -f ./flow/$(DEPDIR)/feenox-instruction.Po
-rm -f ./flow/$(DEPDIR)/feenox-run.Po
-rm -f ./flow/$(DEPDIR)/feenox-step.Po
-rm -f ./io/$(DEPDIR)/feenox-file.Po
-rm -f ./io/$(DEPDIR)/feenox-print.Po
-rm -f ./io/$(DEPDIR)/feenox-printf.Po
-rm -f ./io/$(DEPDIR)/feenox-read.Po
-rm -f ./math/$(DEPDIR)/feenox-alias.Po
-rm -f ./math/$(DEPDIR)/feenox-assignment.Po
-rm -f ./math/$(DEPDIR)/feenox-builtin_functionals.Po
-rm -f ./math/$(DEPDIR)/feenox-builtin_functions.Po
-rm -f ./math/$(DEPDIR)/feenox-builtin_vectorfunctions.Po
-rm -f ./math/$(DEPDIR)/feenox-dae.Po
-rm -f ./math/$(DEPDIR)/feenox-expressions.Po
-rm -f ./math/$(DEPDIR)/feenox-fit.Po
-rm -f ./math/$(DEPDIR)/feenox-function.Po
-rm -f ./math/$(DEPDIR)/feenox-matrix.Po
-rm -f ./math/$(DEPDIR)/feenox-solve.Po
-rm -f ./math/$(DEPDIR)/feenox-vector.Po
-rm -f ./mesh/$(DEPDIR)/feenox-boundary_condition.Po
-rm -f ./mesh/$(DEPDIR)/feenox-calculix.Po
-rm -f ./mesh/$(DEPDIR)/feenox-cell.Po
-rm -f ./mesh/$(DEPDIR)/feenox-element.Po
-rm -f ./mesh/$(DEPDIR)/feenox-extrema.Po
-rm -f ./mesh/$(DEPDIR)/feenox-geometry.Po
-rm -f ./mesh/$(DEPDIR)/feenox-gmsh.Po
-rm -f ./mesh/$(DEPDIR)/feenox-init.Po
-rm -f ./mesh/$(DEPDIR)/feenox-integrate.Po
-rm -f ./mesh/$(DEPDIR)/feenox-interpolate.Po
-rm -f ./mesh/$(DEPDIR)/feenox-material.Po
-rm -f ./mesh/$(DEPDIR)/feenox-mesh.Po
-rm -f ./mesh/$(DEPDIR)/feenox-neighbors.Po
-rm -f ./mesh/$(DEPDIR)/feenox-physical_group.Po
-rm -f ./mesh/$(DEPDIR)/feenox-tag_index_map.Po
-rm -f ./mesh/$(DEPDIR)/feenox-vtk.Po
-rm -f ./mesh/$(DEPDIR)/feenox-vtu.Po
-rm -f ./mesh/$(DEPDIR)/feenox-write.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-hexa20.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-hexa27.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-hexa8.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-line2.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-line3.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-point.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-prism15.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-prism6.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-quad4.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-quad8.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-quad9.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-tet10.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-tet4.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-triang3.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-triang6.Po
-rm -f ./parser/$(DEPDIR)/feenox-auxiliary.Po
-rm -f ./parser/$(DEPDIR)/feenox-parser.Po
-rm -f pdes/$(DEPDIR)/feenox-blas.Po
-rm -f pdes/$(DEPDIR)/feenox-build.Po
-rm -f pdes/$(DEPDIR)/feenox-dirichlet.Po
-rm -f pdes/$(DEPDIR)/feenox-distribution.Po
-rm -f pdes/$(DEPDIR)/feenox-dump.Po
-rm -f pdes/$(DEPDIR)/feenox-fem.Po
-rm -f pdes/$(DEPDIR)/feenox-gradient.Po
-rm -f pdes/$(DEPDIR)/feenox-init.Po
-rm -f pdes/$(DEPDIR)/feenox-parse.Po
-rm -f pdes/$(DEPDIR)/feenox-petsc_ksp.Po
-rm -f pdes/$(DEPDIR)/feenox-petsc_snes.Po
-rm -f pdes/$(DEPDIR)/feenox-petsc_ts.Po
-rm -f pdes/$(DEPDIR)/feenox-reaction.Po
-rm -f pdes/$(DEPDIR)/feenox-slepc_eps.Po
-rm -f pdes/$(DEPDIR)/feenox-solve.Po
-rm -f pdes/laplace/$(DEPDIR)/feenox-bc.Po
-rm -f pdes/laplace/$(DEPDIR)/feenox-bulk.Po
-rm -f pdes/laplace/$(DEPDIR)/feenox-init.Po
-rm -f pdes/laplace/$(DEPDIR)/feenox-parser.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-bc.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-bulk.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-gradient.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-init.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-linearize.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-parser.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-post.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-strain.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-stress.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-strain.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-stress.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-isotropic.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-orthotropic.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-hencky.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-linear-isotropic.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-linear-orthotropic.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-mooney-rivlin.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-neohookean.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-saint_venant-kirchoff.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-bc.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-bulk.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-elastic-isotropic.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-elastic-orthotropic.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-elastic-plane-strain.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-elastic-plane-stress.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-init.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-parser.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-post.Po
-rm -f pdes/neutron_diffusion/$(DEPDIR)/feenox-bc.Po
-rm -f pdes/neutron_diffusion/$(DEPDIR)/feenox-bulk.Po
-rm -f pdes/neutron_diffusion/$(DEPDIR)/feenox-currents.Po
-rm -f pdes/neutron_diffusion/$(DEPDIR)/feenox-init.Po
-rm -f pdes/neutron_diffusion/$(DEPDIR)/feenox-parser.Po
-rm -f pdes/neutron_diffusion/$(DEPDIR)/feenox-post.Po
-rm -f pdes/neutron_sn/$(DEPDIR)/feenox-bc.Po
-rm -f pdes/neutron_sn/$(DEPDIR)/feenox-bulk.Po
-rm -f pdes/neutron_sn/$(DEPDIR)/feenox-init.Po
-rm -f pdes/neutron_sn/$(DEPDIR)/feenox-parser.Po
-rm -f pdes/neutron_sn/$(DEPDIR)/feenox-post.Po
-rm -f pdes/thermal/$(DEPDIR)/feenox-bc.Po
-rm -f pdes/thermal/$(DEPDIR)/feenox-bulk.Po
-rm -f pdes/thermal/$(DEPDIR)/feenox-heatflux.Po
-rm -f pdes/thermal/$(DEPDIR)/feenox-init.Po
-rm -f pdes/thermal/$(DEPDIR)/feenox-parser.Po
-rm -f pdes/thermal/$(DEPDIR)/feenox-post.Po
-rm -f Makefile
distclean-am: clean-am distclean-compile distclean-generic \
distclean-tags
dvi: dvi-am
dvi-am:
html: html-am
html-am:
info: info-am
info-am:
install-data-am:
install-dvi: install-dvi-am
install-dvi-am:
install-exec-am: install-binPROGRAMS
install-html: install-html-am
install-html-am:
install-info: install-info-am
install-info-am:
install-man:
install-pdf: install-pdf-am
install-pdf-am:
install-ps: install-ps-am
install-ps-am:
installcheck-am:
maintainer-clean: maintainer-clean-am
-rm -f ./$(DEPDIR)/feenox-feenox.Po
-rm -f ./$(DEPDIR)/feenox-version.Po
-rm -f ./contrib/$(DEPDIR)/feenox-kdtree.Po
-rm -f ./flow/$(DEPDIR)/feenox-abort.Po
-rm -f ./flow/$(DEPDIR)/feenox-cleanup.Po
-rm -f ./flow/$(DEPDIR)/feenox-conditional.Po
-rm -f ./flow/$(DEPDIR)/feenox-define.Po
-rm -f ./flow/$(DEPDIR)/feenox-error.Po
-rm -f ./flow/$(DEPDIR)/feenox-getptr.Po
-rm -f ./flow/$(DEPDIR)/feenox-init.Po
-rm -f ./flow/$(DEPDIR)/feenox-instruction.Po
-rm -f ./flow/$(DEPDIR)/feenox-run.Po
-rm -f ./flow/$(DEPDIR)/feenox-step.Po
-rm -f ./io/$(DEPDIR)/feenox-file.Po
-rm -f ./io/$(DEPDIR)/feenox-print.Po
-rm -f ./io/$(DEPDIR)/feenox-printf.Po
-rm -f ./io/$(DEPDIR)/feenox-read.Po
-rm -f ./math/$(DEPDIR)/feenox-alias.Po
-rm -f ./math/$(DEPDIR)/feenox-assignment.Po
-rm -f ./math/$(DEPDIR)/feenox-builtin_functionals.Po
-rm -f ./math/$(DEPDIR)/feenox-builtin_functions.Po
-rm -f ./math/$(DEPDIR)/feenox-builtin_vectorfunctions.Po
-rm -f ./math/$(DEPDIR)/feenox-dae.Po
-rm -f ./math/$(DEPDIR)/feenox-expressions.Po
-rm -f ./math/$(DEPDIR)/feenox-fit.Po
-rm -f ./math/$(DEPDIR)/feenox-function.Po
-rm -f ./math/$(DEPDIR)/feenox-matrix.Po
-rm -f ./math/$(DEPDIR)/feenox-solve.Po
-rm -f ./math/$(DEPDIR)/feenox-vector.Po
-rm -f ./mesh/$(DEPDIR)/feenox-boundary_condition.Po
-rm -f ./mesh/$(DEPDIR)/feenox-calculix.Po
-rm -f ./mesh/$(DEPDIR)/feenox-cell.Po
-rm -f ./mesh/$(DEPDIR)/feenox-element.Po
-rm -f ./mesh/$(DEPDIR)/feenox-extrema.Po
-rm -f ./mesh/$(DEPDIR)/feenox-geometry.Po
-rm -f ./mesh/$(DEPDIR)/feenox-gmsh.Po
-rm -f ./mesh/$(DEPDIR)/feenox-init.Po
-rm -f ./mesh/$(DEPDIR)/feenox-integrate.Po
-rm -f ./mesh/$(DEPDIR)/feenox-interpolate.Po
-rm -f ./mesh/$(DEPDIR)/feenox-material.Po
-rm -f ./mesh/$(DEPDIR)/feenox-mesh.Po
-rm -f ./mesh/$(DEPDIR)/feenox-neighbors.Po
-rm -f ./mesh/$(DEPDIR)/feenox-physical_group.Po
-rm -f ./mesh/$(DEPDIR)/feenox-tag_index_map.Po
-rm -f ./mesh/$(DEPDIR)/feenox-vtk.Po
-rm -f ./mesh/$(DEPDIR)/feenox-vtu.Po
-rm -f ./mesh/$(DEPDIR)/feenox-write.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-hexa20.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-hexa27.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-hexa8.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-line2.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-line3.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-point.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-prism15.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-prism6.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-quad4.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-quad8.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-quad9.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-tet10.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-tet4.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-triang3.Po
-rm -f ./mesh/elements/$(DEPDIR)/feenox-triang6.Po
-rm -f ./parser/$(DEPDIR)/feenox-auxiliary.Po
-rm -f ./parser/$(DEPDIR)/feenox-parser.Po
-rm -f pdes/$(DEPDIR)/feenox-blas.Po
-rm -f pdes/$(DEPDIR)/feenox-build.Po
-rm -f pdes/$(DEPDIR)/feenox-dirichlet.Po
-rm -f pdes/$(DEPDIR)/feenox-distribution.Po
-rm -f pdes/$(DEPDIR)/feenox-dump.Po
-rm -f pdes/$(DEPDIR)/feenox-fem.Po
-rm -f pdes/$(DEPDIR)/feenox-gradient.Po
-rm -f pdes/$(DEPDIR)/feenox-init.Po
-rm -f pdes/$(DEPDIR)/feenox-parse.Po
-rm -f pdes/$(DEPDIR)/feenox-petsc_ksp.Po
-rm -f pdes/$(DEPDIR)/feenox-petsc_snes.Po
-rm -f pdes/$(DEPDIR)/feenox-petsc_ts.Po
-rm -f pdes/$(DEPDIR)/feenox-reaction.Po
-rm -f pdes/$(DEPDIR)/feenox-slepc_eps.Po
-rm -f pdes/$(DEPDIR)/feenox-solve.Po
-rm -f pdes/laplace/$(DEPDIR)/feenox-bc.Po
-rm -f pdes/laplace/$(DEPDIR)/feenox-bulk.Po
-rm -f pdes/laplace/$(DEPDIR)/feenox-init.Po
-rm -f pdes/laplace/$(DEPDIR)/feenox-parser.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-bc.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-bulk.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-gradient.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-init.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-linearize.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-parser.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-post.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-strain.Po
-rm -f pdes/mechanical/$(DEPDIR)/feenox-stress.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-strain.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-elastic-plane-stress.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-isotropic.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-expansion-orthotropic.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-hencky.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-linear-isotropic.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-linear-orthotropic.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-mooney-rivlin.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-neohookean.Po
-rm -f pdes/mechanical/materials/$(DEPDIR)/feenox-saint_venant-kirchoff.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-bc.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-bulk.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-elastic-isotropic.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-elastic-orthotropic.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-elastic-plane-strain.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-elastic-plane-stress.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-init.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-parser.Po
-rm -f pdes/modal/$(DEPDIR)/feenox-post.Po
-rm -f pdes/neutron_diffusion/$(DEPDIR)/feenox-bc.Po
-rm -f pdes/neutron_diffusion/$(DEPDIR)/feenox-bulk.Po
-rm -f pdes/neutron_diffusion/$(DEPDIR)/feenox-currents.Po
-rm -f pdes/neutron_diffusion/$(DEPDIR)/feenox-init.Po
-rm -f pdes/neutron_diffusion/$(DEPDIR)/feenox-parser.Po
-rm -f pdes/neutron_diffusion/$(DEPDIR)/feenox-post.Po
-rm -f pdes/neutron_sn/$(DEPDIR)/feenox-bc.Po
-rm -f pdes/neutron_sn/$(DEPDIR)/feenox-bulk.Po
-rm -f pdes/neutron_sn/$(DEPDIR)/feenox-init.Po
-rm -f pdes/neutron_sn/$(DEPDIR)/feenox-parser.Po
-rm -f pdes/neutron_sn/$(DEPDIR)/feenox-post.Po
-rm -f pdes/thermal/$(DEPDIR)/feenox-bc.Po
-rm -f pdes/thermal/$(DEPDIR)/feenox-bulk.Po
-rm -f pdes/thermal/$(DEPDIR)/feenox-heatflux.Po
-rm -f pdes/thermal/$(DEPDIR)/feenox-init.Po
-rm -f pdes/thermal/$(DEPDIR)/feenox-parser.Po
-rm -f pdes/thermal/$(DEPDIR)/feenox-post.Po
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
mostlyclean: mostlyclean-am
mostlyclean-am: mostlyclean-compile mostlyclean-generic
pdf: pdf-am
pdf-am:
ps: ps-am
ps-am:
uninstall-am: uninstall-binPROGRAMS
.MAKE: install-am install-strip
.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \
clean-binPROGRAMS clean-generic cscopelist-am ctags ctags-am \
distclean distclean-compile distclean-generic distclean-tags \
distdir dvi dvi-am html html-am info info-am install \
install-am install-binPROGRAMS install-data install-data-am \
install-dvi install-dvi-am install-exec install-exec-am \
install-html install-html-am install-info install-info-am \
install-man install-pdf install-pdf-am install-ps \
install-ps-am install-strip installcheck installcheck-am \
installdirs maintainer-clean maintainer-clean-generic \
mostlyclean mostlyclean-compile mostlyclean-generic pdf pdf-am \
ps ps-am tags tags-am uninstall uninstall-am \
uninstall-binPROGRAMS
.PRECIOUS: Makefile
@INCLUDE_SLEPC_TRUE@ include $(SLEPC_DIR)/lib/slepc/conf/slepc_variables
@INCLUDE_PETSC_TRUE@ include $(PETSC_DIR)/lib/petsc/conf/variables
undefine DESTDIR # this variable is set by petsc somewhere and we need it empty to make install
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:
# Tell GNU make to disable its built-in pattern rules.
%:: %,v
%:: RCS/%,v
%:: RCS/%
%:: s.%
%:: SCCS/s.%
feenox-1.2/src/Makefile.am 0000664 0001750 0001750 00000010505 15055303017 011146 if INCLUDE_SLEPC
include $(SLEPC_DIR)/lib/slepc/conf/slepc_variables
endif
if INCLUDE_PETSC
include $(PETSC_DIR)/lib/petsc/conf/variables
endif
undefine DESTDIR # this variable is set by petsc somewhere and we need it empty to make install
# include $(top_srcdir)/aminclude_static.am
AUTOMAKE_OPTIONS = subdir-objects
ACLOCAL_AMFLAGS = $(ACLOCAL_FLAGS)
# noinst_LIBRARIES = libfeenox.a
# libfeenox_a_CFLAGS = $(SLEPC_CC_INCLUDES) $(PETSC_CC_INCLUDES) $(CC_INCLUDES) $(DOWNLOADED_GSL_INCLUDES) $(all_includes)
bin_PROGRAMS = feenox
feenox_CFLAGS = $(SLEPC_CC_INCLUDES) $(PETSC_CC_INCLUDES) $(CC_INCLUDES) $(DOWNLOADED_GSL_INCLUDES) $(all_includes)
feenox_LDADD = $(SLEPC_LIB) $(PETSC_LIB) $(DOWNLOADED_GSL_LIBS) $(all_libraries)
#feenox_LIBS = $(CODE_COVERAGE_LIBS)
#feenox_LDFLAGS = -rdynamic
#feenox_sources = feenox.c feenox.h
#feenox_LDADD = libfeenox.a $(SLEPC_LIB) $(PETSC_LIB) $(DOWNLOADED_GSL_LIBS) $(all_libraries)
#libfeenox_a_SOURCES =
feenox_SOURCES = \
./feenox.c \
./feenox.h \
./version.c \
./help.h \
./contrib/kdtree.c \
./contrib/kdtree.h \
./contrib/utlist.h \
./contrib/uthash.h \
./flow/init.c \
./flow/abort.c \
./flow/conditional.c \
./flow/error.c \
./flow/define.c \
./flow/getptr.c \
./flow/cleanup.c \
./flow/instruction.c \
./flow/step.c \
./flow/run.c \
./parser/parser.c \
./parser/parser.h \
./parser/auxiliary.c \
./io/file.c \
./io/read.c \
./io/print.c \
./io/printf.c \
./math/alias.c \
./math/assignment.c \
./math/builtin_functions.c \
./math/builtin_functionals.c \
./math/builtin_vectorfunctions.c \
./math/dae.c \
./math/expressions.c \
./math/fit.c \
./math/function.c \
./math/matrix.c \
./math/solve.c \
./math/vector.c \
./mesh/init.c \
./mesh/geometry.c \
./mesh/neighbors.c \
./mesh/boundary_condition.c \
./mesh/physical_group.c \
./mesh/interpolate.c \
./mesh/material.c \
./mesh/element.c \
./mesh/element.h \
./mesh/cell.c \
./mesh/write.c \
./mesh/integrate.c \
./mesh/extrema.c \
./mesh/mesh.c \
./mesh/gmsh.c \
./mesh/calculix.c \
./mesh/vtk.c \
./mesh/vtu.c \
./mesh/tag_index_map.c \
./mesh/elements/line2.c \
./mesh/elements/line3.c \
./mesh/elements/triang3.c \
./mesh/elements/triang6.c \
./mesh/elements/quad4.c \
./mesh/elements/quad8.c \
./mesh/elements/quad9.c \
./mesh/elements/tet4.c \
./mesh/elements/tet10.c \
./mesh/elements/hexa8.c \
./mesh/elements/hexa20.c \
./mesh/elements/hexa27.c \
./mesh/elements/prism6.c \
./mesh/elements/prism15.c \
./mesh/elements/point.c \
pdes/available.h pdes/parse.c pdes/methods.h pdes/thermal/thermal.h pdes/thermal/post.c pdes/thermal/parser.c pdes/thermal/methods.h pdes/thermal/init.c pdes/thermal/heatflux.c pdes/thermal/bulk.c pdes/thermal/bc.c pdes/solve.c pdes/slepc_eps.c pdes/reaction.c pdes/petsc_ts.c pdes/petsc_snes.c pdes/petsc_ksp.c pdes/neutron_sn/post.c pdes/neutron_sn/parser.c pdes/neutron_sn/neutron_sn.h pdes/neutron_sn/methods.h pdes/neutron_sn/init.c pdes/neutron_sn/bulk.c pdes/neutron_sn/bc.c pdes/neutron_diffusion/post.c pdes/neutron_diffusion/parser.c pdes/neutron_diffusion/neutron_diffusion.h pdes/neutron_diffusion/methods.h pdes/neutron_diffusion/init.c pdes/neutron_diffusion/currents.c pdes/neutron_diffusion/bulk.c pdes/neutron_diffusion/bc.c pdes/modal/post.c pdes/modal/parser.c pdes/modal/modal.h pdes/modal/methods.h pdes/modal/init.c pdes/modal/elastic-plane-stress.c pdes/modal/elastic-plane-strain.c pdes/modal/elastic-orthotropic.c pdes/modal/elastic-isotropic.c pdes/modal/bulk.c pdes/modal/bc.c pdes/mechanical/stress.c pdes/mechanical/strain.c pdes/mechanical/post.c pdes/mechanical/parser.c pdes/mechanical/methods.h pdes/mechanical/mechanical.h pdes/mechanical/materials/saint_venant-kirchoff.c pdes/mechanical/materials/neohookean.c pdes/mechanical/materials/mooney-rivlin.c pdes/mechanical/materials/linear-orthotropic.c pdes/mechanical/materials/linear-isotropic.c pdes/mechanical/materials/hencky.c pdes/mechanical/materials/expansion-orthotropic.c pdes/mechanical/materials/expansion-isotropic.c pdes/mechanical/materials/elastic-plane-stress.c pdes/mechanical/materials/elastic-plane-strain.c pdes/mechanical/linearize.c pdes/mechanical/init.c pdes/mechanical/gradient.c pdes/mechanical/bulk.c pdes/mechanical/bc.c pdes/laplace/parser.c pdes/laplace/methods.h pdes/laplace/laplace.h pdes/laplace/init.c pdes/laplace/bulk.c pdes/laplace/bc.c pdes/init.c pdes/gradient.c pdes/fem.c pdes/dump.c pdes/distribution.c pdes/dirichlet.c pdes/build.c pdes/blas.c feenox-1.2/src/pdes/ 0000775 0001750 0001750 00000000000 15055303133 010123 5 feenox-1.2/src/pdes/blas.c 0000664 0001750 0001750 00000011341 15055303016 011130 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's BLAS wrapper routines
*
* Copyright (C) 2023 Jeremy Theler
*
* This file is part of feenox.
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "../feenox.h"
// c = alpha * A*b
int feenox_blas_Ab(const gsl_matrix *A, const gsl_vector *b, const double alpha, gsl_vector *c) {
feenox_call(gsl_blas_dgemv(CblasNoTrans, alpha, A, b, 0.0, c));
return FEENOX_OK;
}
// c = alpha * A'*b
int feenox_blas_Atb(const gsl_matrix *A, const gsl_vector *b, const double alpha, gsl_vector *c) {
feenox_call(gsl_blas_dgemv(CblasTrans, alpha, A, b, 0.0, c));
return FEENOX_OK;
}
// c += alpha * A*b
int feenox_blas_Ab_accum(const gsl_matrix *A, const gsl_vector *b, const double alpha, gsl_vector *c) {
feenox_call(gsl_blas_dgemv(CblasNoTrans, alpha, A, b, 1.0, c));
return FEENOX_OK;
}
// c += alpha * A'*b
int feenox_blas_Atb_accum(const gsl_matrix *A, const gsl_vector *b, const double alpha, gsl_vector *c) {
feenox_call(gsl_blas_dgemv(CblasTrans, alpha, A, b, 1.0, c));
return FEENOX_OK;
}
// R += alpha * B'*B
int feenox_blas_BtB_accum(const gsl_matrix *B, const double alpha, gsl_matrix *R) {
feenox_call(gsl_blas_dgemm(CblasTrans, CblasNoTrans, alpha, B, B, 1.0, R));
return FEENOX_OK;
}
// R = alpha * B'*B
int feenox_blas_BtB(const gsl_matrix *B, const double alpha, gsl_matrix *R) {
feenox_call(gsl_blas_dgemm(CblasTrans, CblasNoTrans, alpha, B, B, 0.0, R));
return FEENOX_OK;
}
// R = alpha * A*B'
int feenox_blas_ABt(const gsl_matrix *A, const gsl_matrix *B, const double alpha, gsl_matrix *R) {
feenox_call(gsl_blas_dgemm(CblasNoTrans, CblasTrans, alpha, A, B, 0.0, R));
return FEENOX_OK;
}
// R += alpha * B'*C*B
int feenox_blas_BtCB_accum(const gsl_matrix *B, const gsl_matrix *C, gsl_matrix *CB, const double alpha, gsl_matrix *R) {
int alloc = 0;
if (CB == NULL) {
CB = gsl_matrix_alloc(C->size1, B->size2);
alloc = 1;
}
feenox_call(gsl_blas_dgemm(CblasNoTrans, CblasNoTrans, 1.0, C, B, 0.0, CB));
feenox_call(gsl_blas_dgemm(CblasTrans, CblasNoTrans, alpha, B, CB, 1.0, R));
if (alloc) {
gsl_matrix_free(CB);
}
return FEENOX_OK;
}
// R = alpha * B'*C*B
int feenox_blas_BtCB(const gsl_matrix *B, const gsl_matrix *C, gsl_matrix *CB, const double alpha, gsl_matrix *R) {
int alloc = 0;
if (CB == NULL) {
CB = gsl_matrix_alloc(C->size1, B->size2);
alloc = 1;
}
feenox_call(gsl_blas_dgemm(CblasNoTrans, CblasNoTrans, 1.0, C, B, 0.0, CB));
feenox_call(gsl_blas_dgemm(CblasTrans, CblasNoTrans, alpha, B, CB, 0.0, R));
if (alloc) {
gsl_matrix_free(CB);
}
return FEENOX_OK;
}
// R = alpha * B*C*B'
int feenox_blas_BCBt(const gsl_matrix *B, const gsl_matrix *C, gsl_matrix *CB, const double alpha, gsl_matrix *R) {
int alloc = 0;
if (CB == NULL) {
CB = gsl_matrix_alloc(C->size1, B->size2);
alloc = 1;
}
feenox_call(gsl_blas_dgemm(CblasTrans, CblasTrans, 1.0, C, B, 0.0, CB));
feenox_call(gsl_blas_dgemm(CblasNoTrans, CblasTrans, alpha, B, CB, 0.0, R));
if (alloc) {
gsl_matrix_free(CB);
}
return FEENOX_OK;
}
// R += alpha * P'*C*B
int feenox_blas_PtCB_accum(const gsl_matrix *P, const gsl_matrix *C, const gsl_matrix *B, gsl_matrix *CB, const double alpha, gsl_matrix *R) {
int alloc = 0;
if (CB == NULL) {
CB = gsl_matrix_alloc(C->size1, B->size2);
alloc = 1;
}
feenox_call(gsl_blas_dgemm(CblasNoTrans, CblasNoTrans, 1.0, C, B, 0.0, CB));
feenox_call(gsl_blas_dgemm(CblasTrans, CblasNoTrans, alpha, P, CB, 1.0, R));
if (alloc) {
gsl_matrix_free(CB);
}
return FEENOX_OK;
}
// R = alpha * P'*C*B
int feenox_blas_PtCB(const gsl_matrix *P, const gsl_matrix *C, const gsl_matrix *B, gsl_matrix *CB, const double alpha, gsl_matrix *R) {
int alloc = 0;
if (CB == NULL) {
CB = gsl_matrix_alloc(C->size1, B->size2);
alloc = 1;
}
feenox_call(gsl_blas_dgemm(CblasNoTrans, CblasNoTrans, 1.0, C, B, 0.0, CB));
feenox_call(gsl_blas_dgemm(CblasTrans, CblasNoTrans, alpha, P, CB, 0.0, R));
if (alloc) {
gsl_matrix_free(CB);
}
return FEENOX_OK;
} feenox-1.2/src/pdes/build.c 0000664 0001750 0001750 00000036335 15055303016 011320 /*------------ -------------- -------- --- ----- --- -- - -
* feenox routines to build elemental objects
*
* Copyright (C) 2015-2025 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
int feenox_problem_build(void) {
#ifdef HAVE_PETSC
size_t step = ceil((double)feenox.pde.mesh->n_elements/100.0);
if (step < 1) {
step = 1;
}
// TODO: may we don't need to always empty stuff, i.e. if we decide to re-use the matrices
// empty global objects
if (feenox.pde.has_stiffness) {
petsc_call(MatZeroEntries(feenox.pde.K));
}
if (feenox.pde.has_mass) {
petsc_call(MatZeroEntries(feenox.pde.M));
}
if (feenox.pde.has_jacobian_K) {
petsc_call(MatZeroEntries(feenox.pde.JK));
}
if (feenox.pde.has_jacobian_b) {
petsc_call(MatZeroEntries(feenox.pde.Jb));
}
if (feenox.pde.has_rhs) {
petsc_call(VecZeroEntries(feenox.pde.b));
}
if (feenox.pde.has_internal_fluxes) {
petsc_call(VecZeroEntries(feenox.pde.f));
}
size_t volumetric_elements = 0;
int ascii_progress_chars = 0;
for (size_t i = 0; i < feenox.pde.mesh->n_elements; i++) {
element_t *e = &feenox.pde.mesh->element[i];
if (is_element_local(feenox.pde.mesh, e)) {
// ------ progress bar ------------------------------------------
if (feenox.pde.progress_ascii == PETSC_TRUE && (i % step) == 0) {
printf(CHAR_PROGRESS_BUILD);
fflush(stdout);
ascii_progress_chars++;
}
// --------------------------------------------------------------
// TODO: make a list of bulk elements and another with BC elements
if (e->type->dim == feenox.pde.dim) {
// volumetric elements need volumetric builds
// TODO: process only elements that are local, i.e. the partition number
// matches the local rank (not necessarily one to one)
// TODO: check if we can skip re-building in linear transient and/or
// nonlinear BCs only
feenox_call(feenox_problem_build_element_volumetric(e));
volumetric_elements++;
} else if (e->physical_group != NULL) {
// lower-dimensional elements might have BCs (or not)
for (int i = 0; i < e->physical_group->n_bcs; i++) {
bc_data_t *bc_data = NULL;
DL_FOREACH(e->physical_group->bc[i]->bc_datums, bc_data) {
// we only handle natural BCs here, essential BCs are handled in feenox_dirichlet_*()
if (bc_data->set_natural != NULL && bc_data->disabled == 0) {
// and only apply them if the condition holds true (or if there's no condition at all)
if (bc_data->condition.items == NULL || fabs(feenox_expression_eval(&bc_data->condition)) > DEFAULT_CONDITION_THRESHOLD) {
feenox_call(feenox_problem_build_element_natural_bc(e, bc_data));
}
}
}
}
}
}
}
int valid_local = (volumetric_elements > 0);
int valid_global = 0;
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wunused-value"
MPI_Allreduce(&valid_local, &valid_global, 1, MPIU_INT, MPIU_SUM, PETSC_COMM_WORLD);
#pragma GCC diagnostic pop
if (valid_global == 0) {
feenox_push_error_message("no volumetric elements found in '%s'", feenox.pde.mesh->file->name);
return FEENOX_ERROR;
}
// do we need this?
feenox_call(feenox_fem_elemental_caches_reset());
// xxx
feenox_call(feenox_problem_build_assemble());
// TODO: put 100 as a define or as a variable
if (feenox.pde.progress_ascii == PETSC_TRUE) {
if (feenox.mpi_size == 1) {
while (ascii_progress_chars++ < 100) {
printf(CHAR_PROGRESS_BUILD);
}
}
if (feenox.mpi_rank == 0) {
printf("\n");
fflush(stdout);
}
}
#endif
return FEENOX_OK;
}
int feenox_problem_build_elemental_objects_allocate(element_t *this) {
#ifdef HAVE_PETSC
feenox_call(feenox_problem_build_elemental_objects_free());
feenox.fem.current_elemental_type = this->type;
feenox.fem.current_GJ = feenox.pde.dofs * this->type->nodes;
feenox_check_alloc(feenox.fem.l = calloc(feenox.fem.current_GJ, sizeof(PetscInt)));
if (feenox.pde.has_stiffness) {
feenox_check_alloc(feenox.fem.Ki = gsl_matrix_calloc(feenox.fem.current_GJ, feenox.fem.current_GJ));
}
if (feenox.pde.has_mass) {
feenox_check_alloc(feenox.fem.Mi = gsl_matrix_calloc(feenox.fem.current_GJ, feenox.fem.current_GJ));
}
if (feenox.pde.has_jacobian_K) {
feenox_check_alloc(feenox.fem.JKi = gsl_matrix_calloc(feenox.fem.current_GJ, feenox.fem.current_GJ));
}
if (feenox.pde.has_jacobian_b) {
feenox_check_alloc(feenox.fem.Jbi = gsl_matrix_calloc(feenox.fem.current_GJ, feenox.fem.current_GJ));
}
if (feenox.pde.has_rhs) {
feenox_check_alloc(feenox.fem.bi = gsl_vector_calloc(feenox.fem.current_GJ));
if (feenox.fem.vec_f == NULL) {
feenox_check_alloc(feenox.fem.vec_f = gsl_vector_calloc(feenox.pde.dofs));
}
}
if (feenox.pde.has_internal_fluxes) {
feenox_check_alloc(feenox.fem.fi = gsl_vector_calloc(feenox.fem.current_GJ));
feenox_check_alloc(feenox.fem.phii = gsl_vector_calloc(feenox.fem.current_GJ));
}
if (feenox.pde.element_build_allocate_aux != NULL) {
feenox.pde.element_build_allocate_aux(this->type->nodes);
}
#endif
return FEENOX_OK;
}
int feenox_problem_build_elemental_objects_free(void) {
#ifdef HAVE_PETSC
feenox_free(feenox.fem.l);
gsl_matrix_free(feenox.fem.Ki);
feenox.fem.Ki = NULL;
gsl_matrix_free(feenox.fem.Mi);
feenox.fem.Mi = NULL;
gsl_matrix_free(feenox.fem.JKi);
feenox.fem.JKi = NULL;
gsl_matrix_free(feenox.fem.Jbi);
feenox.fem.Jbi = NULL;
gsl_vector_free(feenox.fem.bi);
feenox.fem.bi = NULL;
gsl_vector_free(feenox.fem.vec_f);
feenox.fem.vec_f = NULL;
gsl_vector_free(feenox.fem.fi);
feenox.fem.fi = NULL;
gsl_vector_free(feenox.fem.phii);
feenox.fem.phii = NULL;
feenox.fem.current_elemental_type = NULL;
#endif
return FEENOX_OK;
}
int feenox_problem_build_element_volumetric(element_t *this) {
#ifdef HAVE_PETSC
// TODO: maybe we can relax this requirement
if (this->physical_group == NULL) {
feenox_push_error_message("volumetric element %d does not have an associated physical group", this->tag);
return FEENOX_ERROR;
}
// if the current element's size is not equal to the previous one, re-allocate
// TODO: data-oriented approach, store these objects in native arrays
if (feenox.fem.current_elemental_type != this->type) {
feenox_call(feenox_problem_build_elemental_objects_allocate(this));
}
// initialize to zero the elemental objects
if (feenox.pde.has_stiffness) {
gsl_matrix_set_zero(feenox.fem.Ki);
}
if (feenox.pde.has_mass) {
gsl_matrix_set_zero(feenox.fem.Mi);
}
if (feenox.pde.has_jacobian_K) {
gsl_matrix_set_zero(feenox.fem.JKi);
}
if (feenox.pde.has_jacobian_b) {
gsl_matrix_set_zero(feenox.fem.Jbi);
}
if (feenox.pde.has_rhs) {
gsl_vector_set_zero(feenox.fem.bi);
}
if (feenox.pde.has_internal_fluxes) {
gsl_vector_set_zero(feenox.fem.fi);
}
// compute the indices of the DOFs to ensamble
PetscInt *l = feenox_fem_compute_dof_indices(this, feenox.pde.dofs);
// if the guy has internal forces, we need the solution
if (feenox.pde.has_internal_fluxes) {
petsc_call(VecGetValues(feenox.pde.phi_bc, feenox.fem.current_GJ, l, gsl_vector_ptr(feenox.fem.phii, 0)));
}
// a single call over the element
// if the specific pde wants, it can loop over gauss point in the call
// or it can just do some things that are per-element only and then loop below
if (feenox.pde.element_build_volumetric) {
feenox_call(feenox.pde.element_build_volumetric(this));
}
// or, if there's an entry point for gauss points, then we do the loop here
if (feenox.pde.element_build_volumetric_at_gauss != NULL) {
int Q = this->type->gauss[feenox.pde.mesh->integration].Q;
for (unsigned int q = 0; q < Q; q++) {
// TODO: hardcode the name of the method to allow inlining with LTO
feenox_call(feenox.pde.element_build_volumetric_at_gauss(this, q));
}
}
/*
printf("result\n");
printf("Ki\n");
feenox_debug_print_gsl_matrix(feenox.fem.Ki, stdout);
printf("JKi\n");
feenox_debug_print_gsl_matrix(feenox.fem.JKi, stdout);
printf("fi\n");
feenox_debug_print_gsl_vector(feenox.fem.fi, stdout);
printf("bi\n");
feenox_debug_print_gsl_vector(feenox.fem.bi, stdout);
*/
if (feenox.pde.has_stiffness) {
petsc_call(MatSetValues(feenox.pde.K, feenox.fem.current_GJ, l, feenox.fem.current_GJ, l, gsl_matrix_ptr(feenox.fem.Ki, 0, 0), ADD_VALUES));
}
if (feenox.pde.has_mass) {
petsc_call(MatSetValues(feenox.pde.M, feenox.fem.current_GJ, l, feenox.fem.current_GJ, l, gsl_matrix_ptr(feenox.fem.Mi, 0, 0), ADD_VALUES));
}
if (feenox.pde.has_jacobian_K) {
petsc_call(MatSetValues(feenox.pde.JK, feenox.fem.current_GJ, l, feenox.fem.current_GJ, l, gsl_matrix_ptr(feenox.fem.JKi, 0, 0), ADD_VALUES));
}
if (feenox.pde.has_jacobian_b) {
petsc_call(MatSetValues(feenox.pde.Jb, feenox.fem.current_GJ, l, feenox.fem.current_GJ, l, gsl_matrix_ptr(feenox.fem.Jbi, 0, 0), ADD_VALUES));
}
if (feenox.pde.has_rhs) {
petsc_call(VecSetValues(feenox.pde.b, feenox.fem.current_GJ, l, gsl_vector_ptr(feenox.fem.bi, 0), ADD_VALUES));
}
if (feenox.pde.has_internal_fluxes) {
petsc_call(VecSetValues(feenox.pde.f, feenox.fem.current_GJ, l, gsl_vector_ptr(feenox.fem.fi, 0), ADD_VALUES));
}
#endif
return FEENOX_OK;
}
int feenox_problem_build_element_natural_bc(element_t *this, bc_data_t *bc_data) {
#ifdef HAVE_PETSC
// total number of gauss points
unsigned int Q = this->type->gauss[feenox.pde.mesh->integration].Q;
if (feenox.fem.current_elemental_type != this->type) {
feenox_call(feenox_problem_build_elemental_objects_allocate(this));
}
if (feenox.fem.vec_f == NULL) {
feenox_check_alloc(feenox.fem.vec_f = gsl_vector_calloc(feenox.pde.dofs));
} else {
gsl_vector_set_zero(feenox.fem.vec_f);
}
if (feenox.pde.has_rhs) {
gsl_vector_set_zero(feenox.fem.bi);
}
if (bc_data->fills_matrix) {
gsl_matrix_set_zero(feenox.fem.Ki);
}
if (feenox.pde.has_jacobian_b) {
gsl_matrix_set_zero(feenox.fem.Jbi);
}
for (unsigned int q = 0; q < Q; q++) {
feenox_call(bc_data->set_natural(bc_data, this, q));
}
PetscInt *l = feenox_fem_compute_dof_indices(this, feenox.pde.dofs);
if (feenox.pde.has_rhs == PETSC_TRUE) {
petsc_call(VecSetValues(feenox.pde.b, feenox.fem.current_GJ, l, gsl_vector_ptr(feenox.fem.bi, 0), ADD_VALUES));
}
if (bc_data->fills_matrix) {
petsc_call(MatSetValues(feenox.pde.K, feenox.fem.current_GJ, l,
feenox.fem.current_GJ, l, gsl_matrix_ptr(feenox.fem.Ki, 0, 0), ADD_VALUES));
}
/*
if (feenox.pde.has_jacobian_K) {
petsc_call(MatSetValues(feenox.pde.JK, feenox.pde.elemental_size, l, feenox.pde.elemental_size, l, gsl_matrix_ptr(feenox.pde.JKi, 0, 0), ADD_VALUES));
}
*/
if (feenox.pde.has_jacobian_b) {
petsc_call(MatSetValues(feenox.pde.Jb, feenox.fem.current_GJ, l, feenox.fem.current_GJ, l, gsl_matrix_ptr(feenox.fem.Jbi, 0, 0), ADD_VALUES));
}
#endif
return FEENOX_OK;
}
/*
inline double fino_compute_r_for_axisymmetric(element_t *element, int v) {
double r_for_axisymmetric = 1.0;
if (fino.problem_kind == problem_kind_axisymmetric) {
if (element->x == NULL || element->x[v] == NULL) {
mesh_compute_x_at_gauss(element, v, fino.mesh->integration);
}
if (fino.symmetry_axis == symmetry_axis_y) {
if ((r_for_axisymmetric = element->x[v][0]) < ZERO) {
feenox_push_error_message("axisymmetric problems with respect to y cannot have nodes with x <~ 0");
feenox_runtime_error();
}
} else if (fino.symmetry_axis == symmetry_axis_x) {
if ((r_for_axisymmetric = element->x[v][1]) < ZERO) {
feenox_push_error_message("axisymmetric problems with respect to x cannot have nodes with y <~ 0");
feenox_runtime_error();
}
}
}
return r_for_axisymmetric;
}
*/
int feenox_problem_build_assemble(void) {
#ifdef HAVE_PETSC
// TODOD: which is better? measure!
/*
petsc_call(MatAssemblyBegin(feenox.K, MAT_FINAL_ASSEMBLY));
petsc_call(MatAssemblyEnd(feenox.K, MAT_FINAL_ASSEMBLY));
petsc_call(VecAssemblyBegin(feenox.phi));
petsc_call(VecAssemblyEnd(feenox.phi));
if (feenox.M != NULL) {
petsc_call(MatAssemblyBegin(feenox.M, MAT_FINAL_ASSEMBLY));
petsc_call(MatAssemblyEnd(feenox.M, MAT_FINAL_ASSEMBLY));
}
if (feenox.J != NULL) {
petsc_call(VecAssemblyBegin(feenox.b));
petsc_call(VecAssemblyEnd(feenox.b));
}
*/
if (feenox.pde.phi != NULL) {
petsc_call(VecAssemblyBegin(feenox.pde.phi));
}
if (feenox.pde.b != NULL) {
petsc_call(VecAssemblyBegin(feenox.pde.b));
}
if (feenox.pde.K != NULL) {
petsc_call(MatAssemblyBegin(feenox.pde.K, MAT_FINAL_ASSEMBLY));
}
if (feenox.pde.JK != NULL) {
petsc_call(MatAssemblyBegin(feenox.pde.JK, MAT_FINAL_ASSEMBLY));
}
if (feenox.pde.Jb != NULL) {
petsc_call(MatAssemblyBegin(feenox.pde.Jb, MAT_FINAL_ASSEMBLY));
}
if (feenox.pde.M != NULL) {
petsc_call(MatAssemblyBegin(feenox.pde.M, MAT_FINAL_ASSEMBLY));
}
if (feenox.pde.phi != NULL) {
petsc_call(VecAssemblyEnd(feenox.pde.phi));
}
if (feenox.pde.b != NULL) {
petsc_call(VecAssemblyEnd(feenox.pde.b));
}
if (feenox.pde.K != NULL) {
petsc_call(MatAssemblyEnd(feenox.pde.K, MAT_FINAL_ASSEMBLY));
}
if (feenox.pde.JK != NULL) {
petsc_call(MatAssemblyEnd(feenox.pde.JK, MAT_FINAL_ASSEMBLY));
}
if (feenox.pde.Jb != NULL) {
petsc_call(MatAssemblyEnd(feenox.pde.Jb, MAT_FINAL_ASSEMBLY));
}
if (feenox.pde.M != NULL) {
petsc_call(MatAssemblyEnd(feenox.pde.M, MAT_FINAL_ASSEMBLY));
}
#endif
return FEENOX_OK;
}
int feenox_problem_stiffness_add(element_t *e, unsigned int q, gsl_matrix *Kiq) {
#ifdef HAVE_PETSC
double wdet = feenox_fem_compute_w_det_at_gauss(e, q);
gsl_matrix_scale(Kiq, wdet);
gsl_matrix_add(feenox.fem.Ki, Kiq);
#endif
return FEENOX_OK;
}
int feenox_problem_rhs_add(element_t *e, unsigned int q, double *value) {
#ifdef HAVE_PETSC
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
gsl_vector_set(feenox.fem.vec_f, g, value[g]);
}
double wdet = feenox_fem_compute_w_det_at_gauss_integration(e, q, feenox.pde.mesh->integration);
gsl_matrix *H_Gc = feenox_fem_compute_H_Gc_at_gauss(e, q, feenox.pde.mesh->integration);
feenox_call(feenox_blas_Atb_accum(H_Gc, feenox.fem.vec_f, wdet, feenox.fem.bi));
#endif
return FEENOX_OK;
}
feenox-1.2/src/pdes/dirichlet.c 0000664 0001750 0001750 00000036762 15055303016 012174 /*------------ -------------- -------- --- ----- --- -- - -
* feenox routines to handle dirichlet BCs
*
* Copyright (C) 2015-2023 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
int feenox_problem_dirichlet_add(size_t j_global, unsigned int g, double value) {
feenox.pde.dirichlet_nodes[feenox.pde.dirichlet_k] = feenox.pde.mesh->node[j_global].tag;
feenox.pde.dirichlet_dofs[feenox.pde.dirichlet_k] = g;
#ifdef HAVE_PETSC
feenox.pde.dirichlet_indexes[feenox.pde.dirichlet_k] = feenox.pde.mesh->node[j_global].index_dof[g];
feenox.pde.dirichlet_values[feenox.pde.dirichlet_k] = value;
#endif
feenox.pde.dirichlet_k++;
return FEENOX_OK;
}
int feenox_problem_multifreedom_add(size_t j_global, double *coefficients) {
#ifdef HAVE_PETSC
PetscInt *l = NULL;
feenox_check_alloc(l = calloc(feenox.pde.dofs, sizeof(PetscInt)));
gsl_matrix *c = NULL;
feenox_check_alloc(c = gsl_matrix_alloc(1, feenox.pde.dofs));
for (int g = 0; g < feenox.pde.dofs; g++) {
l[g] = feenox.pde.mesh->node[j_global].index_dof[g];
gsl_matrix_set(c, 0, g, coefficients[g]);
}
feenox.pde.multifreedom_indexes[feenox.pde.multifreedom_k] = l;
feenox.pde.multifreedom_coefficients[feenox.pde.multifreedom_k] = c;
feenox.pde.multifreedom_k++;
#endif
return FEENOX_OK;
}
int feenox_problem_dirichlet_reallocate(size_t n_bcs) {
size_t size_plus_safety = n_bcs + feenox.pde.dofs + 1;
feenox_check_alloc(feenox.pde.dirichlet_nodes = reallocarray(feenox.pde.dirichlet_nodes, size_plus_safety, sizeof(size_t)));
feenox_check_alloc(feenox.pde.dirichlet_dofs = reallocarray(feenox.pde.dirichlet_dofs, size_plus_safety, sizeof(unsigned int)));
feenox_check_alloc(feenox.pde.dirichlet_indexes = reallocarray(feenox.pde.dirichlet_indexes, size_plus_safety, sizeof(PetscInt)));
feenox_check_alloc(feenox.pde.dirichlet_values = reallocarray(feenox.pde.dirichlet_values, size_plus_safety, sizeof(PetscScalar)));
feenox_check_alloc(feenox.pde.dirichlet_derivatives = reallocarray(feenox.pde.dirichlet_derivatives, size_plus_safety, sizeof(PetscScalar)));
feenox_check_alloc(feenox.pde.multifreedom_indexes = reallocarray(feenox.pde.multifreedom_indexes, size_plus_safety, sizeof(PetscInt *)));
feenox_check_alloc(feenox.pde.multifreedom_coefficients = reallocarray(feenox.pde.multifreedom_coefficients, size_plus_safety, sizeof(PetscScalar *)));
return FEENOX_OK;
}
// evaluates the dirichlet BCs and stores them in the internal representation
int feenox_problem_dirichlet_eval(void) {
#ifdef HAVE_PETSC
size_t n_bcs = 0;
if (feenox.pde.dirichlet_rows == 0) {
// on the first iteration, assume that all the nodes need a dirichlet BC
// then we trim the extra space to save memory
// caution! in small problems we might end up with more bcs than nodes
// because there might nodes counted more than once because we loop over elements
n_bcs = 0.5 * feenox.pde.dofs * (feenox.pde.last_node - feenox.pde.first_node);
feenox_call(feenox_problem_dirichlet_reallocate(n_bcs));
} else {
// if we are here then we know more or less the number of BCs we need
n_bcs = feenox.pde.dirichlet_rows;
}
feenox.pde.dirichlet_k = 0;
feenox.pde.multifreedom_k = 0;
for (size_t j_global = feenox.pde.first_node; j_global < feenox.pde.last_node; j_global++) {
// TODO: optimize these ugly nested loops
// maybe if we went the other way and looped over the elements first?
// merge_sort + remove duplicates?
physical_group_t *last_physical_group = NULL;
element_ll_t *element_list = NULL;
LL_FOREACH(feenox.pde.mesh->node[j_global].element_list, element_list) {
element_t *element = element_list->element;
if (element != NULL && element->type->dim < feenox.pde.dim && element->physical_group != NULL && element->physical_group != last_physical_group) {
last_physical_group = element->physical_group;
for (int i = 0; i < element->physical_group->n_bcs; i++) {
bc_data_t *bc_data = NULL;
DL_FOREACH(element->physical_group->bc[i]->bc_datums, bc_data) {
// if there is a condition we evaluate it now
if (bc_data->set_essential != NULL && (bc_data->condition.items == NULL || fabs(feenox_expression_eval(&bc_data->condition)) > DEFAULT_CONDITION_THRESHOLD)) {
// TODO: normal-dependent
if (bc_data->space_dependent) {
feenox_fem_update_coord_vars(feenox.pde.mesh->node[j_global].x);
}
if (feenox.pde.dirichlet_k >= n_bcs) {
n_bcs *= M_SQRT2;
feenox_call(feenox_problem_dirichlet_reallocate(n_bcs));
}
// TODO: for multi-freedom high-order nodes end up with a different penalty weight
// TODO: pass the node instead of the index
feenox_call(bc_data->set_essential(bc_data, element, j_global));
}
}
}
}
}
}
// now we know how many rows we need to change
if (feenox.pde.dirichlet_rows != feenox.pde.dirichlet_k) {
feenox.pde.dirichlet_rows = feenox.pde.dirichlet_k;
// if k == 0 this like freeing
feenox_check_alloc(feenox.pde.dirichlet_nodes = realloc(feenox.pde.dirichlet_nodes, feenox.pde.dirichlet_rows * sizeof(size_t)));
feenox_check_alloc(feenox.pde.dirichlet_dofs = realloc(feenox.pde.dirichlet_dofs, feenox.pde.dirichlet_rows * sizeof(unsigned int)));
feenox_check_alloc(feenox.pde.dirichlet_indexes = realloc(feenox.pde.dirichlet_indexes, feenox.pde.dirichlet_rows * sizeof(PetscInt)));
feenox_check_alloc(feenox.pde.dirichlet_values = realloc(feenox.pde.dirichlet_values, feenox.pde.dirichlet_rows * sizeof(PetscScalar)));
feenox_check_alloc(feenox.pde.dirichlet_derivatives = realloc(feenox.pde.dirichlet_derivatives, feenox.pde.dirichlet_rows * sizeof(PetscScalar)));
}
if (feenox.pde.multifreedom_nodes != feenox.pde.multifreedom_k) {
feenox.pde.multifreedom_nodes = feenox.pde.multifreedom_k;
feenox_check_alloc(feenox.pde.multifreedom_indexes = realloc(feenox.pde.multifreedom_indexes, feenox.pde.multifreedom_nodes * sizeof(PetscInt *)));
feenox_check_alloc(feenox.pde.multifreedom_coefficients = realloc(feenox.pde.multifreedom_coefficients, feenox.pde.multifreedom_nodes * sizeof(gsl_matrix *)));
}
#endif
return FEENOX_OK;
}
#ifdef HAVE_PETSC
// K - stiffness matrix: needs one (alpha) in the diagonal, value (alpha*value) in b and keep symmetry
// b - RHS: needs to be updated when modifying K
// this is called only when solving an explicit KSP (or EPS) so
// it takes K and b and writes K_bc and b_bc
int feenox_problem_dirichlet_set_K(void) {
if (feenox.pde.dirichlet_scale == 0) {
feenox_problem_dirichlet_compute_scale();
}
// sometimes there are hanging nodes with no associated volumes
// this can trigger zeros on the diagonal and MatZeroRowsColumns complains
if (feenox.pde.hanging_nodes) {
int found = 0;
Vec vec_diagonal = NULL;
petsc_call(VecDuplicate(feenox.pde.phi, &vec_diagonal));
petsc_call(MatGetDiagonal(feenox.pde.K, vec_diagonal));
const PetscScalar *array_diagonal;
petsc_call(VecGetArrayRead(vec_diagonal, &array_diagonal));
PetscInt size = feenox.pde.last_row - feenox.pde.first_row;
petsc_call(MatSetOption(feenox.pde.K, MAT_NEW_NONZERO_ALLOCATION_ERR, PETSC_FALSE));
for (PetscInt j = 0; j < size; j++) {
if (array_diagonal[j] == 0) {
found = 1;
if (feenox.pde.hanging_nodes == hanging_nodes_detect) {
size_t index = j / feenox.pde.dofs;
if (j % index == 0) {
// only report the first dof where the hanging node is found
feenox_push_error_message("%ld", feenox.pde.mesh->node[index].tag);
}
} else {
PetscInt row = feenox.pde.first_row + j;
petsc_call(MatSetValue(feenox.pde.K, row, row, feenox.pde.dirichlet_scale, INSERT_VALUES));
}
}
}
petsc_call(MatSetOption(feenox.pde.K, MAT_NEW_NONZERO_ALLOCATION_ERR, PETSC_TRUE));
petsc_call(VecRestoreArrayRead(vec_diagonal, &array_diagonal));
petsc_call(VecDestroy(&vec_diagonal));
int found_global = 0;
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wunused-value"
MPI_Allreduce(&found, &found_global, 1, MPIU_INT, MPIU_SUM, PETSC_COMM_WORLD);
#pragma GCC diagnostic pop
if (found_global) {
if (feenox.pde.hanging_nodes == hanging_nodes_detect) {
feenox_push_error_message("hanging nodes detected:");
return FEENOX_ERROR;
} else {
petsc_call(MatAssemblyBegin(feenox.pde.K, MAT_FINAL_ASSEMBLY));
petsc_call(MatAssemblyEnd(feenox.pde.K, MAT_FINAL_ASSEMBLY));
}
}
}
if (feenox.pde.K_bc == NULL) {
petsc_call(MatDuplicate(feenox.pde.K, MAT_COPY_VALUES, &feenox.pde.K_bc));
petsc_call(PetscObjectSetName((PetscObject)(feenox.pde.K_bc), "K_bc"));
} else {
petsc_call(MatCopy(feenox.pde.K, feenox.pde.K_bc, SAME_NONZERO_PATTERN));
}
// add multifreedom constrains using the penalty method (before setting the rows to zero)
// TODO: multi-freedom constrains with lagrange
if (feenox.pde.multifreedom_nodes > 0) {
gsl_matrix *P = NULL;
feenox_check_alloc(P = gsl_matrix_calloc(feenox.pde.dofs, feenox.pde.dofs));
for (unsigned int k = 0; k < feenox.pde.multifreedom_nodes; k++) {
gsl_matrix *c = feenox.pde.multifreedom_coefficients[k];
PetscInt *l = feenox.pde.multifreedom_indexes[k];
gsl_matrix_set_zero(P);
feenox_call(feenox_blas_BtB(c, feenox_var_value(feenox.pde.vars.penalty_weight), P));
petsc_call(MatSetValues(feenox.pde.K_bc, feenox.pde.dofs, l, feenox.pde.dofs, l, gsl_matrix_ptr(P, 0, 0), ADD_VALUES));
}
gsl_matrix_free(P);
}
int has_multidof_global = 0;
int has_multidof_local = (feenox.pde.multifreedom_nodes > 0);
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wunused-value"
MPI_Allreduce(&has_multidof_local, &has_multidof_global, 1, MPIU_INT, MPIU_SUM, PETSC_COMM_WORLD);
#pragma GCC diagnostic pop
if (has_multidof_global) {
petsc_call(MatAssemblyBegin(feenox.pde.K_bc, MAT_FINAL_ASSEMBLY));
petsc_call(MatAssemblyEnd(feenox.pde.K_bc, MAT_FINAL_ASSEMBLY));
}
// this vector holds the dirichlet values and is used to re-write
// the actual rhs vector b in order to keep the symmetry of K
Vec rhs = NULL;
if (feenox.pde.b != NULL) {
if (feenox.pde.b_bc == NULL) {
petsc_call(VecDuplicate(feenox.pde.b, &feenox.pde.b_bc));
petsc_call(PetscObjectSetName((PetscObject)(feenox.pde.b_bc), "b_bc"));
}
petsc_call(VecCopy(feenox.pde.b, feenox.pde.b_bc));
petsc_call(MatCreateVecs(feenox.pde.K, NULL, &rhs));
petsc_call(VecSetValues(rhs, feenox.pde.dirichlet_rows, feenox.pde.dirichlet_indexes, feenox.pde.dirichlet_values, INSERT_VALUES));
}
PetscScalar diagonal = (feenox.pde.eigen_dirichlet_zero == eigen_dirichlet_zero_K) ? 0 : feenox.pde.dirichlet_scale;
if (feenox.pde.symmetric_K) {
petsc_call(MatZeroRowsColumns(feenox.pde.K_bc, feenox.pde.dirichlet_rows, feenox.pde.dirichlet_indexes, diagonal, rhs, feenox.pde.b_bc));
} else {
petsc_call(MatZeroRows(feenox.pde.K_bc, feenox.pde.dirichlet_rows, feenox.pde.dirichlet_indexes, diagonal, rhs, feenox.pde.b_bc));
}
if (rhs != NULL) {
petsc_call(VecDestroy(&rhs));
}
return FEENOX_OK;
}
// M - mass matrix: needs a zero in the diagonal and the same symmetry scheme that K
// this is called only when solving an EPS so it takes
// M and writes M_bc
int feenox_problem_dirichlet_set_M(void) {
if (feenox.pde.M_bc == NULL) {
petsc_call(MatDuplicate(feenox.pde.M, MAT_COPY_VALUES, &feenox.pde.M_bc));
petsc_call(PetscObjectSetName((PetscObject)(feenox.pde.M_bc), "M_bc"));
} else {
petsc_call(MatCopy(feenox.pde.M, feenox.pde.M_bc, SAME_NONZERO_PATTERN));
}
PetscScalar diagonal = (feenox.pde.eigen_dirichlet_zero == eigen_dirichlet_zero_M) ? 0 : feenox.pde.dirichlet_scale;
if (feenox.pde.symmetric_M) {
petsc_call(MatZeroRowsColumns(feenox.pde.M_bc, feenox.pde.dirichlet_rows, feenox.pde.dirichlet_indexes, diagonal, NULL, NULL));
} else {
petsc_call(MatZeroRows(feenox.pde.M_bc, feenox.pde.dirichlet_rows, feenox.pde.dirichlet_indexes, diagonal, NULL, NULL));
}
return FEENOX_OK;
}
// J - Jacobian matrix: same as K but without the RHS vector
int feenox_problem_dirichlet_set_J(Mat J) {
if (feenox.pde.dirichlet_scale == 0)
{
feenox_problem_dirichlet_compute_scale();
}
// the jacobian is exactly one (actually alpha) for the dirichlet values and zero otherwise without keeping symmetry
petsc_call(MatZeroRowsColumns(J, feenox.pde.dirichlet_rows, feenox.pde.dirichlet_indexes, feenox.pde.dirichlet_scale, NULL, NULL));
// petsc_call(MatZeroRows(J, feenox.pde.dirichlet_rows, feenox.pde.dirichlet_indexes, feenox.pde.dirichlet_scale, NULL, NULL));
return FEENOX_OK;
}
// phi - solution: the BC values are set directly in order to be used as a initial condition or guess
int feenox_problem_dirichlet_set_phi(Vec phi) {
petsc_call(VecSetValues(phi, feenox.pde.dirichlet_rows, feenox.pde.dirichlet_indexes, feenox.pde.dirichlet_values, INSERT_VALUES));
return FEENOX_OK;
}
// phi - solution: the values at the BC DOFs are zeroed
int feenox_problem_dirichlet_set_phi_dot(Vec phi_dot) {
petsc_call(VecSetValues(phi_dot, feenox.pde.dirichlet_rows, feenox.pde.dirichlet_indexes, feenox.pde.dirichlet_derivatives, INSERT_VALUES));
return FEENOX_OK;
}
// r - residual: the BC indexes are set to the difference between the value and the solution, scaled by alpha
int feenox_problem_dirichlet_set_r(Vec r, Vec phi) {
// TODO: put this array somewhere and avoid allocating/freeing each time
PetscScalar *diff;
feenox_check_alloc(diff = calloc(feenox.pde.dirichlet_rows, sizeof(PetscScalar)));
petsc_call(VecGetValues(phi, feenox.pde.dirichlet_rows, feenox.pde.dirichlet_indexes, diff));
if (feenox.pde.dirichlet_scale == 0) {
feenox_problem_dirichlet_compute_scale();
}
for (size_t k = 0; k < feenox.pde.dirichlet_rows; k++) {
diff[k] -= feenox.pde.dirichlet_values[k];
diff[k] *= feenox.pde.dirichlet_scale;
}
petsc_call(VecSetValues(r, feenox.pde.dirichlet_rows, feenox.pde.dirichlet_indexes, diff, INSERT_VALUES));
feenox_free(diff);
return FEENOX_OK;
}
// this is alpha in https://scicomp.stackexchange.com/questions/3298/appropriate-space-for-weak-solutions-to-an-elliptical-pde-with-mixed-inhomogeneo/3300#3300
int feenox_problem_dirichlet_compute_scale(void) {
if (feenox.pde.dirichlet_scale_fraction != 0) {
PetscScalar trace = 0;
petsc_call(MatGetTrace(feenox.pde.K, &trace));
feenox.pde.dirichlet_scale = feenox.pde.dirichlet_scale_fraction * trace/feenox.pde.size_global;
} else if (feenox.pde.dirichlet_scale == 0) {
feenox.pde.dirichlet_scale = 1.0;
}
return FEENOX_OK;
}
#endif
feenox-1.2/src/pdes/distribution.c 0000664 0001750 0001750 00000030455 15055303016 012735 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's approach to handling distributions of properties
*
* Copyright (C) 2015-2025 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
// this method updates the linked list of variables and functions the distribution
// depends on, but it does not set the non_linear nor space_dependent flags
int feenox_distribution_init(distribution_t *this, const char *name) {
feenox_check_alloc(this->name = strdup(name));
if (feenox.pde.mesh->n_groups == 0) {
feenox.pde.mesh->n_groups = HASH_COUNT(feenox.pde.mesh->physical_groups);
}
feenox_check_alloc(this->defined_per_group = calloc(feenox.pde.mesh->n_groups, sizeof(int)));
// first try a property, if this is the case then we have it easy
int n_volumes = 0;
int non_uniform = 0;
HASH_FIND_STR(feenox.mesh.properties, name, this->property);
if (this->property != NULL) {
int full = 1; // asume it is full
physical_group_t *physical_group = NULL;
int i = 0;
for (physical_group = feenox.pde.mesh->physical_groups; physical_group != NULL; physical_group = physical_group->hh.next) {
if (physical_group->dimension == feenox.pde.dim) {
if (physical_group->material != NULL) {
property_data_t *property_data = NULL;
HASH_FIND_STR(physical_group->material->property_datums, this->property->name, property_data);
if (property_data != NULL) {
feenox_pull_dependencies_variables(&this->dependency_variables, property_data->expr.variables);
feenox_pull_dependencies_functions(&this->dependency_functions, property_data->expr.functions);
non_uniform = (n_volumes++ > 0) || (feenox_depends_on_space(this->dependency_variables));
this->defined_per_group[i] = 1;
this->defined = 1;
} else {
full = 0;
}
} else {
full = 0;
}
}
i++;
}
this->full = full;
this->non_uniform = non_uniform;
this->eval = feenox_distribution_eval_property;
this->constant = (feenox_depends_on_time(this->dependency_variables) == 0);
return FEENOX_OK;
}
// try one function for each volume
int full = 1;
non_uniform = 0;
n_volumes = 0;
physical_group_t *physical_group = NULL;
int i = 0;
for (physical_group = feenox.pde.mesh->physical_groups; physical_group != NULL; physical_group = physical_group->hh.next) {
if (physical_group->dimension == feenox.pde.dim) {
char *function_name = NULL;
feenox_check_minusone(asprintf(&function_name, "%s_%s", name, physical_group->name));
function_t *function = NULL;
if ((function = feenox_get_function_ptr(function_name)) != NULL) {
if (function->n_arguments != feenox.pde.dim) {
feenox_push_error_message("function '%s' should have %d arguments instead of %d to be used as a distribution", function->name, feenox.pde.dim, function->n_arguments);
return FEENOX_ERROR;
}
if (this->function == NULL) {
this->function = function;
}
// if there's no explicit material we create one
if (physical_group->material == NULL) {
physical_group->material = feenox_define_material_get_ptr(physical_group->name, feenox.pde.mesh);
}
feenox_call(feenox_pull_dependencies_variables_function(&this->dependency_variables, function));
feenox_call(feenox_pull_dependencies_functions_function(&this->dependency_functions, function));
non_uniform = (n_volumes++ > 0) || (feenox_depends_on_space(this->dependency_variables));
this->defined_per_group[i] = 1;
this->defined = 1;
} else {
full = 0;
}
feenox_free(function_name);
}
i++;
}
if (this->function) {
this->full = full;
this->non_uniform = non_uniform;
this->eval = feenox_distribution_eval_function_local;
this->constant = (feenox_depends_on_time(this->dependency_variables) == 0);
return FEENOX_OK;
}
// try a single function
if ((this->function = feenox_get_function_ptr(name)) != NULL) {
if (this->function->n_arguments != feenox.pde.dim) {
feenox_push_error_message("function '%s' should have %d arguments instead of %d to be used as a distribution", this->function->name, feenox.pde.dim, this->function->n_arguments);
return FEENOX_ERROR;
}
for (int i = 0; i < feenox.pde.mesh->n_groups; i++) {
this->defined_per_group[i] = 1;
}
this->defined = 1;
this->full = 1;
this->eval = feenox_distribution_eval_function_global;
this->expr = &this->function->algebraic_expression;
feenox_call(feenox_pull_dependencies_variables_function(&this->dependency_variables, this->function));
feenox_call(feenox_pull_dependencies_functions_function(&this->dependency_functions, this->function));
this->non_uniform = feenox_depends_on_space(this->dependency_variables);
this->constant = (feenox_depends_on_time(this->dependency_variables) == 0);
return FEENOX_OK;
}
// try one variable for each volume
full = 1;
non_uniform = 0;
n_volumes = 0;
physical_group = NULL;
i = 0;
for (physical_group = feenox.pde.mesh->physical_groups; physical_group != NULL; physical_group = physical_group->hh.next) {
if (physical_group->dimension == feenox.pde.dim) {
char *var_name = NULL;
feenox_check_minusone(asprintf(&var_name, "%s_%s", name, physical_group->name));
var_t *variable = NULL;
if ((variable = feenox_get_variable_ptr(var_name)) != NULL) {
if (this->variable == NULL) {
this->variable = variable;
}
// if there's no explicit material we create one
if (physical_group->material == NULL) {
physical_group->material = feenox_define_material_get_ptr(physical_group->name, feenox.pde.mesh);
}
// if there are many volumes, we are not uniform
non_uniform = (n_volumes++ > 0);
this->defined_per_group[i] = 1;
this->defined = 1;
} else {
full = 0;
}
feenox_free(var_name);
}
i++;
}
if (this->variable) {
this->full = full;
this->non_uniform = non_uniform;
this->eval = feenox_distribution_eval_variable_local;
return FEENOX_OK;
}
// try a single global variable
if ((this->variable = feenox_get_variable_ptr(name)) != NULL) {
for (int i = 0; i < feenox.pde.mesh->n_groups; i++) {
this->defined_per_group[i] = 1;
}
this->defined = 1;
this->full = 1;
this->eval = feenox_distribution_eval_variable_global;
return FEENOX_OK;
}
// not finding an actual distribution is not an error, there are optional distributions
this->full = 0;
this->eval = feenox_distribution_eval;
return FEENOX_OK;
}
// default virtual method for undefined distributions
double feenox_distribution_eval(distribution_t *this, const double *x, material_t *material) {
this->value = 0;
return this->value;
}
double feenox_distribution_eval_variable_global(distribution_t *this, const double *x, material_t *material) {
this->value = feenox_var_value(this->variable);
return this->value;
}
double feenox_distribution_eval_function_global(distribution_t *this, const double *x, material_t *material) {
this->value = feenox_function_eval(this->function, x);
return this->value;
}
double feenox_distribution_eval_variable_local(distribution_t *this, const double *x, material_t *material) {
if (material == NULL) {
this->value = 0;
return this->value;
}
if (material != this->last_material) {
char *var_name = NULL;
feenox_check_minusone(asprintf(&var_name, "%s_%s", this->name, material->name));
if ((this->variable = feenox_get_variable_ptr(var_name)) == NULL) {
feenox_push_error_message("cannot find variable '%s'", var_name);
feenox_runtime_error();
}
this->last_material = material;
feenox_free(var_name);
}
this->value = feenox_var_value(this->variable);
return this->value;
}
double feenox_distribution_eval_function_local(distribution_t *this, const double *x, material_t *material) {
if (material == NULL) {
this->value = 0;
return this->value;
}
if (material != this->last_material) {
char *function_name = NULL;
feenox_check_minusone(asprintf(&function_name, "%s_%s", this->name, material->name));
if ((this->function = feenox_get_function_ptr(function_name)) == NULL) {
feenox_push_error_message("cannot find function '%s'", function_name);
feenox_runtime_error();
}
this->last_material = material;
this->expr = &this->function->algebraic_expression;
feenox_free(function_name);
}
this->value = feenox_function_eval(this->function, x);
return this->value;
}
double feenox_distribution_eval_property(distribution_t *this, const double *x, material_t *material) {
if (material == NULL) {
// these can be zeroes if the properties do not depend on space
if (x != NULL) {
switch (feenox.pde.dim) {
case 1:
feenox_push_error_message("cannot find a material for point x=%g", x[0]);
break;
case 2:
feenox_push_error_message("cannot find a material for point x=%g, y=%g", x[0], x[1]);
break;
case 3:
feenox_push_error_message("cannot find a material for point x=%g, y=%g, z=%g", x[0], x[1], x[2]);
break;
}
} else {
feenox_push_error_message("no material nor coordinate for property '%s'", this->name);
}
feenox_runtime_error();
}
if (material != this->last_material) {
this->last_material = material;
property_data_t *property_data = NULL;
HASH_FIND_STR(material->property_datums, this->property->name, property_data);
this->last_property_data = property_data;
if (property_data != NULL) {
this->expr = &property_data->expr;
} else {
this->expr = NULL;
this->value = 0;
return this->value;
}
}
if (this->last_property_data != NULL) {
if (x != NULL) {
// the property has an expression of x,y & z, it's not a function
feenox_var_value(feenox.mesh.vars.x) = x[0];
if (feenox.pde.dim > 1) {
feenox_var_value(feenox.mesh.vars.y) = x[1];
if (feenox.pde.dim > 2) {
feenox_var_value(feenox.mesh.vars.z) = x[2];
}
}
}
this->value = feenox_expression_eval(&this->last_property_data->expr);
return this->value;
}
this->value = 0;
return 0;
}
int feenox_pull_dependencies_variables_function(var_ll_t **to, function_t *function) {
if (function->algebraic_expression.items != NULL) {
feenox_pull_dependencies_variables(to, function->algebraic_expression.variables);
} else {
// we have to assume it depends on x,y & z
var_ll_t *x;
feenox_check_alloc(x = calloc(1, sizeof(var_ll_t)));
x->var = feenox.mesh.vars.x;
LL_APPEND(*to, x);
if (function->n_arguments > 1) {
var_ll_t *y;
feenox_check_alloc(y = calloc(1, sizeof(var_ll_t)));
y->var = feenox.mesh.vars.y;
LL_APPEND(*to, y);
if (function->n_arguments > 2) {
var_ll_t *z;
feenox_check_alloc(z = calloc(1, sizeof(var_ll_t)));
z->var = feenox.mesh.vars.z;
LL_APPEND(*to, z);
}
}
}
return FEENOX_OK;
}
int feenox_pull_dependencies_functions_function(function_ll_t **to, function_t *function) {
if (function->algebraic_expression.items != NULL) {
feenox_pull_dependencies_functions(to, function->algebraic_expression.functions);
}
return FEENOX_OK;
}
feenox-1.2/src/pdes/dump.c 0000664 0001750 0001750 00000006722 15055303016 011163 /*------------ -------------- -------- --- ----- --- -- - -
* feenox function for dumping PETSc objects
*
* Copyright (C) 2009--2015,2021 Jeremy Theler
*
* This file is part of feenox.
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
int feenox_instruction_dump(void *arg) {
#ifdef HAVE_PETSC
dump_t *dump = (dump_t *)arg;
PetscViewer viewer = NULL;
feenox.pde.missed_dump = arg;
if (dump->K && feenox.pde.K != NULL) {
feenox_call(feenox_dump_open_viewer(dump, "K", &viewer));
petsc_call(MatView(feenox.pde.K, viewer));
petsc_call(PetscViewerDestroy(&viewer));
feenox.pde.missed_dump = NULL;
}
if (dump->K_bc && feenox.pde.K_bc) {
feenox_call(feenox_dump_open_viewer(dump, "K_bc", &viewer));
petsc_call(MatView(feenox.pde.K_bc, viewer));
petsc_call(PetscViewerDestroy(&viewer));
feenox.pde.missed_dump = NULL;
}
if (dump->b && feenox.pde.b) {
feenox_call(feenox_dump_open_viewer(dump, "b", &viewer));
petsc_call(VecView(feenox.pde.b, viewer));
petsc_call(PetscViewerDestroy(&viewer));
feenox.pde.missed_dump = NULL;
}
if (dump->b_bc && feenox.pde.b_bc) {
feenox_call(feenox_dump_open_viewer(dump, "b_bc", &viewer));
petsc_call(VecView(feenox.pde.b_bc, viewer));
petsc_call(PetscViewerDestroy(&viewer));
feenox.pde.missed_dump = NULL;
}
if (dump->M && feenox.pde.M) {
feenox_call(feenox_dump_open_viewer(dump, "M", &viewer));
petsc_call(MatView(feenox.pde.M, viewer));
petsc_call(PetscViewerDestroy(&viewer));
feenox.pde.missed_dump = NULL;
}
if (dump->M_bc && feenox.pde.M_bc) {
feenox_call(feenox_dump_open_viewer(dump, "M_bc", &viewer));
petsc_call(MatView(feenox.pde.M_bc, viewer));
petsc_call(PetscViewerDestroy(&viewer));
feenox.pde.missed_dump = NULL;
}
#endif
return FEENOX_OK;
}
#ifdef HAVE_PETSC
int feenox_dump_open_viewer(dump_t *this, const char *name, PetscViewer *viewer) {
char *path = NULL;
switch (this->format) {
case dump_format_default:
case dump_format_octave:
feenox_check_minusone(asprintf(&path, "%s.m", name));
petsc_call(PetscViewerASCIIOpen(PETSC_COMM_WORLD, path, viewer));
petsc_call(PetscViewerPushFormat(*viewer, PETSC_VIEWER_ASCII_MATLAB ));
feenox_free(path);
break;
case dump_format_binary:
feenox_check_minusone(asprintf(&path, "%s.bin", name));
petsc_call(PetscViewerBinaryOpen(PETSC_COMM_WORLD, path, FILE_MODE_WRITE, viewer));
feenox_free(path);
break;
case dump_format_ascii:
feenox_check_minusone(asprintf(&path, "%s.txt", name));
petsc_call(PetscViewerASCIIOpen(PETSC_COMM_WORLD, path, viewer));
petsc_call(PetscViewerPushFormat(*viewer, PETSC_VIEWER_DEFAULT));
feenox_free(path);
break;
}
return FEENOX_OK;
}
#endif
feenox-1.2/src/pdes/fem.c 0000664 0001750 0001750 00000054503 15055303016 010765 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's mesh-related finite-element routines
*
* Copyright (C) 2014--2024 Jeremy Theler
*
* This file is part of feenox.
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "../feenox.h"
int feenox_fem_elemental_caches_reset(void) {
if (feenox.fem.current_gauss_type != NULL) {
int integration = (feenox.pde.mesh != NULL) ? feenox.pde.mesh->integration : 0;
for (unsigned int q = 0; q < feenox.fem.current_gauss_type->gauss[integration].Q; q++) {
if (feenox.fem.x != NULL && feenox.fem.x[q] != NULL) {
feenox_free(feenox.fem.x[q]);
}
if (feenox.fem.Ji != NULL) {
gsl_matrix_free(feenox.fem.Ji[q]);
feenox.fem.Ji[q] = NULL;
}
if (feenox.fem.invJi != NULL) {
gsl_matrix_free(feenox.fem.invJi[q]);
feenox.fem.invJi[q] = NULL;
}
if (feenox.fem.Bi != NULL) {
gsl_matrix_free(feenox.fem.Bi[q]);
feenox.fem.Bi[q] = NULL;
}
if (feenox.fem.B_Gi != NULL) {
gsl_matrix_free(feenox.fem.B_Gi[q]);
feenox.fem.B_Gi[q] = NULL;
}
}
}
feenox_free(feenox.fem.w);
gsl_matrix_free(feenox.fem.C);
feenox.fem.C = NULL;
feenox_free(feenox.fem.x);
feenox_free(feenox.fem.Ji);
feenox_free(feenox.fem.invJi);
feenox_free(feenox.fem.Bi);
feenox_free(feenox.fem.B_Gi);
feenox.fem.current_gauss_element_tag = 0;
feenox.fem.current_gauss_type = NULL;
return FEENOX_OK;
}
// inverts a small-size square matrix
// TODO: virtual methods linked to the element type?
gsl_matrix *feenox_fem_matrix_invert(const gsl_matrix *direct, gsl_matrix *inverse) {
switch (direct->size1) {
case 1:
if (inverse == NULL) {
feenox_check_alloc_null(inverse = gsl_matrix_alloc(1, 1));
}
gsl_matrix_set(inverse, 0, 0, 1.0/gsl_matrix_get(direct, 0, 0));
break;
case 2:
{
double a = gsl_matrix_get(direct, 0, 0);
double d = gsl_matrix_get(direct, 1, 1);
double b = gsl_matrix_get(direct, 0, 1);
double c = gsl_matrix_get(direct, 1, 0);
double det = a*d - b*c;
double invdet = 1.0/det;
if (inverse == NULL) {
inverse = gsl_matrix_alloc(2, 2);
}
gsl_matrix_set(inverse, 0, 0, +invdet*d);
gsl_matrix_set(inverse, 0, 1, -invdet*b);
gsl_matrix_set(inverse, 1, 0, -invdet*c);
gsl_matrix_set(inverse, 1, 1, invdet*a);
}
break;
case 3:
{
// code from PETSc src/ksp/ksp/tutorials/ex42.c
double a00 = gsl_matrix_get(direct, 0, 0);
double a01 = gsl_matrix_get(direct, 0, 1);
double a02 = gsl_matrix_get(direct, 0, 2);
double a10 = gsl_matrix_get(direct, 1, 0);
double a11 = gsl_matrix_get(direct, 1, 1);
double a12 = gsl_matrix_get(direct, 1, 2);
double a20 = gsl_matrix_get(direct, 2, 0);
double a21 = gsl_matrix_get(direct, 2, 1);
double a22 = gsl_matrix_get(direct, 2, 2);
double t4 = a20 * a01;
double t6 = a20 * a02;
double t8 = a10 * a01;
double t10 = a10 * a02;
double t12 = a00 * a11;
double t14 = a00 * a12;
double den = (t4 * a12 - t6 * a11 - t8 * a22 + t10 * a21 + t12 * a22 - t14 * a21);
double t17 = 1.0 / den;
if (inverse == NULL) {
inverse = gsl_matrix_alloc(3, 3);
}
gsl_matrix_set(inverse, 0, 0, +(a11 * a22 - a12 * a21) * t17);
gsl_matrix_set(inverse, 0, 1, -(a01 * a22 - a02 * a21) * t17);
gsl_matrix_set(inverse, 0, 2, +(a01 * a12 - a02 * a11) * t17);
gsl_matrix_set(inverse, 1, 0, -(-a20 * a12 + a10 * a22) * t17);
gsl_matrix_set(inverse, 1, 1, +(-t6 + a00 * a22) * t17);
gsl_matrix_set(inverse, 1, 2, -(-t10 + t14) * t17);
gsl_matrix_set(inverse, 2, 0, +(-a20 * a11 + a10 * a21) * t17);
gsl_matrix_set(inverse, 2, 1, -(-t4 + a00 * a21) * t17);
gsl_matrix_set(inverse, 2, 2, +(-t8 + t12) * t17);
}
break;
default:
feenox_push_error_message("invalid size %d of matrix to invert", direct->size1);
break;
}
return inverse;
}
inline double feenox_fem_determinant(const gsl_matrix *this) {
if (this == NULL) {
return 1.0;
}
switch (this->size1) {
case 0:
return 1.0;
break;
case 1:
return gsl_matrix_get(this, 0, 0);
break;
case 2:
return + gsl_matrix_get(this, 0, 0) * gsl_matrix_get(this, 1, 1)
- gsl_matrix_get(this, 0, 1) * gsl_matrix_get(this, 1, 0);
break;
case 3:
// compare to eigen's proposal
// TODO: measure
/*
template
inline const typename Derived::Scalar bruteforce_det3_helper
(const MatrixBase& matrix, int a, int b, int c)
{
return matrix.coeff(0,a)
* (matrix.coeff(1,b) * matrix.coeff(2,c) - matrix.coeff(1,c) * matrix.coeff(2,b));
}
template struct determinant_impl
{
static inline typename traits::Scalar run(const Derived& m)
{
return bruteforce_det3_helper(m,0,1,2)
- bruteforce_det3_helper(m,1,0,2)
+ bruteforce_det3_helper(m,2,0,1);
}
};
*/
return + gsl_matrix_get(this, 0, 0) * gsl_matrix_get(this, 1, 1) * gsl_matrix_get(this, 2, 2)
+ gsl_matrix_get(this, 0, 1) * gsl_matrix_get(this, 1, 2) * gsl_matrix_get(this, 2, 0)
+ gsl_matrix_get(this, 0, 2) * gsl_matrix_get(this, 1, 0) * gsl_matrix_get(this, 2, 1)
- gsl_matrix_get(this, 0, 2) * gsl_matrix_get(this, 1, 1) * gsl_matrix_get(this, 2, 0)
- gsl_matrix_get(this, 0, 1) * gsl_matrix_get(this, 1, 0) * gsl_matrix_get(this, 2, 2)
- gsl_matrix_get(this, 0, 0) * gsl_matrix_get(this, 1, 2) * gsl_matrix_get(this, 2, 1);
break;
}
return 1.0;
}
// build the canonic B_c matrix at an arbitrary location xi
gsl_matrix *feenox_fem_compute_B_c(element_t *e, double *xi) {
gsl_matrix *B_c = gsl_matrix_calloc(e->type->dim, e->type->nodes);
for (int d = 0; d < e->type->dim; d++) {
for (int j = 0; j < e->type->nodes; j++) {
gsl_matrix_set(B_c, d, j, e->type->dhdxi(j, d, xi));
}
}
return B_c;
}
// compute the gradient of h with respect to x evaluated at any arbitrary location
gsl_matrix *feenox_fem_compute_B(element_t *e, double *xi) {
gsl_matrix *J = feenox_fem_compute_J(e, xi);
gsl_matrix *invJ = feenox_fem_matrix_invert(J, NULL);
gsl_matrix *B_c = feenox_fem_compute_B_c(e, xi);
gsl_matrix *B = gsl_matrix_calloc(e->type->dim, e->type->nodes);
gsl_blas_dgemm(CblasTrans, CblasNoTrans, 1.0, invJ, B_c, 0.0, B);
return B;
}
inline gsl_matrix *feenox_fem_compute_invJ_at_gauss(element_t *e, unsigned int q, int integration) {
// TODO: macro
gsl_matrix ***invJ = (feenox.fem.cache_J) ? &e->invJ : &feenox.fem.invJi;
if (*invJ == NULL) {
feenox_check_alloc_null(*invJ = calloc(e->type->gauss[integration].Q, sizeof(gsl_matrix *)));
}
if ((*invJ)[q] == NULL) {
(*invJ)[q] = gsl_matrix_calloc(e->type->dim, e->type->dim);
} else if (feenox.fem.cache_J) {
return (*invJ)[q];
}
gsl_matrix *J = feenox_fem_compute_J_at_gauss(e, q, integration);
feenox_fem_matrix_invert(J, (*invJ)[q]);
return (*invJ)[q];
}
// matrix with the coordinates
inline gsl_matrix *feenox_fem_compute_C(element_t *e) {
if (feenox.fem.cache_J == 0 && e->type != feenox.fem.current_gauss_type) {
feenox_fem_elemental_caches_reset();
}
gsl_matrix **C = (feenox.fem.cache_J) ? &e->C : &feenox.fem.C;
if ((*C) == NULL) {
feenox_check_alloc_null((*C) = gsl_matrix_calloc(e->type->dim, e->type->nodes));
} else if (feenox.fem.cache_J || e->tag == feenox.fem.current_gauss_element_tag) {
return (*C);
}
// TODO: this is not cache friendly, is it?
for (unsigned int j = 0; j < e->type->nodes; j++) {
for (unsigned int d = 0; d < e->type->dim; d++) {
gsl_matrix_set((*C), d, j, e->node[j]->x[d]);
}
}
feenox.fem.current_gauss_element_tag = e->tag;
return (*C);
}
inline gsl_matrix *feenox_fem_compute_J(element_t *e, double *xi) {
// warning! this only works with volumetric elements, see dxdr_at_gauss()
// TODO: measure
// dxdxi = J = B_c * C_i
// for (unsigned int d = 0; d < e->type->dim; d++) {
// for (unsigned int d_prime = 0; d_prime < e->type->dim; d_prime++) {
// for (unsigned int j = 0; j < e->type->nodes; j++) {
// gsl_matrix_add_to_element(dxdxi, d, d_prime, e->type->dhdxi(j, d_prime, r) * e->node[j]->x[d]);
// }
// }
// }
gsl_matrix *J = gsl_matrix_calloc(e->type->dim, e->type->dim);
gsl_matrix *B_c = feenox_fem_compute_B_c(e, xi);
gsl_matrix *C = feenox_fem_compute_C(e);
gsl_blas_dgemm(CblasNoTrans, CblasTrans, 1.0, C, B_c, 0.0, J);
gsl_matrix_free(B_c);
return J;
}
inline double *feenox_fem_compute_x_at_gauss_if_needed(element_t *e, unsigned int q, int integration, int condition) {
return (condition) ? feenox_fem_compute_x_at_gauss(e, q, integration) : NULL;
}
inline double *feenox_fem_compute_x_at_gauss_if_needed_and_update_var(element_t *e, unsigned int q, int integration, int condition) {
if (condition) {
double *x = feenox_fem_compute_x_at_gauss(e, q, integration);
feenox_fem_update_coord_vars(x);
return x;
}
return NULL;
}
inline double *feenox_fem_compute_x_at_gauss_and_update_var(element_t *e, unsigned int q, int integration) {
double *x = feenox_fem_compute_x_at_gauss(e, q, integration);
feenox_fem_update_coord_vars(x);
return x;
}
inline material_t *feenox_fem_get_material(element_t *e) {
return (e->physical_group != NULL) ? e->physical_group->material : NULL;
}
inline double feenox_fem_compute_w_det_at_gauss_integration(element_t *e, unsigned int q, int integration) {
if (feenox.fem.cache_J == 0 && e->type != feenox.fem.current_gauss_type) {
feenox_fem_elemental_caches_reset();
}
double **w = (feenox.fem.cache_J) ? &e->w : &feenox.fem.w;
if ((*w) == NULL) {
feenox_check_alloc((*w) = calloc(e->type->gauss[integration].Q, sizeof(double)));
feenox.fem.current_gauss_type = e->type;
} else if (((feenox.fem.current_weight_element_tag == e->tag && feenox.fem.current_weight_gauss_point == q) || feenox.fem.cache_J) && (*w)[q] != 0) {
return (*w)[q];
}
gsl_matrix *J = feenox_fem_compute_J_at_gauss(e, q, integration);
// TODO: choose to complain about zero or negative?
// TODO: choose to take the absolute value or not? put these two as defines
double det = feenox_fem_determinant(J);
(*w)[q] = e->type->gauss[integration].w[q] * fabs(det);
feenox.fem.current_weight_element_tag = e->tag;
feenox.fem.current_weight_gauss_point = q;
return (*w)[q];
}
inline gsl_matrix *feenox_fem_compute_J_at_gauss_1d(element_t *e, unsigned int q, int integration, gsl_matrix *J) {
// this is a 1d particularization of the det(J'*J) trick
// TODO: should we code the generic rectangular version of the "square" case below?
double s1 = 0;
for (unsigned int d = 0; d < 3; d++) {
double s2 = 0;
for (unsigned int j = 0; j < e->type->nodes; j++) {
s2 += e->node[j]->x[d] * gsl_matrix_get(e->type->gauss[integration].B_c[q], 0, j);
}
s1 += s2*s2;
}
if (J == NULL) {
feenox_check_alloc_null(J = gsl_matrix_calloc(1,1));
}
gsl_matrix_set(J, 0, 0, sqrt(s1));
return J;
}
inline gsl_matrix *feenox_fem_compute_J_at_gauss_2d(element_t *e, unsigned int q, int integration, gsl_matrix *J) {
/*
* if we are a triangle or a quadrangle (quadrangles are two triangles so they are alike)
* but we do not live on the x-y plane we have to do some tricks:
* we need a transformation matrix R that maps the outward normal n into [0,0,1]
* i.e. such that when R is applied to the triangle, it will now live in the xy plane
* note that there are infinite Rs that do this (because the resulting triangle can look like this
*
*
* + +----------+
* |`\ `\ |
* | `\ `\ |
* | `\ or like this `\ |
* | `\ `\ |
* | `\ `\ |
* +----------+ `+
*
* see
* http://math.stackexchange.com/questions/180418/calculate-rotation-matrix-to-align-vector-a-to-vector-b-in-3d
*/
// the versor in the z direction
double e_z[3] = {0, 0, 1};
double t[3];
feenox_mesh_cross(e->normal, e_z, t);
// double c = feenox_fem_dot(e->normal, e_z); // cosine
double k = 1/(1+feenox_mesh_dot(e->normal, e_z));
/*
(%i4) T:matrix([0, -t2, t1],[t2, 0, -t0],[-t1, t0, 0]);
[ 0 - t2 t1 ]
[ ]
(%o4) [ t2 0 - t0 ]
[ ]
[ - t1 t0 0 ]
(%i5) T . T;
[ 2 2 ]
[ - t2 - t1 t0 t1 t0 t2 ]
[ ]
(%o5) [ 2 2 ]
[ t0 t1 - t2 - t0 t1 t2 ]
[ ]
[ 2 2 ]
[ t0 t2 t1 t2 - t1 - t0 ]
*/
double R[3][3] = {{ 1 + k * (-t[2]*t[2] - t[1]*t[1]),
-t[2] + k * (t[0]*t[1]),
+t[1] + k * (t[0]*t[2])},
{
+t[2] + k * (t[0]*t[1]),
1 + k * (-t[2]*t[2] - t[0]*t[0]),
-t[0] + k * (t[1]*t[2])},
{
-t[1] + k * (t[0]*t[2]),
+t[0] + k * (t[1]*t[2]),
1 + k * (-t[1]*t[1] - t[0]*t[0])
}};
// TODO: measure
// write the new coordinates matrix and compute J (a.k.a dxdxi)
// as the product between B and C
if (J == NULL) {
J = gsl_matrix_calloc(2,2);
}
double s = 0;
for (int d = 0; d < 2; d++) {
for (int d_prime = 0; d_prime < 2; d_prime++) {
s = 0;
for (int j = 0; j < e->type->nodes; j++) {
s += gsl_matrix_get(e->type->gauss[integration].B_c[q], d, j) *
(e->node[j]->x[0] * R[d_prime][0] +
e->node[j]->x[1] * R[d_prime][1] +
e->node[j]->x[2] * R[d_prime][2]);
}
gsl_matrix_set(J, d, d_prime, s);
}
}
return J;
}
inline gsl_matrix *feenox_fem_compute_J_square_at_gauss(element_t *e, unsigned int q, int integration, gsl_matrix *J) {
// we can do a full traditional computation
// i.e. lines are in the x axis
// surfaces are on the xy plane
// volumes are always volumes!
if (e->type->dim == 0)
{
return NULL;
}
// TODO: benchmark
/*
double xi = 0;
for (unsigned int d = 0; d < dim; d++) {
for (unsigned int d_prime = 0; d_prime < dim; d_prime++) {
xi = 0;
for (unsigned int j = 0; j < nodes; j++) {
xi += gsl_matrix_get(e->type->gauss[integration].B_c[q], d_prime, j) * e->node[j]->x[d];
}
gsl_matrix_set(e->J[q], d, d_prime, xi);
}
}
*/
gsl_matrix *C = feenox_fem_compute_C(e);
if (J == NULL) {
feenox_check_alloc_null(J = gsl_matrix_calloc(e->type->dim, e->type->dim));
}
gsl_blas_dgemm(CblasNoTrans, CblasTrans, 1.0, C, e->type->gauss[integration].B_c[q], 0.0, J);
return J;
}
// magic magic magic!
inline gsl_matrix *feenox_fem_compute_J_at_gauss(element_t *e, unsigned int q, int integration) {
if (feenox.fem.cache_J == 0 && e->type != feenox.fem.current_gauss_type) {
feenox_fem_elemental_caches_reset();
}
gsl_matrix ***J = (feenox.fem.cache_J) ? &e->J : &feenox.fem.Ji;
if ((*J) == NULL) {
feenox_check_alloc_null((*J) = calloc(e->type->gauss[integration].Q, sizeof(gsl_matrix *)));
feenox.fem.current_gauss_type = e->type;
}
if ((*J)[q] == NULL) {
feenox_check_alloc_null((*J)[q] = gsl_matrix_calloc(e->type->dim, e->type->dim));
} else if ((feenox.fem.current_gauss_element_tag == e->tag && feenox.fem.current_jacobian_gauss_point == q) || feenox.fem.cache_J) {
return (*J)[q];
}
// TODO: once the problem type and dimension is set, we know which element type
// needs which kind of xixdr computation: we can then use some virtual
// functions defined in e->type
if (e->type->dim == 1 && (e->node[0]->x[1] != 0 || e->node[1]->x[1] != 0 ||
e->node[0]->x[2] != 0 || e->node[1]->x[2] != 0)) {
(*J)[q] = feenox_fem_compute_J_at_gauss_1d(e, q, integration, (*J)[q]);
} else if (e->type->dim == 2 && (e->node[0]->x[2] != 0 || e->node[1]->x[2] != 0 || e->node[2]->x[2])) {
feenox_mesh_compute_normal_2d(e);
double eps = feenox_var_value(feenox.mesh.vars.eps);
// ANDs are more efficient than ORs because the minute one does not hold the evaluation finishes
if (fabs(e->normal[0]) < eps && fabs(e->normal[1]) < eps && fabs(fabs(e->normal[2])-1) < eps) {
(*J)[q] = feenox_fem_compute_J_square_at_gauss(e, q, integration, (*J)[q]);
} else {
(*J)[q] = feenox_fem_compute_J_at_gauss_2d(e, q, integration, (*J)[q]);
}
} else {
(*J)[q] = feenox_fem_compute_J_square_at_gauss(e, q, integration, (*J)[q]);
}
feenox.fem.current_jacobian_element_tag = e->tag;
feenox.fem.current_jacobian_gauss_point = q;
return (*J)[q];
}
inline double *feenox_fem_compute_x_at_gauss(element_t *e, unsigned int q, int integration) {
if (feenox.fem.cache_J == 0 && e->type != feenox.fem.current_gauss_type) {
feenox_fem_elemental_caches_reset();
}
double ***x = (feenox.fem.cache_J) ? &e->x : &feenox.fem.x;
if ((*x) == NULL) {
feenox_check_alloc_null((*x) = calloc(e->type->gauss[integration].Q, sizeof(double *)));
feenox.fem.current_gauss_type = e->type;
}
if ((*x)[q] == NULL) {
feenox_check_alloc_null((*x)[q] = calloc(3, sizeof(double)));
} else if (feenox.fem.cache_J) {
return (*x)[q];
}
gsl_matrix *H = feenox_fem_compute_H_c_at_gauss(e, q, integration);
(*x)[q][0] = (*x)[q][1] = (*x)[q][2] = 0;
for (unsigned int j = 0; j < e->type->nodes; j++) {
double h = gsl_matrix_get(H, 0, j);
for (unsigned int d = 0; d < 3; d++) {
(*x)[q][d] += h * e->node[j]->x[d];
}
}
return (*x)[q];
}
inline gsl_matrix *feenox_fem_compute_H_c_at_gauss(element_t *e, unsigned int q, int integration) {
return e->type->gauss[integration].H_c[q];
}
inline gsl_matrix *feenox_fem_compute_H_Gc_at_gauss(element_t *e, unsigned int q, int integration) {
if (e->type->H_Gc == NULL) {
if (feenox.pde.dofs == 1) {
e->type->H_Gc = e->type->gauss[integration].H_c;
return e->type->H_Gc[q];
} else {
e->type->H_Gc = calloc(e->type->gauss[integration].Q, sizeof(gsl_matrix *));
}
}
if (e->type->H_Gc[q] == NULL) {
unsigned int J = e->type->nodes;
unsigned int G = feenox.pde.dofs;
e->type->H_Gc[q] = gsl_matrix_calloc(G, G*J);
// TODO: measure order of loops
for (unsigned int j = 0; j < J; j++) {
double h = gsl_matrix_get(e->type->gauss[integration].H_c[q], 0, j);
for (unsigned int g = 0; g < G; g++) {
gsl_matrix_set(e->type->H_Gc[q], g, G*j+g, h);
}
}
}
return e->type->H_Gc[q];
}
inline gsl_matrix *feenox_fem_compute_B_at_gauss_integration(element_t *e, unsigned int q, int integration) {
if (feenox.fem.cache_J == 0 && e->type != feenox.fem.current_gauss_type) {
feenox_fem_elemental_caches_reset();
}
gsl_matrix ***B = (feenox.fem.cache_B) ? &e->B : &feenox.fem.Bi;
if ((*B) == NULL) {
feenox_check_alloc_null((*B) = calloc(e->type->gauss[integration].Q, sizeof(gsl_matrix *)));
feenox.fem.current_gauss_type = e->type;
}
if ((*B)[q] == NULL) {
(*B)[q] = gsl_matrix_calloc(e->type->dim, e->type->nodes);
} else if (feenox.fem.cache_B) {
return (*B)[q];
}
gsl_matrix *invJ = feenox_fem_compute_invJ_at_gauss(e, q, feenox.pde.mesh->integration);
gsl_blas_dgemm(CblasTrans, CblasNoTrans, 1.0, invJ, e->type->gauss[integration].B_c[q], 0.0, (*B)[q]);
return (*B)[q];
}
inline gsl_matrix *feenox_fem_compute_B_G_at_gauss(element_t *e, unsigned int q, int integration) {
unsigned int G = feenox.pde.dofs;
if (G == 1) {
// for G=1 B_G = B
return feenox_fem_compute_B_at_gauss_integration(e, q, integration);
}
gsl_matrix ***B_G = (feenox.fem.cache_B) ? &e->B_G : &feenox.fem.B_Gi;
if ((*B_G) == NULL) {
feenox_check_alloc_null((*B_G) = calloc(e->type->gauss[integration].Q, sizeof(gsl_matrix *)));
}
unsigned int J = e->type->nodes;
unsigned int D = e->type->dim;
if ((*B_G)[q] == NULL) {
(*B_G)[q] = gsl_matrix_calloc(G*D, G*J);
} else if (feenox.fem.cache_B) {
return (*B_G)[q];
}
gsl_matrix *B = feenox_fem_compute_B_at_gauss_integration(e, q, integration);
for (unsigned int d = 0; d < D; d++) {
size_t Gd = G*d;
for (unsigned int j = 0; j < J; j++) {
size_t Gj = G*j;
double dhdxi = gsl_matrix_get(B, d, j);
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
gsl_matrix_set((*B_G)[q], Gd+g, Gj+g, dhdxi);
}
}
}
return (*B_G)[q];
}
#ifdef HAVE_PETSC
PetscInt *feenox_fem_compute_dof_indices(element_t *e, int G) {
if (feenox.fem.l == NULL) {
feenox_check_alloc_null(feenox.fem.l = calloc(G * e->type->nodes, sizeof(PetscInt)));
}
// the vector l contains the global indexes of each DOF in the element
// note that this vector is always node major independently of the global ordering
for (unsigned int j = 0; j < e->type->nodes; j++) {
for (unsigned int g = 0; g < G; g++) {
feenox.fem.l[G*j + g] = e->node[j]->index_dof[g];
}
}
return feenox.fem.l;
}
#endif
feenox-1.2/src/pdes/gradient.c 0000664 0001750 0001750 00000026363 15055303016 012016 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for computing the gradients of the PDE solutions
*
* Copyright (C) 2021 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
int feenox_problem_gradient_compute(void) {
#ifdef HAVE_PETSC
/*
// this is needed only for uncertainty in gradients
if (feenox.pde.m2 == NULL) {
feenox_check_alloc(feenox.pde.m2 = gsl_matrix_calloc(feenox.pde.dofs, feenox.pde.dim));
}
*/
// the mesh for "rough" mode is different
mesh_t *mesh = (feenox.pde.rough == 0) ? feenox.pde.mesh : feenox.pde.mesh_rough;
// number of steps we need to make for progress bar
size_t step = ceil((double)(mesh->n_elements + mesh->n_nodes)*feenox.mpi_size/100.0);
if (step < 1) {
step = 1;
}
unsigned int g = 0;
unsigned int m = 0;
if (feenox.pde.gradient[0][0]->vector_value == NULL) {
// gradient vector
for (g = 0; g < feenox.pde.dofs; g++) {
for (m = 0; m < feenox.pde.dim; m++) {
// derivative of the degree of freedom g with respect to dimension m
feenox_problem_fill_aux_solution(feenox.pde.gradient[g][m]);
// feenox_gradient_fill(feenox.pde, delta_gradient[g][m]);
}
}
if (feenox.pde.gradient_fill != NULL) {
feenox_call(feenox.pde.gradient_fill());
}
}
// step 1. sweep elements and compute tensors at each node of each element
size_t progress = 0;
unsigned int ascii_progress_chars = 0;
for (size_t i = 0; i < mesh->n_elements; i++) {
if ((feenox.pde.progress_ascii == PETSC_TRUE) && (progress++ % step) == 0) {
printf(CHAR_PROGRESS_GRADIENT);
fflush(stdout);
ascii_progress_chars++;
}
if (mesh->element[i].type->dim == feenox.pde.dim) {
feenox_call(feenox_problem_gradient_compute_at_element(&mesh->element[i], mesh));
}
}
// step 2. sweep nodes of the output mesh (same as input in smooth, rough in rough)
for (size_t j = 0; j < mesh->n_nodes; j++) {
if ((feenox.pde.progress_ascii == PETSC_TRUE) && (progress++ % step) == 0) {
printf(CHAR_PROGRESS_GRADIENT);
fflush(stdout);
ascii_progress_chars++;
}
if (feenox.pde.rough == 0) {
feenox_call(feenox_problem_gradient_smooth_at_node(&mesh->node[j]));
}
// we now have the averages, now fill in the functions
for (g = 0; g < feenox.pde.dofs; g++) {
for (m = 0; m < feenox.pde.dim; m++) {
feenox_vector_set(feenox.pde.gradient[g][m]->vector_value, j, gsl_matrix_get(mesh->node[j].dphidx, g, m));
// feenox.pde.delta_gradient[g][m]->data_value[j] = gsl_matrix_get(mesh->node[j].delta_dphidx, g, m);
}
}
if (feenox.pde.gradient_fill_fluxes != NULL) {
feenox_call(feenox.pde.gradient_fill_fluxes(mesh, j));
}
}
// TODO: put 100 as a define or as a variable
if (feenox.pde.progress_ascii == PETSC_TRUE) {
if (feenox.mpi_size == 1) {
while (ascii_progress_chars++ < 100) {
printf(CHAR_PROGRESS_GRADIENT);
}
}
if (feenox.mpi_rank == 0) {
printf("\n");
fflush(stdout);
}
}
#endif
return FEENOX_OK;
}
int feenox_problem_gradient_compute_at_element(element_t *e, mesh_t *mesh) {
unsigned int Q = e->type->gauss[mesh->integration].Q;
unsigned int J = e->type->nodes;
// if already alloced, no need to realloc
if (e->dphidx_node == NULL) {
feenox_check_alloc(e->dphidx_node = calloc(J, sizeof(gsl_matrix *)));
for (unsigned int j = 0; j < J; j++) {
feenox_check_alloc(e->dphidx_node[j] = gsl_matrix_calloc(feenox.pde.dofs, feenox.pde.dim));
}
}
if (feenox.pde.rough == 0) {
// TODO: virtual methods
/*
if (feenox.pde.gradient_element_weight == gradient_weight_volume) {
this->type->element_volume(this);
this->weight = this->volume;
} else if (fino.gradient_element_weight == gradient_weight_quality) {
mesh_compute_quality(mesh, this);
this->weight = this->quality;
} else if (fino.gradient_element_weight == gradient_weight_volume_times_quality) {
this->type->element_volume(this);
mesh_compute_quality(mesh, this);
this->weight = this->volume*GSL_MAX(this->quality, 1);
} else if (fino.gradient_element_weight == gradient_weight_flat) {
element->weight = 1;
}
*/
e->gradient_weight = 1;
}
// if we were asked to extrapolate from gauss, we compute all the nodal values
// at once by left-multiplying the gauss values by the (possibly-rectangular)
size_t j_global = 0;
// feenox.pde.gradient_evaluation = gradient_at_nodes;
if (feenox.pde.gradient_evaluation == gradient_gauss_extrapolated && e->type->gauss[mesh->integration].extrap != NULL) {
// extrapolation matrix to get the nodal values
// TODO: allocate each time or have a holder?
gsl_vector *at_gauss = NULL;
feenox_check_alloc(at_gauss = gsl_vector_alloc(Q));
gsl_vector *at_nodes = NULL;
feenox_check_alloc(at_nodes = gsl_vector_alloc(J));
if (e->dphidx_gauss == NULL) {
feenox_check_alloc(e->dphidx_gauss = calloc(Q, sizeof(gsl_matrix *)));
}
for (unsigned int q = 0; q < Q; q++) {
if (e->dphidx_gauss[q] == NULL) {
feenox_check_alloc(e->dphidx_gauss[q] = gsl_matrix_calloc(feenox.pde.dofs, feenox.pde.dim));
} else {
gsl_matrix_set_zero(e->dphidx_gauss[q]);
}
gsl_matrix *B = feenox_fem_compute_B_at_gauss_integration(e, q, mesh->integration);
// aca habria que hacer una matriz con los phi globales
// (de j y g, que de paso no depende de q asi que se podria hacer afuera del for de q)
// y ver como calcular la matriz dphidx como producto de B y esta matriz
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
for (unsigned int d = 0; d < feenox.pde.dim; d++) {
for (unsigned int j = 0; j < e->type->nodes; j++) {
j_global = e->node[j]->index_mesh;
gsl_matrix_add_to_element(e->dphidx_gauss[q], g, d, gsl_matrix_get(B, d, j) * mesh->node[j_global].phi[g]);
}
}
}
}
// take the product of the extrapolation matrix times the values at the gauss points
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
for (unsigned int d = 0; d < feenox.pde.dim; d++) {
for (unsigned int q = 0; q < Q; q++) {
gsl_vector_set(at_gauss, q, gsl_matrix_get(e->dphidx_gauss[q], g, d));
}
gsl_blas_dgemv(CblasNoTrans, 1.0, e->type->gauss[mesh->integration].extrap, at_gauss, 0.0, at_nodes);
for (unsigned int j = 0; j < J; j++) {
gsl_matrix_set(e->dphidx_node[j], g, d, gsl_vector_get(at_nodes, j));
}
}
}
gsl_vector_free(at_gauss);
gsl_vector_free(at_nodes);
} else {
for (unsigned int j = 0; j < J; j++) {
j_global = e->node[j]->index_mesh;
if (e->type->node_parents != NULL && e->type->node_parents[j] != NULL && feenox.pde.gradient_highorder_nodes == gradient_average) {
// average of parents
node_relative_t *parent = NULL;
double den = 0;
LL_FOREACH(e->type->node_parents[j], parent) {
den += 1.0;
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
for (unsigned int d = 0; d < feenox.pde.dim; d++) {
gsl_matrix_add_to_element(e->dphidx_node[j], g, d, gsl_matrix_get(e->dphidx_node[parent->index], g, d));
}
}
}
gsl_matrix_scale(e->dphidx_node[j], 1.0/den);
} else {
// direct evaluation at the nodes
gsl_matrix *B = feenox_fem_compute_B(e, e->type->node_coords[j]);
// the derivatives of each dof g with respect to the coordinate mas nueve derivadas (o menos)
// TODO: como arriba, aunque hay que pelar ojo si hay menos DOFs
size_t j_global_prime = 0;
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
for (unsigned int d = 0; d < feenox.pde.dim; d++) {
for (unsigned int j_local_prime = 0; j_local_prime < J; j_local_prime++) {
j_global_prime = e->node[j_local_prime]->index_mesh;
gsl_matrix_add_to_element(e->dphidx_node[j], g, d, gsl_matrix_get(B, j_local_prime, d) * mesh->node[j_global_prime].phi[g]);
}
}
}
gsl_matrix_free(B);
}
}
}
return FEENOX_OK;
}
int feenox_problem_gradient_smooth_at_node(node_t *node) {
double *mean = NULL;
double *current = NULL;
double delta = 0;
double sum_weight = 0;
double rel_weight = 0;
int found = 0;
if (node->dphidx == NULL) {
feenox_check_alloc(node->dphidx = gsl_matrix_calloc(feenox.pde.dofs, feenox.pde.dim));
} else {
gsl_matrix_set_zero(node->dphidx);
}
/*
if (node->delta_dphidx == NULL) {
node->delta_dphidx = gsl_matrix_calloc(feenox.pde.dofs, feenox.pde.dim);
} else {
gsl_matrix_set_zero(node->delta_dphidx);
}
*/
if (feenox.pde.gradient_alloc_nodal_fluxes != NULL) {
feenox_call(feenox.pde.gradient_alloc_nodal_fluxes(node));
}
size_t j = 0;
unsigned int g = 0;
unsigned int m = 0;
unsigned int n = 0;
element_t *element = NULL;
element_ll_t *associated_element = NULL;
// gsl_matrix_set_zero(feenox.pde.m2);
LL_FOREACH(node->element_list, associated_element) {
element = associated_element->element;
if (element->dphidx_node != NULL) {
found = 0;
for (j = 0; !found && j < element->type->nodes; j++) {
if (element->node[j] == node) {
n++;
found = 1;
sum_weight += element->gradient_weight;
rel_weight = element->gradient_weight / sum_weight;
// derivative and uncertainties according to weldford
for (g = 0; g < feenox.pde.dofs; g++) {
for (m = 0; m < feenox.pde.dim; m++) {
mean = gsl_matrix_ptr(node->dphidx, g, m);
current = gsl_matrix_ptr(element->dphidx_node[j], g, m);
delta = *current - *mean;
*mean += rel_weight * delta;
// gsl_matrix_add_to_element(feenox.pde.m2, g, m, element->gradient_weight * delta * ((*current)-(*mean)));
// gsl_matrix_set(node->delta_dphidx, g, m, sqrt(gsl_matrix_get(feenox.pde.m2, g, m)/sum_weight));
}
}
if (feenox.pde.gradient_add_elemental_contribution_to_node != NULL) {
feenox_call(feenox.pde.gradient_add_elemental_contribution_to_node(node, element, j, rel_weight));
}
}
}
}
}
return FEENOX_OK;
}
feenox-1.2/src/pdes/init.c 0000664 0001750 0001750 00000077216 15055303016 011167 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's PDE initialization routines
*
* Copyright (C) 2015--2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include // for signal
#include // for sysconf
#include // for setenv
int feenox_problem_parse_time_init(void) {
#ifdef HAVE_PETSC
if (feenox.pde.petscinit_called == PETSC_TRUE) {
return FEENOX_OK;
}
if (sizeof(PetscReal) != sizeof(PetscScalar)) {
feenox_push_error_message("PETSc should be compiled with real scalar types and we have PetscReal = %d and PetscScalar = %d", sizeof(PetscReal), sizeof(PetscScalar));
return FEENOX_ERROR;
}
if (sizeof(PetscScalar) != sizeof(double)) {
feenox_push_error_message("PETSc should be compiled with double-precision real scalar types and we have double = %d and PetscScalar = %d", sizeof(double), sizeof(PetscReal));
return FEENOX_ERROR;
}
// we already have processed basic options, now we loop over the original argv and convert
// double-dash options to single-dash so --snes_view transforms into -snes_view
// and split equal signs into two arguments, i.e. --mg_levels_pc_type=sor transforms into
// -mg_levels_pc_type and sor separately
int petsc_argc = 0;
char **petsc_argv = NULL;
if (feenox.argc != 0) { // in benchmark argc might be zero
// worst-case scenario: all strings have arguments that we have to split into two
feenox_check_alloc(petsc_argv = calloc(2*feenox.argc, sizeof(char *)));
petsc_argv[0] = feenox.argv_orig[0];
for (int i = 0; i < feenox.argc; i++) {
if (strlen(feenox.argv_orig[i]) > 2 && feenox.argv_orig[i][0] == '-' && feenox.argv_orig[i][1] == '-' &&
strcmp(feenox.argv_orig[i], "--check") && strcmp(feenox.argv_orig[i], "--ast")) {
feenox_check_alloc(petsc_argv[++petsc_argc] = strdup(feenox.argv_orig[i]+1));
char *value = NULL;
if ((value = strchr(petsc_argv[petsc_argc], '=')) != NULL) {
*value = '\0';
petsc_argv[++petsc_argc] = strdup(value+1);
}
}
}
// this one takes into account argv[0]
petsc_argc++;
}
PetscInt major = 0;
PetscInt minor = 0;
PetscInt subminor = 0;
#ifdef HAVE_SLEPC
// initialize SLEPc (which in turn initializes PETSc) with the original argv & argc
petsc_call(SlepcInitialize(&petsc_argc, &petsc_argv, (char*)0, PETSC_NULLPTR));
// check the headers correspond to the runtime
petsc_call(SlepcGetVersionNumber(&major, &minor, &subminor, NULL));
if (major != SLEPC_VERSION_MAJOR || minor != SLEPC_VERSION_MINOR || subminor != SLEPC_VERSION_SUBMINOR) {
feenox_push_error_message("linked against SLEPc %d.%d.%d but using headers from %d.%d.%d", major, minor, subminor, SLEPC_VERSION_MAJOR, SLEPC_VERSION_MINOR, SLEPC_VERSION_SUBMINOR);
return FEENOX_ERROR;
}
#else
// initialize PETSc
petsc_call(PetscInitialize(&petsc_argc, &petsc_argv, (char*)0, PETSC_NULLPTR));
#endif
feenox_free(petsc_argv);
// check the headers correspond to the runtime
petsc_call(PetscGetVersionNumber(&major, &minor, &subminor, NULL));
if (major != PETSC_VERSION_MAJOR || minor != PETSC_VERSION_MINOR || subminor != PETSC_VERSION_SUBMINOR) {
feenox_push_error_message("linked against PETSc %d.%d.%d but using headers from %d.%d.%d", major, minor, subminor, PETSC_VERSION_MAJOR, PETSC_VERSION_MINOR, PETSC_VERSION_SUBMINOR);
return FEENOX_ERROR;
}
feenox.pde.petscinit_called = PETSC_TRUE;
petsc_call(MPI_Comm_size(PETSC_COMM_WORLD, &feenox.mpi_size));
feenox_special_var_value(mpi_size) = (double)feenox.mpi_size;
petsc_call(MPI_Comm_rank(PETSC_COMM_WORLD, &feenox.mpi_rank));
feenox_special_var_value(mpi_rank) = (double)feenox.mpi_rank;
petsc_call(PetscLogStageRegister("init", &feenox.pde.stage_init));
petsc_call(PetscLogStageRegister("build", &feenox.pde.stage_build));
petsc_call(PetscLogStageRegister("solve", &feenox.pde.stage_solve));
petsc_call(PetscLogStageRegister("post", &feenox.pde.stage_post));
// segfaults are segfaults, try to leave PETSC out of them
signal(SIGSEGV, SIG_DFL);
// TODO: install out error handler for PETSc
// petsc_call(PetscPushErrorHandler(&feenox_handler, NULL));
///va+ksp_atol+name ksp_atol
///va+ksp_atol+detail Absolute tolerance of the iterative linear solver, as passed to PETSc’s
///va+ksp_atol+detail [`KSPSetTolerances`](https://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/KSP/KSPSetTolerances.html)
feenox.pde.vars.ksp_atol = feenox_define_variable_get_ptr("ksp_atol");
// TODO: set to PETSC_DEFAULT?
///va+ksp_atol+detail Default `1e-50`.
feenox_var_value(feenox.pde.vars.ksp_atol) = 1e-50; // same as PETSc
///va+ksp_rtol+name ksp_rtol
///va+ksp_rtol+detail Relative tolerance of the iterative linear solver,
///va+ksp_rtol+detail as passed to PETSc’s
///va+ksp_rtol+detail [`KSPSetTolerances`](https://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/KSP/KSPSetTolerances.html).
feenox.pde.vars.ksp_rtol = feenox_define_variable_get_ptr("ksp_rtol");
///va+ksp_rtol+detail Default `1e-6`.
feenox_var_value(feenox.pde.vars.ksp_rtol) = 1e-6; // PETSc is 1e-5
///va+ksp_divtol+name ksp_divtol
///va+ksp_divtol+detail Divergence tolerance of the iterative linear solver,
///va+ksp_divtol+detail as passed to PETSc’s
///va+ksp_divtol+detail [`KSPSetTolerances`](https://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/KSP/KSPSetTolerances.html).
feenox.pde.vars.ksp_divtol = feenox_define_variable_get_ptr("ksp_divtol");
///va+ksp_divtol+detail Default `1e+4`.
feenox_var_value(feenox.pde.vars.ksp_divtol) = 1e+4; // same as PETSc
///va+ksp_max_it+name ksp_max_it
///va+ksp_max_it+detail Number of maximum iterations of the iterative linear solver before diverging,
///va+ksp_max_it+detail as passed to PETSc’s
///va+ksp_max_it+detail [`KSPSetTolerances`](https://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/KSP/KSPSetTolerances.html).
feenox.pde.vars.ksp_max_it = feenox_define_variable_get_ptr("ksp_max_it");
///va+ksp_max_it+detail Default `10,000`.
feenox_var_value(feenox.pde.vars.ksp_max_it) = 10000; // same as PETSc
///va+snes_atol+name snes_atol
///va+snes_atol+detail Absolute tolerance of the non-linear solver, as passed to PETSc’s
///va+snes_atol+detail [`SNESSetTolerances`](https://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/SNES/SNESSetTolerances.html)
feenox.pde.vars.snes_atol = feenox_define_variable_get_ptr("snes_atol");
///va+snes_atol+detail Default `1e-50`.
feenox_var_value(feenox.pde.vars.snes_atol) = 1e-50; // same as PETSc
///va+snes_rtol+name snes_rtol
///va+snes_rtol+detail Relative tolerance of the non-linear solver,
///va+snes_rtol+detail as passed to PETSc’s
///va+snes_rtol+detail [`SNESSetTolerances`](https://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/SNES/SNESSetTolerances.html).
feenox.pde.vars.snes_rtol = feenox_define_variable_get_ptr("snes_rtol");
///va+feenox_snes_rtol+detail Default `1e-8`.
feenox_var_value(feenox.pde.vars.snes_rtol) = 1e-8; // same as PETSc
///va+snes_stol+name snes_stol
///va+snes_stol+detail Convergence tolerance of the non-linear solver in terms of the norm of the change in the solution between steps,
///va+snes_stol+detail as passed to PETSc’s
///va+snes_stol+detail [`SNESSetTolerances`](https://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/SNES/SNESSetTolerances.html).
feenox.pde.vars.snes_stol = feenox_define_variable_get_ptr("snes_stol");
///va+snes_stol+detail Default `1e-8`.
feenox_var_value(feenox.pde.vars.snes_stol) = 1e-8; // same as PETSc
///va+snes_max_it+name snes_max_it
///va+snes_max_itdetail Number of maximum iterations of the non-linear solver before diverging,
///va+snes_max_it+detail as passed to PETSc’s
///va+snes_max_it+detail [`SNESSetTolerances`](https://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/SNES/SNESSetTolerances.html).
feenox.pde.vars.snes_max_it = feenox_define_variable_get_ptr("snes_max_it");
///va+snes_max_it+detail Default `50`.
feenox_var_value(feenox.pde.vars.snes_max_it) = 50; // same as PETSc
///va+ts_atol+name ts_atol
///va+ts_atol+detail Absolute tolerance of the transient solver, as passed to PETSc’s
///va+ts_atol+detail [`TSSetTolerances`](https://petsc.org/release/docs/manualpages/TS/TSSetTolerances.html)
feenox.pde.vars.ts_atol = feenox_define_variable_get_ptr("ts_atol");
///va+ts_rtol+detail Default `1e-4`.
feenox_var_value(feenox.pde.vars.ts_atol) = 1e-4; // same as PETSc
///va+ts_rtol+name ts_rtol
///va+ts_rtol+detail Relative tolerance of the transient solver, as passed to PETSc’s
///va+ts_rtol+detail [`TSSetTolerances`](https://petsc.org/release/docs/manualpages/TS/TSSetTolerances.html).
feenox.pde.vars.ts_rtol = feenox_define_variable_get_ptr("ts_rtol");
///va+ts_rtol+detail Default `1e-4`.
feenox_var_value(feenox.pde.vars.ts_rtol) = 1e-4; // same as PETSc
///va+eps_tol+name eps_tol
///va+eps_tol+detail Tolerance (relative to the matrix norms) of the eigen solver,
///va+ksp_rtol+detail as passed to SLEPc’s
///va+ksp_rtol+detail [`EPSSetTolerances`](https://slepc.upv.es/documentation/current/docs/manualpages/EPS/EPSSetTolerances.html).
feenox.pde.vars.eps_tol = feenox_define_variable_get_ptr("eps_tol");
///va+ksp_rtol+detail Default `1e-8`.
feenox_var_value(feenox.pde.vars.eps_tol) = 1e-8; // same as SLEPc
///va+eps_max_it+name eps_max_it
///va+eps_max_it Number of maximum iterations allowed in the eigen solver,
///va+eps_max_it+detail as passed to SLEPc’s
///va+ksp_rtol+detail [`EPSSetTolerances`](https://slepc.upv.es/documentation/current/docs/manualpages/EPS/EPSSetTolerances.html).
feenox.pde.vars.eps_max_it = feenox_define_variable_get_ptr("eps_max_it");
///va+snes_max_it+detail Default is a solver-dependent reasonable value`.
feenox_var_value(feenox.pde.vars.eps_max_it) = PETSC_DEFAULT;
///va+eps_st_sigma+name eps_st_sigma
///va+eps_st_sigma Shift $\sigma$ associated with the spectral transformation.
///va+eps_st_sigma+detail as passed to SLEPc’s
///va+eps_st_sigma+detail [`STSetShift`](https://slepc.upv.es/documentation/current/docs/manualpages/ST/STSetShift.html).
feenox.pde.vars.eps_st_sigma = feenox_define_variable_get_ptr("eps_st_sigma");
///va+eps_st_sigma+detail Default is zero (but some PDEs can change it).
feenox_var_value(feenox.pde.vars.eps_st_sigma) = 0;
///va+eps_st_nu+name eps_st_nu
///va+eps_st_nu Value $\nu$ of the anti-shift for the Cayley spectral transformation
///va+eps_st_nu+detail as passed to SLEPc’s
///va+eps_st_nu+detail [`STCayleySetAntishift`](https://slepc.upv.es/documentation/current/docs/manualpages/ST/STCayleySetAntishift.html).
feenox.pde.vars.eps_st_nu = feenox_define_variable_get_ptr("eps_st_nu");
///va+eps_st_nu+detail Default is zero (but some PDEs can change it).
feenox_var_value(feenox.pde.vars.eps_st_nu) = 0;
///va+mumps_cntl_1+name mumps_cntl_1
///va+mumps_cntl_1 MUMPS cntl value with the offset 1, relative threshold for numerical pivoting
///va+mumps_cntl_1+detail It forms a trade-off between preserving sparsity and ensuring numerical stability during
///va+mumps_cntl_1+detail the factorization. In general, a larger value of `CNTL(1)` increases fill-in but leads to
///va+mumps_cntl_1+detail a more accurate factorization.
feenox.pde.vars.mumps_cntl_1 = feenox_define_variable_get_ptr("mumps_cntl_1");
///va+mumps_cntl_1+detail Default is $10^{-3}$
feenox_var_value(feenox.pde.vars.mumps_cntl_1) = 1e-3;
///va+mumps_icntl_14+name mumps_icntl_14
///va+mumps_icntl_14 MUMPS icntl value with the offset 14, relaxation value for the internal array.
///va+mumps_icntl_14+detail For some complex problems this value needs to be set. See MUMPS manual for details.
feenox.pde.vars.mumps_icntl_14 = feenox_define_variable_get_ptr("mumps_icntl_14");
///va+mumps_icntl_14+detail Default is zero, which means use MUMPS default.
feenox_var_value(feenox.pde.vars.mumps_icntl_14) = 0;
///va+mumps_icntl_24+name mumps_icntl_24
///va+mumps_icntl_24 MUMPS icntl value with the offset 24, flag to detect null pivot rows.
///va+mumps_icntl_24+detail For most problems, it is ok to leave this flag as true (default).
///va+mumps_icntl_24+detail For very particular problems, it might be needed to turn it off.
feenox.pde.vars.mumps_icntl_24 = feenox_define_variable_get_ptr("mumps_icntl_24");
///va+mumps_icntl_14+detail Default is true, which asks MUMPS to detect (and handle) null pivot rows.
feenox_var_value(feenox.pde.vars.mumps_icntl_24) = 1;
///va+gamg_threshold+name gamg_threshold
///va+gamg_threshold Relative threshold to use for dropping edges in aggregation graph when using GAMG.
///va+gamg_threshold+detail See `PCGAMGSetThreshold()` in the PETSc documentation for further details.
feenox.pde.vars.gamg_threshold = feenox_define_variable_get_ptr("gamg_threshold");
///va+gamg_threshold+detail Default is zero (note that PETSc's default is -1).
feenox_var_value(feenox.pde.vars.gamg_threshold) = 0;
///va+penalty_weight+name feenox_penalty_weight
///va+penalty_weight+detail The weight\ $w$ used when setting multi-freedom boundary conditions.
///va+penalty_weight+detail Higher values mean better precision in the constrain but worsen
///va+penalty_weight+detail the matrix condition number.
feenox.pde.vars.penalty_weight = feenox_define_variable_get_ptr("penalty_weight");
///va+feenox_penalty_weight+detail Default is `1e8`.
feenox_var_value(feenox.pde.vars.penalty_weight) = 1e8;
///va+nodes_rough+name nodes_rough
///va+nodes_rough+detail The number of nodes of the mesh in `ROUGH` mode.
feenox.pde.vars.nodes_rough = feenox_define_variable_get_ptr("nodes_rough");
///va+total_dofs+name total_dofs
///va+total_dogs+detail The total number of degrees of freedom of the PDE being solved for.
feenox.pde.vars.total_dofs = feenox_define_variable_get_ptr("total_dofs");
///va+memory_available+name memory_available
///va+memory_available+detail Total available memory, in bytes.
feenox.pde.vars.memory_available = feenox_define_variable_get_ptr("memory_available");
#ifdef HAVE_SYSCONF
feenox_var_value(feenox.pde.vars.memory_available) = (double)(sysconf(_SC_PHYS_PAGES)*sysconf(_SC_PAGESIZE));
#else
feenox_var_value(feenox.pde.vars.memory_available) = -1;
#endif
#endif
return FEENOX_OK;
}
int feenox_problem_define_solutions(void) {
#ifdef HAVE_PETSC
char dimension_name[3][2] = {"x", "y", "z"};
if (feenox.pde.dim == 0) {
feenox_push_error_message("do not know how many dimensions the problem has, tell me with DIMENSIONS in either PROBLEM or READ_MESH");
return FEENOX_ERROR;
}
if (feenox.pde.dofs == 0) {
feenox_push_error_message("do not know how many degrees of freedom this problem has");
return FEENOX_ERROR;
}
if (feenox.pde.solution != NULL) {
feenox_push_error_message("solutions already defined");
return FEENOX_ERROR;
}
feenox_check_alloc(feenox.pde.solution = calloc(feenox.pde.dofs, sizeof(function_t *)));
feenox_check_alloc(feenox.pde.gradient = calloc(feenox.pde.dofs, sizeof(function_t *)));
feenox_check_alloc(feenox.pde.delta_gradient = calloc(feenox.pde.dofs, sizeof(function_t *)));
if (feenox.pde.nev > 0) {
feenox_check_alloc(feenox.pde.mode = calloc(feenox.pde.dofs, sizeof(function_t *)));
}
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
char *name = NULL;
if (feenox.pde.unknown_name == NULL) {
feenox_check_minusone(asprintf(&name, "phi%u", g+1));
} else {
feenox_check_minusone(asprintf(&name, "%s", feenox.pde.unknown_name[g]));
}
feenox_check_alloc(feenox.pde.solution[g] = feenox_define_function_get_ptr(name, feenox.pde.dim));
feenox.pde.solution[g]->mesh = feenox.pde.mesh;
feenox.pde.solution[g]->is_solution = 1;
if (feenox.pde.nev == 0) {
// the derivatives of the solutions with respect to space
feenox_check_alloc(feenox.pde.gradient[g] = calloc(feenox.pde.dim, sizeof(function_t *)));
feenox_check_alloc(feenox.pde.delta_gradient[g] = calloc(feenox.pde.dim, sizeof(function_t *)));
for (unsigned int d = 0; d < feenox.pde.dim; d++) {
feenox.pde.solution[g]->var_argument[d] = feenox.mesh.vars.arr_x[d];
char *gradname = NULL;
feenox_check_minusone(asprintf(&gradname, "d%sd%s", name, dimension_name[d]));
feenox_check_alloc(feenox.pde.gradient[g][d] = feenox_define_function_get_ptr(gradname, feenox.pde.dim));
feenox_free(gradname);
feenox.pde.gradient[g][d]->mesh = feenox.pde.solution[g]->mesh;
feenox.pde.gradient[g][d]->var_argument = feenox.pde.solution[g]->var_argument;
feenox.pde.gradient[g][d]->type = function_type_pointwise_mesh_node;
feenox.pde.gradient[g][d]->spatial_derivative_of = feenox.pde.solution[g];
// this flag is used when interpolating
feenox.pde.gradient[g][d]->spatial_derivative_with_respect_to = d;
// this flag is used to know if gradients have to be computed
feenox.pde.gradient[g][d]->is_gradient = 1;
// same for uncertainty
/*
feenox_check_minusone(asprintf(&gradname, "delta_d%sd%s", name, dimension_name[d]));
feenox_check_alloc(feenox.pde.delta_gradient[g][d] = feenox_define_function_get_ptr(gradname, feenox.pde.dim));
feenox_free(gradname);
feenox.pde.delta_gradient[g][d]->mesh = feenox.pde.solution[g]->mesh;
feenox.pde.delta_gradient[g][d]->var_argument = feenox.pde.solution[g]->var_argument;
feenox.pde.delta_gradient[g][d]->type = function_type_pointwise_mesh_node;
feenox.pde.delta_gradient[g][d]->is_gradient = 1;
*/
}
} else {
// there are many solution functions in modal
feenox_check_alloc(feenox.pde.mode[g] = calloc(feenox.pde.nev, sizeof(function_t *)));
for (int i = 0; i < feenox.pde.nev; i++) {
char *modename = NULL;
feenox_check_minusone(asprintf(&modename, "%s%d", name, i+1));
feenox_call(feenox_problem_define_solution_function(modename, &feenox.pde.mode[g][i], FEENOX_SOLUTION_NOT_GRADIENT));
feenox_free(modename);
feenox.pde.mode[g][i]->mesh = feenox.pde.solution[g]->mesh;
feenox.pde.mode[g][i]->is_solution = 1;
feenox.pde.mode[g][i]->var_argument = feenox.pde.solution[g]->var_argument;
}
}
feenox_free(name);
}
#endif
return FEENOX_OK;
}
int feenox_problem_define_solution_function(const char *name, function_t **function, int is_gradient) {
// we can only define what's available at parse time
if ((*function = feenox_define_function_get_ptr(name, feenox.pde.dim)) == NULL) {
feenox_push_error_message("result function '%s' defined twice", name);
return FEENOX_ERROR;
}
// we don't have a valid mesh here, do we?
// (*function)->mesh = feenox.pde.mesh; // esto puede cambiar a rough despues
// feenox_problem_define_solution_clean_nodal_arguments(*function);
if (feenox.pde.solution == NULL) {
feenox_call(feenox_problem_define_solutions());
}
(*function)->var_argument = feenox.pde.solution[0]->var_argument;
(*function)->type = (feenox.mesh.default_field_location == field_location_cells) ? function_type_pointwise_mesh_cell : function_type_pointwise_mesh_node;
(*function)->is_gradient = is_gradient;
(*function)->is_solution = 1;
return FEENOX_OK;
}
int feenox_problem_fill_aux_solution(function_t *function) {
function->mesh = feenox.pde.rough==0 ? feenox.pde.mesh : feenox.pde.mesh_rough;
function->data_size = function->mesh->n_nodes;
feenox_call(feenox_create_pointwise_function_vectors(function));
for (unsigned int d = 0; d < function->n_arguments; d++) {
feenox_realloc_vector_ptr(function->vector_argument[d], gsl_vector_ptr(function->mesh->nodes_argument[d], 0), 0);
}
return FEENOX_OK;
}
int feenox_problem_init_runtime_general(void) {
#ifdef HAVE_PETSC
// first set options from PETSC_OPTIONS
if (feenox.pde.petsc_options != NULL && feenox.pde.do_not_solve == 0) {
petsc_call(PetscOptionsInsertString(NULL, feenox.pde.petsc_options));
}
// command-line arguments take precedence over the options in the input file
// so we have to read them here and overwrite what he have so far
// recall that we already stripped off one dash from the original argv array
PetscBool flag = PETSC_FALSE;
///op+progress+option `--progress`
///op+progress+desc print ASCII progress bars when solving PDEs
if (feenox.pde.progress_ascii == PETSC_FALSE) {
petsc_call(PetscOptionsHasName(PETSC_NULLPTR, PETSC_NULLPTR, "-progress", &feenox.pde.progress_ascii));
}
///op+mumps+option `--mumps`
///op+mumps+desc ask PETSc to use the direct linear solver MUMPS
petsc_call(PetscOptionsHasName(PETSC_NULLPTR, PETSC_NULLPTR, "-mumps", &flag));
if (flag == PETSC_TRUE) {
// mumps is different, we detect these strings later on
feenox.pde.ksp_type = "mumps";
feenox.pde.pc_type = "mumps";
}
///op+gamg+option `--gamg`
///op+gamg+desc ask PETSc to use a GAMG-preconditioned iterative linear solver
petsc_call(PetscOptionsHasName(PETSC_NULLPTR, PETSC_NULLPTR, "-gamg", &flag));
if (flag == PETSC_TRUE) {
feenox.pde.pc_type = PCGAMG;
}
// read these guys just to avoid the "unused database option" complain
petsc_call(PetscOptionsHasName(PETSC_NULLPTR, PETSC_NULLPTR, "-linear", &flag));
petsc_call(PetscOptionsHasName(PETSC_NULLPTR, PETSC_NULLPTR, "-non-linear", &flag));
petsc_call(PetscOptionsHasName(PETSC_NULLPTR, PETSC_NULLPTR, "-nonlinear", &flag));
// check if the dimensions match
if (feenox.pde.dim != 0 && feenox.pde.mesh != NULL && feenox.pde.mesh->dim != 0 && feenox.pde.dim != feenox.pde.mesh->dim) {
feenox_push_error_message("dimension mismatch, in PROBLEM %d != in READ_MESH %d", feenox.pde.dim, feenox.pde.mesh->dim);
return FEENOX_ERROR;
}
// conversely, if we got them there, put it on the mesh
if (feenox.pde.mesh != NULL && feenox.pde.mesh->dim == 0 && feenox.pde.dim != 0) {
feenox.pde.mesh->dim = feenox.pde.dim;
}
if (feenox.pde.dim == 0) {
feenox_push_error_message("could not determine the dimension of the problem, give them using DIMENSIONS in either READ_MESH or PROBLEM");
return FEENOX_ERROR;
}
// link the solution functions with the mesh
// and check if we have to compute gradients
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
for (unsigned int m = 0; m < feenox.pde.dim; m++) {
feenox.pde.solution[g]->var_argument[m] = feenox.mesh.vars.arr_x[m];
if (feenox.pde.gradient != NULL && feenox.pde.gradient[g] != NULL && feenox.pde.gradient[g][m] != NULL) {
feenox.pde.compute_gradients |= feenox.pde.gradient[g][m]->used;
}
}
feenox.pde.solution[g]->mesh = (feenox.pde.rough==0) ? feenox.pde.mesh : feenox.pde.mesh_rough;
feenox_check_alloc(feenox.pde.solution[g]->var_argument = calloc(feenox.pde.dim, sizeof(var_t *)));
feenox.pde.solution[g]->var_argument[0] = feenox.mesh.vars.x;
if (feenox.pde.dim > 1) {
feenox.pde.solution[g]->var_argument[1] = feenox.mesh.vars.y;
if (feenox.pde.dim > 2) {
feenox.pde.solution[g]->var_argument[2] = feenox.mesh.vars.z;
}
}
feenox.pde.solution[g]->var_argument_allocated = 1;
feenox.pde.solution[g]->type = function_type_pointwise_mesh_node;
}
if (feenox.pde.mesh != NULL && feenox.pde.unresolved_bcs == unresolved_bcs_detect) {
// this is a loop over a hash, not over a linked list
for (physical_group_t *physical_group = feenox.pde.mesh->physical_groups; physical_group != NULL; physical_group = physical_group->hh.next) {
if (physical_group->n_bcs != 0 && physical_group->n_elements == 0) {
feenox_push_error_message("physical entity '%s' has a BC but no associated elements. Set ALLOW_UNRESOLVED_BCS if you want to skip this check.", physical_group->name);
return FEENOX_ERROR;
}
if (physical_group->material != NULL && physical_group->n_elements == 0) {
feenox_push_error_message("physical group '%s' has a material but no associated elements. Set ALLOW_UNRESOLVED_BCS if you want to skip this check.", physical_group->name);
return FEENOX_ERROR;
}
}
}
// allocate global petsc objects
if (feenox.pde.size_global == 0) {
if (feenox.pde.spatial_unknowns == 0) {
feenox_push_error_message("internal error, problem init did not set global spatial unknowns");
return FEENOX_ERROR;
}
feenox.pde.size_global = feenox.pde.spatial_unknowns * feenox.pde.dofs;
}
// set the size of the eigenvectors (we did not know their size in init_parser() above
for (int i = 0; i < feenox.pde.nev; i++) {
feenox_call(feenox_vector_set_size(feenox.pde.vectors.phi[i], feenox.pde.size_global));
}
feenox_var_value(feenox.pde.vars.total_dofs) = (double)(feenox.pde.size_global);
// TODO: choose width from input
//#if PETSC_VERSION_LT(3,19,0)
feenox.pde.width = GSL_MAX(feenox.pde.mesh->max_nodes_per_element, feenox.pde.mesh->max_first_neighbor_nodes) * feenox.pde.dofs;
//#endif
// ask how many local nodes we own
feenox.pde.nodes_local = PETSC_DECIDE;
PetscInt n_nodes = feenox.pde.mesh->n_nodes;
petsc_call(PetscSplitOwnership(PETSC_COMM_WORLD, &feenox.pde.nodes_local, &n_nodes));
feenox.pde.size_local = feenox.pde.dofs * feenox.pde.nodes_local;
// the global stiffnes matrix
feenox_check_alloc(feenox.pde.K = feenox_problem_create_matrix("K"));
// the solution (unknown) vector
feenox.pde.phi = feenox_problem_create_vector("phi");
// explicit initial value
petsc_call(VecSet(feenox.pde.phi, 0));
// the right-hand-side vector
if (feenox.pde.has_rhs) {
feenox.pde.b = feenox_problem_create_vector("b");
}
// the internal fluxes (i.e. forces) vector
if (feenox.pde.has_internal_fluxes) {
feenox.pde.f = feenox_problem_create_vector("f");
}
// the mass matrix for modal or heat transient
if (feenox.pde.has_mass) {
feenox_check_alloc(feenox.pde.M = feenox_problem_create_matrix("M"));
}
if (feenox.pde.has_jacobian_K) {
feenox_check_alloc(feenox.pde.JK = feenox_problem_create_matrix("JK"));
}
if (feenox.pde.has_jacobian_b) {
feenox_check_alloc(feenox.pde.Jb = feenox_problem_create_matrix("Jb"));
}
// ask for the local ownership range
petsc_call(MatGetOwnershipRange(feenox.pde.K, &feenox.pde.first_row, &feenox.pde.last_row));
feenox.pde.first_node = feenox.pde.first_row / feenox.pde.dofs;
feenox.pde.last_node = feenox.pde.last_row / feenox.pde.dofs;
// TODO: honor mesh partitions
// https://lists.mcs.anl.gov/pipermail/petsc-users/2014-April/021433.html
if (feenox.pde.mesh->mpi_matches_partitions == mpi_matches_partitions_no) {
feenox_call(feenox_compute_first_last_element(feenox.pde.mesh));
}
// fill in the holders of the continuous functions that will hold the solution
if (feenox.pde.rough == 0) {
if (feenox.pde.solution == NULL) {
feenox_push_error_message("inconsistent internal state, solution functions not allocated");
return FEENOX_ERROR;
}
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
feenox.pde.solution[g]->mesh = feenox.pde.mesh;
feenox.pde.solution[g]->data_size = feenox.pde.spatial_unknowns;
feenox_create_pointwise_function_vectors(feenox.pde.solution[g]);
for (unsigned int d = 0; d < feenox.pde.solution[g]->n_arguments; d++) {
feenox_realloc_vector_ptr(feenox.pde.solution[g]->vector_argument[d], gsl_vector_ptr(feenox.pde.solution[g]->mesh->nodes_argument[d], 0), 0);
}
// in some cases (e.g. neutron) we do not know if we have to solve
// a KSP or an EPS until we read the material data, which is far too late
// in that case, we usually do not care about all the modes so feenox.pde.mode is null
if (feenox.pde.nev > 0 && feenox.pde.mode != NULL) {
unsigned int i = 0;
for (i = 0; i < feenox.pde.nev; i++) {
feenox.pde.mode[g][i]->mesh = feenox.pde.mesh;
feenox.pde.mode[g][i]->data_size = feenox.pde.mesh->n_nodes;
feenox_create_pointwise_function_vectors(feenox.pde.mode[g][i]);
for (unsigned int d = 0; d < feenox.pde.mode[g][i]->n_arguments; d++) {
feenox_realloc_vector_ptr(feenox.pde.mode[g][i]->vector_argument[d], gsl_vector_ptr(feenox.pde.mode[g][i]->mesh->nodes_argument[d], 0), 0);
}
}
}
}
} else {
/*
mesh_post_t *post;
feenox_call(feenox_init_rough_mesh());
// maybe the macros fill_* can be used
for (g = 0; g < feenox.pde.degrees; g++) {
feenox.pde.solution[g]->mesh = feenox.pde.mesh_rough;
feenox.pde.solution[g]->data_size = feenox.pde.mesh_rough->n_nodes;
feenox.pde.solution[g]->data_argument = feenox.pde.mesh_rough->nodes_argument;
feenox.pde.solution[g]->data_value = calloc(feenox.pde.mesh_rough->n_nodes, sizeof(double));
}
// si estamos en rough tenemos que cambiar la malla de salida de los MESH_POSTs
LL_FOREACH(feenox.mesh.posts, post) {
if (post->mesh == feenox.pde.mesh) {
post->mesh = feenox.pde.mesh_rough;
}
}
*/
}
feenox_call(feenox_mesh_init_nodal_indexes(feenox.pde.mesh, feenox.pde.dofs));
#endif
return FEENOX_OK;
}
#ifdef HAVE_PETSC
Mat feenox_problem_create_matrix(const char *name) {
Mat A = NULL;
petsc_call_null(MatCreate(PETSC_COMM_WORLD, &A));
petsc_call_null(MatSetSizes(A, feenox.pde.size_local, feenox.pde.size_local, feenox.pde.size_global, feenox.pde.size_global));
petsc_call_null(MatSetFromOptions(A));
if (feenox.pde.pre_allocate == PETSC_TRUE || PETSC_VERSION_LT(3,19,0)) {
petsc_call_null(MatMPIAIJSetPreallocation(A, feenox.pde.width, PETSC_NULLPTR, feenox.pde.width, PETSC_NULLPTR));
petsc_call_null(MatSeqAIJSetPreallocation(A, feenox.pde.width, PETSC_NULLPTR));
}
// this flag needs the matrix type to be set, and we had just set it with setfromoptions
petsc_call_null(MatSetOption(A, MAT_KEEP_NONZERO_PATTERN, PETSC_TRUE));
if (name != NULL) {
petsc_call_null(PetscObjectSetName((PetscObject)(A), name));
}
if (feenox.pde.allow_new_nonzeros == PETSC_TRUE) {
petsc_call_null(MatSetOption(A, MAT_NEW_NONZERO_ALLOCATION_ERR, PETSC_FALSE));
}
if (feenox.pde.dofs > 1) {
petsc_call_null(MatSetBlockSize(A, feenox.pde.dofs));
}
return A;
}
Vec feenox_problem_create_vector(const char *name) {
if (feenox.pde.K == NULL) {
feenox_push_error_message("stiffness matrix is not created yet");
return NULL;
}
Vec v;
petsc_call_null(MatCreateVecs(feenox.pde.K, &v, NULL));
petsc_call_null(VecSetFromOptions(v));
if (name != NULL) {
petsc_call_null(PetscObjectSetName((PetscObject)(v), name));
}
return v;
}
#endif
// TODO: see if PetscSplitOwnership(MPI_Comm comm, PetscInt *n, PetscInt *N) give the same results
int feenox_compute_first_last_element(mesh_t *mesh) {
mesh->first_element = (mesh->n_elements / feenox.mpi_size) * feenox.mpi_rank;
if (mesh->n_elements % feenox.mpi_size > feenox.mpi_rank) {
mesh->first_element += feenox.mpi_rank;
mesh->last_element = mesh->first_element + (mesh->n_elements / feenox.mpi_size) + 1;
} else {
mesh->first_element += mesh->n_elements % feenox.mpi_size;
mesh->last_element = mesh->first_element + (mesh->n_elements / feenox.mpi_size);
}
return FEENOX_OK;
}
feenox-1.2/src/pdes/petsc_ksp.c 0000664 0001750 0001750 00000027032 15055303016 012206 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's linear solver using PETSc routines
*
* Copyright (C) 2015--2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
int feenox_problem_solve_petsc_linear(void) {
#ifdef HAVE_PETSC
// build ---------------------------------------------------------------------
petsc_call(PetscLogStagePush(feenox.pde.stage_build));
feenox_call(feenox_problem_build());
feenox_call(feenox_problem_dirichlet_eval());
feenox_call(feenox_problem_dirichlet_set_K());
petsc_call(PetscLogStagePop());
// ---------------------------------------------------------------------------
if (feenox.pde.missed_dump != NULL) {
feenox_call(feenox_instruction_dump(feenox.pde.missed_dump));
}
// solve ---------------------------------------------------------------------
petsc_call(PetscLogStagePush(feenox.pde.stage_solve));
// create a KSP object if needed
if (feenox.pde.ksp == NULL) {
petsc_call(KSPCreate(PETSC_COMM_WORLD, &feenox.pde.ksp));
// set the monitor for the ascii progress
if (feenox.pde.progress_ascii == PETSC_TRUE) {
petsc_call(KSPMonitorSet(feenox.pde.ksp, feenox_problem_ksp_monitor, NULL, 0));
}
petsc_call(KSPSetOperators(feenox.pde.ksp, feenox.pde.K_bc, feenox.pde.K_bc));
feenox_call(feenox_problem_setup_ksp(feenox.pde.ksp));
}
// check if the stiffness matrix K has a near nullspace
// and pass it on to K_bc
MatNullSpace near_null_space = NULL;
petsc_call(MatGetNearNullSpace(feenox.pde.K, &near_null_space));
if (near_null_space != NULL) {
petsc_call(MatSetNearNullSpace(feenox.pde.K_bc, near_null_space));
}
// try to use the solution as the initial guess (it already has Dirichlet BCs
// but in quasi-static it has the previous solution which should be similar)
// mumps cannot be used with a non-zero guess
/*
if ((feenox.pde.ksp_type == NULL || strcasecmp(feenox.pde.ksp_type, "mumps") != 0) &&
(feenox.pde.pc_type == NULL || strcasecmp(feenox.pde.pc_type, "mumps") != 0)) {
petsc_call(KSPSetInitialGuessNonzero(feenox.pde.ksp, PETSC_TRUE));
}
*/
feenox.pde.progress_last = 0;
// do the work!
if (feenox.pde.do_not_solve == 0) {
petsc_call(KSPSolve(feenox.pde.ksp, feenox.pde.b_bc, feenox.pde.phi));
// check for convergence
KSPConvergedReason ksp_reason = 0;
petsc_call(KSPGetConvergedReason(feenox.pde.ksp, &ksp_reason));
if (ksp_reason < 0) {
// if the input file asks for a DUMP then we do it now
if (feenox.pde.dumps != NULL) {
feenox_instruction_dump((void *)feenox.pde.dumps);
}
if (ksp_reason == KSP_DIVERGED_PC_FAILED) {
PC pc;
petsc_call(KSPGetPC(feenox.pde.ksp, &pc));
PCFailedReason pc_reason;
petsc_call(PCGetFailedReason(pc, &pc_reason));
feenox_push_error_message("PETSc's pre-conditioner failed '%s' (%d)", PCFailedReasons[pc_reason], pc_reason);
} else {
feenox_push_error_message("PETSc's linear solver did not converge '%s' (%d)", KSPConvergedReasons[ksp_reason], ksp_reason);
}
return FEENOX_ERROR;
}
}
// finish the progress line
if (feenox.pde.progress_ascii == PETSC_TRUE) {
if (feenox.mpi_size == 1) {
int i = 0;
for (i = (int)(100*feenox.pde.progress_last); i < 100; i++) {
printf(CHAR_PROGRESS_SOLVE);
}
}
if (feenox.mpi_rank == 0) {
printf("\n");
fflush(stdout);
}
}
petsc_call(PetscLogStagePop());
// ---------------------------------------------------------------------------
#endif
return FEENOX_OK;
}
#ifdef HAVE_PETSC
PetscErrorCode feenox_problem_ksp_monitor(KSP ksp, PetscInt n, PetscReal rnorm, void *dummy) {
// feenox_value(feenox.pde.vars.iterations) = (double)n;
// feenox_var_value(feenox.pde.vars.residual_norm) = rnorm;
int i;
double current_progress;
if (feenox.mpi_rank == 0) {
if (feenox.pde.progress_r0 == 0) {
feenox.pde.progress_r0 = rnorm;
}
if (rnorm < 1e-20) {
current_progress = 1;
} else {
current_progress = log((rnorm/feenox.pde.progress_r0))/log(feenox_var_value(feenox.pde.vars.ksp_rtol));
if (current_progress > 1) {
current_progress = 1;
}
}
// printf("%d %e %.0f\n", n, rnorm/r0, 100*current_progress);
if (feenox.pde.progress_ascii == PETSC_TRUE) {
if (feenox.pde.progress_last < current_progress) {
for (i = (int)(100*feenox.pde.progress_last); i < (int)(100*current_progress); i++) {
printf(CHAR_PROGRESS_SOLVE);
fflush(stdout);
}
feenox.pde.progress_last = current_progress;
}
}
}
return 0;
}
int feenox_problem_setup_ksp(KSP ksp) {
// the KSP type
if ((feenox.pde.ksp_type != NULL && strcasecmp(feenox.pde.ksp_type, "mumps") == 0) ||
(feenox.pde.pc_type != NULL && strcasecmp(feenox.pde.pc_type, "mumps") == 0)) {
// mumps is a particular case, see feenox_problem_setup_pc
#ifdef PETSC_HAVE_MUMPS
petsc_call(KSPSetType(ksp, KSPPREONLY));
#else
feenox_push_error_message("this version of FeenoX does not support MUMPS");
return FEENOX_ERROR;
#endif
} else if (feenox.pde.ksp_type != NULL) {
petsc_call(KSPSetType(ksp, feenox.pde.ksp_type));
}
if (feenox.pde.setup_ksp != NULL) {
feenox_call(feenox.pde.setup_ksp(ksp));
}
if (feenox.pde.symmetric_K) {
// K is symmetric. Set symmetric flag to enable ICC/Cholesky preconditioner
// TODO: this is K for ksp but J for snes
if (feenox.pde.has_stiffness) {
if (feenox.pde.K != NULL) {
petsc_call(MatSetOption(feenox.pde.K, MAT_SYMMETRIC, PETSC_TRUE));
petsc_call(MatSetOption(feenox.pde.K, MAT_SPD, PETSC_TRUE));
}
if (feenox.pde.K_bc != NULL) {
petsc_call(MatSetOption(feenox.pde.K_bc, MAT_SYMMETRIC, PETSC_TRUE));
petsc_call(MatSetOption(feenox.pde.K_bc, MAT_SPD, PETSC_TRUE));
}
}
if (feenox.pde.has_mass) {
if (feenox.pde.M != NULL) {
petsc_call(MatSetOption(feenox.pde.M, MAT_SYMMETRIC, PETSC_TRUE));
petsc_call(MatSetOption(feenox.pde.M, MAT_SPD, PETSC_TRUE));
}
if (feenox.pde.M_bc != NULL) {
petsc_call(MatSetOption(feenox.pde.M_bc, MAT_SYMMETRIC, PETSC_TRUE));
}
}
/*
if (feenox.pde.has_jacobian_K) {
if (feenox.pde.JK != NULL) {
petsc_call(MatSetOption(feenox.pde.JK, MAT_SYMMETRIC, PETSC_TRUE));
petsc_call(MatSetOption(feenox.pde.JK, MAT_SPD, PETSC_TRUE));
}
}
if (feenox.pde.has_jacobian_b) {
if (feenox.pde.Jb != NULL) {
petsc_call(MatSetOption(feenox.pde.Jb, MAT_SYMMETRIC, PETSC_TRUE));
petsc_call(MatSetOption(feenox.pde.Jb, MAT_SPD, PETSC_TRUE));
}
}
*/
}
petsc_call(KSPSetTolerances(ksp, feenox_var_value(feenox.pde.vars.ksp_rtol),
feenox_var_value(feenox.pde.vars.ksp_atol),
feenox_var_value(feenox.pde.vars.ksp_divtol),
(PetscInt)feenox_var_value(feenox.pde.vars.ksp_max_it)));
PC pc = NULL;
petsc_call(KSPGetPC(ksp, &pc));
if (pc == NULL) {
feenox_push_error_message("cannot get preconditioner object");
return FEENOX_ERROR;
}
feenox_call(feenox_problem_setup_pc(pc));
// read command-line options
petsc_call(KSPSetFromOptions(ksp));
return FEENOX_OK;
}
int feenox_problem_setup_pc(PC pc) {
// if we were asked for mumps, then either LU o cholesky needs to be used
// and MatSolverType to mumps
#ifdef PETSC_HAVE_MUMPS
if ((feenox.pde.ksp_type != NULL && strcasecmp(feenox.pde.ksp_type, "mumps") == 0) ||
(feenox.pde.pc_type != NULL && strcasecmp(feenox.pde.pc_type, "mumps") == 0)) {
#if PETSC_VERSION_GT(3,9,0)
// need to set this guy otherwise PCFactorSetMatSolverType does not work
petsc_call(PCSetType(pc, feenox.pde.symmetric_K ? PCCHOLESKY : PCLU));
petsc_call(PCFactorSetMatSolverType(pc, MATSOLVERMUMPS));
#else
feenox_push_error_message("MUMPS solver needs at least PETSc 3.9");
return FEENOX_ERROR;
#endif
} else {
#endif
if (feenox.pde.pc_type != NULL) {
petsc_call(PCSetType(pc, feenox.pde.pc_type));
}
#ifdef PETSC_HAVE_MUMPS
}
#endif
if (feenox.pde.setup_pc != NULL) {
feenox_call(feenox.pde.setup_pc(pc));
}
// if using MUMPS, set icntl if needed
#ifdef PETSC_HAVE_MUMPS
#ifdef HAVE_SLEPC
// in EPS we need to set the ST type to create it, otherwise the icntls do not work
if (feenox.pde.eps != NULL) {
ST st = NULL;
petsc_call(EPSGetST(feenox.pde.eps, &st));
STType st_type = NULL;
petsc_call(STGetType(st, &st_type));
if (st_type == NULL) {
feenox_push_error_message("internal error, ST type is not set");
return FEENOX_ERROR;
}
// force creation of the operator
petsc_call(STGetOperator(st, NULL));
}
#endif
MatSolverType mat_solver_type = NULL;
petsc_call(PCFactorGetMatSolverType(pc, &mat_solver_type));
if (mat_solver_type != NULL && strcmp(mat_solver_type, MATSOLVERMUMPS) == 0) {
// calling MatMumpsSetCntl()/MatMumpsSetIcntl() needs the matrices to be created
// and when using SNES that does not happen until the first newton-raphson iteration
// this is far simpler for us
char *value_s = NULL;
double value_f = 0;
if ((value_f = feenox_var_value(feenox.pde.vars.mumps_cntl_1)) != 0) {
feenox_check_minusone(asprintf(&value_s, "%g", value_f));
if (feenox.pde.math_type != math_type_eigen) {
petsc_call(PetscOptionsSetValue(NULL, "-mat_mumps_cntl_1", value_s));
} else {
petsc_call(PetscOptionsSetValue(NULL, "-st_mat_mumps_cntl_1", value_s));
}
feenox_free(value_s);
}
if ((value_f = feenox_var_value(feenox.pde.vars.mumps_icntl_14)) != 0) {
feenox_check_minusone(asprintf(&value_s, "%g", value_f));
if (feenox.pde.math_type != math_type_eigen) {
petsc_call(PetscOptionsSetValue(NULL, "-mat_mumps_icntl_14", value_s));
} else {
petsc_call(PetscOptionsSetValue(NULL, "-st_mat_mumps_icntl_14", value_s));
}
feenox_free(value_s);
}
if ((value_f = feenox_var_value(feenox.pde.vars.mumps_icntl_24)) != 0) {
feenox_check_minusone(asprintf(&value_s, "%g", value_f));
if (feenox.pde.math_type != math_type_eigen) {
petsc_call(PetscOptionsSetValue(NULL, "-mat_mumps_icntl_24", value_s));
} else {
petsc_call(PetscOptionsSetValue(NULL, "-st_mat_mumps_icntl_24", value_s));
}
feenox_free(value_s);
}
}
#endif
PCType pc_type;
petsc_call(PCGetType(pc, &pc_type));
if (pc_type != NULL && strcmp(pc_type, PCGAMG) == 0) {
petsc_call(PCGAMGSetThreshold(pc, &feenox_var_value(feenox.pde.vars.gamg_threshold), 1));
}
// read command-line options
petsc_call(PCSetFromOptions(pc));
return FEENOX_OK;
}
#endif
feenox-1.2/src/pdes/petsc_snes.c 0000664 0001750 0001750 00000016312 15055303016 012360 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's non-linear solver using PETSc routines
*
* Copyright (C) 2020--2025 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
int feenox_problem_solve_petsc_nonlinear(void) {
#ifdef HAVE_PETSC
if (feenox.pde.snes == NULL) {
// TODO: move to a separate function
petsc_call(SNESCreate(PETSC_COMM_WORLD, &feenox.pde.snes));
// monitor
// petsc_call(SNESMonitorSet(feenox.pde.snes, feenox.pde.snes_monitor, NULL, 0));
feenox_check_alloc(feenox.pde.r = feenox_problem_create_vector("r"));
petsc_call(SNESSetFunction(feenox.pde.snes, feenox.pde.r, feenox_snes_residual, NULL));
feenox_check_alloc(feenox.pde.J_snes = feenox_problem_create_matrix("J_snes"));
petsc_call(SNESSetJacobian(feenox.pde.snes, feenox.pde.J_snes, feenox.pde.J_snes, feenox_snes_jacobian, NULL));
// TODO
feenox_call(feenox_problem_setup_snes(feenox.pde.snes));
}
// solve
feenox.pde.progress_last = 0; // reset the progress bar counter
if (feenox.pde.do_not_solve == 0) {
petsc_call(SNESSolve(feenox.pde.snes, NULL, feenox.pde.phi));
// check convergence
SNESConvergedReason reason;
petsc_call(SNESGetConvergedReason(feenox.pde.snes, &reason));
if (reason < 0) {
feenox_push_error_message("PETSc's non-linear solver did not converge with reason '%s' (%d)", SNESConvergedReasons[reason], reason);
// TODO: go deeper into the KSP and PC
return FEENOX_ERROR;
}
} else {
// this branch is for the fee2ccx converter
feenox_snes_residual(feenox.pde.snes, feenox.pde.phi, feenox.pde.r, NULL);
}
// finish the progress line
if (feenox.pde.progress_ascii == PETSC_TRUE) {
int i;
if (feenox.mpi_size == 1) {
for (i = (int)(100*feenox.pde.progress_last); i < 100; i++) {
printf(CHAR_PROGRESS_SOLVE);
}
}
if (feenox.mpi_rank == 0) {
printf("\n");
fflush(stdout);
}
}
#endif
return FEENOX_OK;
}
#ifdef HAVE_PETSC
int feenox_problem_setup_snes(SNES snes) {
// TODO: have an explicit default
// TODO: set the line search
if (feenox.pde.snes_type != NULL) {
// if we have an explicit type, we set it
petsc_call(SNESSetType(snes, feenox.pde.snes_type));
}
if (feenox.pde.ls_type != NULL) {
SNESLineSearch ls;
petsc_call(SNESGetLineSearch(snes, &ls));
petsc_call(SNESLineSearchSetType(ls, feenox.pde.ls_type));
}
if (feenox.pde.setup_snes != NULL) {
feenox_call(feenox.pde.setup_snes(snes));
}
petsc_call(SNESSetTolerances(snes, feenox_var_value(feenox.pde.vars.snes_atol),
feenox_var_value(feenox.pde.vars.snes_rtol),
feenox_var_value(feenox.pde.vars.snes_stol),
(PetscInt)feenox_var_value(feenox.pde.vars.snes_max_it),
PETSC_DEFAULT));
#if PETSC_VERSION_LT(3,22,0)
petsc_call(SNESSetDivergenceTolerance(snes, -1));
#else
petsc_call(SNESSetDivergenceTolerance(snes, PETSC_UNLIMITED));
#endif
// TODO: this call complains about DM (?) in thermal-slab-transient.fee
// petsc_call(SNESSetUp(snes));
// customize ksp (and pc)---this needs to come after setting the jacobian
KSP ksp;
petsc_call(SNESGetKSP(snes, &ksp));
feenox_call(feenox_problem_setup_ksp(ksp));
// this has to come after setting up the ksp
petsc_call(SNESSetFromOptions(snes));
return FEENOX_OK;
}
PetscErrorCode feenox_snes_residual(SNES snes, Vec phi, Vec r, void *ctx) {
// set dirichlet BCs on the solution
if (feenox.pde.phi_bc == NULL) {
feenox_check_alloc(feenox.pde.phi_bc = feenox_problem_create_vector("phi_bc"));
}
feenox_call(feenox_problem_dirichlet_eval());
petsc_call(VecCopy(phi, feenox.pde.phi_bc));
feenox_call(feenox_problem_dirichlet_set_phi(feenox.pde.phi_bc));
// build both the residual and the jacobian
feenox_call(feenox_problem_phi_to_solution(feenox.pde.phi_bc, 0));
feenox_call(feenox_problem_build());
if (feenox.pde.has_internal_fluxes) {
// if the problem provides an internal flux, use it
petsc_call(VecCopy(feenox.pde.f, r));
} else {
// otherwise make it up from the stiffness and the solution
petsc_call(MatMult(feenox.pde.K, feenox.pde.phi_bc, r));
}
//#define VERBOSE
#ifdef VERBOSE
printf("r as in f\n");
petsc_call(VecView(r, PETSC_VIEWER_STDOUT_SELF));
#endif
// subtract b
petsc_call(VecAXPY(r, -1.0, feenox.pde.b));
#ifdef VERBOSE
printf("r as in f-b\n");
VecView(r, PETSC_VIEWER_STDOUT_SELF);
#endif
// set dirichlet BCs on the residual
feenox_call(feenox_problem_dirichlet_set_r(r, phi));
#ifdef VERBOSE
printf("r as in f-b + bcs\n");
VecView(r, PETSC_VIEWER_STDOUT_SELF);
printf("solution\n");
VecView(phi, PETSC_VIEWER_STDOUT_SELF);
#endif
return FEENOX_OK;
}
PetscErrorCode feenox_snes_jacobian(SNES snes, Vec phi, Mat J_snes, Mat P, void *ctx) {
// J_snes = (K + JK - Jb)_bc
// TODO: we want SAME_NONZERO_PATTERN!
petsc_call(MatAssemblyBegin(feenox.pde.K, MAT_FINAL_ASSEMBLY));
petsc_call(MatAssemblyEnd(feenox.pde.K, MAT_FINAL_ASSEMBLY));
petsc_call(MatAssemblyBegin(J_snes, MAT_FINAL_ASSEMBLY));
petsc_call(MatAssemblyEnd(J_snes, MAT_FINAL_ASSEMBLY));
petsc_call(MatCopy(feenox.pde.K, J_snes, DIFFERENT_NONZERO_PATTERN));
// printf("K\n");
// MatView(feenox.pde.K, PETSC_VIEWER_STDOUT_SELF);
// printf("JK\n");
// MatView(feenox.pde.JK, PETSC_VIEWER_STDOUT_SELF);
if (feenox.pde.has_jacobian_K) {
petsc_call(MatAXPY(J_snes, +1.0, feenox.pde.JK, DIFFERENT_NONZERO_PATTERN));
}
if (feenox.pde.has_jacobian_b) {
petsc_call(MatAXPY(J_snes, -1.0, feenox.pde.Jb, DIFFERENT_NONZERO_PATTERN));
}
feenox_call(feenox_problem_dirichlet_set_J(J_snes));
// printf("jacobian\n");
// MatView(J_snes, PETSC_VIEWER_STDOUT_SELF);
return FEENOX_OK;
}
PetscErrorCode feenox_snes_monitor(SNES snes, PetscInt n, PetscReal rnorm, void *dummy) {
if (feenox.pde.progress_r0 == 0) {
feenox.pde.progress_r0 = rnorm;
}
double current_progress = (rnorm > 1e-20) ? log((rnorm/feenox.pde.progress_r0))/log(feenox_var_value(feenox.pde.vars.ksp_rtol)) : 1;
if (current_progress > 1) {
current_progress = 1;
}
if (feenox.pde.progress_ascii == PETSC_TRUE) {
size_t i = 0;
for (i = (size_t)(100*feenox.pde.progress_last); i < (size_t)(100*current_progress); i++) {
printf(CHAR_PROGRESS_SOLVE);
fflush(stdout);
}
feenox.pde.progress_last = current_progress;
}
return 0;
}
#endif
feenox-1.2/src/pdes/petsc_ts.c 0000664 0001750 0001750 00000021774 15055303016 012046 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's transient solver using PETSc routines
*
* Copyright (C) 2021-2025 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
int feenox_problem_solve_petsc_transient(void) {
#ifdef HAVE_PETSC
if (feenox_var_value(feenox_special_var(in_static))) {
// if we are in the static step and no initial condition was given, we solve a steady state
if (feenox.pde.initial_condition == NULL) {
if (feenox.pde.math_type == math_type_linear) {
feenox_call(feenox_problem_solve_petsc_linear());
petsc_call(KSPDestroy(&feenox.pde.ksp));
feenox.pde.ksp = NULL;
} else if (feenox.pde.math_type == math_type_nonlinear) {
// when using PSEUDO, we should not solve the initial SNES because
// in pseudo we do not have to scale the BCs so the full problem is
// already set up at t=0 and then we don't take advantage of pseudo
int do_not_solve_update = 0;
int do_not_solve_old = feenox.pde.do_not_solve;
if (feenox.pde.ts_type != NULL && strcmp(feenox.pde.ts_type, TSPSEUDO) == 0) {
do_not_solve_update = 1;
feenox.pde.do_not_solve = 1;
}
feenox_call(feenox_problem_solve_petsc_nonlinear());
petsc_call(SNESDestroy(&feenox.pde.snes));
feenox.pde.snes = NULL;
if (do_not_solve_update) {
feenox.pde.do_not_solve = do_not_solve_old;
}
}
} else {
feenox_function_to_phi(feenox.pde.initial_condition, feenox.pde.phi);
}
if (feenox.pde.ts == NULL) {
petsc_call(TSCreate(PETSC_COMM_WORLD, &feenox.pde.ts));
petsc_call(TSSetIFunction(feenox.pde.ts, NULL, feenox_ts_residual, NULL));
// if we have an initial condition then matrices do not exist yet
if (feenox.pde.initial_condition != NULL) {
feenox_call(feenox_problem_build());
}
// THINK! whats is going on here?
feenox_check_alloc(feenox.pde.J_ts = feenox_problem_create_matrix("J_ts"));
// petsc_call(MatDuplicate(feenox.pde.has_jacobian_K ? feenox.pde.JK : feenox.pde.K, MAT_COPY_VALUES, &feenox.pde.J_ts));
petsc_call(TSSetIJacobian(feenox.pde.ts, feenox.pde.J_ts, feenox.pde.J_ts, feenox_ts_jacobian, NULL));
petsc_call(TSSetProblemType(feenox.pde.ts, (feenox.pde.math_type == math_type_linear) ? TS_LINEAR : TS_NONLINEAR));
// if BCs depend on time we need DAEs
petsc_call(TSSetEquationType(feenox.pde.ts, TS_EQ_IMPLICIT));
// petsc_call(TSSetEquationType(feenox.pde.ts, TS_EQ_DAE_IMPLICIT_INDEX1));
// petsc_call(TSARKIMEXSetFullyImplicit(feenox.pde.ts, PETSC_TRUE));
feenox_call(feenox_problem_setup_ts(feenox.pde.ts));
petsc_call(TSSetTimeStep(feenox.pde.ts, feenox_special_var_value(dt)));
petsc_call(TSSetMaxTime(feenox.pde.ts, 0.0));
petsc_call(TSSolve(feenox.pde.ts, feenox.pde.phi));
petsc_call(TSSetMaxTime(feenox.pde.ts, feenox_special_var_value(end_time)));
petsc_call(TSSetExactFinalTime(feenox.pde.ts, TS_EXACTFINALTIME_MATCHSTEP));
}
return FEENOX_OK;
}
if (feenox.pde.do_not_solve == 0) {
PetscInt ts_step = 0;
petsc_call(TSGetStepNumber(feenox.pde.ts, &ts_step));
petsc_call(TSSetMaxSteps(feenox.pde.ts, ts_step+1));
petsc_call(TSSetMaxTime(feenox.pde.ts, feenox_special_var_value(end_time)));
petsc_call(TSSetTimeStep(feenox.pde.ts, feenox_special_var_value(dt)));
petsc_call(TSSolve(feenox.pde.ts, feenox.pde.phi));
petsc_call(TSGetTime(feenox.pde.ts, feenox_value_ptr(feenox_special_var(t))));
petsc_call(TSGetTimeStep(feenox.pde.ts, feenox_value_ptr(feenox_special_var(dt))));
}
#endif
return FEENOX_OK;
}
#ifdef HAVE_PETSC
int feenox_problem_setup_ts(TS ts) {
if (feenox.pde.ts_type != NULL) {
petsc_call(TSSetType(ts, feenox.pde.ts_type));
// } else if (feenox.pde.transient_type == transient_type_quasistatic) {
// // TODO: the default depends on the physics type
// petsc_call(TSSetType(ts, TSBEULER));
} else {
// TODO: the default depends on the physics type
petsc_call(TSSetType(ts, TSBDF));
}
TSAdapt adapt;
petsc_call(TSGetAdapt(ts, &adapt));
petsc_call(TSAdaptSetType(adapt, (feenox.pde.ts_adapt_type != NULL) ? feenox.pde.ts_adapt_type : TSADAPTBASIC));
// the factors are so we can pass min_dt = max_dt
petsc_call(TSAdaptSetStepLimits(adapt, (feenox_special_var_value(min_dt) > 0) ? (1-1e-8)*feenox_special_var_value(min_dt) : PETSC_DEFAULT,
(feenox_special_var_value(max_dt) > 0) ? (1+1e-8)*feenox_special_var_value(max_dt) : feenox_special_var_value(end_time)));
// TODO: choose
// petsc_call(TSSetMaxStepRejections(feenox.pde.ts, 10000));
// petsc_call(TSSetMaxSNESFailures(feenox.pde.ts, 1000));
// PETSc 3.19 is buggy and needs this guys here
// the problem is that calling TSSetFromOptions here sets the line search to bt
// and we want to default to basic
if (PETSC_VERSION_MAJOR == 3 && PETSC_VERSION_MINOR == 19) {
petsc_call(TSSetFromOptions(ts));
}
SNES snes;
petsc_call(TSGetSNES(ts, &snes));
if (snes != NULL) {
feenox_call(feenox_problem_setup_snes(snes));
} else {
KSP ksp;
petsc_call(TSGetKSP(ts, &ksp));
if (ksp != NULL) {
feenox_call(feenox_problem_setup_ksp(ksp));
}
}
// options overwrite
petsc_call(TSSetFromOptions(ts));
return FEENOX_OK;
}
PetscErrorCode feenox_ts_residual(TS ts, PetscReal t, Vec phi, Vec phi_dot, Vec r, void *ctx) {
feenox_special_var_value(t) = t;
// TODO: store in a global temporary vector
Vec phi_bc;
petsc_call(VecDuplicate(phi, &phi_bc));
petsc_call(VecCopy(phi, phi_bc));
feenox_call(feenox_problem_dirichlet_eval());
if (feenox.pde.math_type == math_type_nonlinear) {
feenox_call(feenox_problem_dirichlet_set_phi(phi_bc));
feenox_call(feenox_problem_phi_to_solution(phi_bc, 0));
if (feenox.pde.phi_bc != NULL) {
petsc_call(VecCopy(phi_bc, feenox.pde.phi_bc));
}
}
// TODO: for time-dependent neumann BCs it should not be needed to re-build the whole matrix, just the RHS
feenox_call(feenox_problem_build());
// compute the residual R(t,phi,phi_dot) = M*(phi_dot)_dirichlet + K*(phi)_dirichlet - b (linear)
// = M*(phi_dot)_dirichlet + f(phi)_dirichlet - b (non-linear)
// TODO: start with the K/f term and add the mass later
// set dirichlet BCs on the time derivative and multiply by M
if (feenox.pde.M != NULL) {
Vec phi_dot_bc;
petsc_call(VecDuplicate(phi, &phi_dot_bc));
petsc_call(VecCopy(phi_dot, phi_dot_bc));
feenox_call(feenox_problem_dirichlet_set_phi_dot(phi_dot_bc));
petsc_call(MatMult(feenox.pde.M, phi_dot_bc, r));
petsc_call(VecDestroy(&phi_dot_bc));
} else {
petsc_call(VecZeroEntries(r));
}
// set dirichlet BCs on the solution compute the residual
if (feenox.pde.has_internal_fluxes) {
// if the problem provides an internal flux, use it
petsc_call(VecCopy(feenox.pde.f, r));
} else {
// otherwise make it up from the stiffness and the solution
petsc_call(MatMultAdd(feenox.pde.K, phi_bc, r, r));
}
petsc_call(VecDestroy(&phi_bc));
petsc_call(VecAXPY(r, -1.0, feenox.pde.b));
// set dirichlet bcs on the residual
feenox_call(feenox_problem_dirichlet_set_r(r, phi));
return FEENOX_OK;
}
PetscErrorCode feenox_ts_jacobian(TS ts, PetscReal t, Vec phi, Vec phi_dot, PetscReal s, Mat J_ts, Mat P, void *ctx) {
petsc_call(MatAssemblyBegin(feenox.pde.K, MAT_FINAL_ASSEMBLY));
petsc_call(MatAssemblyEnd(feenox.pde.K, MAT_FINAL_ASSEMBLY));
petsc_call(MatAssemblyBegin(J_ts, MAT_FINAL_ASSEMBLY));
petsc_call(MatAssemblyEnd(J_ts, MAT_FINAL_ASSEMBLY));
// return (K + JK - Jb + s*M)_bc
petsc_call(MatCopy(feenox.pde.K, J_ts, DIFFERENT_NONZERO_PATTERN));
if (feenox.pde.has_jacobian_K) {
petsc_call(MatAXPY(J_ts, +1.0, feenox.pde.JK, DIFFERENT_NONZERO_PATTERN));
}
if (feenox.pde.has_jacobian_b) {
petsc_call(MatAXPY(J_ts, -1.0, feenox.pde.Jb, DIFFERENT_NONZERO_PATTERN));
}
if (feenox.pde.has_mass) {
petsc_call(MatAXPY(J_ts, s, feenox.pde.M, DIFFERENT_NONZERO_PATTERN));
}
feenox_call(feenox_problem_dirichlet_set_J(J_ts));
return FEENOX_OK;
}
#endif
feenox-1.2/src/pdes/reaction.c 0000664 0001750 0001750 00000013664 15055303016 012025 /*------------ -------------- -------- --- ----- --- -- - -
* feenox function for computing reactions
*
* Copyright (C) 2016--2021 Jeremy Theler
*
* This file is part of feenox.
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
int feenox_instruction_reaction(void *arg) {
#ifdef HAVE_PETSC
reaction_t *reaction = (reaction_t *)arg;
if (reaction->vector != NULL && reaction->vector->initialized == 0) {
feenox_vector_init(reaction->vector, FEENOX_VECTOR_NO_INITIAL);
}
// this is an implicit SOLVE_PROBLEM point
if (feenox.pde.problem_solved == 0) {
feenox_call(feenox_instruction_solve_problem(NULL));
}
// order == 1 for moment
unsigned int g = 0;
Vec arm[] = {NULL, NULL, NULL};
double x0[] = {0, 0, 0};
PetscInt *node_index = NULL;
if (reaction->order == 1) {
feenox_check_alloc(node_index = calloc(feenox.pde.size_local, sizeof(PetscInt)));
for (g = 0; g < feenox.pde.dofs; g++) {
if (reaction->x0[g].items != NULL) {
// if an explicit coordinate was given, use it
x0[g] = feenox_expression_eval(&reaction->x0[g]);
} else {
// use the COG
if (reaction->physical_group->volume == 0) {
feenox_call(feenox_physical_group_compute_volume(reaction->physical_group, feenox.pde.mesh));
}
x0[g] = reaction->physical_group->cog[g];
}
petsc_call(MatCreateVecs(feenox.pde.K, PETSC_NULLPTR, &arm[g]));
}
}
PetscInt *row[] = {NULL, NULL, NULL};
for (g = 0; g < feenox.pde.dofs; g++) {
feenox_check_alloc(row[g] = calloc(feenox.pde.size_local, sizeof(PetscInt)));
}
// get which nodes need to be taken into account
size_t i = 0;
size_t j = 0;
size_t k = 0;
unsigned int j_local = 0;
int add = 0;
for (j = feenox.pde.first_node; j < feenox.pde.last_node; j++) {
add = 0;
// this could have been done by sweeping the assigned elements and checking out if the nodes belong to the entity
for (i = 0; add == 0 && i < reaction->physical_group->n_elements; i++) {
element_t *element = &feenox.pde.mesh->element[reaction->physical_group->element[i]];
for (j_local = 0; add == 0 && j_local < element->type->nodes; j_local++) {
if (element->node[j_local]->index_mesh == j) {
add = 1;
for (g = 0; g < feenox.pde.dofs; g++) {
row[g][k] = feenox.pde.mesh->node[j].index_dof[g];
}
if (reaction->order == 1) {
node_index[k] = j;
}
k++;
}
}
}
}
// the IS of the columns is the same for all the DOFs
IS set_cols = NULL;
petsc_call(ISCreateStride(PETSC_COMM_WORLD, feenox.pde.size_local, feenox.pde.first_row, 1, &set_cols));
IS set_rows[] = {NULL, NULL, NULL};
Mat K_row[] = {NULL, NULL, NULL};
Vec K_row_u[] = {NULL, NULL, NULL};
double R[] = {0, 0, 0};
for (g = 0; g < feenox.pde.dofs; g++) {
// the IS of the rows depends on the DOF
petsc_call(ISCreateGeneral(PETSC_COMM_WORLD, k, row[g], PETSC_USE_POINTER, &set_rows[g]));
petsc_call(MatCreateSubMatrix(feenox.pde.K, set_rows[g], set_cols, MAT_INITIAL_MATRIX, &K_row[g]));
petsc_call(MatCreateVecs(K_row[g], PETSC_NULLPTR, &K_row_u[g]));
petsc_call(MatMult(K_row[g], feenox.pde.phi, K_row_u[g]));
if (reaction->order == 1) {
petsc_call(MatCreateVecs(K_row[g], PETSC_NULLPTR, &arm[g]));
// TODO: do not set non-local values
for (j = 0; j < k; j++) {
petsc_call(VecSetValue(arm[g], j, feenox.pde.mesh->node[node_index[j]].x[g] - x0[g], INSERT_VALUES));
}
}
// zeroth-order reactions con be resolved right now
if (reaction->order == 0) {
petsc_call(VecSum(K_row_u[g], &R[g]));
}
}
// for first-order moments we need to do another loop because moments need all the three forces
if (reaction->order == 1) {
for (g = 0; g < feenox.pde.dofs; g++) {
int a;
int b;
switch (g) {
case 0:
a = 1;
b = 2;
break;
case 1:
a = 0;
b = 2;
break;
case 2:
a = 0;
b = 1;
break;
}
PetscScalar Fa_db = 0;
petsc_call(VecDot(K_row_u[a], arm[b], &Fa_db));
PetscScalar Fb_da = 0;
petsc_call(VecDot(K_row_u[b], arm[a], &Fb_da));
R[g] = Fa_db + Fb_da;
}
}
for (g = 0; g < feenox.pde.dofs; g++) {
if (feenox.pde.dofs == 1) {
feenox_var_value(reaction->scalar) = R[0];
} else {
gsl_vector_set(reaction->vector->value, g, R[g]);
}
petsc_call(VecDestroy(&K_row_u[g]));
petsc_call(MatDestroy(&K_row[g]));
petsc_call(ISDestroy(&set_rows[g]));
if (reaction->order == 1) {
petsc_call(VecDestroy(&arm[g]));
}
feenox_free(row[g]);
}
petsc_call(ISDestroy(&set_cols));
if (reaction->order == 1) {
feenox_free(node_index);
}
// TODO
/*
if (fino.problem_kind == problem_kind_axisymmetric) {
if (fino.symmetry_axis == symmetry_axis_y) {
gsl_vector_set(reaction->vector->value, 0, 0);
gsl_vector_set(reaction->vector->value, 1, 2*M_PI*R[1]);
} else if (fino.symmetry_axis == symmetry_axis_x) {
gsl_vector_set(reaction->vector->value, 0, 2*M_PI*R[0]);
gsl_vector_set(reaction->vector->value, 1, 0);
}
}
*/
#endif
return FEENOX_OK;
}
feenox-1.2/src/pdes/slepc_eps.c 0000664 0001750 0001750 00000015721 15055303016 012172 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's eigen solver using SLEPc routines
*
* Copyright (C) 2021--2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
int feenox_problem_solve_slepc_eigen(void) {
#ifdef HAVE_SLEPC
// build ---------------------------------------------------------------------
petsc_call(PetscLogStagePush(feenox.pde.stage_build));
// we need the matrices to set the operators
feenox_call(feenox_problem_build());
feenox_call(feenox_problem_dirichlet_eval());
feenox_call(feenox_problem_dirichlet_set_K());
feenox_call(feenox_problem_dirichlet_set_M());
petsc_call(PetscLogStagePop());
// ---------------------------------------------------------------------------
if (feenox.pde.missed_dump != NULL) {
feenox_call(feenox_instruction_dump(feenox.pde.missed_dump));
}
// solve ---------------------------------------------------------------------
petsc_call(PetscLogStagePush(feenox.pde.stage_solve));
if (feenox.pde.eps == NULL) {
petsc_call(EPSCreate(PETSC_COMM_WORLD, &feenox.pde.eps));
if (feenox.pde.eps_type != NULL) {
petsc_call(EPSSetType(feenox.pde.eps, feenox.pde.eps_type));
}
// here we might choose whether to use lambda or omega
if (feenox.pde.setup_eps != NULL) {
feenox_call(feenox.pde.setup_eps(feenox.pde.eps));
}
// default is lambda but each PDE should choose whatever works better
if (feenox.pde.eigen_formulation == eigen_formulation_undefined) {
feenox.pde.eigen_formulation = eigen_formulation_lambda;
}
// operators depending on formulation
if (feenox.pde.eigen_formulation == eigen_formulation_lambda) {
petsc_call(EPSSetOperators(feenox.pde.eps, feenox.pde.M_bc, feenox.pde.K_bc));
petsc_call(EPSSetWhichEigenpairs(feenox.pde.eps, EPS_LARGEST_MAGNITUDE));
} else if (feenox.pde.eigen_formulation == eigen_formulation_omega) {
petsc_call(EPSSetOperators(feenox.pde.eps, feenox.pde.K_bc, feenox.pde.M_bc));
petsc_call(EPSSetWhichEigenpairs(feenox.pde.eps, EPS_SMALLEST_MAGNITUDE));
} else {
feenox_push_error_message("internal error, neither omega nor lambda set");
return FEENOX_ERROR;
}
// get the associated spectral transformation
ST st = NULL;
petsc_call(EPSGetST(feenox.pde.eps, &st));
if (st == NULL) {
feenox_push_error_message("cannot retrieve spectral transformation object");
return FEENOX_ERROR;
}
if (feenox.pde.st_type != NULL) {
petsc_call(STSetType(st, feenox.pde.st_type));
} else {
if ((feenox.pde.eigen_formulation == eigen_formulation_lambda && feenox.pde.eigen_dirichlet_zero == eigen_dirichlet_zero_M) ||
(feenox.pde.eigen_formulation == eigen_formulation_omega && feenox.pde.eigen_dirichlet_zero == eigen_dirichlet_zero_K)) {
petsc_call(STSetType(st, STSHIFT));
} else {
petsc_call(STSetType(st, STSINVERT));
}
}
STType sttype = NULL;
feenox_call(STGetType(st, &sttype));
if (strcmp(sttype, STSINVERT) == 0 || strcmp(sttype, STCAYLEY) == 0) {
// shift and invert needs a target
petsc_call(EPSSetTarget(feenox.pde.eps, 0));
petsc_call(EPSSetWhichEigenpairs(feenox.pde.eps, EPS_TARGET_MAGNITUDE));
}
// shift and invert offsets
if (feenox_var_value(feenox.pde.vars.eps_st_sigma) != 0) {
petsc_call(STSetShift(st, feenox_var_value(feenox.pde.vars.eps_st_sigma)));
}
if (feenox_var_value(feenox.pde.vars.eps_st_nu) != 0) {
petsc_call(STCayleySetAntishift(st, feenox_var_value(feenox.pde.vars.eps_st_nu)));
}
// tolerances
petsc_call(EPSSetTolerances(feenox.pde.eps, feenox_var_value(feenox.pde.vars.eps_tol),
(PetscInt)feenox_var_value(feenox.pde.vars.eps_max_it)));
// setup the linear solver
KSP ksp = NULL;
petsc_call(STGetKSP(st, &ksp));
if (ksp == NULL) {
feenox_push_error_message("cannot retrieve linear solver object");
return FEENOX_ERROR;
}
feenox_call(feenox_problem_setup_ksp(ksp));
// this should be faster but it is not
// TODO: let the user choose
EPSProblemType eps_type;
petsc_call(EPSGetProblemType(feenox.pde.eps, &eps_type));
if (eps_type == 0) {
petsc_call(EPSSetProblemType(feenox.pde.eps, (feenox.pde.symmetric_K && feenox.pde.symmetric_M) ? EPS_GHEP : EPS_GNHEP));
}
// specify how many eigenvalues (and eigenvectors) to compute.
if (feenox.pde.eps_ncv.items != NULL) {
petsc_call(EPSSetDimensions(feenox.pde.eps, feenox.pde.nev, (PetscInt)(feenox_expression_eval(&feenox.pde.eps_ncv)), PETSC_DEFAULT));
} else {
petsc_call(EPSSetDimensions(feenox.pde.eps, feenox.pde.nev, PETSC_DEFAULT, PETSC_DEFAULT));
}
feenox_check_alloc(feenox.pde.eigenvalue = calloc(feenox.pde.nev, sizeof(PetscScalar)));
feenox_check_alloc(feenox.pde.eigenvector = calloc(feenox.pde.nev, sizeof(Vec)));
petsc_call(EPSSetFromOptions(feenox.pde.eps));
}
petsc_call(EPSSetInitialSpace(feenox.pde.eps, 1, &feenox.pde.phi));
petsc_call(EPSSolve(feenox.pde.eps));
PetscInt nconv = 0;
petsc_call(EPSGetConverged(feenox.pde.eps, &nconv));
if (nconv == 0) {
feenox_push_error_message("no converged eigen-pairs found (%d requested)", feenox.pde.nev);
return FEENOX_ERROR;
} else if (nconv < feenox.pde.nev) {
feenox_push_error_message("eigen-solver obtained only %d converged eigen-pairs (%d requested)", nconv, feenox.pde.nev);
return FEENOX_ERROR;
}
PetscScalar imag = 0;
unsigned int i = 0;
for (i = 0; i < feenox.pde.nev; i++) {
petsc_call(MatCreateVecs(feenox.pde.K, NULL, &feenox.pde.eigenvector[i]));
petsc_call(EPSGetEigenpair(feenox.pde.eps, i, &feenox.pde.eigenvalue[i], &imag, feenox.pde.eigenvector[i], PETSC_NULLPTR));
// TODO: should we allow complex eigenvalues?
if (fabs(imag) > feenox_var_value(feenox.pde.vars.eps_tol)) {
feenox_push_error_message("the eigenvalue %d is complex (%g + i %g)", i+1, feenox.pde.eigenvalue[i], imag);
return FEENOX_ERROR;
}
}
petsc_call(PetscLogStagePop());
// ---------------------------------------------------------------------------
#endif
return FEENOX_OK;
}
feenox-1.2/src/pdes/solve.c 0000664 0001750 0001750 00000014634 15055303016 011347 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's problem-solving routines
*
* Copyright (C) 2021--2025 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
int feenox_instruction_solve_problem(void *arg) {
#ifdef HAVE_PETSC
// we say that we already solved this because if say a BC depends on
// the unkown, we get into an infinite loop for implicit SOLVE_PROBLEM
feenox.pde.problem_solved = 1;
// init ----------------------------------------------------------------------
petsc_call(PetscLogStagePush(feenox.pde.stage_init));
// initialize only if we did not initialize before
if (feenox.pde.spatial_unknowns == 0) {
// if there is no explicit mesh, use the main one
if (feenox.pde.mesh == NULL && (feenox.pde.mesh = feenox.mesh.mesh_main) == NULL) {
feenox_push_error_message("unknown mesh (no READ_MESH keyword)");
return FEENOX_ERROR;
}
feenox_call(feenox.pde.init_before_run());
if (feenox.pde.solve == NULL) {
feenox_push_error_message("internal mismatch, undefined solver");
return FEENOX_ERROR;
}
feenox_call(feenox_problem_init_runtime_general());
}
if (feenox_var_value(feenox_special_var(in_static)) && feenox.pde.initial_guess != NULL) {
// TODO: what about SLEPc?
feenox_call(feenox_function_to_phi(feenox.pde.initial_guess, feenox.pde.phi));
}
petsc_call(PetscLogStagePop());
// ---------------------------------------------------------------------------
// solve the problem with this per-mathematics virtual method
// (which in turn calls a per-physics matrix & vector builds)
feenox_call(feenox.pde.solve());
// post ----------------------------------------------------------------------
petsc_call(PetscLogStagePush(feenox.pde.stage_post));
// TODO: how to do this in parallel?
feenox_call(feenox_problem_phi_to_solution((feenox.pde.nev == 0) ? feenox.pde.phi : feenox.pde.eigenvector[0], 1));
if (feenox.pde.solve_post != NULL) {
feenox_call(feenox.pde.solve_post());
}
petsc_call(PetscLogStagePop());
// ---------------------------------------------------------------------------
#endif
return FEENOX_OK;
}
#ifdef HAVE_PETSC
int feenox_function_to_phi(function_t *function, Vec phi) {
// fill the petsc vector with the data from the initial condition function of space
size_t j = 0;
for (j = feenox.pde.first_node; j < feenox.pde.last_node; j++) {
petsc_call(VecSetValue(phi, feenox.pde.mesh->node[j].index_dof[0], feenox_function_eval(function, feenox.pde.mesh->node[j].x), INSERT_VALUES));
}
// TODO: add prefixes to allow -vec_view
petsc_call(VecAssemblyBegin(phi));
petsc_call(VecAssemblyEnd(phi));
return FEENOX_OK;
}
int feenox_problem_phi_to_solution(Vec phi, int gradients) {
VecScatter vscat;
Vec phi_full;
PetscScalar *phi_full_array;
PetscInt nlocal;
// TODO: if nprocs == 1 then we already have the full vector
petsc_call(VecScatterCreateToAll(phi, &vscat, &phi_full));
petsc_call(VecScatterBegin(vscat, phi, phi_full, INSERT_VALUES, SCATTER_FORWARD));
petsc_call(VecScatterEnd(vscat, phi, phi_full, INSERT_VALUES, SCATTER_FORWARD));
petsc_call(VecGetLocalSize(phi_full, &nlocal));
if (nlocal != feenox.pde.size_global) {
feenox_push_error_message("internal check of problem size with scatter failed, %d != %d\n", nlocal, feenox.pde.size_global);
return FEENOX_ERROR;
}
petsc_call(VecGetArray(phi_full, &phi_full_array));
// make up G functions with the solution
for (size_t j = 0; j < feenox.pde.spatial_unknowns; j++) {
if (feenox.pde.mesh->node[j].phi == NULL) {
feenox_check_alloc(feenox.pde.mesh->node[j].phi = calloc(feenox.pde.dofs, sizeof(double)));
}
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
feenox.pde.mesh->node[j].phi[g] = phi_full_array[feenox.pde.mesh->node[j].index_dof[g]];
// if we are not in rough mode we fill the solution here
// because it is easier, in rough mode we need to
// iterate over the elements instead of over the nodes
if (feenox.pde.rough == 0) {
feenox_vector_set(feenox.pde.solution[g]->vector_value, j, feenox.pde.mesh->node[j].phi[g]);
}
if (feenox.pde.nev > 1) {
PetscScalar xi = 0;
for (int i = 0; i < feenox.pde.nev; i++) {
// the values already have the excitation factor
PetscInt index = feenox.pde.mesh->node[j].index_dof[g];
petsc_call(VecGetValues(feenox.pde.eigenvector[i], 1, &index, &xi));
feenox_vector_set(feenox.pde.mode[g][i]->vector_value, j, xi);
// TODO: point this to the former!
feenox_vector_set(feenox.pde.vectors.phi[i], j, xi);
}
}
}
}
petsc_call(VecRestoreArray(phi_full, &phi_full_array));
petsc_call(VecDestroy(&phi_full));
petsc_call(VecScatterDestroy(&vscat));
if (feenox.pde.rough) {
node_t *node;
// in rough mode we need to iterate over the elements first and then over the nodes
// TODO: see if the order of the loops is the optimal one
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
for (size_t i = 0; i < feenox.pde.mesh_rough->n_elements; i++) {
for (size_t j = 0; j < feenox.pde.mesh_rough->element[i].type->nodes; j++) {
node = feenox.pde.mesh_rough->element[i].node[j];
feenox_vector_set(feenox.pde.solution[g]->vector_value, node->index_mesh, node->phi[g]);
}
}
}
}
if (feenox.pde.compute_gradients && gradients) {
feenox_call(feenox_problem_gradient_compute());
}
return FEENOX_OK;
}
#endif
int feenox_problem_init_default(void) {
return FEENOX_OK;
}
feenox-1.2/src/pdes/methods.h 0000664 0001750 0001750 00000000345 15055303017 011662 // automatically generated by autogen.sh
#include "laplace/methods.h"
#include "mechanical/methods.h"
#include "modal/methods.h"
#include "neutron_diffusion/methods.h"
#include "neutron_sn/methods.h"
#include "thermal/methods.h"
feenox-1.2/src/pdes/parse.c 0000664 0001750 0001750 00000005076 15055303017 011332 // automatically generated by autogen.sh
#include "feenox.h"
int feenox_pde_parse_problem_type(const char *token) {
///kw_pde+PROBLEM+desc Ask FeenoX to solve a partial differential equation problem.
///kw_pde+PROBLEM+usage PROBLEM
///kw_pde+PROBLEM+detail Currently, FeenoX can solve the following types of PDE-casted problems:
///kw_pde+PROBLEM+detail @
///kw_pde+PROBLEM+usage { laplace
///kw_pde+PROBLEM+detail * `laplace` the Laplace (or Poisson) equation, either steady state or transient
if (strcasecmp(token, "laplace") == 0) {
feenox.pde.parse_problem = feenox_problem_parse_problem_laplace;
///kw_pde+PROBLEM+usage | mechanical
///kw_pde+PROBLEM+detail * `mechanical` steady-state solid mechanics with elastic or hyperelastic materials
} else if (strcasecmp(token, "mechanical") == 0) {
feenox.pde.parse_problem = feenox_problem_parse_problem_mechanical;
///kw_pde+PROBLEM+usage | modal
///kw_pde+PROBLEM+detail * `modal` natural mechanical frequencies and modes of oscillation
} else if (strcasecmp(token, "modal") == 0) {
feenox.pde.parse_problem = feenox_problem_parse_problem_modal;
///kw_pde+PROBLEM+usage | neutron_diffusion
///kw_pde+PROBLEM+detail * `neutron_diffusion` multi-group core-level neutron diffusion with a FEM formulation
} else if (strcasecmp(token, "neutron_diffusion") == 0) {
feenox.pde.parse_problem = feenox_problem_parse_problem_neutron_diffusion;
///kw_pde+PROBLEM+usage | neutron_sn
///kw_pde+PROBLEM+detail * `neutron_sn` multi-group core-level neutron transport using
///kw_pde+PROBLEM+detail - discrete ordinates $S_N$ for angular discretization, and
///kw_pde+PROBLEM+detail - isoparametric finite elements for spatial discretization.
} else if (strcasecmp(token, "neutron_sn") == 0) {
feenox.pde.parse_problem = feenox_problem_parse_problem_neutron_sn;
///kw_pde+PROBLEM+usage | thermal
///kw_pde+PROBLEM+detail * `thermal` heat conduction including transients and non-linear conductivity
} else if (strcasecmp(token, "thermal") == 0) {
feenox.pde.parse_problem = feenox_problem_parse_problem_thermal;
} else {
feenox_push_error_message("unknown problem type '%s'", token);
return FEENOX_ERROR;
}
///kw_pde+PROBLEM+usage }@
///kw_pde+PROBLEM+detail @
///kw_pde+PROBLEM+detail > If you are a programmer and want to contribute with another problem type, please do so!
///kw_pde+PROBLEM+detail > Check out the [programming guide in the FeenoX repository](https://github.com/seamplex/feenox/blob/main/doc/programming.md).
///kw_pde+PROBLEM+detail @
return FEENOX_OK;
}
feenox-1.2/src/pdes/available.h 0000664 0001750 0001750 00000000135 15055303017 012134 #define AVAILABLE_PDES "laplace\nmechanical\nmodal\nneutron_diffusion\nneutron_sn\nthermal\n" feenox-1.2/src/pdes/thermal/ 0000775 0001750 0001750 00000000000 15055303133 011557 5 feenox-1.2/src/pdes/thermal/bc.c 0000664 0001750 0001750 00000015577 15055303016 012246 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for the heat equation: boundary conditions
*
* Copyright (C) 2021--2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "thermal.h"
// this virtual method is called from the parser, it fills in the already-allocated
// structure bc_data according to the two strings lhs=rhs, i.e. q=1 or T=1+x
// note that h=a and Tref=b are handled by two bc_datas but linked together through next
int feenox_problem_bc_parse_thermal(bc_data_t *bc_data, const char *lhs, char *rhs) {
// TODO: document BCs with triple comments
if (strcmp(lhs, "T") == 0) {
// temperature
bc_data->type_phys = BC_TYPE_THERMAL_TEMPERATURE;
bc_data->type_math = bc_type_math_dirichlet;
bc_data->set_essential = feenox_problem_bc_set_thermal_temperature;
} else if (strcmp(lhs, "q''") == 0 || strcmp(lhs, "q") == 0 || strcmp(lhs, "adiabatic") == 0) {
// heat flux
bc_data->type_phys = BC_TYPE_THERMAL_HEATFLUX;
bc_data->type_math = bc_type_math_neumann;
bc_data->set_natural = feenox_problem_bc_set_thermal_heatflux;
} else if (strcmp(lhs, "h") == 0) {
// heat flux
bc_data->type_phys = BC_TYPE_THERMAL_CONVECTION_COEFFICIENT;
bc_data->type_math = bc_type_math_robin;
bc_data->set_natural = feenox_problem_bc_set_thermal_convection;
bc_data->fills_matrix = 1;
} else if (strcmp(lhs, "Tref") == 0 || strcmp(lhs, "T_ref") == 0 ||
strcmp(lhs, "Tinf") == 0 || strcmp(lhs, "T_inf") == 0) {
// heat flux
bc_data->type_phys = BC_TYPE_THERMAL_CONVECTION_TEMPERATURE;
bc_data->type_math = bc_type_math_robin;
bc_data->set_natural = feenox_problem_bc_set_thermal_convection;
bc_data->fills_matrix = 1;
} else {
feenox_push_error_message("unknown thermal boundary condition '%s'", lhs);
return FEENOX_ERROR;
}
feenox_call(feenox_expression_parse(&bc_data->expr, rhs));
// for non-linear problems it is important to have a good initial guess
// if the user did not give us one in T_guess we average all the temperatures from the BCs
// but we have to be sure that the BC expression does not involve a function coming from somewhere else
if (bc_data->type_phys == BC_TYPE_THERMAL_TEMPERATURE || bc_data->type_phys == BC_TYPE_THERMAL_CONVECTION_TEMPERATURE ) {
thermal.guessed_initial_guess += feenox_expression_eval(&bc_data->expr);
thermal.n_bc_temperatures++;
}
bc_data->space_dependent = feenox_depends_on_space(bc_data->expr.variables);
bc_data->nonlinear = feenox_depends_on_function(bc_data->expr.functions, feenox.pde.solution[0]);
if (bc_data->nonlinear && bc_data->type_phys == BC_TYPE_THERMAL_TEMPERATURE) {
feenox_push_error_message("essential boundary condition '%s' cannot depend on temperature", rhs);
return FEENOX_ERROR;
}
// TODO: check that a single BC does not mix T and Tref
return FEENOX_OK;
}
// this virtual method fills in the dirichlet indexes and values with bc_data
int feenox_problem_bc_set_thermal_temperature(bc_data_t *this, element_t *e, size_t j_global) {
#ifdef HAVE_PETSC
feenox_call(feenox_problem_dirichlet_add(j_global, 0, feenox_expression_eval(&this->expr)));
// TODO: only in transient
// feenox.pde.dirichlet_derivatives[*k] = feenox_expression_derivative_wrt_variable(&bc_data->expr, feenox_special_var(t), feenox_special_var_value(t));
#endif
return FEENOX_OK;
}
// this virtual method builds the surface elemental matrix
// TODO: one method for constant flux, one for temp, one for space
int feenox_problem_bc_set_thermal_heatflux(bc_data_t *this, element_t *e, unsigned int q) {
#ifdef HAVE_PETSC
// TODO: cache if neither space nor temperature dependent
double *x = feenox_fem_compute_x_at_gauss_if_needed_and_update_var(e, q, feenox.pde.mesh->integration, this->space_dependent);
double power = feenox_expression_eval(&this->expr);
feenox_call(feenox_problem_rhs_add(e, q, &power));
if (this->nonlinear) {
double T = feenox_function_eval(feenox.pde.solution[0], x);
double dqdT = feenox_expression_derivative_wrt_function(&this->expr, feenox.pde.solution[0], T);
// mind the positive sign!
gsl_matrix *H = feenox_fem_compute_H_Gc_at_gauss(e, q, feenox.pde.mesh->integration);
double wdet = feenox_fem_compute_w_det_at_gauss_integration(e, q, feenox.pde.mesh->integration);
feenox_call(feenox_blas_BtB_accum(H, +wdet*dqdT, feenox.fem.Jbi));
}
#endif
return FEENOX_OK;
}
// this virtual method builds the surface elemental matrix
int feenox_problem_bc_set_thermal_convection(bc_data_t *this, element_t *e, unsigned int q) {
#ifdef HAVE_PETSC
// convection needs something in the next bc_data, if there is nothing then we are done
if (this->next == NULL) {
return FEENOX_OK;
}
feenox_fem_compute_x_at_gauss_if_needed_and_update_var(e, q, feenox.pde.mesh->integration, this->space_dependent);
double h = 0;
double Tref = 0;
if (this->type_phys == BC_TYPE_THERMAL_CONVECTION_COEFFICIENT && this->next->type_phys == BC_TYPE_THERMAL_CONVECTION_TEMPERATURE) {
h = feenox_expression_eval(&this->expr);
Tref = feenox_expression_eval(&this->next->expr);
} else if (this->type_phys == BC_TYPE_THERMAL_CONVECTION_TEMPERATURE && this->next->type_phys == BC_TYPE_THERMAL_CONVECTION_COEFFICIENT) {
Tref = feenox_expression_eval(&this->expr);
h = feenox_expression_eval(&this->next->expr);
} else {
feenox_push_error_message("convection condition needs h and Tref");
return FEENOX_ERROR;
}
// the h*Tref goes to b
double rhs = h*Tref;
feenox_call(feenox_problem_rhs_add(e, q, &rhs));
// TODO: the h*T goes directly to the stiffness matrix
// this is not efficient because if h depends on t or T we might need to re-build the whole K
double wdet = feenox_fem_compute_w_det_at_gauss_integration(e, q, feenox.pde.mesh->integration);
gsl_matrix *H = feenox_fem_compute_H_Gc_at_gauss(e, q, feenox.pde.mesh->integration);
feenox_call(feenox_blas_BtB_accum(H, +wdet*h, feenox.fem.Ki));
#endif
return FEENOX_OK;
}
// TODO: we can do something of the like for radiation but care
// has to be taken regarding the units of the temperatures!
feenox-1.2/src/pdes/thermal/bulk.c 0000664 0001750 0001750 00000007702 15055303016 012606 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for the heat equation: bulk elements
*
* Copyright (C) 2021--2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "thermal.h"
// TODO: put the gauss loop inside this call so we can cache number of nodes, etc
int feenox_problem_build_volumetric_gauss_point_thermal(element_t *e, unsigned int q) {
#ifdef HAVE_PETSC
double *x = feenox_fem_compute_x_at_gauss_if_needed(e, q, feenox.pde.mesh->integration, thermal.space_dependent_stiffness || thermal.space_dependent_source || thermal.space_dependent_mass);
material_t *material = feenox_fem_get_material(e);
double k = thermal.k.eval(&thermal.k, x, material);
double wdet = feenox_fem_compute_w_det_at_gauss_integration(e, q, feenox.pde.mesh->integration);
gsl_matrix *B = feenox_fem_compute_B_at_gauss_integration(e, q, feenox.pde.mesh->integration);
feenox_call(feenox_blas_BtB_accum(B, wdet*k, feenox.fem.Ki));
// volumetric heat source term Ht*q
// TODO: total source Q
if (thermal.q.defined) {
double power = thermal.q.eval(&thermal.q, x, material);
feenox_call(feenox_problem_rhs_add(e, q, &power));
}
if (feenox.pde.has_jacobian) {
gsl_matrix *elemental_T = NULL;
feenox_check_alloc(elemental_T = gsl_matrix_calloc(e->type->nodes, 1));
double T = 0;
double Tj = 0;
gsl_matrix *H = feenox_fem_compute_H_Gc_at_gauss(e, q, feenox.pde.mesh->integration);
for (unsigned int j = 0; j < e->type->nodes; j++) {
Tj = feenox_vector_get(feenox.pde.solution[0]->vector_value, e->node[j]->index_dof[0]);
gsl_matrix_set(elemental_T, j, 0, Tj);
T += gsl_matrix_get(H, 0, j) * Tj;
}
if (thermal.temperature_dependent_stiffness) {
double dkdT = feenox_expression_derivative_wrt_function(thermal.k.expr, feenox.pde.solution[0], T);
gsl_matrix *BtB = gsl_matrix_calloc(e->type->nodes, e->type->nodes);
feenox_call(feenox_blas_BtB(B, 1.0, BtB));
feenox_call(feenox_blas_PtCB_accum(BtB, elemental_T, H, NULL, wdet*dkdT, feenox.fem.JKi));
gsl_matrix_free(BtB);
}
if (thermal.temperature_dependent_source) {
double dqdT = feenox_expression_derivative_wrt_function(thermal.q.expr, feenox.pde.solution[0], T);
// mind the positive sign!
feenox_call(feenox_blas_BtB_accum(H, +wdet*dqdT, feenox.fem.Jbi));
}
gsl_matrix_free(elemental_T);
}
// mass matrix Ht*rho*cp*H
if (feenox.pde.has_mass) {
double rhocp = 0;
if (thermal.rhocp.defined) {
rhocp = thermal.rhocp.eval(&thermal.rhocp, x, material);
} else if (thermal.kappa.defined) {
rhocp = k / thermal.kappa.eval(&thermal.kappa, x, material);
} else if (thermal.rho.defined && thermal.cp.defined) {
rhocp = thermal.rho.eval(&thermal.rho, x, material) * thermal.cp.eval(&thermal.cp, x, material);
} else {
// this should have been already checked
feenox_push_error_message("no heat capacity found");
return FEENOX_ERROR;
}
gsl_matrix *H = feenox_fem_compute_H_Gc_at_gauss(e, q, feenox.pde.mesh->integration);
feenox_call(feenox_blas_BtB_accum(H, wdet*rhocp, feenox.fem.Mi));
}
#endif
return FEENOX_OK;
}
feenox-1.2/src/pdes/thermal/heatflux.c 0000664 0001750 0001750 00000005324 15055303016 013467 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for the heat equation: computation of heat fluxes
*
* Copyright (C) 2021 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "thermal.h"
int feenox_problem_gradient_fill_thermal(void) {
feenox_call(feenox_problem_fill_aux_solution(thermal.qx));
if (feenox.pde.dim > 1) {
feenox_call(feenox_problem_fill_aux_solution(thermal.qy));
if (feenox.pde.dim > 2) {
feenox_call(feenox_problem_fill_aux_solution(thermal.qz));
}
}
return FEENOX_OK;
}
// used only in rough
int feenox_problem_gradient_properties_at_element_nodes_thermal(element_t *element, mesh_t *mesh) {
return FEENOX_OK;
}
int feenox_problem_gradient_fluxes_at_node_alloc_thermal(node_t *node) {
if (node->flux == NULL) {
feenox_check_alloc(node->flux = calloc(feenox.pde.dim, sizeof(double)));
} else {
for (unsigned int d = 0; d < feenox.pde.dim; d++) {
node->flux[d] = 0;
}
}
return FEENOX_OK;
}
int feenox_problem_gradient_add_elemental_contribution_to_node_thermal(node_t *node, element_t *element, unsigned int j, double rel_weight) {
double heat_flux = 0;
double k = thermal.k.eval(&thermal.k, node->x, element->physical_group->material);
for (unsigned int d = 0; d < feenox.pde.dim; d++) {
heat_flux = -k * gsl_matrix_get(element->dphidx_node[j], 0, d);
node->flux[d] += rel_weight * (heat_flux - node->flux[d]);
}
return FEENOX_OK;
}
int feenox_problem_gradient_fill_fluxes_thermal(mesh_t *mesh, size_t j) {
// TODO: wrappers so pdes don't have to access the vectors
feenox_vector_set(thermal.qx->vector_value, j, mesh->node[j].flux[0]);
if (feenox.pde.dim > 1) {
feenox_vector_set(thermal.qy->vector_value, j, mesh->node[j].flux[1]);
if (feenox.pde.dim > 2) {
feenox_vector_set(thermal.qz->vector_value, j, mesh->node[j].flux[2]);
}
}
// TODO: uncertainties
return FEENOX_OK;
}
feenox-1.2/src/pdes/thermal/init.c 0000664 0001750 0001750 00000042120 15055303016 012605 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for the heat equation: initialization
*
* Copyright (C) 2021-2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "thermal.h"
thermal_t thermal;
int feenox_problem_parse_time_init_thermal(void) {
///kw_pde+PROBLEM+detail * `thermal` heat conduction including transients and non-linear conductivity
#ifdef HAVE_PETSC
// virtual methods
feenox.pde.parse_bc = feenox_problem_bc_parse_thermal;
feenox.pde.parse_write_results = feenox_problem_parse_write_post_thermal;
feenox.pde.init_before_run = feenox_problem_init_runtime_thermal;
feenox.pde.setup_ksp = feenox_problem_setup_ksp_thermal;
feenox.pde.setup_pc = feenox_problem_setup_pc_thermal;
feenox.pde.element_build_volumetric_at_gauss = feenox_problem_build_volumetric_gauss_point_thermal;
feenox.pde.solve_post = feenox_problem_solve_post_thermal;
feenox.pde.gradient_fill = feenox_problem_gradient_fill_thermal;
feenox.pde.gradient_nodal_properties = feenox_problem_gradient_properties_at_element_nodes_thermal;
feenox.pde.gradient_alloc_nodal_fluxes = feenox_problem_gradient_fluxes_at_node_alloc_thermal;
feenox.pde.gradient_add_elemental_contribution_to_node = feenox_problem_gradient_add_elemental_contribution_to_node_thermal;
feenox.pde.gradient_fill_fluxes = feenox_problem_gradient_fill_fluxes_thermal;
// we are FEM
feenox.mesh.default_field_location = field_location_nodes;
// thermal is a scalar problem
feenox.pde.dofs = 1;
///re_thermal+T+description The temperature field\ $T(\vec{x})$. This is the primary unknown of the problem.
feenox_check_alloc(feenox.pde.unknown_name = calloc(feenox.pde.dofs, sizeof(char *)));
feenox_check_alloc(feenox.pde.unknown_name[0] = strdup("T"));
// heat fluxes
///re_thermal+qx+description The heat flux field\ $q_x(\vec{x}) = -k(\vec{x}) \cdot \frac{\partial T}{\partial x}$ in the\ $x$ direction. This is a secondary unknown of the problem.
///re_thermal+qy+description The heat flux field\ $q_y(\vec{x}) = -k(\vec{x}) \cdot \frac{\partial T}{\partial y}$ in the\ $x$ direction. This is a secondary unknown of the problem.
///re_thermal+qy+description Only available for two and three-dimensional problems.
///re_thermal+qz+description The heat flux field\ $q_z(\vec{x}) = -k(\vec{x}) \cdot \frac{\partial T}{\partial z}$ in the\ $x$ direction. This is a secondary unknown of the problem.
///re_thermal+qz+description Only available for three-dimensional problems.
feenox_call(feenox_problem_define_solution_function("qx", &thermal.qx, FEENOX_SOLUTION_GRADIENT));
if (feenox.pde.dim > 1) {
feenox_call(feenox_problem_define_solution_function("qy", &thermal.qy, FEENOX_SOLUTION_GRADIENT));
if (feenox.pde.dim > 2) {
feenox_call(feenox_problem_define_solution_function("qz", &thermal.qz, FEENOX_SOLUTION_GRADIENT));
}
}
///pr_thermal+T_0+description The initial condition for the temperature in transient problems.
///pr_thermal+T_0+description If not given, a steady-steady computation at $t=0$ is performed.
///pr_thermal+T_guess+description The initial guess for the temperature in steady-state problems.
///pr_thermal+T_guess+description If not given, a uniform distribution equal to the the average
///pr_thermal+T_guess+description of all the temperature appearing in boundary conditions is used.
///va_thermal+T_max+detail The maximum temperature\ $T_\text{max}$.
feenox_check_null(thermal.T_max = feenox_define_variable_get_ptr("T_max"));
///va_thermal+T_min+detail The minimum temperature\ $T_\text{min}$.
feenox_check_null(thermal.T_min = feenox_define_variable_get_ptr("T_min"));
#endif
return FEENOX_OK;
}
int feenox_problem_init_runtime_thermal(void) {
#ifdef HAVE_PETSC
// we are FEM not FVM
feenox.pde.mesh->data_type = data_type_node;
feenox.pde.spatial_unknowns = feenox.pde.mesh->n_nodes;
// check if we were given an initial guess
if ((feenox.pde.initial_guess = feenox_get_function_ptr("T_guess")) != NULL) {
if (feenox.pde.initial_guess->n_arguments != feenox.pde.dim) {
feenox_push_error_message("initial guess function T_guess ought to have %d arguments instead of %d", feenox.pde.dim, feenox.pde.initial_guess->n_arguments);
return FEENOX_ERROR;
}
}
// check if we were given an initial solution
if ((feenox.pde.initial_condition = feenox_get_function_ptr("T_0")) != NULL) {
if (feenox.pde.initial_condition->n_arguments != feenox.pde.dim) {
feenox_push_error_message("initial condition function T_0 ought to have %d arguments instead of %d", feenox.pde.dim, feenox.pde.initial_condition->n_arguments);
return FEENOX_ERROR;
}
}
// initialize distributions
// here we just initialize everything, during build we know which
// of them are mandatory and which are optional
///pr_thermal+k+usage k
///pr_thermal+k+description The thermal conductivity in units of power per length per degree of temperature.
///pr_thermal+k+description This property is mandatory.
feenox_distribution_define_mandatory(thermal, k, "k", "thermal conductivity");
thermal.k.non_uniform = feenox_depends_on_space(thermal.k.dependency_variables);
thermal.k.non_linear = feenox_depends_on_function(thermal.k.dependency_functions, feenox.pde.solution[0]);
// TODO: orthotropic heat conduction
///pr_thermal+q'''+usage q'''
///pr_thermal+q'''+description The volumetric power dissipated in the material in units of power per unit of volume.
///pr_thermal+q'''+description Default is zero (i.e. no power).
feenox_call(feenox_distribution_init(&thermal.q, "q'''"));
if (thermal.q.defined == 0) {
///pr_thermal+q+usage q
///pr_thermal+q+description Alias for `q'''`
feenox_call(feenox_distribution_init(&thermal.q, "q"));
}
thermal.q.non_uniform = feenox_depends_on_space(thermal.q.dependency_variables);
thermal.q.non_linear = feenox_depends_on_function(thermal.q.dependency_functions, feenox.pde.solution[0]);
feenox.pde.has_mass = (feenox_var_value(feenox_special_var(end_time)) > 0) && (feenox.pde.transient_type != transient_type_quasistatic);
if (feenox.pde.has_mass) {
///pr_thermal+kappa+usage kappa
///pr_thermal+kappa+description Thermal diffusivity in units of area per unit of time.
///pr_thermal+kappa+description Equal to $k / (\rho c_p)$, the thermal conductivity `k` divided by the density `rho` and specific heat capacity `cp`.
///pr_thermal+kappa+description Either `kappa`, `rhocp` or both `rho` and `cp` are needed for transient
feenox_call(feenox_distribution_init(&thermal.kappa, "kappa"));
if (thermal.kappa.defined == 0) {
///pr_thermal+rhocp+usage rhocp
///pr_thermal+rhocp+description Product of the density `rho` times the specific heat capacity `cp`,
///pr_thermal+rhocp+description in units of energy per unit of volume per degree of temperature.
///pr_thermal+rhocp+description Either `kappa`, `rhocp` or both `rho` and `cp` are needed for transient
feenox_call(feenox_distribution_init(&thermal.rhocp, "rhocp"));
if (thermal.rhocp.defined == 0) {
///pr_thermal+rho+usage rho
///pr_thermal+rho+description Density in units of mass per unit of volume.
///pr_thermal+rho+description Either `kappa`, `rhocp` or both `rho` and `cp` are needed for transient
feenox_call(feenox_distribution_init(&thermal.rho, "rho"));
///pr_thermal+cp+usage cp
///pr_thermal+cp+description Specific heat in units of energy per unit of mass per degree of temperature.
///pr_thermal+cp+description Either `kappa`, `rhocp` or both `rho` and `cp` are needed for transient
feenox_call(feenox_distribution_init(&thermal.cp, "cp"));
if (thermal.rho.defined == 0 || thermal.cp.defined == 0) {
feenox_push_error_message("either 'kappa', 'rhocp' or both 'rho' and 'cp' are needed for transient");
return FEENOX_ERROR;
}
if (thermal.rho.full == 0 || thermal.cp.full == 0) {
feenox_push_error_message("either 'rho' or 'cp' is not defined over all volumes");
return FEENOX_ERROR;
}
} else if (thermal.rhocp.full == 0) {
feenox_push_error_message("product 'rhocp' is not defined over all volumes");
return FEENOX_ERROR;
}
} else if (thermal.kappa.full == 0) {
feenox_push_error_message("thermal diffusivity 'kappa' is not defined over all volumes");
return FEENOX_ERROR;
}
}
thermal.kappa.non_uniform = feenox_depends_on_space(thermal.kappa.dependency_variables);
thermal.rho.non_uniform = feenox_depends_on_space(thermal.rho.dependency_variables);
thermal.cp.non_uniform = feenox_depends_on_space(thermal.cp.dependency_variables);
thermal.rhocp.non_uniform = feenox_depends_on_space(thermal.rhocp.dependency_variables);
thermal.kappa.non_linear = feenox_depends_on_function(thermal.kappa.dependency_functions, feenox.pde.solution[0]);
thermal.rho.non_linear = feenox_depends_on_function(thermal.rho.dependency_functions, feenox.pde.solution[0]);
thermal.cp.non_linear = feenox_depends_on_function(thermal.cp.dependency_functions, feenox.pde.solution[0]);
thermal.rhocp.non_linear = feenox_depends_on_function(thermal.rhocp.dependency_functions, feenox.pde.solution[0]);
thermal.space_dependent_stiffness = thermal.k.non_uniform ||
thermal.kx.non_uniform ||
thermal.ky.non_uniform ||
thermal.kz.non_uniform;
thermal.space_dependent_source = thermal.q.non_uniform;
thermal.space_dependent_mass = thermal.kappa.non_uniform ||
thermal.rho.non_uniform ||
thermal.cp.non_uniform ||
thermal.rhocp.non_uniform;
thermal.temperature_dependent_source = thermal.q.non_linear;
thermal.temperature_dependent_stiffness = feenox_depends_on_function(thermal.k.dependency_functions, feenox.pde.solution[0]) ||
feenox_depends_on_function(thermal.kx.dependency_functions, feenox.pde.solution[0]) ||
feenox_depends_on_function(thermal.ky.dependency_functions, feenox.pde.solution[0]) ||
feenox_depends_on_function(thermal.kz.dependency_functions, feenox.pde.solution[0]);
thermal.temperature_dependent_mass = feenox_depends_on_function(thermal.kappa.dependency_functions, feenox.pde.solution[0]) ||
feenox_depends_on_function(thermal.rho.dependency_functions, feenox.pde.solution[0]) ||
feenox_depends_on_function(thermal.cp.dependency_functions, feenox.pde.solution[0]) ||
feenox_depends_on_function(thermal.rhocp.dependency_functions, feenox.pde.solution[0]);
// check BCs are consistent
bc_t *bc = NULL;
bc_t *bc_tmp = NULL;
HASH_ITER(hh, feenox.mesh.bcs, bc, bc_tmp) {
int first_type_math = bc_type_math_undefined;
bc_data_t *bc_data = NULL;
bc_data_t *bc_data_tmp = NULL;
DL_FOREACH_SAFE(bc->bc_datums, bc_data, bc_data_tmp) {
// this is general, maybe we can put it in a non-virtual method
if (first_type_math == bc_type_math_undefined) {
first_type_math = bc_data->type_math;
} else if (first_type_math != bc_data->type_math) {
feenox_push_error_message("BCs of different types cannot be mixed '%s' and '%s'", bc->bc_datums->string, bc_data->string);
return FEENOX_ERROR;
}
// convection (i.e. Robin) BCs have two arguments h and Tref,
// we need to check they both are given (and only these two and nothing more)
if (bc_data->type_math == bc_type_math_robin) {
// first, check that there are only two bc_datums
// utlist's doubly-linked lists work like this, sorry!
if (bc_data == bc->bc_datums && bc_data->next == NULL) {
feenox_push_error_message("both 'h' and 'Tref' have to be given in the same BC line");
return FEENOX_ERROR;
} else if (!(bc_data->prev == bc_data->next || bc_data->next == NULL)) {
feenox_push_error_message("only 'h' and 'Tref' have to be given in the same BC line");
return FEENOX_ERROR;
}
// check we have one h and one Tref
if (bc_data == bc->bc_datums) {
if ((bc_data->type_phys == BC_TYPE_THERMAL_CONVECTION_COEFFICIENT && bc_data->next->type_phys == BC_TYPE_THERMAL_CONVECTION_COEFFICIENT) ||
(bc_data->type_phys == BC_TYPE_THERMAL_CONVECTION_TEMPERATURE && bc_data->next->type_phys == BC_TYPE_THERMAL_CONVECTION_TEMPERATURE)) {
feenox_push_error_message("convection BC needs one 'h' and one 'Tref' in the same BC line");
return FEENOX_ERROR;
}
} else if (bc_data->next == NULL) {
// mark the second as disabled so only the first one is processed
bc_data->disabled = 1;
} else {
feenox_push_error_message("internal mismatch in convection BC");
return FEENOX_ERROR;
}
}
bc_data->space_dependent = feenox_depends_on_space(bc_data->expr.variables);
thermal.space_dependent_bc |= bc_data->space_dependent;
bc_data->nonlinear = feenox_depends_on_function(bc_data->expr.functions, feenox.pde.solution[0]);
thermal.temperature_dependent_bc |= bc_data->nonlinear;
}
}
// if there is no initial guess, make up one
if (feenox.pde.initial_guess == NULL && thermal.n_bc_temperatures != 0) {
// average BC temperatures
thermal.guessed_initial_guess /= thermal.n_bc_temperatures;
if (feenox.pde.initial_guess == NULL) {
feenox_check_null(feenox.pde.initial_guess = feenox_define_function_get_ptr("T_guess", feenox.pde.dim));
feenox_call(feenox_function_set_argument_variable("T_guess", 0, "x"));
if (feenox.pde.dim > 1) {
feenox_call(feenox_function_set_argument_variable("T_guess", 1, "y"));
if (feenox.pde.dim > 2) {
feenox_call(feenox_function_set_argument_variable("T_guess", 2, "z"));
}
}
}
char *evaluated_temp = NULL;
feenox_check_minusone(asprintf(&evaluated_temp, "%g", thermal.guessed_initial_guess));
feenox_call(feenox_function_set_expression("T_guess", evaluated_temp));
feenox_free(evaluated_temp);
}
if (feenox.pde.math_type == math_type_automatic) {
feenox.pde.math_type = (thermal.temperature_dependent_stiffness == 0 &&
thermal.temperature_dependent_mass == 0 &&
thermal.temperature_dependent_source == 0 &&
thermal.temperature_dependent_bc == 0) ? math_type_linear : math_type_nonlinear;
}
// TODO: check for transient_type
feenox.pde.solve = (feenox_special_var_value(end_time) > 0) ? feenox_problem_solve_petsc_transient :
((feenox.pde.math_type == math_type_linear) ? feenox_problem_solve_petsc_linear :
feenox_problem_solve_petsc_nonlinear);
feenox.pde.has_stiffness = 1;
feenox.pde.has_rhs = 1;
// has_mass is above
feenox.pde.has_jacobian_K = thermal.temperature_dependent_stiffness;
feenox.pde.has_jacobian_M = feenox.pde.has_mass && thermal.temperature_dependent_mass;
feenox.pde.has_jacobian_b = (thermal.temperature_dependent_source || thermal.temperature_dependent_bc);
feenox.pde.has_jacobian = feenox.pde.has_jacobian_K || feenox.pde.has_jacobian_M || feenox.pde.has_jacobian_b;
// if the conductivity depends on temperature the jacobian is not symmetric
feenox.pde.symmetric_K = !thermal.temperature_dependent_stiffness;
feenox.pde.symmetric_M = 1;
// see if we have to compute gradients
feenox.pde.compute_gradients |= (thermal.qx != NULL && thermal.qx->used) ||
(thermal.qy != NULL && thermal.qy->used) ||
(thermal.qz != NULL && thermal.qz->used);
#endif
return FEENOX_OK;
}
#ifdef HAVE_PETSC
int feenox_problem_setup_pc_thermal(PC pc) {
PCType pc_type = NULL;
petsc_call(PCGetType(pc, &pc_type));
if (pc_type == NULL) {
petsc_call(PCSetType(pc, PCGAMG));
}
return FEENOX_OK;
}
int feenox_problem_setup_ksp_thermal(KSP ksp ) {
KSPType ksp_type = NULL;
petsc_call(KSPGetType(ksp, &ksp_type));
if (ksp_type == NULL) {
petsc_call(KSPSetType(ksp, KSPCG));
}
return FEENOX_OK;
}
#endif
feenox-1.2/src/pdes/thermal/methods.h 0000664 0001750 0001750 00000005037 15055303016 013320 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for the heat equation: virtual methods
*
* Copyright (C) 2021--2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#ifndef THERMAL_METHODS_H
#define THERMAL_METHODS_H
// thermal/parser.c
extern int feenox_problem_parse_problem_thermal(const char *token);
extern int feenox_problem_parse_write_post_thermal(mesh_write_t *mesh_write, const char *token);
// thermal/init.c
extern int feenox_problem_parse_time_init_thermal(void);
extern int feenox_problem_init_runtime_thermal(void);
#ifdef HAVE_PETSC
extern int feenox_problem_setup_pc_thermal(PC pc);
extern int feenox_problem_setup_ksp_thermal(KSP ksp);
#endif
// thermal/bulk.c
extern int feenox_problem_build_volumetric_gauss_point_thermal(element_t *element, unsigned int q);
// thermal/bc.c
extern int feenox_problem_bc_parse_thermal(bc_data_t *bc_data, const char *lhs, char *rhs);
extern int feenox_problem_bc_set_thermal_temperature(bc_data_t *bc_data, element_t *e, size_t j_global);
extern int feenox_problem_bc_set_thermal_heatflux(bc_data_t *bc_data, element_t *e, unsigned int q);
extern int feenox_problem_bc_set_thermal_convection(bc_data_t *bc_data, element_t *e, unsigned int q);
// thermal/heatflux.c
extern int feenox_problem_gradient_fill_thermal(void);
extern int feenox_problem_gradient_properties_at_element_nodes_thermal(element_t *element, mesh_t *mesh);
extern int feenox_problem_gradient_fluxes_at_node_alloc_thermal(node_t *node);
extern int feenox_problem_gradient_add_elemental_contribution_to_node_thermal(node_t *node, element_t *element, unsigned int j, double rel_weight);
extern int feenox_problem_gradient_fill_fluxes_thermal(mesh_t *mesh, size_t j);
// thermal/post.c
extern int feenox_problem_solve_post_thermal(void);
#endif
feenox-1.2/src/pdes/thermal/parser.c 0000664 0001750 0001750 00000005131 15055303016 013137 /*------------ -------------- -------- --- ----- --- -- - -
* FeenoX parser for thermal-specific keywords
*
* Copyright (C) 2023 Jeremy Theler
*
* This file is part of FeenoX.
*
* FeenoX is free software: you can redistribute it and/or modify
* it under the terms "of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "../../parser/parser.h"
#include "thermal.h"
int feenox_problem_parse_problem_thermal(const char *token) {
///kw_pde+PROBLEM+detail * `thermal` solves the heat conduction problem.
// no need to parse anything;
if (token != NULL) {
feenox_push_error_message("undefined keyword '%s'", token);
return FEENOX_ERROR;
} else {
// if token is NULL we have to do the parse-time initialization
feenox_call(feenox_problem_parse_time_init_thermal());
}
return FEENOX_OK;
}
int feenox_problem_parse_write_post_thermal(mesh_write_t *mesh_write, const char *token) {
if (strcmp(token, "all") == 0) {
feenox_call(feenox_problem_parse_write_post_thermal(mesh_write, "temperature"));
feenox_call(feenox_problem_parse_write_post_thermal(mesh_write, "heat_flux"));
} else if (strcmp(token, "temperature") == 0 || strcmp(token, "T") == 0) {
feenox_call(feenox_add_post_field(mesh_write, 1, &feenox.pde.solution[0]->name, NULL, field_location_nodes));
} else if (strcmp(token, "heat_flux") == 0 || strcmp(token, "heat_fluxes") == 0) {
char *tokens[3] = {NULL, NULL, NULL};
tokens[0] = strdup((0 < feenox.pde.dim) ? thermal.qx->name : "0");
tokens[1] = strdup((1 < feenox.pde.dim) ? thermal.qy->name : "0");
tokens[2] = strdup((2 < feenox.pde.dim) ? thermal.qz->name : "0");
feenox_call(feenox_add_post_field(mesh_write, 3, tokens, "heat_flux", field_location_nodes));
for (unsigned int m = 0; m < 3; m++) {
feenox_free(tokens[m]);
}
} else {
feenox_push_error_message("undefined keyword '%s' for thermal WRITE_RESULTS", token);
return FEENOX_ERROR;
}
return FEENOX_OK;
}
feenox-1.2/src/pdes/thermal/post.c 0000664 0001750 0001750 00000003135 15055303016 012632 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for the heat equation: post
*
* Copyright (C) 2021 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "thermal.h"
// TODO: move to heatflux
int feenox_problem_solve_post_thermal(void) {
if (thermal.T_max->used == 0 && thermal.T_min->used == 0) {
return FEENOX_OK;
}
double T = 0;
feenox_var_value(thermal.T_max) = -INFTY;
feenox_var_value(thermal.T_min) = +INFTY;
for (size_t j = 0; j < feenox.pde.mesh->n_nodes; j++) {
T = feenox_vector_get(feenox.pde.solution[0]->vector_value, j);
if (T > feenox_var_value(thermal.T_max)) {
feenox_var_value(thermal.T_max) = T;
}
if (T < feenox_var_value(thermal.T_min)) {
feenox_var_value(thermal.T_min) = T;
}
}
return FEENOX_OK;
}
feenox-1.2/src/pdes/thermal/thermal.h 0000664 0001750 0001750 00000004525 15055303016 013312 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for the heat equation: global header
*
* Copyright (C) 2021 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#ifndef THERMAL_H
#define THERMAL_H
#define BC_TYPE_THERMAL_UNDEFINED 0
#define BC_TYPE_THERMAL_TEMPERATURE 1
#define BC_TYPE_THERMAL_HEATFLUX 2
#define BC_TYPE_THERMAL_CONVECTION_COEFFICIENT 3
#define BC_TYPE_THERMAL_CONVECTION_TEMPERATURE 4
typedef struct thermal_t thermal_t;
struct thermal_t {
distribution_t k; // isotropic conductivity
distribution_t kx, ky, kz; // orthotropic conductivity
distribution_t q; // volumetric heat source
distribution_t kappa; // thermal diffusivity = k/(rho cp)
distribution_t rho; // density
distribution_t cp; // heat capacity
distribution_t rhocp; // density times heat capacity
int space_dependent_stiffness;
int temperature_dependent_stiffness;
int space_dependent_mass;
int temperature_dependent_mass;
int space_dependent_source;
int temperature_dependent_source;
int space_dependent_bc;
int temperature_dependent_bc;
double guessed_initial_guess;
int n_bc_temperatures;
// heat fluxes
function_t *qx;
function_t *qy;
function_t *qz;
// extrema
var_t *T_max;
var_t *T_min;
// caches for uniform properties
struct {
double k;
double kx, ky, kz;
double q;
double kappa;
double rho;
double cp;
double rhocp;
} cache;
};
extern thermal_t thermal;
#endif /* THERMAL_H */
feenox-1.2/src/pdes/neutron_sn/ 0000775 0001750 0001750 00000000000 15055303133 012315 5 feenox-1.2/src/pdes/neutron_sn/bc.c 0000664 0001750 0001750 00000012064 15055303016 012770 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for neutron transport FEM: boundary conditions
*
* Copyright (C) 2023--2024 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "neutron_sn.h"
int feenox_problem_bc_parse_neutron_sn(bc_data_t *bc_data, const char *lhs, char *rhs) {
// TODO: should this be the default BC?
if (strcmp(lhs, "vacuum") == 0 || strcmp(lhs, "null") == 0) {
// "null" is supported for compatibility with diffusion
bc_data->type_math = bc_type_math_dirichlet;
bc_data->set_essential = feenox_problem_bc_set_neutron_sn_vacuum;
bc_data->dof = -1;
} else if (strcmp(lhs, "mirror") == 0 || strcmp(lhs, "symmetry") == 0) {
bc_data->type_math = bc_type_math_dirichlet;
bc_data->dof = -1;
bc_data->set_essential = feenox_problem_bc_set_neutron_sn_mirror;
// TODO: albedo
// TODO: white current
// TODO: individual scalar fluxes as a function of theta & phi
} else {
feenox_push_error_message("unknown neutron_sn boundary condition '%s'", lhs);
return FEENOX_ERROR;
}
bc_data->space_dependent = feenox_depends_on_space(bc_data->expr.variables);
bc_data->nonlinear = feenox_depends_on_function(bc_data->expr.functions, feenox.pde.solution[0]);
if (bc_data->nonlinear && bc_data->type_math == bc_type_math_dirichlet) {
feenox_push_error_message("essential boundary condition '%s' cannot depend on phi", rhs);
return FEENOX_ERROR;
}
feenox_call(feenox_expression_parse(&bc_data->expr, rhs));
// TODO: check consistency, non-linearities, etc.
return FEENOX_OK;
}
// these virtual method fill in the dirichlet indexes and values with bc_data
int feenox_problem_bc_set_neutron_sn_vacuum(bc_data_t *this, element_t *e, size_t j_global) {
#ifdef HAVE_PETSC
PetscScalar outward_normal[3] = {0,0,0};
feenox_call(feenox_mesh_compute_outward_normal(e, outward_normal));
for (unsigned m = 0; m < neutron_sn.directions; m++) {
if (feenox_mesh_dot(neutron_sn.Omega[m], outward_normal) < 0) {
// if the direction is inward set it to zero
for (unsigned int g = 0; g < neutron_sn.groups; g++) {
feenox_call(feenox_problem_dirichlet_add(j_global, sn_dof_index(m,g), 0));
}
}
}
#endif
return FEENOX_OK;
}
int feenox_problem_bc_set_neutron_sn_mirror(bc_data_t *this, element_t *e, size_t j_global) {
#ifdef HAVE_PETSC
PetscScalar outward_normal[3] = {0,0,0};
PetscScalar reflected[3] = {0,0,0};
PetscScalar Omega_dot_outward = 0;
PetscScalar eps = feenox_var_value(feenox.mesh.vars.eps);
// TODO: mark the BC as dependent on the normal and compute it in the caller
feenox_call(feenox_mesh_compute_outward_normal(e, outward_normal));
for (unsigned m = 0; m < neutron_sn.directions; m++) {
if ((Omega_dot_outward = feenox_mesh_dot(neutron_sn.Omega[m], outward_normal)) < 0) {
// if the direction is inward then we have to reflect it
// if Omega is the incident direction with respect to the outward normal then
// reflected = Omega - 2*(Omega dot outward_normal) * outward_normal
for (int d = 0; d < 3; d++) {
reflected[d] = neutron_sn.Omega[m][d] - 2*Omega_dot_outward * outward_normal[d];
}
unsigned int m_prime = 0; // leave this out of the loop, it is used below
for (m_prime = 0; m_prime < neutron_sn.directions; m_prime++) {
if (fabs(reflected[0] - neutron_sn.Omega[m_prime][0]) < eps &&
fabs(reflected[1] - neutron_sn.Omega[m_prime][1]) < eps &&
fabs(reflected[2] - neutron_sn.Omega[m_prime][2]) < eps) {
break;
}
}
if (m_prime == neutron_sn.directions) {
feenox_push_error_message("cannot find a reflected direction for m=%d (out of %d in S%d) for node %d", m, neutron_sn.directions, neutron_sn.N, feenox.pde.mesh->node[j_global].tag);
return FEENOX_ERROR;
}
double *coefficients = NULL;
feenox_check_alloc(coefficients = calloc(feenox.pde.dofs, sizeof(double)));
for (unsigned int g = 0; g < neutron_sn.groups; g++) {
coefficients[sn_dof_index(m,g)] = -1;
coefficients[sn_dof_index(m_prime,g)] = +1;
}
feenox_call(feenox_problem_multifreedom_add(j_global, coefficients));
feenox_free(coefficients);
}
}
#endif
return FEENOX_OK;
}
feenox-1.2/src/pdes/neutron_sn/bulk.c 0000664 0001750 0001750 00000020132 15055303016 013334 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for neutron transport FEM: bulk elements
*
* Copyright (C) 2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "neutron_sn.h"
int feenox_problem_build_allocate_aux_neutron_sn(unsigned int J) {
neutron_sn.n_nodes = J;
int G = neutron_sn.groups;
int M = neutron_sn.directions;
int MG = M*G;
int JMG = J * MG;
if (neutron_sn.Li != NULL) {
gsl_matrix_free(neutron_sn.Li);
gsl_matrix_free(neutron_sn.Ai);
if (neutron_sn.has_fission) {
gsl_matrix_free(neutron_sn.Fi);
}
if (neutron_sn.has_sources) {
gsl_vector_free(neutron_sn.Si);
}
gsl_matrix_free(neutron_sn.P);
gsl_matrix_free(neutron_sn.DB);
gsl_matrix_free(neutron_sn.AH);
if (neutron_sn.has_fission) {
gsl_matrix_free(neutron_sn.Fi);
gsl_matrix_free(neutron_sn.XH);
}
}
feenox_check_alloc(neutron_sn.Li = gsl_matrix_calloc(JMG, JMG));
feenox_check_alloc(neutron_sn.Ai = gsl_matrix_calloc(JMG, JMG));
if (neutron_sn.has_fission) {
feenox_check_alloc(neutron_sn.Fi = gsl_matrix_calloc(JMG, JMG));
}
if (neutron_sn.has_sources) {
feenox_check_alloc(neutron_sn.Si = gsl_vector_calloc(JMG));
}
feenox_check_alloc(neutron_sn.P = gsl_matrix_calloc(MG, JMG));
feenox_check_alloc(neutron_sn.DB = gsl_matrix_calloc(MG, JMG));
feenox_check_alloc(neutron_sn.AH = gsl_matrix_calloc(MG, JMG));
if (neutron_sn.has_fission) {
feenox_check_alloc(neutron_sn.XH = gsl_matrix_calloc(MG, JMG));
}
return FEENOX_OK;
}
int feenox_problem_build_volumetric_neutron_sn(element_t *e) {
if (neutron_sn.space_XS == 0) {
feenox_call(feenox_problem_neutron_sn_eval_XS(feenox_fem_get_material(e), NULL));
}
return FEENOX_OK;
}
int feenox_problem_neutron_sn_eval_XS(material_t *material, double *x) {
// initialize to zero
gsl_matrix_set_zero(neutron_sn.R);
if (neutron_sn.has_fission) {
gsl_matrix_set_zero(neutron_sn.X);
}
if (neutron_sn.has_sources) {
gsl_vector_set_zero(neutron_sn.s);
}
for (int g = 0; g < neutron_sn.groups; g++) {
// independent sources
if (neutron_sn.S[g].defined) {
neutron_sn.S[g].eval(&neutron_sn.S[g], x, material);
}
// fission
if (neutron_sn.nu_Sigma_f[g].defined) {
neutron_sn.nu_Sigma_f[g].eval(&neutron_sn.nu_Sigma_f[g], x, material);
}
// scattering
for (unsigned int g_prime = 0; g_prime < neutron_sn.groups; g_prime++) {
if (neutron_sn.Sigma_s0[g_prime][g].defined) {
neutron_sn.Sigma_s0[g_prime][g].eval(&neutron_sn.Sigma_s0[g_prime][g], x, material);
}
if (neutron_sn.Sigma_s1[g_prime][g].defined) {
neutron_sn.Sigma_s1[g_prime][g].eval(&neutron_sn.Sigma_s1[g_prime][g], x, material);
}
}
// absorption
if (neutron_sn.Sigma_t[g].defined) {
neutron_sn.Sigma_t[g].eval(&neutron_sn.Sigma_t[g], x, material);
}
if (neutron_sn.Sigma_a[g].defined) {
neutron_sn.Sigma_a[g].eval(&neutron_sn.Sigma_a[g], x, material);
}
}
for (unsigned int m = 0; m < neutron_sn.directions; m++) {
for (unsigned int g = 0; g < neutron_sn.groups; g++) {
// independent sources
int diag = sn_dof_index(m,g);
gsl_vector_set(neutron_sn.s, diag, neutron_sn.S[g].value);
// scattering and fission
for (unsigned int g_prime = 0; g_prime < neutron_sn.groups; g_prime++) {
for (unsigned int m_prime = 0; m_prime < neutron_sn.directions; m_prime++) {
// scattering
double accum = -neutron_sn.w[m_prime] * neutron_sn.Sigma_s0[g_prime][g].value;
// anisotropic scattering l = 1
if (neutron_sn.Sigma_s1[g_prime][g].defined) {
accum -= neutron_sn.w[m_prime] * neutron_sn.Sigma_s1[g_prime][g].value * 3.0 * feenox_mesh_dot(neutron_sn.Omega[m], neutron_sn.Omega[m_prime]);
}
gsl_matrix_set(neutron_sn.R, diag, sn_dof_index(m_prime,g_prime), accum);
// fision
if (neutron_sn.has_fission) {
gsl_matrix_set(neutron_sn.X, diag, sn_dof_index(m_prime,g_prime), +neutron_sn.w[m_prime] * feenox_vector_get(neutron_sn.chi, g) * neutron_sn.nu_Sigma_f[g_prime].value);
}
}
}
// absorption
double accum = gsl_matrix_get(neutron_sn.R, diag, diag);
if (neutron_sn.Sigma_t[g].defined) {
accum += neutron_sn.Sigma_t[g].value;
} else {
accum += neutron_sn.Sigma_a[g].value;
for (unsigned int g_prime = 0; g_prime < neutron_sn.groups; g_prime++) {
accum += neutron_sn.Sigma_s0[g][g_prime].value;
}
}
gsl_matrix_set(neutron_sn.R, diag, diag, accum);
}
}
return FEENOX_OK;
}
int feenox_problem_build_volumetric_gauss_point_neutron_sn(element_t *e, unsigned int q) {
#ifdef HAVE_PETSC
if (neutron_sn.space_XS != 0) {
double *x = feenox_fem_compute_x_at_gauss(e, q, feenox.pde.mesh->integration);
feenox_call(feenox_problem_neutron_sn_eval_XS(feenox_fem_get_material(e), x));
}
// printf("build %ld %d\n", e->tag, q);
// petrov stabilization matrix
int MG = neutron_sn.directions * neutron_sn.groups;
double tau = feenox_var_value(neutron_sn.sn_alpha) * e->type->size(e);
gsl_matrix *H_G = feenox_fem_compute_H_Gc_at_gauss(e, q, feenox.pde.mesh->integration);
gsl_matrix *B = feenox_fem_compute_B_at_gauss_integration(e, q, feenox.pde.mesh->integration);
feenox_call(gsl_matrix_memcpy(neutron_sn.P, H_G));
for (unsigned int j = 0; j < neutron_sn.n_nodes; j++) {
int MGj = MG*j;
for (unsigned int m = 0; m < neutron_sn.directions; m++) {
for (unsigned int d = 0; d < feenox.pde.dim; d++) {
double value = tau * neutron_sn.Omega[m][d] * gsl_matrix_get(B, d, j);
for (unsigned int g = 0; g < neutron_sn.groups; g++) {
int diag = sn_dof_index(m,g);
gsl_matrix_add_to_element(neutron_sn.P, diag, MGj + diag, value);
}
}
}
}
// petrov-stabilized leakage term
double wdet = feenox_fem_compute_w_det_at_gauss_integration(e, q, feenox.pde.mesh->integration);
gsl_matrix *B_G = feenox_fem_compute_B_G_at_gauss(e, q, feenox.pde.mesh->integration);
feenox_call(feenox_blas_PtCB(neutron_sn.P, neutron_sn.D, B_G, neutron_sn.DB, wdet, neutron_sn.Li));
// petrov-stabilized removal term
feenox_call(feenox_blas_PtCB(neutron_sn.P, neutron_sn.R, H_G, neutron_sn.AH, wdet, neutron_sn.Ai));
// petrov-stabilized fission term
if (neutron_sn.has_fission) {
feenox_call(feenox_blas_PtCB(neutron_sn.P, neutron_sn.X, H_G, neutron_sn.XH, wdet, neutron_sn.Fi));
}
// petrov-stabilized source term
if (neutron_sn.has_sources) {
feenox_call(feenox_blas_Atb(neutron_sn.P, neutron_sn.s, wdet, neutron_sn.Si));
}
// for source-driven problems
// K = Ki + Ai - Xi
// for criticallity problems
// K = Ki + Ai
// M = Xi
feenox_call(gsl_matrix_add(neutron_sn.Li, neutron_sn.Ai));
if (neutron_sn.has_fission) {
if (neutron_sn.has_sources) {
feenox_call(gsl_matrix_scale(neutron_sn.Fi, -1.0));
feenox_call(gsl_matrix_add(neutron_sn.Li, neutron_sn.Fi));
} else {
feenox_call(gsl_matrix_add(feenox.fem.Mi, neutron_sn.Fi));
}
}
if (neutron_sn.has_sources) {
feenox_call(gsl_vector_add(feenox.fem.bi, neutron_sn.Si));
}
feenox_call(gsl_matrix_add(feenox.fem.Ki, neutron_sn.Li));
#endif
return FEENOX_OK;
}
feenox-1.2/src/pdes/neutron_sn/init.c 0000664 0001750 0001750 00000055771 15055303016 013363 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for neutron transport FEM: initialization
*
* Copyright (C) 2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "neutron_sn.h"
neutron_sn_t neutron_sn;
int feenox_problem_parse_time_init_neutron_sn(void) {
///kw_pde+PROBLEM+detail * `neutron_sn` multi-group core-level neutron transport using
///kw_pde+PROBLEM+detail - discrete ordinates $S_N$ for angular discretization, and
///kw_pde+PROBLEM+detail - isoparametric finite elements for spatial discretization.
// virtual methods
#ifdef HAVE_PETSC
feenox.pde.parse_bc = feenox_problem_bc_parse_neutron_sn;
feenox.pde.parse_write_results = feenox_problem_parse_write_post_neutron_sn;
feenox.pde.init_before_run = feenox_problem_init_runtime_neutron_sn;
#ifdef HAVE_SLEPC
feenox.pde.setup_eps = feenox_problem_setup_eps_neutron_sn;
#endif
feenox.pde.setup_ksp = feenox_problem_setup_ksp_neutron_sn;
feenox.pde.setup_pc = feenox_problem_setup_pc_neutron_sn;
feenox.pde.element_build_allocate_aux = feenox_problem_build_allocate_aux_neutron_sn;
feenox.pde.element_build_volumetric = feenox_problem_build_volumetric_neutron_sn;
feenox.pde.element_build_volumetric_at_gauss = feenox_problem_build_volumetric_gauss_point_neutron_sn;
feenox.pde.solve_post = feenox_problem_solve_post_neutron_sn;
// we are FEM
feenox.mesh.default_field_location = field_location_nodes;
// default is 1 group
if (neutron_sn.groups == 0) {
neutron_sn.groups = 1;
}
// default is N=2
if (neutron_sn.N == 0) {
neutron_sn.N = 2;
}
if (neutron_sn.N % 2 != 0) {
feenox_push_error_message("number of ordinates N = %d has to be even", neutron_sn.N);
return FEENOX_ERROR;
}
// stammler's eq 6.19
switch(feenox.pde.dim) {
case 1:
neutron_sn.directions = neutron_sn.N;
break;
case 2:
neutron_sn.directions = 0.5*neutron_sn.N*(neutron_sn.N+2);
break;
case 3:
neutron_sn.directions = neutron_sn.N*(neutron_sn.N+2);
break;
}
// dofs = number of directions * number of groups
feenox.pde.dofs = neutron_sn.directions * neutron_sn.groups;
// ------- neutron transport outputs -----------------------------------
// the angular fluxes psi
feenox_check_alloc(feenox.pde.unknown_name = calloc(feenox.pde.dofs, sizeof(char *)));
// TODO: document from comments
// NOTE: it is more natural to put first the group and then the direction
// while in the doc we use $\psi_{mg}$
for (unsigned int g = 0; g < neutron_sn.groups; g++) {
for (unsigned int m = 0; m < neutron_sn.directions; m++) {
feenox_check_minusone(asprintf(&feenox.pde.unknown_name[sn_dof_index(m,g)], "psi%u.%u", g+1, m+1));
}
}
// the scalar fluxes phi
// TODO: document
// TODO: for one group make an alias between phi1 and phi
feenox_check_alloc(neutron_sn.phi = calloc(neutron_sn.groups, sizeof(function_t *)));
for (unsigned int g = 0; g < neutron_sn.groups; g++) {
char *name = NULL;
feenox_check_minusone(asprintf(&name, "phi%u", g+1));
feenox_call(feenox_problem_define_solution_function(name, &neutron_sn.phi[g], FEENOX_SOLUTION_NOT_GRADIENT));
feenox_free(name);
}
///va_neutron_sn+keff+desc The effective multiplication factor\ $k_\text{eff}$.
neutron_sn.keff = feenox_define_variable_get_ptr("keff");
///va_neutron_sn+sn_alpha+desc The stabilization parameter\ $\alpha$ for $S_N$.
neutron_sn.sn_alpha = feenox_define_variable_get_ptr("sn_alpha");
feenox_var_value(neutron_sn.sn_alpha) = 0.5;
///va_neutron_sn+chi+desc A vector of size groups with the fission spectrum.
///va_neutron_sn+chi+desc Default is one in the first group and zero in the rest.
neutron_sn.chi = feenox_define_vector_get_ptr("chi", neutron_sn.groups);
feenox_vector_set(neutron_sn.chi, 0, 1.0);
// decrease the penalty weight
feenox_var_value(feenox.pde.vars.penalty_weight) = 100;
// ------------ initialize the SN weights ------------------------------------
// TODO: when adding FVM, these are the same so we should move it into a single location
feenox_check_alloc(neutron_sn.w = calloc(neutron_sn.directions, sizeof(double)));
feenox_check_alloc(neutron_sn.Omega = calloc(neutron_sn.directions, sizeof(double *)));
for (unsigned int m = 0; m < neutron_sn.directions; m++) {
feenox_check_alloc(neutron_sn.Omega[m] = calloc(3, sizeof(double)));
}
if (feenox.pde.dim == 1) {
// table 3-1 page 121 lewiss
// in 1D the directions are the zeros of the legendre polymonials
// and the weights are such the gauss quadrature is exact
switch (neutron_sn.N) {
case 2:
neutron_sn.Omega[0][0] = +1.0/M_SQRT3;
neutron_sn.w[0] = 1.0/2.0;
neutron_sn.Omega[1][0] = -neutron_sn.Omega[0][0];
neutron_sn.w[1] = neutron_sn.w[0];
break;
case 4:
neutron_sn.Omega[0][0] = sqrt(3.0/7.0 - 2.0/7.0 * sqrt(6.0/5.0));
neutron_sn.w[0] = 0.6521451549/2.0;
neutron_sn.Omega[1][0] = sqrt(3.0/7.0 + 2.0/7.0 * sqrt(6.0/5.0));
neutron_sn.w[1] = 0.3478548451/2.0;
neutron_sn.Omega[2][0] = -neutron_sn.Omega[0][0];
neutron_sn.w[2] = neutron_sn.w[0];
neutron_sn.Omega[3][0] = -neutron_sn.Omega[1][0];
neutron_sn.w[3] = neutron_sn.w[1];
break;
case 6:
neutron_sn.Omega[0][0] = 0.2386191860;
neutron_sn.w[0] = 0.4679139346/2.0;
neutron_sn.Omega[1][0] = 0.6612093864;
neutron_sn.w[1] = 0.3607615730/2.0;
neutron_sn.Omega[2][0] = 0.9324695142;
neutron_sn.w[2] = 0.1713244924/2.0;
neutron_sn.Omega[3][0] = -neutron_sn.Omega[0][0];
neutron_sn.w[3] = neutron_sn.w[0];
neutron_sn.Omega[4][0] = -neutron_sn.Omega[1][0];
neutron_sn.w[4] = neutron_sn.w[1];
neutron_sn.Omega[5][0] = -neutron_sn.Omega[2][0];
neutron_sn.w[5] = neutron_sn.w[2];
break;
case 8:
neutron_sn.Omega[0][0] = 0.1834346424;
neutron_sn.w[0] = 0.3626837834/2.0;
neutron_sn.Omega[1][0] = 0.5255324099;
neutron_sn.w[1] = 0.3137066459/2.0;
neutron_sn.Omega[2][0] = 0.7966664774;
neutron_sn.w[2] = 0.2223810344/2.0;
neutron_sn.Omega[3][0] = 0.9602898564;
neutron_sn.w[3] = 0.1012285363/2.0;
neutron_sn.Omega[4][0] = -neutron_sn.Omega[0][0];
neutron_sn.w[4] = neutron_sn.w[0];
neutron_sn.Omega[5][0] = -neutron_sn.Omega[1][0];
neutron_sn.w[5] = neutron_sn.w[1];
neutron_sn.Omega[6][0] = -neutron_sn.Omega[2][0];
neutron_sn.w[6] = neutron_sn.w[2];
neutron_sn.Omega[7][0] = -neutron_sn.Omega[3][0];
neutron_sn.w[7] = neutron_sn.w[3];
break;
default:
feenox_push_error_message("unsupported N = %d in 1D", neutron_sn.N);
return FEENOX_ERROR;
break;
}
} else {
// table 4-1 page 162 from lewiss
// we could have used file sndir2.dat from fentraco, but the values are different
// first set the weights as all the possible permutations in the first octant
// and then we fill in the others
// the initial cosine directions passed to feenox_problem_neutron_sn_init_cosines()
// are taken from table 4-1 from lewiss (p 162)
// which coincide with table 1 p 208 from stammler-abbate
// TODO: allow user provided first cosine and weights
double *weights_array = NULL;
switch (neutron_sn.N) {
case 2:
{
feenox_call(feenox_problem_neutron_sn_init_cosines(1.0/M_SQRT3));
feenox_check_alloc(weights_array = calloc(1, sizeof(double)));
weights_array[0] = 1;
}
break;
case 4:
{
feenox_call(feenox_problem_neutron_sn_init_cosines(0.3500212));
feenox_check_alloc(weights_array = calloc(1, sizeof(double)));
weights_array[0] = 1.0/3.0;
}
break;
case 6:
{
feenox_call(feenox_problem_neutron_sn_init_cosines(0.2666355));
feenox_check_alloc(weights_array = calloc(2, sizeof(double)));
weights_array[0] = 0.1761263;
weights_array[1] = 0.1572071;
}
break;
case 8:
{
feenox_call(feenox_problem_neutron_sn_init_cosines(0.2182179));
feenox_check_alloc(weights_array = calloc(3, sizeof(double)));
weights_array[0] = 0.1209877;
weights_array[1] = 0.0907407;
weights_array[2] = 0.0925926;
}
break;
case 10:
{
feenox_call(feenox_problem_neutron_sn_init_cosines(0.1893213));
feenox_check_alloc(weights_array = calloc(4, sizeof(double)));
weights_array[0] = 0.1402771*2/M_PI;
weights_array[1] = 0.1139285*2/M_PI;
weights_array[2] = 0.0707546*2/M_PI;
weights_array[3] = 0.0847101*2/M_PI;
}
break;
case 12:
{
feenox_call(feenox_problem_neutron_sn_init_cosines(0.1672126));
feenox_check_alloc(weights_array = calloc(5, sizeof(double)));
weights_array[0] = 0.0707626;
weights_array[1] = 0.0558811;
weights_array[2] = 0.0373377;
weights_array[3] = 0.0502819;
weights_array[4] = 0.0258513;
}
break;
case 16:
{
feenox_call(feenox_problem_neutron_sn_init_cosines(0.1389568));
feenox_check_alloc(weights_array = calloc(8, sizeof(double)));
weights_array[0] = 0.0489872;
weights_array[1] = 0.0413296;
weights_array[2] = 0.0212326;
weights_array[3] = 0.0256207;
weights_array[4] = 0.0360486;
weights_array[5] = 0.0144589;
weights_array[6] = 0.0344958;
weights_array[7] = 0.0085179;
}
break;
default:
feenox_push_error_message("unsupported N = %d in %dD", neutron_sn.N, feenox.pde.dim);
return FEENOX_ERROR;
break;
}
// from the weights array now assign one weight to each direction
feenox_call(feenox_problem_neutron_sn_init_triangles(weights_array));
feenox_free(weights_array);
// print the nice SN triangle
/*
int N_over_2 = neutron_sn.N/2;
for (int i = 0; i < N_over_2; i++) {
for (int j = 0; j < N_over_2-1-i; j++) {
printf(" ");
}
for (int j = 0; j < i+1; j++) {
printf("%d ", 1+neutron_sn.SN_triangle[i][j]);
}
printf("\n");
}
*/
// we have filled the first octant, now fill in the other ones
// this is for 2 and 3 dimensions only
int N_octs = (feenox.pde.dim == 2) ? 4 : 8;
int J_octs = neutron_sn.directions / N_octs;
for (int n = 1; n < N_octs; n++) {
for (int j = 0; j < J_octs; j++) {
neutron_sn.Omega[n*J_octs + j][0] = ((n & 1) ? (-1) : (+1)) * neutron_sn.Omega[j][0];
neutron_sn.Omega[n*J_octs + j][1] = ((n & 2) ? (-1) : (+1)) * neutron_sn.Omega[j][1];
neutron_sn.Omega[n*J_octs + j][2] = ((n & 4) ? (-1) : (+1)) * neutron_sn.Omega[j][2];
neutron_sn.w[n*J_octs + j] = neutron_sn.w[j];
}
}
}
// checks
double s = 0;
for (unsigned int m = 0; m < neutron_sn.directions; m++) {
s += neutron_sn.w[m];
}
if (fabs(s-1) > 1e-6) {
feenox_push_error_message("S%d weights do not sum up to one but to %g", neutron_sn.N, s);
return FEENOX_ERROR;
}
for (unsigned int d = 0; d < feenox.pde.dim; d++) {
s = 0;
for (unsigned int m = 0; m < neutron_sn.directions; m++) {
s += neutron_sn.w[m] * neutron_sn.Omega[m][d];
}
if (fabs(s) > 1e-6) {
feenox_push_error_message("S%d weights are not symmetric (zero != %g)", neutron_sn.N, s);
return FEENOX_ERROR;
}
s = 0;
for (unsigned int m = 0; m < neutron_sn.directions; m++) {
s += neutron_sn.w[m] * gsl_pow_2(neutron_sn.Omega[m][d]);
}
if (fabs(s-1.0/3.0) > 1e-6) {
feenox_push_error_message("S%d weights are not symmetric (one third != %g)", neutron_sn.N, s);
return FEENOX_ERROR;
}
}
// ---------------------------------------------------------------------------
#endif
return FEENOX_OK;
}
int feenox_problem_init_runtime_neutron_sn(void) {
#ifdef HAVE_PETSC
feenox.pde.mesh->data_type = data_type_node;
feenox.pde.spatial_unknowns = feenox.pde.mesh->n_nodes;
// initialize XSs
// TODO: allow not to give the group number in one-group problems
unsigned int G = neutron_sn.groups;
double fission_spectrum_integral = 0;
feenox_check_alloc(neutron_sn.Sigma_t = calloc(G, sizeof(distribution_t)));
feenox_check_alloc(neutron_sn.Sigma_a = calloc(G, sizeof(distribution_t)));
feenox_check_alloc(neutron_sn.nu_Sigma_f = calloc(G, sizeof(distribution_t)));
feenox_check_alloc(neutron_sn.S = calloc(G, sizeof(distribution_t)));
feenox_check_alloc(neutron_sn.Sigma_s0 = calloc(G, sizeof(distribution_t *)));
feenox_check_alloc(neutron_sn.Sigma_s1 = calloc(G, sizeof(distribution_t *)));
for (unsigned int g = 0; g < G; g++) {
char *name = NULL;
feenox_check_minusone(asprintf(&name, "Sigma_t%d", g+1));
feenox_distribution_init(&neutron_sn.Sigma_t[g], name);
if (neutron_sn.Sigma_t[g].defined) {
neutron_sn.Sigma_t[g].non_uniform = feenox_depends_on_space(neutron_sn.Sigma_t[g].dependency_variables);
}
feenox_free(name);
feenox_check_minusone(asprintf(&name, "Sigma_a%d", g+1));
feenox_distribution_init(&neutron_sn.Sigma_a[g], name);
if (neutron_sn.Sigma_a[g].defined) {
neutron_sn.Sigma_a[g].non_uniform = feenox_depends_on_space(neutron_sn.Sigma_a[g].dependency_variables);
}
feenox_free(name);
feenox_check_minusone(asprintf(&name, "nuSigma_f%d", g+1));
feenox_distribution_init(&neutron_sn.nu_Sigma_f[g], name);
if (neutron_sn.nu_Sigma_f[g].defined) {
neutron_sn.has_fission = 1;
neutron_sn.nu_Sigma_f[g].non_uniform = feenox_depends_on_space(neutron_sn.nu_Sigma_f[g].dependency_variables);
}
feenox_free(name);
feenox_check_minusone(asprintf(&name, "S%d", g+1));
feenox_distribution_init(&neutron_sn.S[g], name);
if (neutron_sn.S[g].defined) {
neutron_sn.has_sources = 1;
neutron_sn.S[g].non_uniform = feenox_depends_on_space(neutron_sn.S[g].dependency_variables);
}
feenox_free(name);
feenox_check_alloc(neutron_sn.Sigma_s0[g] = calloc(G, sizeof(distribution_t)));
feenox_check_alloc(neutron_sn.Sigma_s1[g] = calloc(G, sizeof(distribution_t)));
for (int g_prime = 0; g_prime < G; g_prime++) {
feenox_check_minusone(asprintf(&name, "Sigma_s%d.%d", g+1, g_prime+1));
feenox_distribution_init(&neutron_sn.Sigma_s0[g][g_prime], name);
if (neutron_sn.Sigma_s0[g][g_prime].defined) {
neutron_sn.Sigma_s0[g][g_prime].non_uniform = feenox_depends_on_space(neutron_sn.Sigma_s0[g][g_prime].dependency_variables);
}
feenox_free(name);
feenox_check_minusone(asprintf(&name, "Sigma_s_one%d.%d", g+1, g_prime+1));
feenox_distribution_init(&neutron_sn.Sigma_s1[g][g_prime], name);
if (neutron_sn.Sigma_s1[g][g_prime].defined) {
neutron_sn.Sigma_s1[g][g_prime].non_uniform = feenox_depends_on_space(neutron_sn.Sigma_s1[g][g_prime].dependency_variables);
}
feenox_free(name);
}
fission_spectrum_integral += feenox_vector_get(neutron_sn.chi, g);
}
if (neutron_sn.has_sources == 0 && neutron_sn.has_fission == 0) {
feenox_push_error_message("neither fission nor sources found");
return FEENOX_ERROR;
}
if (fabs(fission_spectrum_integral-1) > 1e-6) {
feenox_push_error_message("fission spectrum is not normalized, its integral is %g", fission_spectrum_integral);
return FEENOX_ERROR;
}
if (neutron_sn.has_sources == 0) {
#ifdef HAVE_SLEPC
feenox.pde.math_type = math_type_eigen;
feenox.pde.solve = feenox_problem_solve_slepc_eigen;
feenox.pde.has_mass = 1;
feenox.pde.has_rhs = 0;
// TODO: higher harmonics?
feenox.pde.nev = 1;
// define eigenvectors (we don't know its size yet)
feenox_check_alloc(feenox.pde.vectors.phi = calloc(feenox.pde.nev, sizeof(vector_t *)));
for (int g = 0; g < feenox.pde.nev; g++) {
char *modename = NULL;
feenox_check_minusone(asprintf(&modename, "eig%d", g+1));
feenox_check_alloc(feenox.pde.vectors.phi[g] = feenox_define_vector_get_ptr(modename, 0));
feenox_free(modename);
}
#else
feenox_push_error_message("criticality problems cannot be solved without SLEPc");
return FEENOX_ERROR;
#endif
} else {
// TODO: non-linear?
feenox.pde.math_type = math_type_linear;
feenox.pde.solve = feenox_problem_solve_petsc_linear;
feenox.pde.has_mass = 0;
feenox.pde.has_rhs = 1;
}
// allocate elemental XS matrices
unsigned int M = neutron_sn.directions;
unsigned int MG = M*G;
feenox_check_alloc(neutron_sn.R = gsl_matrix_calloc(MG, MG));
feenox_check_alloc(neutron_sn.X = gsl_matrix_calloc(MG, MG));
feenox_check_alloc(neutron_sn.s = gsl_vector_calloc(MG));
// direction matrix
feenox_check_alloc(neutron_sn.D = gsl_matrix_calloc(MG, MG * feenox.pde.dim));
for (unsigned int m = 0; m < M; m++) {
for (unsigned int g = 0; g < G; g++) {
for (unsigned int d = 0; d < feenox.pde.dim; d++) {
gsl_matrix_set(neutron_sn.D, sn_dof_index(m,g), d*MG + sn_dof_index(m,g), neutron_sn.Omega[m][d]);
}
}
}
feenox.pde.has_stiffness = 1;
feenox.pde.has_jacobian_K = 0;
feenox.pde.has_jacobian_M = 0;
feenox.pde.has_jacobian_b = 0;
feenox.pde.has_jacobian = feenox.pde.has_jacobian_K || feenox.pde.has_jacobian_M || feenox.pde.has_jacobian_b;
feenox.pde.symmetric_K = 0;
feenox.pde.symmetric_M = 0;
#endif
return FEENOX_OK;
}
#ifdef HAVE_PETSC
int feenox_problem_setup_pc_neutron_sn(PC pc) {
PCType pc_type = NULL;
petsc_call(PCGetType(pc, &pc_type));
if (pc_type == NULL) {
// if we don't set the pc type here then we PCFactorSetMatSolverType does not work
petsc_call(PCSetType(pc, feenox.pde.symmetric_K ? PCCHOLESKY : PCLU));
#ifdef PETSC_HAVE_MUMPS
petsc_call(PCFactorSetMatSolverType(pc, MATSOLVERMUMPS));
#else
// defaults so in serial it should be petsc's lu and in parallel ilu (I think)
// petsc_call(PCSetType(pc, PCLU));
#endif
}
return FEENOX_OK;
}
int feenox_problem_setup_ksp_neutron_sn(KSP ksp ) {
KSPType ksp_type = NULL;
petsc_call(KSPGetType(ksp, &ksp_type));
if (ksp_type == NULL) {
petsc_call(KSPSetType(ksp, KSPPREONLY))
}
return FEENOX_OK;
}
#endif
#ifdef HAVE_SLEPC
int feenox_problem_setup_eps_neutron_sn(EPS eps) {
// generalized non-hermitian problem
petsc_call(EPSSetProblemType(eps, EPS_GNHEP));
// we expect the eigenvalue to be near one and an absolute test is faster
petsc_call(EPSSetConvergenceTest(feenox.pde.eps, EPS_CONV_ABS));
// offsets around one
if (feenox_var_value(feenox.pde.vars.eps_st_sigma) == 0)
{
feenox_var_value(feenox.pde.vars.eps_st_sigma) = 1.0;
}
if (feenox_var_value(feenox.pde.vars.eps_st_nu) == 0)
{
feenox_var_value(feenox.pde.vars.eps_st_nu) = 1.0;
}
return FEENOX_OK;
}
#endif
int feenox_problem_neutron_sn_init_cosines(double mu1) {
int N_over_2 = neutron_sn.N/2;
double *mu = NULL;
feenox_check_alloc(mu = calloc(N_over_2, sizeof(double)));
// equation 21 in stammler
// equation 4-8 in lewis
mu[0] = mu1;
double C = 2*(1-3*gsl_pow_2(mu1))/(neutron_sn.N-2);
for (int i = 1; i < N_over_2; i++) {
mu[i] = sqrt(gsl_pow_2(mu1) + C*i);
}
// now we have to assign the cosines to each of the m directions
int m = 0;
for (int row = 0; row < N_over_2; row++) {
for (int col = 0; col <= row; col++) {
int i = N_over_2 - row - 1;
int j = col;
int k = N_over_2 + 2 - 3 - i - j;
neutron_sn.Omega[m][0] = mu[i];
neutron_sn.Omega[m][1] = mu[j];
neutron_sn.Omega[m][2] = (feenox.pde.dim == 3) ? mu[k] : 0;
m++;
}
}
feenox_free(mu);
return FEENOX_OK;
}
int feenox_problem_neutron_sn_init_triangles(double *weights_array) {
int N_over_2 = neutron_sn.N/2;
// allocate stuff
int ***tmp = NULL;
feenox_check_alloc(tmp = calloc(6, sizeof(int **)));
for (int p = 0; p < 6; p++) {
feenox_check_alloc(tmp[p] = calloc(N_over_2, sizeof(int *)));
for (int j = 0; j < N_over_2; j++) {
feenox_check_alloc(tmp[p][j] = calloc(N_over_2, sizeof(int)));
}
}
feenox_check_alloc(neutron_sn.SN_triangle = calloc(N_over_2, sizeof(int *)));
for (int j = 0; j < N_over_2; j++) {
feenox_check_alloc(neutron_sn.SN_triangle[j] = calloc(N_over_2, sizeof(int *)));
}
int *weight_map = NULL;
feenox_check_alloc(weight_map = calloc(neutron_sn.N*(neutron_sn.N+1)/2, sizeof(int)));
// fill in the 6 temporary triangles
int m = 1;
for (int i = N_over_2-1; i >= 0; i--) {
for (int j = 0; j < i+1; j++) {
tmp[0][i][j] = m;
m++;
}
}
for (int i = 0; i < N_over_2; i++) {
for (int j = 0; j < i+1; j++) {
tmp[1][i][i-j] = tmp[0][i][j];
}
}
for (int i = 0; i < N_over_2; i++) {
for (int j = 0; j < i+1; j++) {
tmp[2][i][j] = tmp[1][N_over_2-i-1 + j][j];
}
}
for (int i = 0; i < N_over_2; i++) {
for (int j = 0; j < i+1; j++) {
tmp[3][i][j] = tmp[0][N_over_2-j-1][N_over_2-i-1];
}
}
for (int i = 0; i < N_over_2; i++) {
for (int j = 0; j < i+1; j++) {
tmp[4][i][j] = tmp[3][N_over_2-i-1 + j][j];
}
}
for (int i = 0; i < N_over_2; i++) {
for (int j = 0; j < i+1; j++) {
tmp[5][i][j] = tmp[0][N_over_2-i-1 + j][j];
}
}
// compute the min and create a map
for (int i = 0; i < N_over_2; i++) {
for (int j = 0; j < i+1; j++) {
int min = neutron_sn.N;
for (int p = 0; p < 6; p++) {
if (tmp[p][i][j] < min) {
min = tmp[p][i][j];
}
}
neutron_sn.SN_triangle[i][j] = min;
weight_map[min] = 1;
}
}
// assign the weight and create the SN triangle
double N_octs = (feenox.pde.dim == 2) ? 4 : 8;
m = 0;
for (int i = 0; i < N_over_2; i++) {
for (int j = 0; j < i+1; j++) {
int w = 0;
for (int k = 0; k < neutron_sn.SN_triangle[i][j]; k++) {
w += weight_map[k] != 0;
}
neutron_sn.w[m] = weights_array[w]/N_octs;
neutron_sn.SN_triangle[i][j] = w;
m++;
}
}
for (int p = 0; p < 6; p++) {
for (int i = 0; i < N_over_2; i++) {
feenox_free(tmp[p][i]);
}
feenox_free(tmp[p]);
}
feenox_free(tmp);
feenox_free(weight_map);
return FEENOX_OK;
}
feenox-1.2/src/pdes/neutron_sn/methods.h 0000664 0001750 0001750 00000004704 15055303016 014056 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for neutron transport FEM: virtual methods
*
* Copyright (C) 2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#ifndef NEUTRON_SN_METHODS_H
#define NEUTRON_SN_METHODS_H
// neutron_sn/parser.c
extern int feenox_problem_parse_problem_neutron_sn(const char *);
extern int feenox_problem_parse_write_post_neutron_sn(mesh_write_t *mesh_write, const char *token);
// neutron_sn/init.c
extern int feenox_problem_neutron_sn_init_cosines(double mu1);
extern int feenox_problem_neutron_sn_init_triangles(double *weights);
extern int feenox_problem_parse_time_init_neutron_sn(void);
extern int feenox_problem_init_runtime_neutron_sn(void);
#ifdef HAVE_PETSC
extern int feenox_problem_setup_pc_neutron_sn(PC pc);
extern int feenox_problem_setup_ksp_neutron_sn(KSP ksp);
#endif
#ifdef HAVE_SLEPC
extern int feenox_problem_setup_eps_neutron_sn(EPS eps);
#endif
// neutron_sn/bulk.c
extern int feenox_problem_build_allocate_aux_neutron_sn(unsigned int n_nodes);
extern int feenox_problem_neutron_sn_eval_XS(material_t *material, double *x);
extern int feenox_problem_build_volumetric_neutron_sn(element_t *e);
extern int feenox_problem_build_volumetric_gauss_point_neutron_sn(element_t *element, unsigned int q);
// neutron_sn/bc.c
extern int feenox_problem_bc_parse_neutron_sn(bc_data_t *bc_data, const char *lhs, char *rhs);
extern int feenox_problem_bc_set_neutron_sn_vacuum(bc_data_t *bc_data, element_t *e, size_t j_global);
extern int feenox_problem_bc_set_neutron_sn_mirror(bc_data_t *bc_data, element_t *e, size_t j_global);
// neutron_sn/post.c
extern int feenox_problem_solve_post_neutron_sn(void);
#endif // NEUTRON_SN_METHODS_H
feenox-1.2/src/pdes/neutron_sn/neutron_sn.h 0000664 0001750 0001750 00000005077 15055303016 014611 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for neutron transport FEM: global header
*
* Copyright (C) 2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#ifndef NEUTRON_SN_H
#define NEUTRON_SN_H
#define sn_dof_index(m,g) ((g)*neutron_sn.directions + (m))
typedef struct neutron_sn_t neutron_sn_t;
struct neutron_sn_t {
unsigned int N;
unsigned int directions;
unsigned int groups;
// directions and weights
double **Omega;
int **SN_triangle;
double *w;
// total XS
distribution_t *Sigma_t;
// absorption XS
distribution_t *Sigma_a;
// scattering XS
distribution_t **Sigma_s0;
distribution_t **Sigma_s1;
// product of nu and fission XS
distribution_t *nu_Sigma_f;
// product of energy per fission and fission XS
// distribution_t *e_Sigma_f;
// independent neutron source
distribution_t *S;
// removal XSs: groups x groups
gsl_matrix *R;
// fission XSs: groups x groups
gsl_matrix *X;
// independent sources: groups
gsl_vector *s;
// elemental matrices
unsigned int n_nodes;
// Petrov-stabilized H_Gc
gsl_matrix *P;
// Direction matrix
gsl_matrix *D;
// intermediate
gsl_matrix *DB;
gsl_matrix *AH;
gsl_matrix *XH;
// elemental matrices (size J*M*G x J*M*G)
gsl_matrix *Li; // leakage
gsl_matrix *Ai; // absorption
gsl_matrix *Fi; // fission
gsl_vector *Si; // sources (vector)
int has_sources;
int has_fission;
int space_XS;
// fission spectrum
vector_t *chi;
// supg stabilization factor
var_t *sn_alpha;
// --- results ----------------------
// effective multiplication factor
var_t *keff;
// scalar fluxes (array of G functions)
function_t **phi;
};
extern neutron_sn_t neutron_sn;
#endif /* NEUTRON_SN_H */
feenox-1.2/src/pdes/neutron_sn/parser.c 0000664 0001750 0001750 00000006055 15055303016 013703 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for neutron transport FEM: input parsing
*
* Copyright (C) 2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "neutron_sn.h"
#include "../../parser/parser.h"
int feenox_problem_parse_problem_neutron_sn(const char *token) {
if (token != NULL) {
if (strcasecmp(token, "GROUPS") == 0) {
double xi = 0;
feenox_call(feenox_parser_expression_in_string(&xi));
neutron_sn.groups = (unsigned int)(xi);
} else if (strcasecmp(token, "SN") == 0 || strcasecmp(token, "N") == 0) {
double xi = 0;
feenox_call(feenox_parser_expression_in_string(&xi));
neutron_sn.N = (unsigned int)(xi);
if (neutron_sn.N % 2 == 1) {
feenox_push_error_message("The N in SN should be even and %d is not (as far as I know)", neutron_sn.N);
return FEENOX_ERROR;
}
} else {
feenox_push_error_message("undefined keyword '%s'", token);
return FEENOX_ERROR;
}
} else {
// if token is NULL we have to do the parse-time initialization
feenox_call(feenox_problem_parse_time_init_neutron_sn());
}
return FEENOX_OK;
}
int feenox_problem_parse_write_post_neutron_sn(mesh_write_t *mesh_write, const char *token) {
if (strcmp(token, "all") == 0) {
feenox_call(feenox_problem_parse_write_post_neutron_sn(mesh_write, "scalar_fluxes"));
feenox_call(feenox_problem_parse_write_post_neutron_sn(mesh_write, "angular_fluxes"));
} else if (strcmp(token, "scalar_flux") == 0 || strcmp(token, "scalar_fluxes") == 0) {
for (unsigned int g = 0; g < neutron_sn.groups; g++) {
feenox_call(feenox_add_post_field(mesh_write, 1, &neutron_sn.phi[g]->name, NULL, field_location_nodes));
}
} else if (strcmp(token, "angular_flux") == 0 || strcmp(token, "angular_fluxes") == 0) {
for (unsigned int g = 0; g < neutron_sn.groups; g++) {
for (unsigned int m = 0; m < neutron_sn.directions; m++) {
feenox_call(feenox_add_post_field(mesh_write, 1, &feenox.pde.unknown_name[sn_dof_index(m,g)], NULL, field_location_nodes));
}
}
} else {
feenox_push_error_message("undefined keyword '%s' for neutron_sn WRITE_RESULTS", token);
return FEENOX_ERROR;
}
return FEENOX_OK;
}
feenox-1.2/src/pdes/neutron_sn/post.c 0000664 0001750 0001750 00000006763 15055303016 013402
/*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for neutron transport FEM: post
*
* Copyright (C) 2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "neutron_sn.h"
int feenox_problem_solve_post_neutron_sn(void) {
#ifdef HAVE_PETSC
if (neutron_sn.has_sources == 0) {
#ifdef HAVE_SLEPC
if (feenox.pde.eigen_formulation == eigen_formulation_omega) {
feenox_var_value(neutron_sn.keff) = 1.0/feenox.pde.eigenvalue[0];
} else {
feenox_var_value(neutron_sn.keff) = feenox.pde.eigenvalue[0];
}
// TODO: this is wrong
// normalization without power
double num = 0;
double den = 0;
int integration = feenox.pde.mesh->integration;
for (size_t i = 0; i < feenox.pde.mesh->n_elements; i++) {
element_t *element = &feenox.pde.mesh->element[i];
if (element->type != NULL && element->type->dim == feenox.pde.dim) {
num += element->type->volume(element);
// for now I'd rather perform the computation myself instead of
// calling feenox_mesh_integral_over_element() because that wastes a lot of fem calls
for (unsigned int q = 0; q < element->type->gauss[integration].Q; q++) {
double wdet = feenox_fem_compute_w_det_at_gauss_integration(element, q, integration);
for (unsigned int j = 0; j < element->type->nodes; j++) {
double h = gsl_matrix_get(element->type->gauss[integration].H_c[q], 0, j);
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
den += wdet * h * feenox_vector_get(feenox.pde.solution[g]->vector_value, element->node[j]->index_mesh);
}
}
}
}
}
double factor = num/den;
// normalize the fluxes
for (size_t j = 0; j < feenox.pde.mesh->n_nodes; j++) {
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
double xi = feenox_vector_get(feenox.pde.solution[g]->vector_value, j);
feenox_vector_set(feenox.pde.solution[g]->vector_value, j, factor*xi);
}
}
#endif
}
// compute the scalar fluxes out of the directional fluxes
for (unsigned int g = 0; g < neutron_sn.groups; g++) {
feenox_problem_fill_aux_solution(neutron_sn.phi[g]);
}
for (size_t j = 0; j < feenox.pde.mesh->n_nodes; j++) {
for (unsigned int g = 0; g < neutron_sn.groups; g++) {
double xi = 0;
for (unsigned int m = 0; m < neutron_sn.directions; m++) {
xi += neutron_sn.w[m] * feenox_vector_get(feenox.pde.solution[sn_dof_index(m,g)]->vector_value, j);
}
// TODO: wrapper, the pde has to set the function value not the vector
feenox_vector_set(neutron_sn.phi[g]->vector_value, j, xi);
}
}
#endif
return FEENOX_OK;
}
feenox-1.2/src/pdes/neutron_diffusion/ 0000775 0001750 0001750 00000000000 15055303133 013663 5 feenox-1.2/src/pdes/neutron_diffusion/bc.c 0000664 0001750 0001750 00000013244 15055303016 014337 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for neutron diffusion FEM: boundary conditions
*
* Copyright (C) 2021--2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "neutron_diffusion.h"
#include "pdes/neutron_sn/neutron_sn.h"
int feenox_problem_bc_parse_neutron_diffusion(bc_data_t *bc_data, const char *lhs, char *rhs) {
if (strcmp(lhs, "null") == 0) {
bc_data->type_math = bc_type_math_dirichlet;
bc_data->dof = -1;
bc_data->set_essential = feenox_problem_bc_set_neutron_diffusion_null;
} else if (strcmp(lhs, "symmetry") == 0 || strcmp(lhs, "mirror") == 0) {
bc_data->type_math = bc_type_math_neumann;
bc_data->dof = -1;
} else if (strcmp(lhs, "vacuum") == 0) {
bc_data->type_math = bc_type_math_robin;
bc_data->set_natural = feenox_problem_bc_set_neutron_diffusion_vacuum;
bc_data->fills_matrix = 1;
bc_data->dof = -1;
} else if (strncmp(lhs, "phi", 3) == 0) {
bc_data->type_math = bc_type_math_dirichlet;
int dof = 0;
if (sscanf(lhs+3, "%d", &dof) != 1) {
feenox_push_error_message("could not read group number in neutron_diffusion boundary condition '%s'", lhs);
return FEENOX_ERROR;
}
if (dof < 0 || dof > neutron_diffusion.groups) {
feenox_push_error_message("invalid group number in neutron_diffusion boundary condition '%s'", lhs);
return FEENOX_ERROR;
}
bc_data->dof = dof-1;
bc_data->set_essential = feenox_problem_bc_set_neutron_diffusion_flux;
} else if (strncmp(lhs, "J", 1) == 0) {
bc_data->type_math = bc_type_math_neumann;
int dof = 0;
if (sscanf(lhs+1, "%d", &dof) != 1) {
feenox_push_error_message("could not read group number in neutron_diffusion boundary condition '%s'", lhs);
return FEENOX_ERROR;
}
if (dof < 0 || dof > neutron_diffusion.groups) {
feenox_push_error_message("invalid group number in neutron_diffusion boundary condition '%s'", lhs);
return FEENOX_ERROR;
}
bc_data->dof = dof-1;
bc_data->set_natural = feenox_problem_bc_set_neutron_diffusion_current;
neutron_diffusion.has_sources = 1;
} else {
feenox_push_error_message("unknown neutron_diffusion boundary condition '%s'", lhs);
return FEENOX_ERROR;
}
feenox_call(feenox_expression_parse(&bc_data->expr, rhs));
// TODO: initial guesses
// if (bc_data->type_phys == BC_TYPE_THERMAL_TEMPERATURE || bc_data->type_phys == BC_TYPE_THERMAL_CONVECTION_TEMPERATURE ) {
// thermal.guessed_initial_guess += feenox_expression_eval(&bc_data->expr);
// thermal.n_bc_temperatures++;
// }
bc_data->space_dependent = feenox_depends_on_space(bc_data->expr.variables);
bc_data->nonlinear = feenox_depends_on_function(bc_data->expr.functions, feenox.pde.solution[0]);
if (bc_data->nonlinear && bc_data->type_math == bc_type_math_dirichlet) {
feenox_push_error_message("essential boundary condition '%s' cannot depend on flux", rhs);
return FEENOX_ERROR;
}
// TODO: check consistency, non-linearities, etc.
return FEENOX_OK;
}
// this virtual method fills in the dirichlet indexes and values with bc_data
int feenox_problem_bc_set_neutron_diffusion_null(bc_data_t *this, element_t *e, size_t j_global) {
#ifdef HAVE_PETSC
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
feenox_call(feenox_problem_dirichlet_add(j_global, g, 0));
}
#endif
return FEENOX_OK;
}
// this virtual method fills in the dirichlet indexes and values with bc_data
int feenox_problem_bc_set_neutron_diffusion_flux(bc_data_t *this, element_t *e, size_t j_global) {
#ifdef HAVE_PETSC
feenox_call(feenox_problem_dirichlet_add(j_global, this->dof, feenox_expression_eval(&this->expr)));
#endif
return FEENOX_OK;
}
// this virtual method builds the surface elemental matrix
int feenox_problem_bc_set_neutron_diffusion_vacuum(bc_data_t *this, element_t *e, unsigned int q) {
#ifdef HAVE_PETSC
feenox_fem_compute_x_at_gauss_if_needed_and_update_var(e, q, feenox.pde.mesh->integration, this->space_dependent);
double coeff = (this->expr.items != NULL) ? feenox_expression_eval(&this->expr) : 0.5;
// TODO: convenience call like feenox_problem_rhs_set()?
double wdet = feenox_fem_compute_w_det_at_gauss_integration(e, q, feenox.pde.mesh->integration);
gsl_matrix *H = feenox_fem_compute_H_Gc_at_gauss(e, q, feenox.pde.mesh->integration);
feenox_call(feenox_blas_BtB_accum(H, wdet*coeff, feenox.fem.Ki));
#endif
return FEENOX_OK;
}
int feenox_problem_bc_set_neutron_diffusion_current(bc_data_t *this, element_t *e, unsigned int q) {
#ifdef HAVE_PETSC
feenox_fem_compute_x_at_gauss_if_needed_and_update_var(e, q, feenox.pde.mesh->integration, this->space_dependent);
double *current = calloc(neutron_sn.groups, sizeof(double));
current[this->dof] = feenox_expression_eval(&this->expr);
feenox_call(feenox_problem_rhs_add(e, q, current));
feenox_free(current);
#endif
return FEENOX_OK;
}
feenox-1.2/src/pdes/neutron_diffusion/bulk.c 0000664 0001750 0001750 00000014521 15055303016 014707 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for neutron diffusion FEM: bulk elements
*
* Copyright (C) 2021--2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "neutron_diffusion.h"
int feenox_problem_build_allocate_aux_neutron_diffusion(unsigned int J) {
neutron_diffusion.n_nodes = J;
int G = neutron_diffusion.groups;
int D = feenox.pde.dim;
int GJ = G*J;
if (neutron_diffusion.Li != NULL) {
gsl_matrix_free(neutron_diffusion.Li);
gsl_matrix_free(neutron_diffusion.Ai);
gsl_matrix_free(neutron_diffusion.DB);
gsl_matrix_free(neutron_diffusion.RH);
if (neutron_diffusion.has_fission) {
gsl_matrix_free(neutron_diffusion.Fi);
gsl_matrix_free(neutron_diffusion.XH);
}
}
feenox_check_alloc(neutron_diffusion.Li = gsl_matrix_calloc(GJ, GJ));
feenox_check_alloc(neutron_diffusion.Ai = gsl_matrix_calloc(GJ, GJ));
feenox_check_alloc(neutron_diffusion.DB = gsl_matrix_calloc(G*D, G*J));
feenox_check_alloc(neutron_diffusion.RH = gsl_matrix_calloc(G, GJ));
if (neutron_diffusion.has_fission) {
feenox_check_alloc(neutron_diffusion.Fi = gsl_matrix_calloc(GJ, GJ));
feenox_check_alloc(neutron_diffusion.XH = gsl_matrix_calloc(G, GJ));
}
return FEENOX_OK;
}
int feenox_problem_build_volumetric_neutron_diffusion(element_t *e) {
if (neutron_diffusion.space_XS == 0) {
feenox_call(feenox_problem_neutron_diffusion_eval_XS(feenox_fem_get_material(e), NULL));
}
return FEENOX_OK;
}
int feenox_problem_neutron_diffusion_eval_XS(material_t *material, double *x) {
gsl_matrix_set_zero(neutron_diffusion.D_G);
gsl_matrix_set_zero(neutron_diffusion.R);
if (neutron_diffusion.has_fission) {
gsl_matrix_set_zero(neutron_diffusion.X);
}
for (int g = 0; g < neutron_diffusion.groups; g++) {
// independent sources
if (neutron_diffusion.has_sources) {
// TODO: macro to make it nicer
gsl_vector_set(neutron_diffusion.s, g, neutron_diffusion.S[g].eval(&neutron_diffusion.S[g], x, material));
}
// scattering and fission
for (int g_prime = 0; g_prime < neutron_diffusion.groups; g_prime++) {
gsl_matrix_set(neutron_diffusion.R, g, g_prime, -neutron_diffusion.Sigma_s[g_prime][g].eval(&neutron_diffusion.Sigma_s[g_prime][g], x, material));
if (neutron_diffusion.has_fission) {
gsl_matrix_set(neutron_diffusion.X, g, g_prime, feenox_vector_get(neutron_diffusion.chi, g)*neutron_diffusion.nu_Sigma_f[g_prime].eval(&neutron_diffusion.nu_Sigma_f[g_prime], x, material));
}
}
// absorption
double val = gsl_matrix_get(neutron_diffusion.R, g, g);
if (neutron_diffusion.Sigma_t[g].defined) {
val += neutron_diffusion.Sigma_t[g].eval(&neutron_diffusion.Sigma_t[g], x, material);
} else {
val += neutron_diffusion.Sigma_a[g].eval(&neutron_diffusion.Sigma_a[g], x, material);
for (int g_prime = 0; g_prime < neutron_diffusion.groups; g_prime++) {
val += neutron_diffusion.Sigma_s[g][g_prime].eval(&neutron_diffusion.Sigma_s[g][g_prime], x, material);
}
}
gsl_matrix_set(neutron_diffusion.R, g, g, val);
// leaks
for (int m = 0; m < feenox.pde.dim; m++) {
if (neutron_diffusion.D[g].defined) {
val = neutron_diffusion.D[g].eval(&neutron_diffusion.D[g], x, material);
} else if (neutron_diffusion.Sigma_t[g].defined) {
val = 1.0/(3.0*neutron_diffusion.Sigma_t[g].eval(&neutron_diffusion.Sigma_t[g], x, material));
} else {
feenox_push_error_message("neither D nor Sigma_t given for group %d", g);
return FEENOX_ERROR;
}
unsigned int index = m*neutron_diffusion.groups + g;
gsl_matrix_set(neutron_diffusion.D_G, index, index, val);
}
}
return FEENOX_OK;
}
int feenox_problem_build_volumetric_gauss_point_neutron_diffusion(element_t *e, unsigned int q) {
#ifdef HAVE_PETSC
if (neutron_diffusion.space_XS != 0) {
double *x = feenox_fem_compute_x_at_gauss(e, q, feenox.pde.mesh->integration);
feenox_call(feenox_problem_neutron_diffusion_eval_XS(feenox_fem_get_material(e), x));
}
// elemental stiffness for the diffusion term B'*D*B
double wdet = feenox_fem_compute_w_det_at_gauss_integration(e, q, feenox.pde.mesh->integration);
gsl_matrix *B = feenox_fem_compute_B_G_at_gauss(e, q, feenox.pde.mesh->integration);
feenox_call(feenox_blas_BtCB(B, neutron_diffusion.D_G, neutron_diffusion.DB, wdet, neutron_diffusion.Li));
// elemental scattering H'*A*H
gsl_matrix *H = feenox_fem_compute_H_Gc_at_gauss(e, q, feenox.pde.mesh->integration);
feenox_call(feenox_blas_BtCB(H, neutron_diffusion.R, neutron_diffusion.RH, wdet, neutron_diffusion.Ai));
// elemental fission matrix
if (neutron_diffusion.has_fission) {
feenox_call(feenox_blas_BtCB(H, neutron_diffusion.X, neutron_diffusion.XH, wdet, neutron_diffusion.Fi));
}
if (neutron_diffusion.has_sources) {
feenox_call(feenox_blas_Atb_accum(H, neutron_diffusion.s, wdet, feenox.fem.bi));
}
// for source-driven problems
// Ki = Li + Ai - Xi
// for criticallity problems
// Ki = Li + Ai
// Mi = Xi
feenox_call(gsl_matrix_add(neutron_diffusion.Li, neutron_diffusion.Ai));
if (neutron_diffusion.has_fission) {
if (neutron_diffusion.has_sources) {
feenox_call(gsl_matrix_scale(neutron_diffusion.Fi, -1.0));
feenox_call(gsl_matrix_add(neutron_diffusion.Li, neutron_diffusion.Fi));
} else {
feenox_call(gsl_matrix_add(feenox.fem.Mi, neutron_diffusion.Fi));
}
}
feenox_call(gsl_matrix_add(feenox.fem.Ki, neutron_diffusion.Li));
#endif
return FEENOX_OK;
}
feenox-1.2/src/pdes/neutron_diffusion/currents.c 0000664 0001750 0001750 00000006241 15055303016 015617 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for neutron diffusion FEM: computation of neutron currents
*
* Copyright (C) 2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "neutron_diffusion.h"
int feenox_problem_gradient_fill_neutron_diffusion(void) {
for (unsigned int g = 0; g < neutron_diffusion.groups; g++) {
feenox_call(feenox_problem_fill_aux_solution(neutron_diffusion.Jx[g]));
if (feenox.pde.dim > 1) {
feenox_call(feenox_problem_fill_aux_solution(neutron_diffusion.Jy[g]));
if (feenox.pde.dim > 2) {
feenox_call(feenox_problem_fill_aux_solution(neutron_diffusion.Jz[g]));
}
}
}
return FEENOX_OK;
}
// used only in rough
int feenox_problem_gradient_properties_at_element_nodes_neutron_diffusion(element_t *element, mesh_t *mesh) {
return FEENOX_OK;
}
int feenox_problem_gradient_fluxes_at_node_alloc_neutron_diffusion(node_t *node) {
unsigned int DG = feenox.pde.dim*neutron_diffusion.groups;
if (node->flux == NULL) {
feenox_check_alloc(node->flux = calloc(DG, sizeof(double)));
} else {
for (unsigned i = 0; i < DG; i++) {
node->flux[i] = 0;
}
}
return FEENOX_OK;
}
int feenox_problem_gradient_add_elemental_contribution_to_node_neutron_diffusion(node_t *node, element_t *element, unsigned int j, double rel_weight) {
double current = 0;
double D = 0;
for (unsigned int g = 0; g < neutron_diffusion.groups; g++) {
D = neutron_diffusion.D[g].eval(&neutron_diffusion.D[g], node->x, element->physical_group->material);
for (unsigned int d = 0; d < feenox.pde.dim; d++) {
current = -D * gsl_matrix_get(element->dphidx_node[j], 0, d);
node->flux[g*feenox.pde.dim + d] += rel_weight * (current - node->flux[g*feenox.pde.dim + d]);
}
}
return FEENOX_OK;
}
int feenox_problem_gradient_fill_fluxes_neutron_diffusion(mesh_t *mesh, size_t j) {
for (unsigned int g = 0; g < neutron_diffusion.groups; g++) {
feenox_vector_set(neutron_diffusion.Jx[g]->vector_value, j, mesh->node[j].flux[g*feenox.pde.dim + 0]);
if (feenox.pde.dim > 1) {
feenox_vector_set(neutron_diffusion.Jy[g]->vector_value, j, mesh->node[j].flux[g*feenox.pde.dim + 1]);
if (feenox.pde.dim > 2) {
feenox_vector_set(neutron_diffusion.Jz[g]->vector_value, j, mesh->node[j].flux[g*feenox.pde.dim + 2]);
}
}
}
return FEENOX_OK;
}
feenox-1.2/src/pdes/neutron_diffusion/init.c 0000664 0001750 0001750 00000034237 15055303016 014723 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for neutron diffusion FEM: initialization
*
* Copyright (C) 2021--2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "neutron_diffusion.h"
neutron_diffusion_t neutron_diffusion;
int feenox_problem_parse_time_init_neutron_diffusion(void) {
///kw_pde+PROBLEM+detail * `neutron_diffusion` multi-group core-level neutron diffusion with a FEM formulation
#ifdef HAVE_PETSC
// virtual methods
feenox.pde.parse_bc = feenox_problem_bc_parse_neutron_diffusion;
feenox.pde.parse_write_results = feenox_problem_parse_write_post_neutron_diffusion;
feenox.pde.init_before_run = feenox_problem_init_runtime_neutron_diffusion;
#ifdef HAVE_SLEPC
feenox.pde.setup_eps = feenox_problem_setup_eps_neutron_diffusion;
#endif
feenox.pde.setup_ksp = feenox_problem_setup_ksp_neutron_diffusion;
feenox.pde.setup_pc = feenox_problem_setup_pc_neutron_diffusion;
feenox.pde.element_build_allocate_aux = feenox_problem_build_allocate_aux_neutron_diffusion;
feenox.pde.element_build_volumetric = feenox_problem_build_volumetric_neutron_diffusion;
feenox.pde.element_build_volumetric_at_gauss = feenox_problem_build_volumetric_gauss_point_neutron_diffusion;
feenox.pde.solve_post = feenox_problem_solve_post_neutron_diffusion;
feenox.pde.gradient_fill = feenox_problem_gradient_fill_neutron_diffusion;
feenox.pde.gradient_nodal_properties = feenox_problem_gradient_properties_at_element_nodes_neutron_diffusion;
feenox.pde.gradient_alloc_nodal_fluxes = feenox_problem_gradient_fluxes_at_node_alloc_neutron_diffusion;
feenox.pde.gradient_add_elemental_contribution_to_node = feenox_problem_gradient_add_elemental_contribution_to_node_neutron_diffusion;
feenox.pde.gradient_fill_fluxes = feenox_problem_gradient_fill_fluxes_neutron_diffusion;
// we are FEM
feenox.mesh.default_field_location = field_location_nodes;
// default is 1 group
if (neutron_diffusion.groups == 0) {
neutron_diffusion.groups = 1;
}
// dofs = number of groups
feenox.pde.dofs = neutron_diffusion.groups;
// scalar fluxes and currents
feenox_check_alloc(feenox.pde.unknown_name = calloc(neutron_diffusion.groups, sizeof(char *)));
for (unsigned int g = 0; g < neutron_diffusion.groups; g++) {
///re_neutron_diffusion+phi+description The scalar flux for the group $g$ is `phig`, i.e. `phi1`, `phi2`, etc. This is the primary unknown of the problem.
feenox_check_minusone(asprintf(&feenox.pde.unknown_name[g], "phi%u", g+1));
}
// currents (we need a different loop from the one used for fluxes)
feenox_check_alloc(neutron_diffusion.Jx = calloc(neutron_diffusion.groups, sizeof(function_t *)));
if (feenox.pde.dim > 1) {
feenox_check_alloc(neutron_diffusion.Jy = calloc(neutron_diffusion.groups, sizeof(function_t *)));
if (feenox.pde.dim > 2) {
feenox_check_alloc(neutron_diffusion.Jz = calloc(neutron_diffusion.groups, sizeof(function_t *)));
}
}
///re_neutron_diffusion+Jx+description The\ $x$ component of the neutron current for group\ $g$ is `Jxg`, i.e. `Jx1`, `Jx2`. etc. This is a secondary unknown of the problem.
///re_neutron_diffusion+Jx+description The\ $y$ component of the neutron current for group\ $g$ is `Jzg`, i.e. `Jz1`, `Jz2`. etc. This is a secondary unknown of the problem.
///re_neutron_diffusion+Jy+description Only available for two and three-dimensional problems.
///re_neutron_diffusion+Jx+description The\ $z$ component of the neutron current for group\ $g$ is `Jzg`, i.e. `Jz1`, `Jz2`. etc. This is a secondary unknown of the problem.
///re_neutron_diffusion+Jz+description Only available for three-dimensional problems.
for (unsigned int g = 0; g < neutron_diffusion.groups; g++) {
char *name = NULL;
feenox_check_minusone(asprintf(&name, "Jx%u", g+1));
feenox_call(feenox_problem_define_solution_function(name, &neutron_diffusion.Jx[g], FEENOX_SOLUTION_GRADIENT));
feenox_free(name);
if (feenox.pde.dim > 1) {
feenox_check_minusone(asprintf(&name, "Jy%u", g+1));
feenox_call(feenox_problem_define_solution_function(name, &neutron_diffusion.Jy[g], FEENOX_SOLUTION_GRADIENT));
feenox_free(name);
if (feenox.pde.dim > 2) {
feenox_check_minusone(asprintf(&name, "Jz%u", g+1));
feenox_call(feenox_problem_define_solution_function(name, &neutron_diffusion.Jz[g], FEENOX_SOLUTION_GRADIENT));
feenox_free(name);
}
}
}
// TODO: for one group make an alias between phi1 and phi
///va_neutron_diffusion+chi+desc A vector of size groups with the fission spectrum.
///va_neutron_diffusion+chi+desc Default is one in the first group and zero in the rest.
neutron_diffusion.chi = feenox_define_vector_get_ptr("chi", neutron_diffusion.groups);
feenox_vector_set(neutron_diffusion.chi, 0, 1.0);
///va_neutron_diffusion+keff+desc The effective multiplication factor\ $k_\text{eff}$.
neutron_diffusion.keff = feenox_define_variable_get_ptr("keff");
#endif
return FEENOX_OK;
}
int feenox_problem_init_runtime_neutron_diffusion(void) {
#ifdef HAVE_PETSC
// we are FEM
feenox.mesh.default_field_location = field_location_nodes;
feenox.pde.mesh->data_type = data_type_node;
feenox.pde.spatial_unknowns = feenox.pde.mesh->n_nodes;
// initialize XSs
int G = neutron_diffusion.groups;
double fission_spectrum_integral = 0;
feenox_check_alloc(neutron_diffusion.D = calloc(G, sizeof(distribution_t)));
feenox_check_alloc(neutron_diffusion.Sigma_t = calloc(G, sizeof(distribution_t)));
feenox_check_alloc(neutron_diffusion.Sigma_a = calloc(G, sizeof(distribution_t)));
feenox_check_alloc(neutron_diffusion.nu_Sigma_f = calloc(G, sizeof(distribution_t)));
feenox_check_alloc(neutron_diffusion.S = calloc(G, sizeof(distribution_t)));
feenox_check_alloc(neutron_diffusion.Sigma_s = calloc(G, sizeof(distribution_t *)));
for (unsigned int g = 0; g < G; g++) {
char *name = NULL;
feenox_check_minusone(asprintf(&name, "D%u", g+1));
feenox_distribution_init(&neutron_diffusion.D[g], name);
if (neutron_diffusion.D[g].defined) {
neutron_diffusion.D[g].non_uniform = feenox_depends_on_space(neutron_diffusion.D[g].dependency_variables);
neutron_diffusion.space_XS |= neutron_diffusion.D[g].non_uniform;
}
feenox_free(name);
feenox_check_minusone(asprintf(&name, "Sigma_t%u", g+1));
feenox_distribution_init(&neutron_diffusion.Sigma_t[g], name);
if (neutron_diffusion.Sigma_t[g].defined) {
neutron_diffusion.Sigma_t[g].non_uniform = feenox_depends_on_space(neutron_diffusion.Sigma_t[g].dependency_variables);
neutron_diffusion.space_XS |= neutron_diffusion.Sigma_t[g].non_uniform;
}
feenox_free(name);
feenox_check_minusone(asprintf(&name, "Sigma_a%u", g+1));
feenox_distribution_init(&neutron_diffusion.Sigma_a[g], name);
if (neutron_diffusion.Sigma_a[g].defined) {
neutron_diffusion.Sigma_a[g].non_uniform = feenox_depends_on_space(neutron_diffusion.Sigma_a[g].dependency_variables);
neutron_diffusion.space_XS |= neutron_diffusion.Sigma_a[g].non_uniform;
}
feenox_free(name);
feenox_check_minusone(asprintf(&name, "nuSigma_f%u", g+1));
feenox_distribution_init(&neutron_diffusion.nu_Sigma_f[g], name);
if (neutron_diffusion.nu_Sigma_f[g].defined) {
neutron_diffusion.has_fission = 1;
neutron_diffusion.nu_Sigma_f[g].non_uniform = feenox_depends_on_space(neutron_diffusion.nu_Sigma_f[g].dependency_variables);
neutron_diffusion.space_XS |= neutron_diffusion.nu_Sigma_f[g].non_uniform;
}
feenox_free(name);
feenox_check_minusone(asprintf(&name, "S%u", g+1));
feenox_distribution_init(&neutron_diffusion.S[g], name);
if (neutron_diffusion.S[g].defined) {
neutron_diffusion.has_sources = 1;
neutron_diffusion.S[g].non_uniform = feenox_depends_on_space(neutron_diffusion.S[g].dependency_variables);
neutron_diffusion.space_XS |= neutron_diffusion.S[g].non_uniform;
}
feenox_free(name);
feenox_check_alloc(neutron_diffusion.Sigma_s[g] = calloc(feenox.pde.dofs, sizeof(distribution_t)));
unsigned int g_prime = 0;
for (g_prime = 0; g_prime < feenox.pde.dofs; g_prime++) {
feenox_check_minusone(asprintf(&name, "Sigma_s%u.%u", g+1, g_prime+1));
feenox_distribution_init(&neutron_diffusion.Sigma_s[g][g_prime], name);
if (neutron_diffusion.Sigma_s[g][g_prime].defined) {
neutron_diffusion.Sigma_s[g][g_prime].non_uniform = feenox_depends_on_space(neutron_diffusion.Sigma_s[g][g_prime].dependency_variables);
}
feenox_free(name);
// try again with another underscore
if (neutron_diffusion.Sigma_s[g][g_prime].defined == 0) {
feenox_check_minusone(asprintf(&name, "Sigma_s%u_%u", g+1, g_prime+1));
feenox_distribution_init(&neutron_diffusion.Sigma_s[g][g_prime], name);
if (neutron_diffusion.Sigma_s[g][g_prime].defined) {
neutron_diffusion.Sigma_s[g][g_prime].non_uniform = feenox_depends_on_space(neutron_diffusion.Sigma_s[g][g_prime].dependency_variables);
}
feenox_free(name);
}
}
fission_spectrum_integral += feenox_vector_get(neutron_diffusion.chi, g);
}
if (neutron_diffusion.has_sources == 0 && neutron_diffusion.has_fission == 0) {
feenox_push_error_message("neither fission nor sources found");
return FEENOX_ERROR;
}
if (fabs(fission_spectrum_integral-1) > 1e-6) {
feenox_push_error_message("fission spectrum is not normalized, its integral is %g", fission_spectrum_integral);
return FEENOX_ERROR;
}
if (neutron_diffusion.has_sources == 0) {
#ifdef HAVE_SLEPC
// TODO: higher harmonics?
feenox.pde.nev = 1;
// define eigenvectors (we don't know its size yet)
feenox_check_alloc(feenox.pde.vectors.phi = calloc(feenox.pde.nev, sizeof(vector_t *)));
for (unsigned int g = 0; g < feenox.pde.nev; g++) {
char *modename = NULL;
feenox_check_minusone(asprintf(&modename, "eig%u", g+1));
feenox_check_alloc(feenox.pde.vectors.phi[g] = feenox_define_vector_get_ptr(modename, 0));
feenox_free(modename);
}
#else
feenox_push_error_message("criticality problems cannot be solved without SLEPc");
return FEENOX_ERROR;
#endif
}
// allocate elemental XS matrices
feenox_check_alloc(neutron_diffusion.D_G = gsl_matrix_calloc(G * feenox.pde.dim, G * feenox.pde.dim));
feenox_check_alloc(neutron_diffusion.R = gsl_matrix_calloc(G, G));
feenox_check_alloc(neutron_diffusion.X = gsl_matrix_calloc(G, G));
feenox_check_alloc(neutron_diffusion.s = gsl_vector_calloc(G));
feenox.pde.math_type = neutron_diffusion.has_sources ? math_type_linear : math_type_eigen;
feenox.pde.solve = neutron_diffusion.has_sources ? feenox_problem_solve_petsc_linear : feenox_problem_solve_slepc_eigen;
feenox.pde.has_stiffness = 1;
feenox.pde.has_mass = !neutron_diffusion.has_sources;
feenox.pde.has_rhs = neutron_diffusion.has_sources;
feenox.pde.has_jacobian_K = 0;
feenox.pde.has_jacobian_M = 0;
feenox.pde.has_jacobian_b = 0;
feenox.pde.has_jacobian = feenox.pde.has_jacobian_K || feenox.pde.has_jacobian_M || feenox.pde.has_jacobian_b;
feenox.pde.symmetric_K = 0;
feenox.pde.symmetric_M = 0;
// see if we have to compute gradients
for (unsigned int g = 0; g < neutron_diffusion.groups; g++) {
feenox.pde.compute_gradients |= (neutron_diffusion.Jx != NULL && neutron_diffusion.Jx[g]->used) ||
(neutron_diffusion.Jy != NULL && neutron_diffusion.Jy[g]->used) ||
(neutron_diffusion.Jz != NULL && neutron_diffusion.Jz[g]->used);
}
#endif
return FEENOX_OK;
}
#ifdef HAVE_PETSC
int feenox_problem_setup_pc_neutron_diffusion(PC pc) {
PCType pc_type = NULL;
petsc_call(PCGetType(pc, &pc_type));
if (pc_type == NULL) {
if (neutron_diffusion.has_sources == 0) {
// PC for EPS
#ifdef PETSC_HAVE_MUMPS
// if we don't set the pc type here then we PCFactorSetMatSolverType does not work
petsc_call(PCSetType(pc, feenox.pde.symmetric_K ? PCCHOLESKY : PCLU));
petsc_call(PCFactorSetMatSolverType(pc, MATSOLVERMUMPS));
#else
// TODO: this will complain in parallel
// petsc_call(PCSetType(pc, PCLU));
#endif
} else {
// plain PC
// defaults
}
}
return FEENOX_OK;
}
int feenox_problem_setup_ksp_neutron_diffusion(KSP ksp ) {
KSPType ksp_type = NULL;
petsc_call(KSPGetType(ksp, &ksp_type));
if (ksp_type == NULL) {
if (neutron_diffusion.has_sources == 0) {
// KSP for EPS
// defaults
} else {
// plain KSP
// defaults
}
}
return FEENOX_OK;
}
#endif
#ifdef HAVE_SLEPC
int feenox_problem_setup_eps_neutron_diffusion(EPS eps) {
petsc_call(EPSSetProblemType(eps, (neutron_diffusion.groups == 1) ? EPS_PGNHEP : EPS_GNHEP));
// we expect the eigenvalue to be near one and an absolute test is faster
petsc_call(EPSSetConvergenceTest(feenox.pde.eps, EPS_CONV_ABS));
// offsets around one
if (feenox_var_value(feenox.pde.vars.eps_st_sigma) == 0)
{
feenox_var_value(feenox.pde.vars.eps_st_sigma) = 1.0;
}
if (feenox_var_value(feenox.pde.vars.eps_st_nu) == 0)
{
feenox_var_value(feenox.pde.vars.eps_st_nu) = 1.0;
}
if (feenox.pde.eigen_formulation == eigen_formulation_omega) {
petsc_call(EPSSetWhichEigenpairs(eps, EPS_SMALLEST_MAGNITUDE));
} else {
petsc_call(EPSSetWhichEigenpairs(eps, EPS_LARGEST_MAGNITUDE));
}
return FEENOX_OK;
}
#endif
feenox-1.2/src/pdes/neutron_diffusion/methods.h 0000664 0001750 0001750 00000006342 15055303016 015424 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for neutron diffusion FEM: virtual methods
*
* Copyright (C) 2021--2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#ifndef NEUTRON_DIFFUSION_FEM_METHODS_H
#define NEUTRON_DIFFUSION_FEM_METHODS_H
// neutron_diffusion/parser.c
extern int feenox_problem_parse_problem_neutron_diffusion(const char *token);
extern int feenox_problem_parse_write_post_neutron_diffusion(mesh_write_t *mesh_write, const char *token);
// neutron_diffusion/init.c
extern int feenox_problem_parse_time_init_neutron_diffusion(void);
extern int feenox_problem_init_runtime_neutron_diffusion(void);
#ifdef HAVE_PETSC
extern int feenox_problem_setup_pc_neutron_diffusion(PC pc);
extern int feenox_problem_setup_ksp_neutron_diffusion(KSP ksp);
#endif
#ifdef HAVE_SLEPC
extern int feenox_problem_setup_eps_neutron_diffusion(EPS eps);
#endif
// neutron_diffusion/bulk.c
extern int feenox_problem_build_allocate_aux_neutron_diffusion(unsigned int n_nodes);
extern int feenox_problem_neutron_diffusion_eval_XS(material_t *material, double *x);
extern int feenox_problem_build_volumetric_neutron_diffusion(element_t *e);
extern int feenox_problem_build_volumetric_gauss_point_neutron_diffusion(element_t *element, unsigned int q);
// neutron_diffusion/bc.c
extern int feenox_problem_bc_parse_neutron_diffusion(bc_data_t *bc_data, const char *lhs, char *rhs);
extern int feenox_problem_bc_set_neutron_diffusion_null(bc_data_t *bc_data, element_t *e, size_t j_global);
extern int feenox_problem_bc_set_neutron_diffusion_flux(bc_data_t *bc_data, element_t *e, size_t j_global);
extern int feenox_problem_bc_set_neutron_diffusion_vacuum(bc_data_t *bc_data, element_t *e, unsigned int q);
extern int feenox_problem_bc_set_neutron_diffusion_current(bc_data_t *bc_data, element_t *e, unsigned int q);
// thermal/currents.c
extern int feenox_problem_gradient_fill_neutron_diffusion(void);
extern int feenox_problem_gradient_properties_at_element_nodes_neutron_diffusion(element_t *element, mesh_t *mesh);
extern int feenox_problem_gradient_fluxes_at_node_alloc_neutron_diffusion(node_t *node);
extern int feenox_problem_gradient_add_elemental_contribution_to_node_neutron_diffusion(node_t *node, element_t *element, unsigned int j, double rel_weight);
extern int feenox_problem_gradient_fill_fluxes_neutron_diffusion(mesh_t *mesh, size_t j);
// neutron_diffusion/post.c
extern int feenox_problem_solve_post_neutron_diffusion(void);
#endif // NEUTRON_DIFFUSION_FEM
feenox-1.2/src/pdes/neutron_diffusion/neutron_diffusion.h 0000664 0001750 0001750 00000004115 15055303016 017515 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for neutron diffusion FEM: global header
*
* Copyright (C) 2021--2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#ifndef NEUTRON_DIFFUSION_H
#define NEUTRON_DIFFUSION_H
typedef struct neutron_diffusion_t neutron_diffusion_t;
struct neutron_diffusion_t {
unsigned int groups;
distribution_t *D;
distribution_t *Sigma_t;
distribution_t *Sigma_a;
distribution_t *nu_Sigma_f;
distribution_t **Sigma_s;
distribution_t *S;
// diffusion coefficients, (groups * dim) x (groups * dim)
gsl_matrix *D_G;
// removal XSs: groups x groups
gsl_matrix *R;
// fission XSs: groups x groups
gsl_matrix *X;
// independent sources: groups
gsl_vector *s;
unsigned int n_nodes;
// elemental matrices (size J*G x J*G)
gsl_matrix *Li; // leakage
gsl_matrix *Ai; // absorption
gsl_matrix *Fi; // fission
// intermediate matrices
gsl_matrix *DB;
gsl_matrix *RH;
gsl_matrix *XH;
int has_sources;
int has_fission;
int space_XS;
// fission spectrum
vector_t *chi;
// effective multiplication factor
var_t *keff;
// neutron currents
function_t **Jx;
function_t **Jy;
function_t **Jz;
};
extern neutron_diffusion_t neutron_diffusion;
#endif /* NEUTRON_DIFFUSION_FEM_H */
feenox-1.2/src/pdes/neutron_diffusion/parser.c 0000664 0001750 0001750 00000004357 15055303016 015254 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for neutron diffusion FEM: input parsing
*
* Copyright (C) 2021 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "neutron_diffusion.h"
#include "../../parser/parser.h"
int feenox_problem_parse_problem_neutron_diffusion(const char *token) {
if (token != NULL) {
if (strcasecmp(token, "GROUPS") == 0) {
double xi = 0;
feenox_call(feenox_parser_expression_in_string(&xi));
neutron_diffusion.groups = (unsigned int)(xi);
} else {
feenox_push_error_message("undefined keyword '%s'", token);
return FEENOX_ERROR;
}
} else {
// if token is NULL we have to do the parse-time initialization
feenox_call(feenox_problem_parse_time_init_neutron_diffusion());
}
return FEENOX_OK;
}
int feenox_problem_parse_write_post_neutron_diffusion(mesh_write_t *mesh_write, const char *token) {
if (strcmp(token, "all") == 0) {
feenox_call(feenox_problem_parse_write_post_neutron_diffusion(mesh_write, "fluxes"));
} else if (strcmp(token, "flux") == 0 || strcmp(token, "fluxes") == 0) {
for (int g = 0; g < neutron_diffusion.groups; g++) {
feenox_call(feenox_add_post_field(mesh_write, 1, &feenox.pde.unknown_name[g], NULL, field_location_nodes));
}
} else {
feenox_push_error_message("undefined keyword '%s' for neutron_diffusion WRITE_RESULTS", token);
return FEENOX_ERROR;
}
return FEENOX_OK;
}
feenox-1.2/src/pdes/neutron_diffusion/post.c 0000664 0001750 0001750 00000004421 15055303016 014735
/*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for neutron diffusion FEM: post
*
* Copyright (C) 2021 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "neutron_diffusion.h"
int feenox_problem_solve_post_neutron_diffusion(void) {
#ifdef HAVE_PETSC
if (neutron_diffusion.has_sources == 0) {
#ifdef HAVE_SLEPC
if (feenox.pde.eigen_formulation == eigen_formulation_omega) {
feenox_var_value(neutron_diffusion.keff) = 1.0/feenox.pde.eigenvalue[0];
} else {
feenox_var_value(neutron_diffusion.keff) = feenox.pde.eigenvalue[0];
}
// normalization without power
double num = 0;
double den = 0;
for (size_t i = 0; i < feenox.pde.mesh->n_elements; i++) {
element_t *element = &feenox.pde.mesh->element[i];
if (element->type != NULL && element->type->dim == feenox.pde.dim) {
num += element->type->volume(element);
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
den += feenox_mesh_integral_over_element(element, feenox.pde.mesh, feenox.pde.solution[g]);
}
}
}
double factor = num/den;
// normalize the fluxes
for (size_t j = 0; j < feenox.pde.mesh->n_nodes; j++) {
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
double xi = feenox_vector_get(feenox.pde.solution[g]->vector_value, j);
feenox_vector_set(feenox.pde.solution[g]->vector_value, j, factor*xi);
}
}
#endif
}
#endif
return FEENOX_OK;
}
feenox-1.2/src/pdes/modal/ 0000775 0001750 0001750 00000000000 15055303133 011217 5 feenox-1.2/src/pdes/modal/bc.c 0000664 0001750 0001750 00000022523 15055303016 011673 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for modal analysis: boundary conditions
*
* Copyright (C) 2021-2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "modal.h"
int feenox_problem_bc_parse_modal(bc_data_t *bc_data, const char *lhs, char *rhs) {
// TODO: document BCs with triple comments
if (strcmp(lhs, "fixed") == 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_DISPLACEMENT;
bc_data->type_math = bc_type_math_dirichlet;
bc_data->set_essential = feenox_problem_bc_set_modal_displacement;
bc_data->dof = -1;
modal.has_dirichlet_bcs = 1;
} else if (strcmp(lhs, "u") == 0 || strcmp(lhs, "u_x") == 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_DISPLACEMENT;
bc_data->type_math = bc_type_math_dirichlet;
bc_data->set_essential = feenox_problem_bc_set_modal_displacement;
bc_data->dof = 0;
modal.has_dirichlet_bcs = 1;
} else if (strcmp(lhs, "v") == 0 || strcmp(lhs, "u_y") == 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_DISPLACEMENT;
bc_data->type_math = bc_type_math_dirichlet;
bc_data->set_essential = feenox_problem_bc_set_modal_displacement;
bc_data->dof = 1;
modal.has_dirichlet_bcs = 1;
if (feenox.pde.dofs < 1) {
feenox_push_error_message("cannot set u (displacement in y) with DOFs < 2");
return FEENOX_ERROR;
}
} else if (strcmp(lhs, "w") == 0 || strcmp(lhs, "u_z") == 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_DISPLACEMENT;
bc_data->type_math = bc_type_math_dirichlet;
bc_data->set_essential = feenox_problem_bc_set_modal_displacement;
bc_data->dof = 2;
modal.has_dirichlet_bcs = 1;
if (feenox.pde.dofs < 2) {
feenox_push_error_message("cannot set w (displacement in z) with DOFs < 3");
return FEENOX_ERROR;
}
} else if (strcmp(lhs, "symmetry") == 0 || strcmp(lhs, "tangential") == 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_TANGENTIAL_SYMMETRY;
bc_data->type_math = bc_type_math_multifreedom;
bc_data->set_essential = feenox_problem_bc_set_modal_symmetry;
} else if (strcmp(lhs, "radial") == 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_RADIAL_SYMMETRY;
bc_data->type_math = bc_type_math_multifreedom;
bc_data->set_essential = feenox_problem_bc_set_modal_radial;
// TODO: x0, y0 and z0
} else if (strcmp(lhs, "0") == 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_MULTIDOF_EXPRESSION;
bc_data->type_math = bc_type_math_multifreedom;
bc_data->set_essential = feenox_problem_bc_set_modal_multifreedom;
// trick: the idea is that the user might write an expression of space
// x,y,z but also maybe of u,v y w. However, u,v,w are functinos and not variables!
// what we do is to define variables named U,V,W and string-replace u,v,w -> U,V,W
// in the entered expression
// TODO: there should be a separator (i.e. operator) before and after
char *s = rhs;
while (*s != '\0') {
if (*s == 'u') {
*s = 'U';
} else if (*s == 'v') {
*s = 'V';
} else if (*s == 'w') {
*s = 'W';
}
s++;
}
} else {
feenox_push_error_message("unknown modal boundary condition '%s'", lhs);
return FEENOX_ERROR;
}
if (rhs != NULL && strcmp(rhs, "0") != 0) {
feenox_push_error_message("boundary conditions in modal have to be homogeneous not '%s'", rhs);
return FEENOX_ERROR;
}
return FEENOX_OK;
}
// this virtual method fills in the dirichlet indexes and values with bc_data
int feenox_problem_bc_set_modal_displacement(bc_data_t *this, element_t *e, size_t j_global) {
#ifdef HAVE_PETSC
if (this->dof != -1) {
// only one dof
feenox_call(feenox_problem_dirichlet_add(j_global, this->dof, feenox_expression_eval(&this->expr)));
} else {
// -1 means all dofs (and the only possibility is to have all them equal to zero)
feenox_call(feenox_problem_dirichlet_add(j_global, 0, 0));
if (feenox.pde.dofs > 1) {
feenox_call(feenox_problem_dirichlet_add(j_global, 1, 0));
if (feenox.pde.dofs > 2) {
feenox_call(feenox_problem_dirichlet_add(j_global, 2, 0));
}
}
}
#endif
return FEENOX_OK;
}
int feenox_problem_bc_set_modal_symmetry(bc_data_t *this, element_t *e, size_t j_global) {
#ifdef HAVE_PETSC
// outward normal (smoothed over all elements on the physical group of the BC)
// TODO: choose to smooth or to use the local one
PetscScalar normal[3] = {0, 0, 0};
PetscScalar n_element[3] = {0, 0, 0};
element_ll_t *element_item = NULL;
LL_FOREACH(feenox.pde.mesh->node[j_global].element_list, element_item) {
element_t *e_prime = element_item->element;
if (e_prime != NULL && e_prime->type->dim == (feenox.pde.dim-1) && e_prime->physical_group == e->physical_group) {
feenox_call(feenox_mesh_compute_outward_normal(element_item->element, n_element));
normal[0] += n_element[0];
normal[1] += n_element[1];
normal[2] += n_element[2];
}
}
// feenox_call(feenox_mesh_compute_outward_normal(element, normal));
int coordinate_direction = -1;
double norm = gsl_hypot3(normal[0], normal[1], normal[2]);
if (feenox_likely(norm != 0)) {
// if the outward normal coincides with one of the three axes, we can get away with a regular dirichlet BC
for (int g = 0; g < 3; g++) {
normal[g] /= norm;
if (fabs(normal[g]) > (1-1e-4)) {
coordinate_direction = g;
}
}
} else {
feenox_push_error_message("outward normal has zero norm");
return FEENOX_ERROR;
}
// if the condition results in a direction normal to one of the three coordinate planes
// then we set a traditional dirichlet bc (i.e. u=0 or v=0 or w=0)
// otherwise we need a generic multifreedom
if (coordinate_direction != -1) {
feenox_call(feenox_problem_dirichlet_add(j_global, coordinate_direction, 0));
} else {
feenox_call(feenox_problem_multifreedom_add(j_global, normal));
}
#endif
return FEENOX_OK;
}
int feenox_problem_bc_set_modal_radial(bc_data_t *this, element_t *e, size_t j_global) {
#ifdef HAVE_PETSC
double x[3] = {0,0,0};
double eps = 1e-2;
if (e->physical_group->volume == 0) {
feenox_call(feenox_physical_group_compute_volume(e->physical_group, feenox.pde.mesh));
}
// TODO! read center of the radial condition
for (int g = 0; g < 3; g++) {
// x[g] = feenox.pde.mesh->node[node_global_index].x[g] - ((bc_data->expr[g].items == NULL) ? element->physical_entity->cog[d] : feenox_expression_eval(bc_data->expr[g]));
x[g] = feenox.pde.mesh->node[j_global].x[g] - e->physical_group->cog[g];
}
double coefficients[3] = {0,0,0};
// x-y
if (fabs(x[0]) > eps && fabs(x[1]) > eps) {
coefficients[0] = +x[1];
coefficients[1] = -x[0];
coefficients[2] = 0;
feenox_call(feenox_problem_multifreedom_add(j_global, coefficients));
}
// x-z
if (fabs(x[0]) > eps && fabs(x[2]) > eps) {
coefficients[0] = +x[2];
coefficients[1] = 0;
coefficients[2] = -x[0];
feenox_call(feenox_problem_multifreedom_add(j_global, coefficients));
}
// y-z
if (fabs(x[1]) > eps && fabs(x[2]) > eps) {
coefficients[0] = 0;
coefficients[1] = +x[2];
coefficients[2] = -x[1];
feenox_call(feenox_problem_multifreedom_add(j_global, coefficients));
}
#endif
return FEENOX_OK;
}
typedef struct {
expr_t *expr;
int dof;
} feenox_gsl_function_of_uvw_params_t;
// this virtual method fills in the dirichlet indexes and values with bc_data
int feenox_problem_bc_set_modal_multifreedom(bc_data_t *this, element_t *e, size_t j_global) {
#ifdef HAVE_PETSC
feenox_gsl_function_of_uvw_params_t params = { &this->expr, -1 };
gsl_function F = {feenox_modal_gsl_function_of_uvw, ¶ms};
double coefficients[3] = {0, 0, 0};
// TODO: choose
double h = 1e-5;
double result = 0;
double abserr = 0;
for (int g = 0; g < 3; g++) {
params.dof = g;
gsl_deriv_central(&F, 0, h, &result, &abserr);
coefficients[g] = -result;
}
// TODO: non-homogeneous RHS
feenox_call(feenox_problem_multifreedom_add(j_global, coefficients));
#endif
return FEENOX_OK;
}
// wrapper to compute derivatives with GSL
double feenox_modal_gsl_function_of_uvw(double x, void *params) {
feenox_gsl_function_of_uvw_params_t *p = (feenox_gsl_function_of_uvw_params_t *)params;
feenox_var_value(modal.displ_for_bc[0]) = 0;
feenox_var_value(modal.displ_for_bc[1]) = 0;
feenox_var_value(modal.displ_for_bc[2]) = 0;
feenox_var_value(modal.displ_for_bc[p->dof]) = x;
double y = feenox_expression_eval(p->expr);
if (gsl_isnan(y) || gsl_isinf(y)) {
feenox_nan_error();
}
return y;
}
feenox-1.2/src/pdes/modal/bulk.c 0000664 0001750 0001750 00000007724 15055303016 012252 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for modal analysis: bulk elements
*
* Copyright (C) 2021--2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "modal.h"
int feenox_problem_build_allocate_aux_modal(unsigned int n_nodes) {
modal.n_nodes = n_nodes;
if (modal.B != NULL) {
gsl_matrix_free(modal.B);
}
feenox_check_alloc(modal.B = gsl_matrix_calloc(modal.stress_strain_size, feenox.pde.dofs * modal.n_nodes));
if (modal.CB != NULL) {
gsl_matrix_free(modal.CB);
}
feenox_check_alloc(modal.CB = gsl_matrix_calloc(modal.stress_strain_size, feenox.pde.dofs * modal.n_nodes));
return FEENOX_OK;
}
int feenox_problem_build_volumetric_gauss_point_modal(element_t *e, unsigned int q) {
#ifdef HAVE_PETSC
// material stress-strain relationship
// TODO: see how to optimize uniform properties
double *x = feenox_fem_compute_x_at_gauss(e, q, feenox.pde.mesh->integration);
modal.compute_C(x, feenox_fem_get_material(e));
// TODO: unify with mechanical!
gsl_matrix *dhdx = feenox_fem_compute_B_at_gauss_integration(e, q, feenox.pde.mesh->integration);
for (unsigned int j = 0; j < modal.n_nodes; j++) {
// TODO: virtual methods? they cannot be inlined...
if (modal.variant == variant_full) {
gsl_matrix_set(modal.B, 0, 3*j+0, gsl_matrix_get(dhdx, 0, j));
gsl_matrix_set(modal.B, 1, 3*j+1, gsl_matrix_get(dhdx, 1, j));
gsl_matrix_set(modal.B, 2, 3*j+2, gsl_matrix_get(dhdx, 2, j));
gsl_matrix_set(modal.B, 3, 3*j+0, gsl_matrix_get(dhdx, 1, j));
gsl_matrix_set(modal.B, 3, 3*j+1, gsl_matrix_get(dhdx, 0, j));
gsl_matrix_set(modal.B, 4, 3*j+1, gsl_matrix_get(dhdx, 2, j));
gsl_matrix_set(modal.B, 4, 3*j+2, gsl_matrix_get(dhdx, 1, j));
gsl_matrix_set(modal.B, 5, 3*j+0, gsl_matrix_get(dhdx, 2, j));
gsl_matrix_set(modal.B, 5, 3*j+2, gsl_matrix_get(dhdx, 0, j));
} else if (modal.variant == variant_axisymmetric) {
feenox_push_error_message("axisymmetric still not implemented");
return FEENOX_ERROR;
} else if (modal.variant == variant_plane_stress || modal.variant == variant_plane_strain) {
// plane stress and plane strain are the same
// see equation 14.18 IFEM CH.14 sec 14.4.1 pag 14-11
gsl_matrix_set(modal.B, 0, 2*j+0, gsl_matrix_get(dhdx, 0, j));
gsl_matrix_set(modal.B, 1, 2*j+1, gsl_matrix_get(dhdx, 1, j));
gsl_matrix_set(modal.B, 2, 2*j+0, gsl_matrix_get(dhdx, 1, j));
gsl_matrix_set(modal.B, 2, 2*j+1, gsl_matrix_get(dhdx, 0, j));
} else {
return FEENOX_ERROR;
}
}
// wdet
double wdet = feenox_fem_compute_w_det_at_gauss_integration(e, q, feenox.pde.mesh->integration);
// elemental stiffness B'*C*B
feenox_call(feenox_blas_BtCB_accum(modal.B, modal.C, modal.CB, wdet, feenox.fem.Ki));
// elemental mass H'*rho*H
// TODO: see how to optimize uniform properties
modal.rho.eval(&modal.rho, x, feenox_fem_get_material(e));
gsl_matrix *H_Gc = feenox_fem_compute_H_Gc_at_gauss(e, q, feenox.pde.mesh->integration);
feenox_call(feenox_blas_BtB_accum(H_Gc, wdet * modal.rho.value, feenox.fem.Mi));
#endif
return FEENOX_OK;
}
feenox-1.2/src/pdes/modal/elastic-isotropic.c 0000664 0001750 0001750 00000003465 15055303016 014750 /*------------ -------------- -------- --- ----- --- -- - -
* feenox elastic isotropic mechanical material
*
* Copyright (C) 2021-2023 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "modal.h"
int feenox_problem_build_compute_modal_C_elastic_isotropic(const double *x, material_t *material) {
double E = modal.E.eval(&modal.E, x, material);
double nu = modal.nu.eval(&modal.nu, x, material);
double lambda = E*nu/((1+nu)*(1-2*nu));
double mu = 0.5*E/(1+nu);
double lambda2mu = lambda + 2*mu;
gsl_matrix_set(modal.C, 0, 0, lambda2mu);
gsl_matrix_set(modal.C, 0, 1, lambda);
gsl_matrix_set(modal.C, 0, 2, lambda);
gsl_matrix_set(modal.C, 1, 0, lambda);
gsl_matrix_set(modal.C, 1, 1, lambda2mu);
gsl_matrix_set(modal.C, 1, 2, lambda);
gsl_matrix_set(modal.C, 2, 0, lambda);
gsl_matrix_set(modal.C, 2, 1, lambda);
gsl_matrix_set(modal.C, 2, 2, lambda2mu);
gsl_matrix_set(modal.C, 3, 3, mu);
gsl_matrix_set(modal.C, 4, 4, mu);
gsl_matrix_set(modal.C, 5, 5, mu);
return FEENOX_OK;
}
feenox-1.2/src/pdes/modal/elastic-orthotropic.c 0000664 0001750 0001750 00000010345 15055303016 015304 /*------------ -------------- -------- --- ----- --- -- - -
* feenox elastic orthotropic mechanical material
*
* Copyright (C) 2023 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "modal.h"
int feenox_problem_build_compute_modal_C_elastic_orthotropic(const double *x, material_t *material) {
// TODO: check ranges of validity
// E > 0
// G > 0
// | nu_ij | < sqrt(E_i/E_j)
// 1 - nu12*nu21 - nu23*nu32 - nu31*nu13 - 2*nu21*nu32*nu13 > 0
double E_x = modal.E_x.eval(&modal.E_x, x, material);
double E_y = modal.E_y.eval(&modal.E_y, x, material);
double E_z = modal.E_z.eval(&modal.E_z, x, material);
// TODO: handle engineering nu12,nu23 and nu13 (instead of nu31)
double nu_xy = modal.nu_xy.eval(&modal.nu_xy, x, material);
double nu_yz = modal.nu_yz.eval(&modal.nu_yz, x, material);
double nu_zx = modal.nu_zx.eval(&modal.nu_zx, x, material);
double G_xy = modal.G_xy.eval(&modal.G_xy, x, material);
double G_yz = modal.G_yz.eval(&modal.G_yz, x, material);
double G_zx = modal.G_zx.eval(&modal.G_zx, x, material);
gsl_matrix *S = NULL; // reduced compliance matrix (only the normal-stress stuff)
feenox_check_alloc(S = gsl_matrix_calloc(3, 3));
gsl_matrix *C = NULL; // reduced stiffness matrix
feenox_check_alloc(C = gsl_matrix_calloc(3, 3));
// > if you noticed that C is called the stiffness tensor and S is called the compliance
// > tensor and wondered about it, this is not a mistake and there is no intention to confuse
// > you. It is a long-time convention that cannot be reverted anymore
// source: https://www.weizmann.ac.il/chembiophys/bouchbinder/sites/chemphys.bouchbinder/files/uploads/Courses/2016/ta5-linear_elasticity-i.pdf
// fill the 3x3 reduced compliance matrix first
// [ 1/E1 -nu21/E2 -nu31/E3 ]
// [ -nu12/E1 1/E2 -nu32/E3 ]
// [ -nu13/E1 -nu23/E2 1/E3 ]
gsl_matrix_set(S, 0, 0, 1.0/E_x);
gsl_matrix_set(S, 1, 1, 1.0/E_y);
gsl_matrix_set(S, 2, 2, 1.0/E_z);
// since S is symmetric,
// nu21/E2 = nu12/E1
// nu31/E3 = nu13/E1
// nu32/E3 = nu23/E2
// but we ask for nu12, nu23 and nu31 (not nu21, nu32 nor nu13) so we use
double minus_nu_xy_over_E_x = -nu_xy/E_x;
double minus_nu_zx_over_E_z = -nu_zx/E_z;
double minus_nu_yz_over_E_y = -nu_yz/E_y;
// to set the off-diagonal (symmetric) entries
gsl_matrix_set(S, 0, 1, minus_nu_xy_over_E_x);
gsl_matrix_set(S, 1, 0, minus_nu_xy_over_E_x);
gsl_matrix_set(S, 0, 2, minus_nu_zx_over_E_z);
gsl_matrix_set(S, 2, 0, minus_nu_zx_over_E_z);
gsl_matrix_set(S, 1, 2, minus_nu_yz_over_E_y);
gsl_matrix_set(S, 2, 1, minus_nu_yz_over_E_y);
// compute the stiffness by inverting the 3x3 compliance
C = feenox_fem_matrix_invert(S, C);
// now fill the full 6x6 C
gsl_matrix_set(modal.C, 0, 0, gsl_matrix_get(C, 0, 0));
gsl_matrix_set(modal.C, 0, 1, gsl_matrix_get(C, 0, 1));
gsl_matrix_set(modal.C, 0, 2, gsl_matrix_get(C, 0, 2));
gsl_matrix_set(modal.C, 1, 0, gsl_matrix_get(C, 1, 0));
gsl_matrix_set(modal.C, 1, 1, gsl_matrix_get(C, 1, 1));
gsl_matrix_set(modal.C, 1, 2, gsl_matrix_get(C, 1, 2));
gsl_matrix_set(modal.C, 2, 0, gsl_matrix_get(C, 2, 0));
gsl_matrix_set(modal.C, 2, 1, gsl_matrix_get(C, 2, 1));
gsl_matrix_set(modal.C, 2, 2, gsl_matrix_get(C, 2, 2));
gsl_matrix_set(modal.C, 3, 3, G_xy);
gsl_matrix_set(modal.C, 4, 4, G_zx);
gsl_matrix_set(modal.C, 5, 5, G_yz);
gsl_matrix_free(C);
gsl_matrix_free(S);
return FEENOX_OK;
}
feenox-1.2/src/pdes/modal/elastic-plane-strain.c 0000664 0001750 0001750 00000003061 15055303016 015322 /*------------ -------------- -------- --- ----- --- -- - -
* feenox elastic isotropic plane-strain mechanical material
*
* Copyright (C) 2021-2023 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "modal.h"
int feenox_problem_build_compute_modal_C_elastic_plane_strain(const double *x, material_t *material) {
double E = modal.E.eval(&modal.E, x, material);
double nu = modal.nu.eval(&modal.nu, x, material);
double lambda = E*nu/((1+nu)*(1-2*nu));
double mu = 0.5*E/(1+nu);
double lambda2mu = lambda + 2*mu;
gsl_matrix_set(modal.C, 0, 0, lambda2mu);
gsl_matrix_set(modal.C, 0, 1, lambda);
gsl_matrix_set(modal.C, 1, 0, lambda);
gsl_matrix_set(modal.C, 1, 1, lambda2mu);
gsl_matrix_set(modal.C, 2, 2, mu);
return FEENOX_OK;
}
feenox-1.2/src/pdes/modal/elastic-plane-stress.c 0000664 0001750 0001750 00000002755 15055303016 015356 /*------------ -------------- -------- --- ----- --- -- - -
* feenox elastic isotropic plane-stress mechanical material
*
* Copyright (C) 2021-2022 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "modal.h"
int feenox_problem_build_compute_modal_C_elastic_plane_stress(const double *x, material_t *material) {
double E = modal.E.eval(&modal.E, x, material);
double nu = modal.nu.eval(&modal.nu, x, material);
double c1 = E/(1-nu*nu);
double c2 = nu * c1;
gsl_matrix_set(modal.C, 0, 0, c1);
gsl_matrix_set(modal.C, 0, 1, c2);
gsl_matrix_set(modal.C, 1, 0, c2);
gsl_matrix_set(modal.C, 1, 1, c1);
gsl_matrix_set(modal.C, 2, 2, c1*0.5*(1-nu));
return FEENOX_OK;
}
feenox-1.2/src/pdes/modal/init.c 0000664 0001750 0001750 00000041161 15055303016 012251 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for modal analysis: initialization
*
* Copyright (C) 2021--2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "modal.h"
modal_t modal;
int feenox_problem_parse_time_init_modal(void) {
///kw_pde+PROBLEM+detail * `modal` natural mechanical frequencies and modes of oscillation
#ifdef HAVE_SLEPC
// virtual methods
feenox.pde.parse_bc = feenox_problem_bc_parse_modal;
feenox.pde.parse_write_results = feenox_problem_parse_write_post_modal;
feenox.pde.init_before_run = feenox_problem_init_runtime_modal;
feenox.pde.setup_eps = feenox_problem_setup_eps_modal;
feenox.pde.setup_ksp = feenox_problem_setup_ksp_modal;
feenox.pde.setup_pc = feenox_problem_setup_pc_modal;
feenox.pde.element_build_allocate_aux = feenox_problem_build_allocate_aux_modal;
feenox.pde.element_build_volumetric_at_gauss = feenox_problem_build_volumetric_gauss_point_modal;
feenox.pde.solve_post = feenox_problem_solve_post_modal;
// we are FEM
feenox.mesh.default_field_location = field_location_nodes;
// move symmetry_axis which is a general PDE setting to
// the mechanically-particular axisymmetric variant
if (feenox.pde.symmetry_axis != symmetry_axis_none) {
modal.variant = variant_axisymmetric;
}
// check consistency of problem type and dimensions
if (modal.variant == variant_axisymmetric ||
modal.variant == variant_plane_stress ||
modal.variant == variant_plane_strain) {
if (feenox.pde.dim != 0) {
if (feenox.pde.dim != 2) {
feenox_push_error_message("dimension inconsistency, expected 2 dimensions not %d", feenox.pde.dim);
return FEENOX_ERROR;
}
} else {
feenox.pde.dim = 2;
}
if (feenox.pde.dofs != 0) {
if (feenox.pde.dofs != 2) {
feenox_push_error_message("DOF inconsistency, expected DOFs per node = 2");
return FEENOX_ERROR;
}
} else {
feenox.pde.dofs = 2;
}
} else {
if (feenox.pde.dim == 0) {
// default is 3d
feenox.pde.dim = 3;
} else if (feenox.pde.dim == 1) {
feenox_push_error_message("cannot solve 1D modal problems");
return FEENOX_ERROR;
} else if (feenox.pde.dim == 2) {
feenox_push_error_message("to solve 2D problems give either plane_stress, plane_strain or axisymmetric");
return FEENOX_ERROR;
} else if (feenox.pde.dim != 3) {
feenox_push_error_message("dimension inconsistency, expected DIM 3 instead of %d", feenox.pde.dim);
return FEENOX_ERROR;
}
feenox.pde.dofs = feenox.pde.dim;
}
// TODO: custom names
feenox_check_alloc(feenox.pde.unknown_name = calloc(feenox.pde.dofs, sizeof(char *)));
feenox_check_alloc(feenox.pde.unknown_name[0] = strdup("u"));
if (feenox.pde.dofs > 1) {
feenox_check_alloc(feenox.pde.unknown_name[1] = strdup("v"));
if (feenox.pde.dofs > 2) {
feenox_check_alloc(feenox.pde.unknown_name[2] = strdup("w"));
}
}
// if there are no explicit number of eigenvalues we set a non-zero value here
if (feenox.pde.nev == 0) {
feenox.pde.nev = DEFAULT_MODAL_MODES;
}
// ------- modal-related vectors & outputs -----------------------------------
///va+M_T+desc A scalar with the total mass\ $m$ computed from the mass matrix\ $M$ as
///va+M_T+desc
///va+M_T+desc \[ M_T = \frac{1}{n_\text{DOFs}} \cdot \vec{1}^T \cdot M \cdot \vec{1} \]
///va+M_T+desc
///va+M_T+desc where $n_\text{DOFs}$ is the number of degrees of freedoms per node.
///va+M_T+desc Note that this is only approximately equal to the actual mass which is
///va+M_T+desc the integral of the density $\rho(x,y,z)$ over the problem domain.
feenox_check_alloc(modal.M_T = feenox_define_variable_get_ptr("M_T"));
///ve+f+desc _Size:_ number of requested modes.
///ve+f+desc _Elements:_ The frequency $f_i$ of the $i$-th mode, in cycles per unit of time.
feenox_check_alloc(modal.f = feenox_define_vector_get_ptr("f", feenox.pde.nev));
///ve+omega+desc _Size:_ number of requested modes.
///ve+omega+desc _Elements:_ The angular frequency $\omega_i$ of the $i$-th mode, in radians per unit of time.
feenox_check_alloc(modal.omega = feenox_define_vector_get_ptr("omega", feenox.pde.nev));
///ve+m+desc _Size:_ number of requested modes.
///ve+m+desc _Elements:_ The generalized modal mass $m_i$ of the $i$-th mode computed as
///ve+m+desc
///ve+m+desc \[ \text{m}_i = \frac{1}{n_\text{DOFs}} \vec{\phi}_i^T \cdot M \cdot \vec{\phi}_i \]
///va+m+desc
///va+m+desc where $n_\text{DOFs}$ is the number of degrees of freedoms per node, $M$ is the mass matrix
///va+m+desc and $\vec{\phi}_i$ is the $i$-th eigenvector normalized such that the largest element is equal to one.
feenox_check_alloc(modal.m = feenox_define_vector_get_ptr("m", feenox.pde.nev));
///ve+L+desc _Size:_ number of requested modes.
///ve+L+desc _Elements:_ The excitation factor $L_i$ of the $i$-th mode computed as
///ve+L+desc
///ve+L+desc \[ L_i = \frac{1}{n_\text{DOFs}} \cdot \vec{\phi}_i^T \cdot M \cdot \vec{1} \]
///va+L+desc
///va+L+desc where $n_\text{DOFs}$ is the number of degrees of freedoms per node, $M$ is the mass matrix
///va+L+desc and $\vec{\phi}_i$ is the $i$-th eigenvector normalized such that the largest element is equal to one.
feenox_check_alloc(modal.L = feenox_define_vector_get_ptr("L", feenox.pde.nev));
///ve+Gamma+desc _Size:_ number of requested modes.
///ve+Gamma+desc _Elements:_ The participation factor $\Gamma_i$ of the $i$-th mode computed as
///ve+Gamma+desc
///ve+Gamma+desc \[ \Gamma_i = \frac{ \vec{\phi}_i^T \cdot M \cdot \vec{1} }{ \vec{\phi}_i^T \cdot M \cdot \vec{\phi}} \]
feenox_check_alloc(modal.Gamma = feenox_define_vector_get_ptr("Gamma", feenox.pde.nev));
///ve+mu+desc _Size:_ number of requested modes.
///ve+mu+desc _Elements:_ The relative effective modal mass $\mu_i$ of the $i$-th mode computed as
///ve+mu+desc
///ve+mu+desc \[ \mu_i = \frac{L_i^2}{M_t \cdot n_\text{DOFs} \cdot m_i} \]
///ve+mu+desc
///ve+mu+desc Note that $\sum_{i=1}^N m_i = 1$, where $N$ is total number of degrees of freedom ($n_\text{DOFs}$ times the number of nodes).
feenox_check_alloc(modal.mu = feenox_define_vector_get_ptr("mu", feenox.pde.nev));
///ve+Mu+desc _Size:_ number of requested modes.
///ve+Mu+desc _Elements:_ The accumulated relative effective modal mass $\Mu_i$ up to the $i$-th mode computed as
///ve+Mu+desc
///ve+Mu+desc \[ \Mu_i = \sum_{j=1}^i \mu_i \]
///ve+Mu+desc
///ve+Mu+desc Note that $\Mu_N = 1$, where $N$ is total number of degrees of freedom ($n_\text{DOFs}$ times the number of nodes).
feenox_check_alloc(modal.Mu = feenox_define_vector_get_ptr("Mu", feenox.pde.nev));
// define eigenvectors (we don't know its size yet)
feenox_check_alloc(feenox.pde.vectors.phi = calloc(feenox.pde.nev, sizeof(vector_t *)));;
for (unsigned int i = 0; i < feenox.pde.nev; i++) {
char *modename = NULL;
feenox_check_minusone(asprintf(&modename, "phi%u", i+1));
feenox_check_alloc(feenox.pde.vectors.phi[i] = feenox_define_vector_get_ptr(modename, 0));
feenox_free(modename);
}
// these are for the algebraic expressions in the implicitly-defined BCs
// i.e. 0=u*nx+v*ny or 0=u*y-v*x
// here they are defined as uppercase because there already exist functions named u, v and w
// but the parser changes their case when an implicit BC is read
modal.displ_for_bc[0]= feenox_define_variable_get_ptr("U");
modal.displ_for_bc[1]= feenox_define_variable_get_ptr("V");
modal.displ_for_bc[2]= feenox_define_variable_get_ptr("W");
#else
feenox_push_error_message("modal problems need a FeenoX binary linked against SLEPc.");
return FEENOX_ERROR;
#endif
return FEENOX_OK;
}
int feenox_problem_init_runtime_modal(void) {
#ifdef HAVE_PETSC
feenox.pde.mesh->data_type = data_type_node;
feenox.pde.spatial_unknowns = feenox.pde.mesh->n_nodes;
// initialize distributions
feenox_distribution_define_mandatory(modal, rho, "rho", "density");
// modal.rho.non_uniform = feenox_expression_depends_on_space(modal.rho.dependency_variables);
// initialize distributions
// first see if we have linear elastic
feenox_call(feenox_distribution_init(&modal.E, "E"));
// modal.E.non_uniform = feenox_expression_depends_on_space(modal.E.dependency_variables);
feenox_call(feenox_distribution_init(&modal.nu, "nu"));
// modal.nu.non_uniform = feenox_expression_depends_on_space(modal.nu.dependency_variables);
// TODO: allow different volumes to have different material models
if (modal.E.defined && modal.nu.defined) {
if (modal.E.full == 0) {
feenox_push_error_message("Young modulus 'E' is not defined over all volumes");
return FEENOX_ERROR;
}
if (modal.nu.full == 0) {
feenox_push_error_message("Poisson’s ratio 'nu' is not defined over all volumes");
return FEENOX_ERROR;
}
modal.material_model = material_model_elastic_isotropic;
} else if (modal.E.defined) {
feenox_push_error_message("Young modulus 'E' defined but Poisson’s ratio 'nu' not defined");
return FEENOX_ERROR;
} else if (modal.nu.defined) {
feenox_push_error_message("Poisson’s ratio 'nu' defined but Young modulus 'E' not defined");
return FEENOX_ERROR;
}
// see if there are orthotropic properties
feenox_call(feenox_distribution_init(&modal.E_x, "Ex"));
if (modal.E_x.defined == 0) {
feenox_call(feenox_distribution_init(&modal.E_x, "E_x"));
}
feenox_call(feenox_distribution_init(&modal.E_y, "Ey"));
if (modal.E_y.defined == 0) {
feenox_call(feenox_distribution_init(&modal.E_y, "E_y"));
}
feenox_call(feenox_distribution_init(&modal.E_z, "Ez"));
if (modal.E_z.defined == 0) {
feenox_call(feenox_distribution_init(&modal.E_z, "E_z"));
}
feenox_call(feenox_distribution_init(&modal.nu_xy, "nuxy"));
if (modal.nu_xy.defined == 0) {
feenox_call(feenox_distribution_init(&modal.nu_xy, "nu_xy"));
}
feenox_call(feenox_distribution_init(&modal.nu_yz, "nuyz"));
if (modal.nu_yz.defined == 0) {
feenox_call(feenox_distribution_init(&modal.nu_yz, "nu_yz"));
}
feenox_call(feenox_distribution_init(&modal.nu_zx, "nuzx"));
if (modal.nu_zx.defined == 0) {
feenox_call(feenox_distribution_init(&modal.nu_zx, "nu_zx"));
}
feenox_call(feenox_distribution_init(&modal.G_xy, "Gxy"));
if (modal.G_xy.defined == 0) {
feenox_call(feenox_distribution_init(&modal.G_xy, "G_xy"));
}
feenox_call(feenox_distribution_init(&modal.G_yz, "Gyz"));
if (modal.G_yz.defined == 0) {
feenox_call(feenox_distribution_init(&modal.G_yz, "G_yz"));
}
feenox_call(feenox_distribution_init(&modal.G_zx, "Gzx"));
if (modal.G_zx.defined == 0) {
feenox_call(feenox_distribution_init(&modal.G_zx, "G_zx"));
}
// check for consistency
int n_ortho = modal.E_x.defined + modal.E_y.defined + modal.E_z.defined +
modal.nu_xy.defined + modal.nu_yz.defined + modal.nu_zx.defined +
modal.G_xy.defined + modal.G_yz.defined + modal.G_zx.defined;
if (n_ortho > 0) {
if (modal.material_model == material_model_elastic_isotropic) {
feenox_push_error_message("both isotropic and orthotropic properties given, choose one");
return FEENOX_ERROR;
} else if (n_ortho < 9) {
feenox_push_error_message("%d orthotropic properties missing", 9-n_ortho);
return FEENOX_ERROR;
} else if (modal.material_model == material_model_unknown) {
modal.material_model = material_model_elastic_orthotropic;
}
}
// set material model virtual methods
switch (modal.material_model) {
case material_model_elastic_isotropic:
modal.uniform_C = ((modal.E.non_uniform == 0) && (modal.nu.non_uniform == 0));
if (modal.variant == variant_full) {
modal.compute_C = feenox_problem_build_compute_modal_C_elastic_isotropic;
} else if (modal.variant == variant_plane_stress) {
modal.compute_C = feenox_problem_build_compute_modal_C_elastic_plane_stress;
} else if (modal.variant == variant_plane_strain) {
modal.compute_C = feenox_problem_build_compute_modal_C_elastic_plane_strain;
}
break;
case material_model_elastic_orthotropic:
if (modal.variant != variant_full) {
feenox_push_error_message("elastic orthotropic materials cannot be used in plane stress/strain");
return FEENOX_ERROR;
}
modal.compute_C = feenox_problem_build_compute_modal_C_elastic_orthotropic;
break;
default:
feenox_push_error_message("unknown material model, usual way to go is to define E and nu");
return FEENOX_ERROR;
break;
}
// size of stress-strain matrix
if (modal.variant == variant_full) {
modal.stress_strain_size = 6;
} else if (modal.variant == variant_axisymmetric) {
modal.stress_strain_size = 4;
} else if (modal.variant == variant_plane_stress || modal.variant == variant_plane_strain) {
modal.stress_strain_size = 3;
} else {
feenox_push_error_message("internal mismatch, unknown variant");
return FEENOX_ERROR;
}
// allocate stress-strain objects
feenox_check_alloc(modal.C = gsl_matrix_calloc(modal.stress_strain_size, modal.stress_strain_size));
if (modal.uniform_C) {
// cache properties
feenox_call(modal.compute_C(NULL, NULL));
}
feenox.pde.math_type = math_type_eigen;
feenox.pde.solve = feenox_problem_solve_slepc_eigen;
feenox.pde.has_stiffness = 1;
feenox.pde.has_mass = 1;
feenox.pde.has_rhs = 0;
feenox.pde.has_jacobian_K = 0;
feenox.pde.has_jacobian_M = 0;
feenox.pde.has_jacobian_b = 0;
feenox.pde.has_jacobian = feenox.pde.has_jacobian_K || feenox.pde.has_jacobian_M || feenox.pde.has_jacobian_b;
feenox.pde.symmetric_K = 1;
feenox.pde.symmetric_M = 1;
#endif
return FEENOX_OK;
}
#ifdef HAVE_PETSC
int feenox_problem_setup_pc_modal(PC pc) {
PCType pc_type = NULL;
petsc_call(PCGetType(pc, &pc_type));
if (pc_type == NULL) {
// if we don't set the pc type here then we PCFactorSetMatSolverType does not work
// xxx LU?
petsc_call(PCSetType(pc, feenox.pde.symmetric_K ? PCCHOLESKY : PCLU));
#ifdef PETSC_HAVE_MUMPS
petsc_call(PCFactorSetMatSolverType(pc, MATSOLVERMUMPS));
#endif
}
petsc_call(PCGetType(pc, &pc_type));
if (strcmp(pc_type, PCGAMG) == 0) {
if (modal.rigid_body_base == NULL) {
feenox_problem_compute_rigid_nullspace(&modal.rigid_body_base);
}
petsc_call(MatSetNearNullSpace(feenox.pde.K, modal.rigid_body_base));
petsc_call(MatSetNearNullSpace(feenox.pde.M, modal.rigid_body_base));
}
return FEENOX_OK;
}
int feenox_problem_setup_ksp_modal(KSP ksp ) {
KSPType ksp_type = NULL;
petsc_call(KSPGetType(ksp, &ksp_type));
if (ksp_type == NULL) {
// if the user did not choose anything, we default to preonly + direct solver
petsc_call(KSPSetType(ksp, KSPPREONLY));
}
return FEENOX_OK;
}
#endif
#ifdef HAVE_SLEPC
// these two are not
int feenox_problem_setup_eps_modal(EPS eps) {
// to be able to solve free-body vibrations we have to set a deflation space
if (modal.has_dirichlet_bcs == 0) {
if (feenox.pde.eigen_formulation == eigen_formulation_undefined) {
feenox.pde.eigen_formulation = eigen_formulation_omega;
} else if (feenox.pde.eigen_formulation == eigen_formulation_lambda) {
feenox_push_error_message("free-free modal problems do not work with the lambda formulation");
return FEENOX_ERROR;
}
if (modal.rigid_body_base == NULL) {
feenox_problem_compute_rigid_nullspace(&modal.rigid_body_base);
}
// getvecs below needs a const vec pointer
PetscBool has_const;
PetscInt n;
const Vec *vecs;
Vec rigid[6];
petsc_call(MatNullSpaceGetVecs(modal.rigid_body_base, &has_const, &n, &vecs));
// but eps needs modifiable vectors so we copy them
for (unsigned int k = 0; k < n; k++) {
petsc_call(VecDuplicate(vecs[k], &rigid[k]));
petsc_call(VecCopy(vecs[k], rigid[k]));
}
petsc_call(EPSSetDeflationSpace(eps, n, rigid));
}
return FEENOX_OK;
}
#endif
feenox-1.2/src/pdes/modal/methods.h 0000664 0001750 0001750 00000005412 15055303016 012755 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for modal analysis: virtual methods
*
* Copyright (C) 2021--2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#ifndef MODAL_METHODS_H
#define MODAL_METHODS_H
// modal/parser.c
extern int feenox_problem_parse_problem_modal(const char *token);
extern int feenox_problem_parse_write_post_modal(mesh_write_t *mesh_write, const char *token);
// modal/init.c
extern int feenox_problem_parse_time_init_modal(void);
extern int feenox_problem_init_runtime_modal(void);
#ifdef HAVE_PETSC
extern int feenox_problem_setup_pc_modal(PC pc);
extern int feenox_problem_setup_ksp_modal(KSP ksp);
#endif
#ifdef HAVE_SLEPC
extern int feenox_problem_setup_eps_modal(EPS eps);
#endif
// modal/bulk.c
extern int feenox_problem_build_allocate_aux_modal(unsigned int J);
extern int feenox_problem_build_volumetric_gauss_point_modal(element_t *element, unsigned int q);
// modal/bc.c
extern int feenox_problem_bc_parse_modal(bc_data_t *bc_data, const char *lhs, char *rhs);
extern int feenox_problem_bc_set_modal_displacement(bc_data_t *bc_data, element_t *e, size_t j_global);
extern int feenox_problem_bc_set_modal_symmetry(bc_data_t *bc_data, element_t *e, size_t j_global);
extern int feenox_problem_bc_set_modal_radial(bc_data_t *bc_data, element_t *e, size_t j_global);
extern int feenox_problem_bc_set_modal_multifreedom(bc_data_t *bc_data, element_t *e, size_t j_global);
extern double feenox_modal_gsl_function_of_uvw(double x, void *params);
// material models
extern int feenox_problem_build_compute_modal_C_elastic_isotropic(const double *x, material_t *material);
extern int feenox_problem_build_compute_modal_C_elastic_plane_stress(const double *x, material_t *material);
extern int feenox_problem_build_compute_modal_C_elastic_plane_strain(const double *x, material_t *material);
extern int feenox_problem_build_compute_modal_C_elastic_orthotropic(const double *x, material_t *material);
// modal/post.c
extern int feenox_problem_solve_post_modal(void);
#endif
feenox-1.2/src/pdes/modal/modal.h 0000664 0001750 0001750 00000006133 15055303016 012407 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for modal analysis: global header
*
* Copyright (C) 2021 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#ifndef MODAL_H
#define MODAL_H
#define DEFAULT_MODAL_MODES 10
#define BC_TYPE_MECHANICAL_UNDEFINED 0
#define BC_TYPE_MECHANICAL_DISPLACEMENT 1
#define BC_TYPE_MECHANICAL_TANGENTIAL_SYMMETRY 2
#define BC_TYPE_MECHANICAL_RADIAL_SYMMETRY 3
#define BC_TYPE_MECHANICAL_MULTIDOF_EXPRESSION 4
typedef struct modal_t modal_t;
struct modal_t {
enum {
variant_full,
variant_plane_stress,
variant_plane_strain,
variant_axisymmetric,
} variant;
// TODO: have a "mixed" material model where each volume has its own model
enum {
material_model_unknown,
material_model_elastic_isotropic,
material_model_elastic_orthotropic,
} material_model;
int has_dirichlet_bcs;
distribution_t rho; // density
// isotropic properties
distribution_t E; // Young's modulus
distribution_t nu; // Poisson's ratio
// orthotropic properties
distribution_t E_x, E_y, E_z; // Young's moduli
distribution_t nu_xy, nu_yz, nu_zx; // Poisson's ratios
distribution_t G_xy, G_yz, G_zx; // Shear moduli
distribution_t alpha_x, alpha_y, alpha_z; // (mean) thermal expansion coefficient
int space_E;
int space_nu;
int space_rho;
// flags to speed up things
int uniform_C;
int constant_C;
int uniform_expansion;
int constant_expansion;
unsigned int n_nodes;
unsigned int stress_strain_size;
// holder for the rigid-body displacements
#ifdef HAVE_PETSC
MatNullSpace rigid_body_base;
#endif
int (*compute_C)(const double *x, material_t *material);
// auxiliary intermediate matrices
gsl_matrix *C; // stress-strain matrix, 6x6 for 3d
gsl_matrix *B; // strain-displacement matrix, 6x(3*n_nodes) for 3d
gsl_matrix *CB; // product of C times B, 6x(3*n_nodes) for 3d
gsl_vector *et; // thermal strain vector, size 6 for 3d
gsl_vector *Cet; // product of C times et, size 6 for 3d
var_t *M_T;
vector_t *f;
vector_t *omega;
vector_t *m;
vector_t *L;
vector_t *Gamma;
vector_t *mu;
vector_t *Mu;
// for implicit multi-dof BCs
var_t *displ_for_bc[3];
};
extern modal_t modal;
#endif /* MODAL_H */
feenox-1.2/src/pdes/modal/parser.c 0000664 0001750 0001750 00000005447 15055303016 012611 /*------------ -------------- -------- --- ----- --- -- - -
* FeenoX parser for modal-specific keywords
*
* Copyright (C) 2023 Jeremy Theler
*
* This file is part of FeenoX.
*
* FeenoX is free software: you can redistribute it and/or modify
* it under the terms "of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "../../parser/parser.h"
#include "modal.h"
int feenox_problem_parse_problem_modal(const char *token) {
///kw_pde+PROBLEM+detail * `modal` computes the natural mechanical frequencies and oscillation modes.
#ifndef HAVE_SLEPC
feenox_push_error_message("modal problems need a FeenoX binary linked against SLEPc.");
return FEENOX_ERROR;
#endif
if (token != NULL) {
if (strcasecmp(token, "plane_stress") == 0) {
modal.variant = variant_plane_stress;
} else if (strcasecmp(token, "plane_strain") == 0) {
modal.variant = variant_plane_strain;
} else {
feenox_push_error_message("undefined keyword '%s'", token);
return FEENOX_ERROR;
}
} else {
// if token is NULL we have to do the parse-time initialization
feenox_call(feenox_problem_parse_time_init_modal());
}
return FEENOX_OK;
}
int feenox_problem_parse_write_post_modal(mesh_write_t *mesh_write, const char *token) {
#ifdef HAVE_SLEPC
if (strcmp(token, "all") == 0) {
char *tokens[3] = {NULL, NULL, NULL};
for (unsigned int i = 0; i < feenox.pde.nev; i++) {
for (unsigned int g = 0; g < 3; g++) {
if (g < feenox.pde.dofs) {
if (asprintf(&tokens[g], "%s%d", feenox.pde.unknown_name[g], i+1) <= 0) {
return FEENOX_ERROR;
}
} else {
tokens[g] = strdup("0");
}
}
char *mode_name = NULL;
if (asprintf(&mode_name, "mode%d", i+1) <= 0) {
return FEENOX_ERROR;
}
feenox_call(feenox_add_post_field(mesh_write, 3, tokens, mode_name, field_location_nodes));
feenox_free(mode_name);
for (unsigned int g = 0; g < 3; g++) {
feenox_free(tokens[g]);
}
}
} else {
feenox_push_error_message("undefined keyword '%s' for modal WRITE_RESULTS", token);
return FEENOX_ERROR;
}
#endif
return FEENOX_OK;
}
feenox-1.2/src/pdes/modal/post.c 0000664 0001750 0001750 00000010675 15055303016 012301 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for modal analysis: post
*
* Copyright (C) 2021 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "modal.h"
int feenox_problem_solve_post_modal(void) {
#ifdef HAVE_SLEPC
if (modal.f->used || modal.omega->used) {
double omega = 0;
for (unsigned int i = 0; i < feenox.pde.nev; i++) {
if (feenox.pde.eigen_formulation == eigen_formulation_omega) {
omega = sqrt(feenox.pde.eigenvalue[i]);
} else {
omega = 1.0/sqrt(feenox.pde.eigenvalue[i]);
}
feenox_call(feenox_vector_set(modal.omega, i, omega));
// convert it to cycles per time
feenox_call(feenox_vector_set(modal.f, i, omega/(2*M_PI)));
}
}
if (modal.M_T->used ||
modal.m->used ||
modal.L->used ||
modal.Gamma->used ||
modal.mu->used ||
modal.Mu->used) {
Vec one = NULL;
petsc_call(VecDuplicate(feenox.pde.phi, &one));
petsc_call(VecSet(one, 1.0));
Vec Mone = NULL;
petsc_call(VecDuplicate(feenox.pde.phi, &Mone));
petsc_call(MatMult(feenox.pde.M, one, Mone));
// phi depends on i, so here we allocate but fill it below
Vec Mphi = NULL;
petsc_call(VecDuplicate(feenox.pde.phi, &Mphi));
// total mass (scalar)
PetscScalar oneMone = 0;
petsc_call(VecDot(one, Mone, &oneMone));
feenox_var_value(modal.M_T) = oneMone/(PetscScalar)feenox.pde.dofs;
// accumulator
PetscScalar Mu = 0;
// TODO: this is pretty inefficient
PetscScalar norm = 0;
PetscScalar mu = 0;
PetscScalar phiMphi = 0;
PetscScalar phiMone = 0;
PetscScalar Gamma = 0;
for (unsigned int i = 0; i < feenox.pde.nev; i++) {
// normalization works like this: first we normalize to max = 1
// so we can compare the scalar products with the mass matrix
// as a norm against 1'*M*1
petsc_call(VecNorm(feenox.pde.eigenvector[i], NORM_INFINITY, &norm));
petsc_call(VecScale(feenox.pde.eigenvector[i], 1.0/norm));
// now we compute the product M*phi which we are going to use
// below in 1'*M*phi and in phi'*M*phi
petsc_call(MatMult(feenox.pde.M, feenox.pde.eigenvector[i], Mphi));
// modal mass
petsc_call(VecDot(feenox.pde.eigenvector[i], Mphi, &phiMphi));
feenox_call(feenox_vector_set(modal.m, i, phiMphi));
// excitation factor
petsc_call(VecDot(feenox.pde.eigenvector[i], Mone, &phiMone));
feenox_call(feenox_vector_set(modal.L, i, phiMone));
// participacion factor
Gamma = phiMone/(feenox.pde.dofs * phiMphi);
feenox_call(feenox_vector_set(modal.Gamma, i, Gamma));
// effective mass
mu = gsl_pow_2(phiMone)/(oneMone * phiMphi);
feenox_call(feenox_vector_set(modal.mu, i, mu));
// accumulated effective mass
Mu += mu;
feenox_call(feenox_vector_set(modal.Mu, i, Mu));
// now we have to re-normalize the eigenvector such that the maximum displacement
// sqrt(u^2+v^2+w^2) is equal to one and then we multiply by the excitation factor Gamma
// TODO: parallel
PetscScalar norm = -1;
PetscScalar chi = 0;
PetscScalar xi = 0;
PetscInt index = 0;
for (size_t j = 0; j < feenox.pde.spatial_unknowns; j++) {
chi = 0;
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
index = feenox.pde.mesh->node[j].index_dof[g];
feenox_call(VecGetValues(feenox.pde.eigenvector[i], 1, &index, &xi));
chi += gsl_pow_2(xi);
}
if (chi > norm) {
norm = chi;
}
}
feenox_call(VecScale(feenox.pde.eigenvector[i], Gamma/sqrt(norm)));
}
}
#endif
return FEENOX_OK;
}
feenox-1.2/src/pdes/mechanical/ 0000775 0001750 0001750 00000000000 15055303133 012207 5 feenox-1.2/src/pdes/mechanical/bc.c 0000664 0001750 0001750 00000033671 15055303016 012671 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines to handle mechanical BCs
*
* Copyright (C) 2021-2025 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "mechanical.h"
int feenox_problem_bc_parse_mechanical(bc_data_t *bc_data, const char *lhs, char *rhs) {
// TODO: document BCs with triple comments
if (strcmp(lhs, "fixed") == 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_DISPLACEMENT;
bc_data->type_math = bc_type_math_dirichlet;
bc_data->set_essential = feenox_problem_bc_set_mechanical_displacement;
bc_data->dof = -1;
} else if ((strcmp(lhs, "u") == 0 || strcmp(lhs, "u_x") == 0) && strcmp(rhs, "") != 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_DISPLACEMENT;
bc_data->type_math = bc_type_math_dirichlet;
bc_data->set_essential = feenox_problem_bc_set_mechanical_displacement;
bc_data->dof = 0;
} else if ((strcmp(lhs, "v") == 0 || strcmp(lhs, "u_y") == 0) && strcmp(rhs, "") != 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_DISPLACEMENT;
bc_data->type_math = bc_type_math_dirichlet;
bc_data->set_essential = feenox_problem_bc_set_mechanical_displacement;
bc_data->dof = 1;
if (feenox.pde.dofs < 1) {
feenox_push_error_message("cannot set u (displacement in y) with DOFs < 2");
return FEENOX_ERROR;
}
} else if ((strcmp(lhs, "w") == 0 || strcmp(lhs, "u_z") == 0) && strcmp(rhs, "") != 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_DISPLACEMENT;
bc_data->type_math = bc_type_math_dirichlet;
bc_data->set_essential = feenox_problem_bc_set_mechanical_displacement;
bc_data->dof = 2;
if (feenox.pde.dofs < 2) {
feenox_push_error_message("cannot set w (displacement in z) with DOFs < 3");
return FEENOX_ERROR;
}
} else if (strcmp(lhs, "p") == 0 || strcmp(lhs, "compression") == 0 || strcmp(lhs, "pressure") == 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_PRESSURE_COMPRESSION;
bc_data->type_math = bc_type_math_neumann;
bc_data->set_natural = feenox_problem_bc_set_mechanical_compression;
} else if (strcmp(lhs, "t") == 0 || strcmp(lhs, "tension") == 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_PRESSURE_TENSION;
bc_data->type_math = bc_type_math_neumann;
bc_data->set_natural = feenox_problem_bc_set_mechanical_tension;
} else if (strcmp(lhs, "tx") == 0 || strcmp(lhs, "ty") == 0 || strcmp(lhs, "tz") == 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_TRACTION;
bc_data->type_math = bc_type_math_neumann;
bc_data->set_natural = feenox_problem_bc_set_mechanical_traction;
if (strcmp(lhs, "tx") == 0) {
bc_data->dof = 0;
} else if (strcmp(lhs, "ty") == 0) {
bc_data->dof = 1;
} else if (strcmp(lhs, "tz") == 0) {
bc_data->dof = 2;
}
} else if (strcmp(lhs, "Fx") == 0 || strcmp(lhs, "Fy") == 0 || strcmp(lhs, "Fz") == 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_FORCE;
bc_data->type_math = bc_type_math_neumann;
bc_data->set_natural = feenox_problem_bc_set_mechanical_force;
if (strcmp(lhs, "Fx") == 0) {
bc_data->dof = 0;
} else if (strcmp(lhs, "Fy") == 0) {
bc_data->dof = 1;
} else if (strcmp(lhs, "Fz") == 0) {
bc_data->dof = 2;
}
} else if (strcmp(lhs, "symmetry") == 0 || strcmp(lhs, "tangential") == 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_TANGENTIAL_SYMMETRY;
bc_data->type_math = bc_type_math_multifreedom;
bc_data->set_essential = feenox_problem_bc_set_mechanical_symmetry;
} else if (strcmp(lhs, "radial") == 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_RADIAL_SYMMETRY;
bc_data->type_math = bc_type_math_multifreedom;
bc_data->set_essential = feenox_problem_bc_set_mechanical_radial;
// TODO: x0, y0 and z0
} else if (strcmp(lhs, "0") == 0) {
bc_data->type_phys = BC_TYPE_MECHANICAL_MULTIDOF_EXPRESSION;
bc_data->type_math = bc_type_math_multifreedom;
bc_data->set_essential = feenox_problem_bc_set_mechanical_multifreedom;
// trick: the idea is that the user might write an expression of space
// x,y,z but also maybe of u,v y w. However, u,v,w are functinos and not variables!
// what we do is to define variables named U,V,W and string-replace u,v,w -> U,V,W
// in the entered expression
// TODO: there should be a separator (i.e. operator) before and after
char *s = rhs;
while (*s != '\0') {
if (*s == 'u') {
*s = 'U';
} else if (*s == 'v') {
*s = 'V';
} else if (*s == 'w') {
*s = 'W';
}
s++;
}
} else if (strcmp(rhs, "") != 0) {
feenox_push_error_message("unknown mechanical boundary condition '%s'", lhs);
return FEENOX_ERROR;
}
if (rhs != NULL && strcmp(rhs, "0") != 0) {
feenox_call(feenox_expression_parse(&bc_data->expr, rhs));
}
bc_data->space_dependent = feenox_depends_on_space(bc_data->expr.variables);
bc_data->nonlinear = feenox_depends_on_function(bc_data->expr.functions, feenox.pde.solution[0]);
if (feenox.pde.dofs > 1) {
bc_data->nonlinear |= feenox_depends_on_function(bc_data->expr.functions, feenox.pde.solution[1]);
if (feenox.pde.dofs > 2) {
bc_data->nonlinear |= feenox_depends_on_function(bc_data->expr.functions, feenox.pde.solution[2]);
}
}
if (bc_data->nonlinear && bc_data->type_math == bc_type_math_dirichlet) {
feenox_push_error_message("essential boundary condition '%s' cannot depend on the unknown", rhs);
return FEENOX_ERROR;
}
return FEENOX_OK;
}
int feenox_problem_bc_set_mechanical_displacement(bc_data_t *this, element_t *e, size_t j_global) {
#ifdef HAVE_PETSC
if (this->dof != -1) {
// only one dof
feenox_call(feenox_problem_dirichlet_add(j_global, this->dof, feenox_expression_eval(&this->expr)));
} else {
// -1 means all dofs (and the only possibility is to have all them equal to zero)
feenox_call(feenox_problem_dirichlet_add(j_global, 0, 0));
if (feenox.pde.dofs > 1) {
feenox_call(feenox_problem_dirichlet_add(j_global, 1, 0));
if (feenox.pde.dofs > 2) {
feenox_call(feenox_problem_dirichlet_add(j_global, 2, 0));
}
}
}
#endif
return FEENOX_OK;
}
int feenox_problem_bc_set_mechanical_symmetry(bc_data_t *this, element_t *e, size_t j_global) {
#ifdef HAVE_PETSC
// outward normal (smoothed over all elements on the physical group of the BC)
// TODO: choose to smooth or to use the local one
PetscScalar normal[3] = {0, 0, 0};
PetscScalar n_element[3] = {0, 0, 0};
element_ll_t *element_item = NULL;
LL_FOREACH(feenox.pde.mesh->node[j_global].element_list, element_item) {
element_t *e_prime = element_item->element;
if (e_prime != NULL && e_prime->type->dim == (feenox.pde.dim-1) && e_prime->physical_group == e->physical_group) {
feenox_call(feenox_mesh_compute_outward_normal(element_item->element, n_element));
normal[0] += n_element[0];
normal[1] += n_element[1];
normal[2] += n_element[2];
}
}
int coordinate_direction = -1;
double norm = gsl_hypot3(normal[0], normal[1], normal[2]);
if (feenox_likely(norm != 0)) {
// if the outward normal coincides with one of the three axes, we can get away with a regular dirichlet BC
for (int g = 0; g < 3; g++) {
normal[g] /= norm;
if (fabs(normal[g]) > (1-1e-4)) {
coordinate_direction = g;
}
}
} else {
feenox_push_error_message("outward normal has zero norm");
return FEENOX_ERROR;
}
// if the condition results in a direction normal to one of the three coordinate planes
// then we set a traditional dirichlet bc (i.e. u=0 or v=0 or w=0)
// otherwise we need a generic multifreedom
if (coordinate_direction != -1) {
feenox_call(feenox_problem_dirichlet_add(j_global, coordinate_direction, 0));
} else {
feenox_call(feenox_problem_multifreedom_add(j_global, normal));
}
#endif
return FEENOX_OK;
}
int feenox_problem_bc_set_mechanical_radial(bc_data_t *this, element_t *e, size_t j_global) {
#ifdef HAVE_PETSC
double x[3] = {0,0,0};
double eps = 1e-2;
if (e->physical_group->volume == 0) {
feenox_call(feenox_physical_group_compute_volume(e->physical_group, feenox.pde.mesh));
}
// TODO! read center of the radial condition
for (int g = 0; g < 3; g++) {
// x[g] = feenox.pde.mesh->node[node_global_index].x[g] - ((bc_data->expr[g].items == NULL) ? element->physical_entity->cog[d] : feenox_expression_eval(bc_data->expr[g]));
x[g] = feenox.pde.mesh->node[j_global].x[g] - e->physical_group->cog[g];
}
double coefficients[3] = {0,0,0};
// x-y
if (fabs(x[0]) > eps && fabs(x[1]) > eps) {
coefficients[0] = +x[1];
coefficients[1] = -x[0];
coefficients[2] = 0;
feenox_call(feenox_problem_multifreedom_add(j_global, coefficients));
}
// x-z
if (fabs(x[0]) > eps && fabs(x[2]) > eps) {
coefficients[0] = +x[2];
coefficients[1] = 0;
coefficients[2] = -x[0];
feenox_call(feenox_problem_multifreedom_add(j_global, coefficients));
}
// y-z
if (fabs(x[1]) > eps && fabs(x[2]) > eps) {
coefficients[0] = 0;
coefficients[1] = +x[2];
coefficients[2] = -x[1];
feenox_call(feenox_problem_multifreedom_add(j_global, coefficients));
}
#endif
return FEENOX_OK;
}
typedef struct {
expr_t *expr;
int dof;
} feenox_gsl_function_of_uvw_params_t;
int feenox_problem_bc_set_mechanical_multifreedom(bc_data_t *this, element_t *e, size_t j_global) {
#ifdef HAVE_PETSC
feenox_gsl_function_of_uvw_params_t params = { &this->expr, -1 };
gsl_function F = {feenox_mechanical_gsl_function_of_uvw, ¶ms};
double coefficients[3] = {0, 0, 0};
// TODO: choose
double h = 1e-5;
double result = 0;
double abserr = 0;
for (int g = 0; g < 3; g++) {
params.dof = g;
gsl_deriv_central(&F, 0, h, &result, &abserr);
coefficients[g] = -result;
}
// TODO: non-homogeneous RHS
feenox_call(feenox_problem_multifreedom_add(j_global, coefficients));
#endif
return FEENOX_OK;
}
int feenox_problem_bc_set_mechanical_tension(bc_data_t *this, element_t *e, unsigned int q) {
feenox_call(feenox_problem_bc_set_mechanical_normal_stress(this, e, q, +1));
return FEENOX_OK;
}
int feenox_problem_bc_set_mechanical_compression(bc_data_t *this, element_t *e, unsigned int q) {
feenox_call(feenox_problem_bc_set_mechanical_normal_stress(this, e, q, -1));
return FEENOX_OK;
}
// this virtual method builds the surface elemental matrix
int feenox_problem_bc_set_mechanical_normal_stress(bc_data_t *this, element_t *e, unsigned int q, signed int sign) {
// maybe this check can be made on the dimension of the physical entity at parse time
if ((feenox.pde.dim - e->type->dim) != 1) {
feenox_push_error_message("pressure BCs can only be applied to surfaces");
return FEENOX_ERROR;
}
#ifdef HAVE_PETSC
// outward normal
double n[3];
feenox_call(feenox_mesh_compute_outward_normal(e, n));
// TODO: cache if not space dependent
feenox_fem_compute_x_at_gauss_if_needed_and_update_var(e, q, feenox.pde.mesh->integration, this->space_dependent);
double p = feenox_expression_eval(&this->expr);
// remember that here p > 0 means compression
double t[3];
for (unsigned int g = 0; g < feenox.pde.dim; g++) {
t[g] = sign * p * n[g];
}
//feenox_call(feenox_problem_bc_natural_set(e, v, t));
feenox_call(feenox_problem_rhs_add(e, q, t));
#endif
return FEENOX_OK;
}
int feenox_problem_bc_set_mechanical_traction(bc_data_t *this, element_t *e, unsigned int q) {
#ifdef HAVE_PETSC
// TODO: cache if not space dependent
// TODO: have different functions, one for space and one for constant?
feenox_fem_compute_x_at_gauss_if_needed_and_update_var(e, q, feenox.pde.mesh->integration, this->space_dependent);
// TODO: set all the DOFs at the same time
double t[3] = {0,0,0};
// TODO: wrap feenox_expression_eval() with virtual methods according to the dependence of the bc
t[this->dof] = feenox_expression_eval(&this->expr);
// printf("%g\n", t[bc_data->dof]);
// feenox_call(feenox_problem_bc_natural_set(e, v, t));
feenox_call(feenox_problem_rhs_add(e, q, t));
#endif
return FEENOX_OK;
}
int feenox_problem_bc_set_mechanical_force(bc_data_t *this, element_t *e, unsigned int q) {
#ifdef HAVE_PETSC
// TODO: cache if not space dependent
feenox_fem_compute_x_at_gauss_if_needed_and_update_var(e, q, feenox.pde.mesh->integration, this->space_dependent);
// TODO: set all the DOFs at the same time
double t[3] = {0,0,0};
if (e->physical_group->volume == 0) {
feenox_call(feenox_physical_group_compute_volume(e->physical_group, feenox.pde.mesh));
}
t[this->dof] = feenox_expression_eval(&this->expr) / e->physical_group->volume;
feenox_call(feenox_problem_rhs_add(e, q, t));
#endif
return FEENOX_OK;
}
// wrapper to compute derivatives with GSL
double feenox_mechanical_gsl_function_of_uvw(double x, void *params) {
feenox_gsl_function_of_uvw_params_t *p = (feenox_gsl_function_of_uvw_params_t *)params;
feenox_var_value(mechanical.displ_for_bc[0]) = 0;
feenox_var_value(mechanical.displ_for_bc[1]) = 0;
feenox_var_value(mechanical.displ_for_bc[2]) = 0;
feenox_var_value(mechanical.displ_for_bc[p->dof]) = x;
double y = feenox_expression_eval(p->expr);
if (gsl_isnan(y) || gsl_isinf(y)) {
feenox_nan_error();
}
return y;
}
feenox-1.2/src/pdes/mechanical/bulk.c 0000664 0001750 0001750 00000040317 15055303016 013235 /*------------ -------------- -------- --- ----- --- -- - -
* feenox routines to build elemental mechanical objects
*
* Copyright (C) 2021--2025 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "mechanical.h"
int feenox_problem_build_allocate_aux_mechanical(unsigned int n_nodes) {
mechanical.n_nodes = n_nodes;
// matrix with the shape functions
if (mechanical.B_shape != NULL) {
gsl_matrix_free(mechanical.B_shape);
}
feenox_check_alloc(mechanical.B_shape = gsl_matrix_calloc(mechanical.stress_strain_size, feenox.pde.dofs * mechanical.n_nodes));
// this is a temporary holder to compute things like BtCB
if (mechanical.CB != NULL) {
gsl_matrix_free(mechanical.CB);
}
feenox_check_alloc(mechanical.CB = gsl_matrix_calloc(mechanical.stress_strain_size, feenox.pde.dofs * mechanical.n_nodes));
// --- non-linear stuff ------------------
if (feenox.pde.math_type == math_type_nonlinear) {
// matrix with shape derivatives for jacobian
if (mechanical.G != NULL) {
gsl_matrix_free(mechanical.G);
}
feenox_check_alloc(mechanical.G = gsl_matrix_calloc(feenox.pde.dofs*feenox.pde.dofs, feenox.pde.dofs * mechanical.n_nodes));
// 9x9 expansion of stresses for jacobian
if (mechanical.Sigma != NULL) {
gsl_matrix_free(mechanical.Sigma);
}
feenox_check_alloc(mechanical.Sigma = gsl_matrix_calloc(feenox.pde.dofs*feenox.pde.dofs, feenox.pde.dofs*feenox.pde.dofs));
// temporary holder to compute GtSigmaG
if (mechanical.SigmaG != NULL) {
gsl_matrix_free(mechanical.SigmaG);
}
feenox_check_alloc(mechanical.SigmaG = gsl_matrix_calloc(feenox.pde.dofs*feenox.pde.dofs, feenox.pde.dofs * mechanical.n_nodes));
if (mechanical.grad_u == NULL) {
// 3x3 identity (the symbol I is already taken by complex.h)
feenox_check_alloc(mechanical.eye = gsl_matrix_alloc(feenox.pde.dofs, feenox.pde.dofs));
gsl_matrix_set_identity(mechanical.eye);
// displacement gradient
feenox_check_alloc(mechanical.grad_u = gsl_matrix_calloc(feenox.pde.dofs, feenox.pde.dofs));
// deformation gradient
feenox_check_alloc(mechanical.F = gsl_matrix_calloc(feenox.pde.dofs, feenox.pde.dofs));
feenox_check_alloc(mechanical.F_inv = gsl_matrix_calloc(feenox.pde.dofs, feenox.pde.dofs));
// strains
feenox_check_alloc(mechanical.eps = gsl_matrix_calloc(feenox.pde.dofs, feenox.pde.dofs));
feenox_check_alloc(mechanical.B = gsl_matrix_calloc(feenox.pde.dofs, feenox.pde.dofs));
feenox_check_alloc(mechanical.C = gsl_matrix_calloc(feenox.pde.dofs, feenox.pde.dofs));
feenox_check_alloc(mechanical.C_inv = gsl_matrix_calloc(feenox.pde.dofs, feenox.pde.dofs));
// stresses
// feenox_check_alloc(mechanical.PK1 = gsl_matrix_calloc(feenox.pde.dofs, feenox.pde.dofs));
feenox_check_alloc(mechanical.PK2 = gsl_matrix_calloc(feenox.pde.dofs, feenox.pde.dofs));
feenox_check_alloc(mechanical.PK2_voigt = gsl_vector_calloc(mechanical.stress_strain_size));
feenox_check_alloc(mechanical.cauchy = gsl_matrix_calloc(feenox.pde.dofs, feenox.pde.dofs));
}
}
return FEENOX_OK;
}
int feenox_problem_build_volumetric_forces(element_t *e, unsigned int q, double wdet, double *x) {
// volumetric force densities in the reference configuration
if (mechanical.f_x.defined || mechanical.f_y.defined || mechanical.f_z.defined) {
if (x == NULL) {
x = feenox_fem_compute_x_at_gauss(e, q, feenox.pde.mesh->integration);
}
material_t *material = feenox_fem_get_material(e);
gsl_matrix *H = feenox_fem_compute_H_c_at_gauss(e, q, feenox.pde.mesh->integration);
double f_x = mechanical.f_x.eval(&mechanical.f_x, x, material);
double f_y = mechanical.f_y.eval(&mechanical.f_y, x, material);
double f_z = mechanical.f_z.eval(&mechanical.f_z, x, material);
for (int j = 0; j < e->type->nodes; j++) {
int offset = feenox.pde.dofs*j;
// TODO: matrix-vector product
double wh = wdet * gsl_matrix_get(H, 0, j);
if (mechanical.f_x.defined) {
gsl_vector_add_to_element(feenox.fem.bi, offset+0, wh * f_x);
}
if (mechanical.f_y.defined) {
gsl_vector_add_to_element(feenox.fem.bi, offset+1, wh * f_y);
}
if (mechanical.f_z.defined) {
gsl_vector_add_to_element(feenox.fem.bi, offset+2, wh * f_z);
}
}
}
return FEENOX_OK;
}
// linear small deformation
int feenox_problem_build_volumetric_gauss_point_mechanical(element_t *e, unsigned int q) {
#ifdef HAVE_PETSC
double *x = NULL;
if (mechanical.uniform_properties == 0) {
// material stress-strain relationship
x = feenox_fem_compute_x_at_gauss(e, q, feenox.pde.mesh->integration);
feenox_call(mechanical.compute_material_tangent(x, feenox_fem_get_material(e)));
}
gsl_matrix *dhdx = feenox_fem_compute_B_at_gauss_integration(e, q, feenox.pde.mesh->integration);
for (unsigned int j = 0; j < mechanical.n_nodes; j++) {
// TODO: virtual methods? they cannot be inlined...
if (mechanical.variant == variant_full) {
gsl_matrix_set(mechanical.B_shape, 0, 3*j+0, gsl_matrix_get(dhdx, 0, j));
gsl_matrix_set(mechanical.B_shape, 1, 3*j+1, gsl_matrix_get(dhdx, 1, j));
gsl_matrix_set(mechanical.B_shape, 2, 3*j+2, gsl_matrix_get(dhdx, 2, j));
gsl_matrix_set(mechanical.B_shape, 3, 3*j+0, gsl_matrix_get(dhdx, 1, j));
gsl_matrix_set(mechanical.B_shape, 3, 3*j+1, gsl_matrix_get(dhdx, 0, j));
gsl_matrix_set(mechanical.B_shape, 4, 3*j+1, gsl_matrix_get(dhdx, 2, j));
gsl_matrix_set(mechanical.B_shape, 4, 3*j+2, gsl_matrix_get(dhdx, 1, j));
gsl_matrix_set(mechanical.B_shape, 5, 3*j+0, gsl_matrix_get(dhdx, 2, j));
gsl_matrix_set(mechanical.B_shape, 5, 3*j+2, gsl_matrix_get(dhdx, 0, j));
} else if (mechanical.variant == variant_axisymmetric) {
feenox_push_error_message("axisymmetric still not implemented");
return FEENOX_ERROR;
} else if (mechanical.variant == variant_plane_stress || mechanical.variant == variant_plane_strain) {
// plane stress and plane strain are the same
// see equation 14.18 IFEM CH.14 sec 14.4.1 pag 14-11
gsl_matrix_set(mechanical.B_shape, 0, 2*j+0, gsl_matrix_get(dhdx, 0, j));
gsl_matrix_set(mechanical.B_shape, 1, 2*j+1, gsl_matrix_get(dhdx, 1, j));
gsl_matrix_set(mechanical.B_shape, 2, 2*j+0, gsl_matrix_get(dhdx, 1, j));
gsl_matrix_set(mechanical.B_shape, 2, 2*j+1, gsl_matrix_get(dhdx, 0, j));
} else {
return FEENOX_ERROR;
}
}
// wdet
double wdet = feenox_fem_compute_w_det_at_gauss_integration(e, q, feenox.pde.mesh->integration);
// volumetric forces
// TODO: this is wrong! if the forces depend on x we have to evaluate it
feenox_call(feenox_problem_build_volumetric_forces(e, q, wdet, x));
// elemental stiffness B'*C*B
feenox_call(feenox_blas_BtCB_accum(mechanical.B_shape, mechanical.C_tangent, mechanical.CB, wdet, feenox.fem.Ki));
// thermal expansion strain vector
if (mechanical.thermal_expansion_model != thermal_expansion_model_none) {
if (x == NULL) {
x = feenox_fem_compute_x_at_gauss(e, q, feenox.pde.mesh->integration);
}
mechanical.et = mechanical.compute_thermal_strain(x, feenox_fem_get_material(e));
feenox_call(feenox_blas_Atb(mechanical.C_tangent, mechanical.et, 1.0, mechanical.Cet));
feenox_call(feenox_blas_Atb_accum(mechanical.B_shape, mechanical.Cet, wdet, feenox.fem.bi));
}
#endif
return FEENOX_OK;
}
// nonlinear large deformation
int feenox_problem_build_volumetric_gauss_point_mechanical_nonlinear(element_t *e, unsigned int q) {
#ifdef HAVE_PETSC
// compute the derivatives of the shape function at the q-th integration point
gsl_matrix *dhdx = feenox_fem_compute_B_at_gauss_integration(e, q, feenox.pde.mesh->integration);
// gradient of the displacements out of the elemental solution phi
mechanical.grad_u = feenox_problem_mechanical_compute_gradient_displacement(dhdx, feenox.fem.phii);
// TODO: these three are repeated in gradient, should we make a function for them?
// deformation gradient
mechanical.F = feenox_problem_mechanical_compute_gradient_deformation(mechanical.grad_u);
// right cauchy-green stress tensor
mechanical.C = feenox_problem_mechanical_compute_strain_cauchy_green_left(mechanical.F);
// green-lagrange strain tensor
mechanical.eps = feenox_problem_mechanical_compute_strain_green_lagrange(mechanical.C);
// each material now has to compute the second piola kirchoff stress tensor
double *x = feenox_fem_compute_x_at_gauss(e, q, feenox.pde.mesh->integration);
material_t *material = feenox_fem_get_material(e);
mechanical.PK2 = mechanical.compute_PK2(x, material);
// residual = B^T*PK_voigt
// material stiffness = B^T*C*B
// geometric stiffness = G^T*S*G
// individual stresses from PK2
double Sxx = gsl_matrix_get(mechanical.PK2, 0, 0);
double Syy = gsl_matrix_get(mechanical.PK2, 1, 1);
double Szz = gsl_matrix_get(mechanical.PK2, 2, 2);
double Sxy = gsl_matrix_get(mechanical.PK2, 0, 1);
double Syz = gsl_matrix_get(mechanical.PK2, 1, 2);
double Szx = gsl_matrix_get(mechanical.PK2, 2, 0);
// here voigt is not Landau's lexicographical but the cyclic ordering
gsl_vector_set(mechanical.PK2_voigt, 0, Sxx);
gsl_vector_set(mechanical.PK2_voigt, 1, Syy);
gsl_vector_set(mechanical.PK2_voigt, 2, Szz);
gsl_vector_set(mechanical.PK2_voigt, 3, Sxy);
gsl_vector_set(mechanical.PK2_voigt, 4, Syz);
gsl_vector_set(mechanical.PK2_voigt, 5, Szx);
// the 9x9 Sigma matrix
// row 1
gsl_matrix_set(mechanical.Sigma, 0, 0, Sxx);
gsl_matrix_set(mechanical.Sigma, 1, 1, Sxx);
gsl_matrix_set(mechanical.Sigma, 2, 2, Sxx);
gsl_matrix_set(mechanical.Sigma, 0, 3, Sxy);
gsl_matrix_set(mechanical.Sigma, 1, 4, Sxy);
gsl_matrix_set(mechanical.Sigma, 2, 5, Sxy);
gsl_matrix_set(mechanical.Sigma, 0, 6, Szx);
gsl_matrix_set(mechanical.Sigma, 1, 7, Szx);
gsl_matrix_set(mechanical.Sigma, 2, 8, Szx);
// row 2
gsl_matrix_set(mechanical.Sigma, 3, 0, Sxy);
gsl_matrix_set(mechanical.Sigma, 4, 1, Sxy);
gsl_matrix_set(mechanical.Sigma, 5, 2, Sxy);
gsl_matrix_set(mechanical.Sigma, 3, 3, Syy);
gsl_matrix_set(mechanical.Sigma, 4, 4, Syy);
gsl_matrix_set(mechanical.Sigma, 5, 5, Syy);
gsl_matrix_set(mechanical.Sigma, 3, 6, Syz);
gsl_matrix_set(mechanical.Sigma, 4, 7, Syz);
gsl_matrix_set(mechanical.Sigma, 5, 8, Syz);
// row 3
gsl_matrix_set(mechanical.Sigma, 6, 0, Szx);
gsl_matrix_set(mechanical.Sigma, 7, 1, Szx);
gsl_matrix_set(mechanical.Sigma, 8, 2, Szx);
gsl_matrix_set(mechanical.Sigma, 6, 3, Syz);
gsl_matrix_set(mechanical.Sigma, 7, 4, Syz);
gsl_matrix_set(mechanical.Sigma, 8, 5, Syz);
gsl_matrix_set(mechanical.Sigma, 6, 6, Szz);
gsl_matrix_set(mechanical.Sigma, 7, 7, Szz);
gsl_matrix_set(mechanical.Sigma, 8, 8, Szz);
for (unsigned int j = 0; j < mechanical.n_nodes; j++) {
// the non-linear B matrix with the shape functions
gsl_matrix_set(mechanical.B_shape, 0, 3*j+0, gsl_matrix_get(dhdx, 0, j) * gsl_matrix_get(mechanical.F, 0, 0));
gsl_matrix_set(mechanical.B_shape, 0, 3*j+1, gsl_matrix_get(dhdx, 0, j) * gsl_matrix_get(mechanical.F, 1, 0));
gsl_matrix_set(mechanical.B_shape, 0, 3*j+2, gsl_matrix_get(dhdx, 0, j) * gsl_matrix_get(mechanical.F, 2, 0));
gsl_matrix_set(mechanical.B_shape, 1, 3*j+0, gsl_matrix_get(dhdx, 1, j) * gsl_matrix_get(mechanical.F, 0, 1));
gsl_matrix_set(mechanical.B_shape, 1, 3*j+1, gsl_matrix_get(dhdx, 1, j) * gsl_matrix_get(mechanical.F, 1, 1));
gsl_matrix_set(mechanical.B_shape, 1, 3*j+2, gsl_matrix_get(dhdx, 1, j) * gsl_matrix_get(mechanical.F, 2, 1));
gsl_matrix_set(mechanical.B_shape, 2, 3*j+0, gsl_matrix_get(dhdx, 2, j) * gsl_matrix_get(mechanical.F, 0, 2));
gsl_matrix_set(mechanical.B_shape, 2, 3*j+1, gsl_matrix_get(dhdx, 2, j) * gsl_matrix_get(mechanical.F, 1, 2));
gsl_matrix_set(mechanical.B_shape, 2, 3*j+2, gsl_matrix_get(dhdx, 2, j) * gsl_matrix_get(mechanical.F, 2, 2));
gsl_matrix_set(mechanical.B_shape, 3, 3*j+0, gsl_matrix_get(dhdx, 1, j) * gsl_matrix_get(mechanical.F, 0, 0) + gsl_matrix_get(dhdx, 0, j) * gsl_matrix_get(mechanical.F, 0, 1));
gsl_matrix_set(mechanical.B_shape, 3, 3*j+1, gsl_matrix_get(dhdx, 1, j) * gsl_matrix_get(mechanical.F, 1, 0) + gsl_matrix_get(dhdx, 0, j) * gsl_matrix_get(mechanical.F, 1, 1));
gsl_matrix_set(mechanical.B_shape, 3, 3*j+2, gsl_matrix_get(dhdx, 1, j) * gsl_matrix_get(mechanical.F, 2, 0) + gsl_matrix_get(dhdx, 0, j) * gsl_matrix_get(mechanical.F, 2, 1));
gsl_matrix_set(mechanical.B_shape, 4, 3*j+0, gsl_matrix_get(dhdx, 2, j) * gsl_matrix_get(mechanical.F, 0, 1) + gsl_matrix_get(dhdx, 1, j) * gsl_matrix_get(mechanical.F, 0, 2));
gsl_matrix_set(mechanical.B_shape, 4, 3*j+1, gsl_matrix_get(dhdx, 2, j) * gsl_matrix_get(mechanical.F, 1, 1) + gsl_matrix_get(dhdx, 1, j) * gsl_matrix_get(mechanical.F, 1, 2));
gsl_matrix_set(mechanical.B_shape, 4, 3*j+2, gsl_matrix_get(dhdx, 2, j) * gsl_matrix_get(mechanical.F, 2, 1) + gsl_matrix_get(dhdx, 1, j) * gsl_matrix_get(mechanical.F, 2, 2));
gsl_matrix_set(mechanical.B_shape, 5, 3*j+0, gsl_matrix_get(dhdx, 2, j) * gsl_matrix_get(mechanical.F, 0, 0) + gsl_matrix_get(dhdx, 0, j) * gsl_matrix_get(mechanical.F, 0, 2));
gsl_matrix_set(mechanical.B_shape, 5, 3*j+1, gsl_matrix_get(dhdx, 2, j) * gsl_matrix_get(mechanical.F, 1, 0) + gsl_matrix_get(dhdx, 0, j) * gsl_matrix_get(mechanical.F, 1, 2));
gsl_matrix_set(mechanical.B_shape, 5, 3*j+2, gsl_matrix_get(dhdx, 2, j) * gsl_matrix_get(mechanical.F, 2, 0) + gsl_matrix_get(dhdx, 0, j) * gsl_matrix_get(mechanical.F, 2, 2));
// the matrix of shape function derivatives G
gsl_matrix_set(mechanical.G, 0, 3*j+0, gsl_matrix_get(dhdx, 0, j));
gsl_matrix_set(mechanical.G, 1, 3*j+1, gsl_matrix_get(dhdx, 0, j));
gsl_matrix_set(mechanical.G, 2, 3*j+2, gsl_matrix_get(dhdx, 0, j));
gsl_matrix_set(mechanical.G, 3, 3*j+0, gsl_matrix_get(dhdx, 1, j));
gsl_matrix_set(mechanical.G, 4, 3*j+1, gsl_matrix_get(dhdx, 1, j));
gsl_matrix_set(mechanical.G, 5, 3*j+2, gsl_matrix_get(dhdx, 1, j));
gsl_matrix_set(mechanical.G, 6, 3*j+0, gsl_matrix_get(dhdx, 2, j));
gsl_matrix_set(mechanical.G, 7, 3*j+1, gsl_matrix_get(dhdx, 2, j));
gsl_matrix_set(mechanical.G, 8, 3*j+2, gsl_matrix_get(dhdx, 2, j));
}
// wdet
double wdet = feenox_fem_compute_w_det_at_gauss_integration(e, q, feenox.pde.mesh->integration);
// external volumetric forces
feenox_call(feenox_problem_build_volumetric_forces(e, q, wdet, x));
// internal non-linear force
feenox_call(feenox_blas_Atb_accum(mechanical.B_shape, mechanical.PK2_voigt, wdet, feenox.fem.fi));
// elemental stiffness B'*C*B
feenox_call(feenox_blas_BtCB_accum(mechanical.B_shape, mechanical.C_tangent, mechanical.CB, wdet, feenox.fem.Ki));
// elemental geometric stiffness G'*S*G
feenox_call(feenox_blas_BtCB_accum(mechanical.G, mechanical.Sigma, mechanical.SigmaG, wdet, feenox.fem.JKi));
//#define VERBOSE
#ifdef VERBOSE
printf("B\n");
feenox_debug_print_gsl_matrix(mechanical.B_shape, stdout);
printf("C\n");
feenox_debug_print_gsl_matrix(mechanical.C_tangent, stdout);
printf("K\n");
feenox_debug_print_gsl_matrix(feenox.fem.Ki, stdout);
printf("G\n");
feenox_debug_print_gsl_matrix(mechanical.G, stdout);
printf("Sigma\n");
feenox_debug_print_gsl_matrix(mechanical.Sigma, stdout);
printf("JK\n");
feenox_debug_print_gsl_matrix(feenox.fem.JKi, stdout);
#endif
#endif
return FEENOX_OK;
}
feenox-1.2/src/pdes/mechanical/gradient.c 0000664 0001750 0001750 00000025007 15055303016 014074 /*------------ -------------- -------- --- ----- --- -- - -
* feenox routines to compute gradient-realated fields
*
* Copyright (C) 2021-2025 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "mechanical.h"
#define FLUX_SIGMAX 0
#define FLUX_SIGMAY 1
#define FLUX_SIGMAZ 2
#define FLUX_TAUXY 3
#define FLUX_TAUYZ 4
#define FLUX_TAUZX 5
#define FLUX_EXX 6
#define FLUX_EYY 7
#define FLUX_EZZ 8
#define FLUX_EXY 9
#define FLUX_EYZ 10
#define FLUX_EZX 11
#define FLUX_SIZE 12
int feenox_problem_gradient_fill_mechanical(void) {
feenox_problem_fill_aux_solution(mechanical.exx);
feenox_problem_fill_aux_solution(mechanical.eyy);
feenox_problem_fill_aux_solution(mechanical.exy);
if (feenox.pde.dofs == 3) {
feenox_problem_fill_aux_solution(mechanical.ezz);
feenox_problem_fill_aux_solution(mechanical.eyz);
feenox_problem_fill_aux_solution(mechanical.ezx);
}
feenox_problem_fill_aux_solution(mechanical.sigmax);
feenox_problem_fill_aux_solution(mechanical.sigmay);
feenox_problem_fill_aux_solution(mechanical.tauxy);
if (feenox.pde.dofs == 3) {
feenox_problem_fill_aux_solution(mechanical.sigmaz);
feenox_problem_fill_aux_solution(mechanical.tauyz);
feenox_problem_fill_aux_solution(mechanical.tauzx);
}
// if one is used, all of them are
if (mechanical.sigma1->used || mechanical.sigma2->used || mechanical.sigma3->used) {
feenox_problem_fill_aux_solution(mechanical.sigma1);
feenox_problem_fill_aux_solution(mechanical.sigma2);
feenox_problem_fill_aux_solution(mechanical.sigma3);
}
if (mechanical.sigma->used) {
feenox_problem_fill_aux_solution(mechanical.sigma);
}
if (mechanical.tresca->used) {
feenox_problem_fill_aux_solution(mechanical.tresca);
}
return FEENOX_OK;
}
// used only in rough
int feenox_problem_gradient_properties_at_element_nodes_mechanical(element_t *element, mesh_t *mesh) {
return FEENOX_OK;
}
int feenox_problem_gradient_fluxes_at_node_alloc_mechanical(node_t *node) {
if (node->flux == NULL) {
feenox_check_alloc(node->flux = calloc(FLUX_SIZE, sizeof(double)));
} else {
for (int m = 0; m < FLUX_SIZE; m++) {
node->flux[m] = 0;
}
}
return FEENOX_OK;
}
int feenox_problem_gradient_add_elemental_contribution_to_node_mechanical(node_t *node, element_t *element, unsigned int j, double rel_weight) {
double exx = 0;
double eyy = 0;
double ezz = 0;
double exy = 0;
double eyz = 0;
double ezx = 0;
double sigmax = 0;
double sigmay = 0;
double sigmaz = 0;
double tauxy = 0;
double tauyz = 0;
double tauzx = 0;
if (mechanical.nonlinear_material == 0 && mechanical.nonlinear_geom == 0) {
exx = gsl_matrix_get(element->dphidx_node[j], 0, 0);
eyy = gsl_matrix_get(element->dphidx_node[j], 1, 1);
ezz = (feenox.pde.dofs == 3) ? gsl_matrix_get(element->dphidx_node[j], 2, 2) : 0;
double gammaxy = gsl_matrix_get(element->dphidx_node[j], 0, 1) + gsl_matrix_get(element->dphidx_node[j], 1, 0);
double gammayz = 0;
double gammazx = 0;
if (feenox.pde.dofs == 3) {
gammayz = gsl_matrix_get(element->dphidx_node[j], 1, 2) + gsl_matrix_get(element->dphidx_node[j], 2, 1);
gammazx = gsl_matrix_get(element->dphidx_node[j], 2, 0) + gsl_matrix_get(element->dphidx_node[j], 0, 2);
}
exy = 0.5 * gammaxy;
eyz = 0.5 * gammayz;
ezx = 0.5 * gammazx;
feenox_call(mechanical.compute_stress_from_strain(node, element, j,
exx, eyy, ezz, gammaxy, gammayz, gammazx,
&sigmax, &sigmay, &sigmaz, &tauxy, &tauyz, &tauzx));
} else {
// TODO: these three are repeated in bulk, should we make a function for them?
mechanical.F = feenox_problem_mechanical_compute_gradient_deformation(element->dphidx_node[j]);
mechanical.C = feenox_problem_mechanical_compute_strain_cauchy_green_left(mechanical.F);
mechanical.eps = feenox_problem_mechanical_compute_strain_green_lagrange(mechanical.C);
// each material now has to compute the second piola kirchoff stress tensor
mechanical.PK2 = mechanical.compute_PK2(node->x, feenox_fem_get_material(element));
// and then we convert it to cauchy
mechanical.cauchy = feenox_cauchy_stress_cauchy_from_PK2(mechanical.F, mechanical.PK2, mechanical.J);
// note this is voigt in cyclic order, not Landau's lexicographical order
exx = gsl_matrix_get(mechanical.eps, 0, 0);
eyy = gsl_matrix_get(mechanical.eps, 1, 1);
ezz = gsl_matrix_get(mechanical.eps, 2, 2);
exy = gsl_matrix_get(mechanical.eps, 0, 1);
eyz = gsl_matrix_get(mechanical.eps, 1, 2);
ezx = gsl_matrix_get(mechanical.eps, 2, 0);
sigmax = gsl_matrix_get(mechanical.cauchy, 0, 0);
sigmay = gsl_matrix_get(mechanical.cauchy, 1, 1);
sigmaz = gsl_matrix_get(mechanical.cauchy, 2, 2);
tauxy = gsl_matrix_get(mechanical.cauchy, 0, 1);
tauyz = gsl_matrix_get(mechanical.cauchy, 1, 2);
tauzx = gsl_matrix_get(mechanical.cauchy, 2, 0);
}
if (mechanical.thermal_expansion_model != thermal_expansion_model_none) {
// subtract the thermal contribution to the normal stresses (see IFEM.Ch30)
double sigmax_thermal = 0;
double sigmay_thermal = 0;
double sigmaz_thermal = 0;
feenox_call(mechanical.compute_thermal_stress(node->x, element->physical_group->material, &sigmax_thermal, &sigmay_thermal, &sigmaz_thermal));
sigmax -= sigmax_thermal;
sigmay -= sigmay_thermal;
sigmaz -= sigmaz_thermal;
}
node->flux[FLUX_EXX] += rel_weight * (exx - node->flux[FLUX_EXX]);
node->flux[FLUX_EYY] += rel_weight * (eyy - node->flux[FLUX_EYY]);
node->flux[FLUX_EXY] += rel_weight * (exy - node->flux[FLUX_EXY]);
if (feenox.pde.dofs == 3) {
node->flux[FLUX_EZZ] += rel_weight * (ezz - node->flux[FLUX_EZZ]);
node->flux[FLUX_EYZ] += rel_weight * (eyz - node->flux[FLUX_EYZ]);
node->flux[FLUX_EZX] += rel_weight * (ezx - node->flux[FLUX_EZX]);
}
node->flux[FLUX_SIGMAX] += rel_weight * (sigmax - node->flux[FLUX_SIGMAX]);
node->flux[FLUX_SIGMAY] += rel_weight * (sigmay - node->flux[FLUX_SIGMAY]);
node->flux[FLUX_TAUXY] += rel_weight * (tauxy - node->flux[FLUX_TAUXY]);
if (feenox.pde.dofs == 3) {
node->flux[FLUX_SIGMAZ] += rel_weight * (sigmaz - node->flux[FLUX_SIGMAZ]);
node->flux[FLUX_TAUYZ] += rel_weight * (tauyz - node->flux[FLUX_TAUYZ]);
node->flux[FLUX_TAUZX] += rel_weight * (tauzx - node->flux[FLUX_TAUZX]);
}
return FEENOX_OK;
}
int feenox_problem_gradient_fill_fluxes_mechanical(mesh_t *mesh, size_t j) {
feenox_vector_set(mechanical.exx->vector_value, j, mesh->node[j].flux[FLUX_EXX]);
feenox_vector_set(mechanical.eyy->vector_value, j, mesh->node[j].flux[FLUX_EYY]);
feenox_vector_set(mechanical.exy->vector_value, j, mesh->node[j].flux[FLUX_EXY]);
if (feenox.pde.dofs == 3) {
feenox_vector_set(mechanical.ezz->vector_value, j, mesh->node[j].flux[FLUX_EZZ]);
feenox_vector_set(mechanical.eyz->vector_value, j, mesh->node[j].flux[FLUX_EYZ]);
feenox_vector_set(mechanical.ezx->vector_value, j, mesh->node[j].flux[FLUX_EZX]);
}
feenox_vector_set(mechanical.sigmax->vector_value, j, mesh->node[j].flux[FLUX_SIGMAX]);
feenox_vector_set(mechanical.sigmay->vector_value, j, mesh->node[j].flux[FLUX_SIGMAY]);
feenox_vector_set(mechanical.tauxy->vector_value, j, mesh->node[j].flux[FLUX_TAUXY]);
if (feenox.pde.dofs == 3) {
feenox_vector_set(mechanical.sigmaz->vector_value, j, mesh->node[j].flux[FLUX_SIGMAZ]);
feenox_vector_set(mechanical.tauyz->vector_value, j, mesh->node[j].flux[FLUX_TAUYZ]);
feenox_vector_set(mechanical.tauzx->vector_value, j, mesh->node[j].flux[FLUX_TAUZX]);
}
if ((mechanical.sigma1 != NULL && mechanical.sigma1->used) ||
(mechanical.sigma2 != NULL && mechanical.sigma2->used) ||
(mechanical.sigma3 != NULL && mechanical.sigma3->used) ||
(mechanical.tresca != NULL && mechanical.tresca->used)) {
double sigma1 = 0;
double sigma2 = 0;
double sigma3 = 0;
feenox_principal_stress_from_cauchy(mesh->node[j].flux[FLUX_SIGMAX],
mesh->node[j].flux[FLUX_SIGMAY],
mesh->node[j].flux[FLUX_SIGMAZ],
mesh->node[j].flux[FLUX_TAUXY],
mesh->node[j].flux[FLUX_TAUYZ],
mesh->node[j].flux[FLUX_TAUZX],
&sigma1,
&sigma2,
&sigma3);
feenox_vector_set(mechanical.sigma1->vector_value, j, sigma1);
feenox_vector_set(mechanical.sigma2->vector_value, j, sigma2);
feenox_vector_set(mechanical.sigma3->vector_value, j, sigma3);
if (mechanical.sigma->used) {
feenox_vector_set(mechanical.sigma->vector_value, j, feenox_vonmises_from_principal(sigma1, sigma2, sigma3));
}
if (mechanical.tresca->used) {
feenox_vector_set(mechanical.tresca->vector_value, j, sigma1 - sigma3);
}
} else if (mechanical.sigma->used) {
feenox_vector_set(mechanical.sigma->vector_value, j, feenox_vonmises_from_stress_tensor(mesh->node[j].flux[FLUX_SIGMAX],
mesh->node[j].flux[FLUX_SIGMAY],
mesh->node[j].flux[FLUX_SIGMAZ],
mesh->node[j].flux[FLUX_TAUXY],
mesh->node[j].flux[FLUX_TAUYZ],
mesh->node[j].flux[FLUX_TAUZX]));
}
// TODO: uncertainties
return FEENOX_OK;
}
feenox-1.2/src/pdes/mechanical/init.c 0000664 0001750 0001750 00000071463 15055303016 013251 /*------------ -------------- -------- --- ----- --- -- - -
* feenox elastic mechanical initialization routines
*
* Copyright (C) 2021--2025 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "mechanical.h"
mechanical_t mechanical;
int feenox_problem_parse_time_init_mechanical(void) {
///kw_pde+PROBLEM+detail * `mechanical` steady-state solid mechanics with elastic or hyperelastic materials
#ifdef HAVE_PETSC
// virtual methods
feenox.pde.parse_bc = feenox_problem_bc_parse_mechanical;
feenox.pde.parse_write_results = feenox_problem_parse_write_post_mechanical;
feenox.pde.init_before_run = feenox_problem_init_runtime_mechanical;
feenox.pde.setup_snes = feenox_problem_setup_snes_mechanical;
feenox.pde.setup_ksp = feenox_problem_setup_ksp_mechanical;
feenox.pde.setup_pc = feenox_problem_setup_pc_mechanical;
feenox.pde.element_build_allocate_aux = feenox_problem_build_allocate_aux_mechanical;
feenox.pde.element_build_volumetric_at_gauss = feenox_problem_build_volumetric_gauss_point_mechanical;
feenox.pde.solve_post = feenox_problem_solve_post_mechanical;
feenox.pde.gradient_fill = feenox_problem_gradient_fill_mechanical;
feenox.pde.gradient_nodal_properties = feenox_problem_gradient_properties_at_element_nodes_mechanical;
feenox.pde.gradient_alloc_nodal_fluxes = feenox_problem_gradient_fluxes_at_node_alloc_mechanical;
feenox.pde.gradient_add_elemental_contribution_to_node = feenox_problem_gradient_add_elemental_contribution_to_node_mechanical;
feenox.pde.gradient_fill_fluxes = feenox_problem_gradient_fill_fluxes_mechanical;
// we are FEM
feenox.mesh.default_field_location = field_location_nodes;
// move symmetry_axis which is a general PDE setting to
// the mechanically-particular axisymmetric variant
if (feenox.pde.symmetry_axis != symmetry_axis_none) {
mechanical.variant = variant_axisymmetric;
}
// check consistency of problem type and dimensions
if (mechanical.variant == variant_axisymmetric ||
mechanical.variant == variant_plane_stress ||
mechanical.variant == variant_plane_strain) {
if (feenox.pde.dim != 0) {
if (feenox.pde.dim != 2) {
feenox_push_error_message("dimension inconsistency, expected 2 dimensions not %d", feenox.pde.dim);
return FEENOX_ERROR;
}
} else {
feenox.pde.dim = 2;
}
if (feenox.pde.dofs != 0) {
if (feenox.pde.dofs != 2) {
feenox_push_error_message("DOF inconsistency, expected DOFs per node = 2");
return FEENOX_ERROR;
}
} else {
feenox.pde.dofs = 2;
}
} else {
if (feenox.pde.dim == 0) {
// default is 3d
feenox.pde.dim = 3;
} else if (feenox.pde.dim == 1) {
feenox_push_error_message("cannot solve 1D mechanical problems");
return FEENOX_ERROR;
} else if (feenox.pde.dim == 2) {
feenox_push_error_message("to solve 2D problems give either plane_stress, plane_strain or axisymmetric");
return FEENOX_ERROR;
} else if (feenox.pde.dim != 3) {
feenox_push_error_message("dimension inconsistency, expected DIM 2 or 3 instead of %d", feenox.pde.dim);
return FEENOX_ERROR;
}
feenox.pde.dofs = feenox.pde.dim;
}
// TODO: custom names
// TODO: document
feenox_check_alloc(feenox.pde.unknown_name = calloc(feenox.pde.dofs, sizeof(char *)));
feenox_check_alloc(feenox.pde.unknown_name[0] = strdup("u"));
if (feenox.pde.dofs > 1) {
feenox_check_alloc(feenox.pde.unknown_name[1] = strdup("v"));
if (feenox.pde.dofs > 2) {
feenox_check_alloc(feenox.pde.unknown_name[2] = strdup("w"));
}
}
// ------- elasticity-related outputs -----------------------------------
// TODO: document
feenox_call(feenox_problem_define_solution_function("exx", &mechanical.exx, FEENOX_SOLUTION_GRADIENT));
feenox_call(feenox_problem_define_solution_function("eyy", &mechanical.eyy, FEENOX_SOLUTION_GRADIENT));
feenox_call(feenox_problem_define_solution_function("exy", &mechanical.exy, FEENOX_SOLUTION_GRADIENT));
if (feenox.pde.dofs == 3) {
feenox_call(feenox_problem_define_solution_function("ezz", &mechanical.ezz, FEENOX_SOLUTION_GRADIENT));
feenox_call(feenox_problem_define_solution_function("eyz", &mechanical.eyz, FEENOX_SOLUTION_GRADIENT));
feenox_call(feenox_problem_define_solution_function("ezx", &mechanical.ezx, FEENOX_SOLUTION_GRADIENT));
}
feenox_call(feenox_problem_define_solution_function("sigmax", &mechanical.sigmax, FEENOX_SOLUTION_GRADIENT));
feenox_call(feenox_problem_define_solution_function("sigmay", &mechanical.sigmay, FEENOX_SOLUTION_GRADIENT));
feenox_call(feenox_problem_define_solution_function("tauxy", &mechanical.tauxy, FEENOX_SOLUTION_GRADIENT));
if (feenox.pde.dofs == 3) {
feenox_call(feenox_problem_define_solution_function("sigmaz", &mechanical.sigmaz, FEENOX_SOLUTION_GRADIENT));
feenox_call(feenox_problem_define_solution_function("tauyz", &mechanical.tauyz, FEENOX_SOLUTION_GRADIENT));
feenox_call(feenox_problem_define_solution_function("tauzx", &mechanical.tauzx, FEENOX_SOLUTION_GRADIENT));
}
feenox_call(feenox_problem_define_solution_function("sigma1", &mechanical.sigma1, FEENOX_SOLUTION_GRADIENT));
feenox_call(feenox_problem_define_solution_function("sigma2", &mechanical.sigma2, FEENOX_SOLUTION_GRADIENT));
feenox_call(feenox_problem_define_solution_function("sigma3", &mechanical.sigma3, FEENOX_SOLUTION_GRADIENT));
feenox_call(feenox_problem_define_solution_function("sigma", &mechanical.sigma, FEENOX_SOLUTION_GRADIENT));
// feenox_call(feenox_problem_define_solution_function("delta_sigma", &mechanical.delta_sigma, FEENOX_SOLUTION_GRADIENT));
feenox_call(feenox_problem_define_solution_function("tresca", &mechanical.tresca, FEENOX_SOLUTION_GRADIENT));
///va+ldef+detail Flag that turns the large-deformation formulation on or off.
///va+ldef+detail It can also be turned on with the `NONLINEAR` keyword in `PROBLEM`
///va+ldef+detail or with the `--non-linear` command-line option.
feenox_check_alloc(mechanical.ldef = feenox_define_variable_get_ptr("ldef"));
//va+ldef+detail Flag that asks FeenoX to check if the deformations are large after
//va+ldef+detail solving a linear problem. If they are, a warning is issued.
// feenox_check_alloc(mechanical.ldef_check = feenox_define_variable_get_ptr("ldef_check"));
// these are for the algebraic expressions in the implicitly-defined BCs
// i.e. 0=u*nx+v*ny or 0=u*y-v*x
// here they are defined as uppercase because there already exist functions named u, v and w
// but the parser changes their case when an implicit BC is read
mechanical.displ_for_bc[0]= feenox_define_variable_get_ptr("U");
mechanical.displ_for_bc[1]= feenox_define_variable_get_ptr("V");
mechanical.displ_for_bc[2]= feenox_define_variable_get_ptr("W");
///va+strain_energy+detail The strain energy stored in the solid, computed as
///va+strain_energy+detail $1/2 \cdot \vec{u}^T K \vec{u}$
///va+strain_energy+detail where $\vec{u}$ is the displacements vector and $K$ is the stiffness matrix.
feenox_check_alloc(mechanical.strain_energy = feenox_define_variable_get_ptr("strain_energy"));
///va+displ_max+detail The module of the maximum displacement of the elastic problem.
feenox_check_alloc(mechanical.displ_max = feenox_define_variable_get_ptr("displ_max"));
///va+displ_max_x+detail The\ $x$ coordinate of the maximum displacement of the elastic problem.
feenox_check_alloc(mechanical.displ_max_x = feenox_define_variable_get_ptr("displ_max_x"));
///va+displ_max_y+detail The\ $y$ coordinate of the maximum displacement of the elastic problem.
feenox_check_alloc(mechanical.displ_max_y = feenox_define_variable_get_ptr("displ_max_y"));
///va+displ_max_z+detail The\ $z$ coordinate of the maximum displacement of the elastic problem.
feenox_check_alloc(mechanical.displ_max_z = feenox_define_variable_get_ptr("displ_max_z"));
///va+u_at_displ_max+detail The\ $x$ component\ $u$ of the maximum displacement of the elastic problem.
feenox_check_alloc(mechanical.u_at_displ_max = feenox_define_variable_get_ptr("u_at_displ_max"));
///va+v_at_displ_max+detail The\ $y$ component\ $v$ of the maximum displacement of the elastic problem.
feenox_check_alloc(mechanical.v_at_displ_max = feenox_define_variable_get_ptr("v_at_displ_max"));
///va+w_at_displ_max+detail The\ $z$ component\ $w$ of the maximum displacement of the elastic problem.
feenox_check_alloc(mechanical.w_at_displ_max = feenox_define_variable_get_ptr("w_at_displ_max"));
///va+sigma_max+detail The maximum von Mises stress\ $\sigma$ of the elastic problem.
feenox_check_alloc(mechanical.sigma_max = feenox_define_variable_get_ptr("sigma_max"));
///va+delta_sigma_max+detail The uncertainty of the maximum Von Mises stress\ $\sigma$ of the elastic problem.
///va+delta_sigma_max+detail Not to be confused with the maximum uncertainty of the Von Mises stress.
feenox_check_alloc(mechanical.delta_sigma_max = feenox_define_variable_get_ptr("delta_sigma_max"));
///va+sigma_max_x+detail The\ $x$ coordinate of the maximum von Mises stress\ $\sigma$ of the elastic problem.
feenox_check_alloc(mechanical.sigma_max_x = feenox_define_variable_get_ptr("sigma_max_x"));
///va+sigma_max_y+detail The\ $x$ coordinate of the maximum von Mises stress\ $\sigma$ of the elastic problem.
feenox_check_alloc(mechanical.sigma_max_y = feenox_define_variable_get_ptr("sigma_max_y"));
///va+sigma_max_z+detail The\ $x$ coordinate of the maximum von Mises stress\ $\sigma$ of the elastic problem.
feenox_check_alloc(mechanical.sigma_max_z = feenox_define_variable_get_ptr("sigma_max_z"));
///va+u_at_sigma_max+detail The\ $x$ component\ $u$ of the displacement where the maximum von Mises stress\ $\sigma$ of the elastic problem is located.
feenox_check_alloc(mechanical.u_at_sigma_max = feenox_define_variable_get_ptr("u_at_sigma_max"));
///va+v_at_sigma_max+detail The\ $y$ component\ $v$ of the displacement where the maximum von Mises stress\ $\sigma$ of the elastic problem is located.
feenox_check_alloc(mechanical.v_at_sigma_max = feenox_define_variable_get_ptr("v_at_sigma_max"));
///va+w_at_sigma_max+detail The\ $z$ component\ $w$ of the displacement where the maximum von Mises stress\ $\sigma$ of the elastic problem is located.
feenox_check_alloc(mechanical.w_at_sigma_max = feenox_define_variable_get_ptr("w_at_sigma_max"));
#endif
return FEENOX_OK;
}
int feenox_problem_init_runtime_mechanical(void) {
#ifdef HAVE_PETSC
feenox.pde.mesh->data_type = data_type_node;
feenox.pde.spatial_unknowns = feenox.pde.mesh->n_nodes;
// valid property names
feenox_call(feenox_distribution_init(&mechanical.E, "E"));
feenox_call(feenox_distribution_init(&mechanical.nu, "nu"));
feenox_call(feenox_distribution_init(&mechanical.lambda, "lambda"));
feenox_call(feenox_distribution_init(&mechanical.mu, "mu"));
// orthotropic properties
feenox_call(feenox_distribution_init(&mechanical.E_x, "Ex"));
if (mechanical.E_x.defined == 0) {
feenox_call(feenox_distribution_init(&mechanical.E_x, "E_x"));
}
feenox_call(feenox_distribution_init(&mechanical.E_y, "Ey"));
if (mechanical.E_y.defined == 0) {
feenox_call(feenox_distribution_init(&mechanical.E_y, "E_y"));
}
feenox_call(feenox_distribution_init(&mechanical.E_z, "Ez"));
if (mechanical.E_z.defined == 0) {
feenox_call(feenox_distribution_init(&mechanical.E_z, "E_z"));
}
feenox_call(feenox_distribution_init(&mechanical.nu_xy, "nuxy"));
if (mechanical.nu_xy.defined == 0) {
feenox_call(feenox_distribution_init(&mechanical.nu_xy, "nu_xy"));
}
feenox_call(feenox_distribution_init(&mechanical.nu_yz, "nuyz"));
if (mechanical.nu_yz.defined == 0) {
feenox_call(feenox_distribution_init(&mechanical.nu_yz, "nu_yz"));
}
feenox_call(feenox_distribution_init(&mechanical.nu_zx, "nuzx"));
if (mechanical.nu_zx.defined == 0) {
feenox_call(feenox_distribution_init(&mechanical.nu_zx, "nu_zx"));
}
feenox_call(feenox_distribution_init(&mechanical.G_xy, "Gxy"));
if (mechanical.G_xy.defined == 0) {
feenox_call(feenox_distribution_init(&mechanical.G_xy, "G_xy"));
}
feenox_call(feenox_distribution_init(&mechanical.G_yz, "Gyz"));
if (mechanical.G_yz.defined == 0) {
feenox_call(feenox_distribution_init(&mechanical.G_yz, "G_yz"));
}
feenox_call(feenox_distribution_init(&mechanical.G_zx, "Gzx"));
if (mechanical.G_zx.defined == 0) {
feenox_call(feenox_distribution_init(&mechanical.G_zx, "G_zx"));
}
mechanical.material_model = -1;
int material_model[feenox.pde.mesh->n_groups];
physical_group_t *physical_group = NULL;
int i = 0;
for (physical_group = feenox.pde.mesh->physical_groups; physical_group != NULL; physical_group = physical_group->hh.next) {
if (physical_group->dimension == feenox.pde.dim) {
material_model[i] = material_model_unknown;
// first see if the materials have explicit models via MODEL model_name
material_t *material = physical_group->material;
if ((material) != NULL) {
if (material->model != NULL) {
if (strcmp(material->model, "linear") == 0 || strcmp(material->model, "isotropic") == 0 || strcmp(material->model, "linear_elastic") == 0 || strcmp(physical_group->material->model, "linear_elastic_isotropic") == 0) {
material_model[i] = feenox_mechanical_material_init_linear_elastic(material, i);
} else if (strcmp(material->model, "orthotropic") == 0 || strcmp(material->model, "elastic_orthotropic") == 0 || strcmp(material->model, "linear_elastic_orthotropic") == 0) {
material_model[i] = feenox_mechanical_material_init_linear_elastic_orthotropic(material, i);
} else if (strcmp(material->model, "neohookean") == 0 || strcmp(material->model, "neo") == 0) {
material_model[i] = feenox_mechanical_material_init_neohookean(material, i);
} else if (strcmp(material->model, "svk") == 0 || strcmp(material->model, "saint-venant-kirchoff") == 0 || strcmp(material->model, "saint-venant") == 0) {
material_model[i] = feenox_mechanical_material_init_svk(material, i);
// TODO: hencky
// TODO: mooney-rivlin
} else {
feenox_push_error_message("unknown material model '%s'", material->model);
return FEENOX_ERROR;
}
}
}
// if not, see if we can figure it out automatically
if (material_model[i] == material_model_unknown) {
int attemped_model = feenox_mechanical_material_init_linear_elastic(material, i);
if (attemped_model == material_model_unknown) {
attemped_model = feenox_mechanical_material_init_linear_elastic_orthotropic(material, i);
}
if (attemped_model == material_model_unknown) {
attemped_model = feenox_mechanical_material_init_neohookean(material, i);
}
if (attemped_model == material_model_unknown) {
feenox_push_error_message("unknown material model, usual way to go is to define E and nu");
return FEENOX_ERROR;
}
material_model[i] = attemped_model;
}
// zero means "that's not my model" so it should be caught in the default about
// -1 means "there's something wrong" so we should fail (the error message
// should be pushed by the particular model)
if (material_model[i] <= 0) {
return FEENOX_ERROR;
}
// if there is an actual material, set it in the context
if (material != NULL) {
if (material->ctx == NULL) {
feenox_check_alloc(material->ctx = calloc(1, sizeof(mechanical_material_ctx_t)));
}
mechanical_material_ctx_t *context = material->ctx;
context->material_model = material_model[i];
}
// see if all the materials have the same model
if (mechanical.material_model == -1) {
mechanical.material_model = material_model[i];
} else if (mechanical.material_model != material_model[i]) {
mechanical.material_model = material_model_unknown;
}
}
i++;
}
// TODO: something similar for mechanical models
// thermal expansion model
// first try isotropic
feenox_call(feenox_distribution_init(&mechanical.alpha, "alpha"));
if (mechanical.alpha.defined) {
mechanical.thermal_expansion_model = thermal_expansion_model_isotropic;
} else {
// see if there are orthotropic properties
feenox_call(feenox_distribution_init(&mechanical.alpha_x, "alphax"));
if (mechanical.alpha_x.defined == 0) {
feenox_call(feenox_distribution_init(&mechanical.alpha_x, "alpha_x"));
}
feenox_call(feenox_distribution_init(&mechanical.alpha_y, "alphay"));
if (mechanical.alpha_y.defined == 0) {
feenox_call(feenox_distribution_init(&mechanical.alpha_y, "alpha_y"));
}
feenox_call(feenox_distribution_init(&mechanical.alpha_z, "alphaz"));
if (mechanical.alpha_z.defined == 0) {
feenox_call(feenox_distribution_init(&mechanical.alpha_z, "alpha_z"));
}
}
// check for consistency
int n_ortho = mechanical.alpha_x.defined + mechanical.alpha_y.defined + mechanical.alpha_z.defined;
if (n_ortho > 0) {
if (mechanical.thermal_expansion_model == thermal_expansion_model_isotropic) {
feenox_push_error_message("both isotropic and orthotropic thermal expansion coefficients given, choose one");
return FEENOX_ERROR;
} else if (n_ortho < 3) {
feenox_push_error_message("%d orthotropic thermal expansion coefficients missing", 3-n_ortho);
return FEENOX_ERROR;
} else if (mechanical.thermal_expansion_model == thermal_expansion_model_none) {
mechanical.thermal_expansion_model = thermal_expansion_model_orthotropic;
}
}
// temperature used for the thermal expansion
feenox_call(feenox_distribution_init(&mechanical.T, "T"));
// reference temperature: it has to be a variable
feenox_call(feenox_distribution_init(&mechanical.T_ref, "T0"));
if (mechanical.T_ref.defined == 0) {
feenox_call(feenox_distribution_init(&mechanical.T_ref, "T_0"));
}
if (mechanical.T_ref.defined) {
if (mechanical.T_ref.non_uniform) {
feenox_push_error_message("reference temperature T0 has to be uniform");
return FEENOX_ERROR;
}
// TODO: it is hard to know if a variable will be constant in time...
/*
if (mechanical.T_ref.constant == 0) {
feenox_push_error_message("reference temperature T0 has to be constant");
return FEENOX_ERROR;
}
*/
// evaluate reference temperature and store it in T0
mechanical.T0 = mechanical.T_ref.eval(&mechanical.T_ref, NULL, NULL);
}
// volumetric force densities
feenox_call(feenox_distribution_init(&mechanical.f_x, "fx"));
if (mechanical.f_x.defined == 0) {
feenox_call(feenox_distribution_init(&mechanical.f_x, "f_x"));
}
feenox_call(feenox_distribution_init(&mechanical.f_y, "fy"));
if (mechanical.f_y.defined == 0) {
feenox_call(feenox_distribution_init(&mechanical.f_y, "f_y"));
}
feenox_call(feenox_distribution_init(&mechanical.f_z, "fz"));
if (mechanical.f_z.defined == 0) {
feenox_call(feenox_distribution_init(&mechanical.f_z, "f_z"));
}
// set material model virtual methods
// TODO: handle several volumes each one with a differen model
switch (mechanical.material_model) {
// we need to call particular methods instead of hard-coding
case material_model_elastic_isotropic:
feenox_call(feenox_mechanical_material_setup_linear_elastic());
break;
case material_model_elastic_orthotropic:
feenox_call(feenox_mechanical_material_setup_linear_elastic_orthotropic());
break;
case material_model_hyperelastic_neohookean:
feenox_call(feenox_mechanical_material_setup_neohookean());
break;
case material_model_hyperelastic_svk:
feenox_call(feenox_mechanical_material_setup_svk());
break;
default:
feenox_push_error_message("unknown material model, usual way to go is to define E and nu");
return FEENOX_ERROR;
break;
}
// size of stress-strain matrix
if (mechanical.variant == variant_full) {
mechanical.stress_strain_size = 6;
} else if (mechanical.variant == variant_axisymmetric) {
mechanical.stress_strain_size = 4;
} else if (mechanical.variant == variant_plane_stress || mechanical.variant == variant_plane_strain) {
mechanical.stress_strain_size = 3;
} else {
feenox_push_error_message("internal mismatch, unknown variant");
return FEENOX_ERROR;
}
// allocate stress-strain objects
feenox_check_alloc(mechanical.C_tangent = gsl_matrix_calloc(mechanical.stress_strain_size, mechanical.stress_strain_size));
if (mechanical.uniform_properties) {
// cache properties
feenox_call(mechanical.compute_material_tangent(NULL, feenox.mesh.materials));
}
switch (mechanical.thermal_expansion_model) {
case thermal_expansion_model_isotropic:
mechanical.compute_thermal_strain = feenox_problem_mechanical_compute_thermal_strain_isotropic;
mechanical.compute_thermal_stress = feenox_problem_mechanical_compute_thermal_stress_isotropic;
break;
case thermal_expansion_model_orthotropic:
mechanical.compute_thermal_strain = feenox_problem_mechanical_compute_thermal_strain_orthotropic;
mechanical.compute_thermal_stress = feenox_problem_mechanical_compute_thermal_stress_orthotropic;
break;
default:
break;
}
if (mechanical.thermal_expansion_model != thermal_expansion_model_none) {
feenox_check_alloc(mechanical.et = gsl_vector_calloc(mechanical.stress_strain_size));
feenox_check_alloc(mechanical.Cet = gsl_vector_calloc(mechanical.stress_strain_size));
}
mechanical.nonlinear_geom = feenox_var_value(mechanical.ldef) != 0;
if (feenox.pde.math_type == math_type_automatic) {
if (mechanical.nonlinear_material || mechanical.nonlinear_geom) {
feenox.pde.math_type = math_type_nonlinear;
} else {
feenox.pde.math_type = math_type_linear;
// feenox_var_value(mechanical.ldef_check) = 1;
}
}
if (feenox.pde.math_type == math_type_nonlinear || feenox.pde.math_type == math_type_nonlinear_pseudo) {
feenox.pde.element_build_volumetric_at_gauss = feenox_problem_build_volumetric_gauss_point_mechanical_nonlinear;
feenox.pde.has_internal_fluxes = 1;
feenox_var_value(mechanical.ldef) = 1;
mechanical.nonlinear_geom = 1;
// feenox_var_value(mechanical.ldef_check) = 0;
}
if (feenox_special_var_value(end_time) == 0 || feenox.pde.transient_type == transient_type_quasistatic_dumb) {
switch (feenox.pde.math_type) {
case math_type_linear:
feenox.pde.solve = feenox_problem_solve_petsc_linear;
break;
case math_type_nonlinear:
feenox.pde.solve = feenox_problem_solve_petsc_nonlinear;
break;
case math_type_nonlinear_pseudo:
// feenox.pde.solve = feenox_problem_solve_petsc_nonlinear_pseudo;
feenox_push_error_message("work in progress");
break;
default:
feenox_push_error_message("unknown math problem type %d", feenox.pde.math_type);
break;
}
} else {
feenox.pde.solve = feenox_problem_solve_petsc_transient;
}
feenox.pde.has_stiffness = 1;
// TODO: transient
feenox.pde.has_mass = 0;
feenox.pde.has_rhs = 1;
feenox.pde.has_jacobian_K = feenox.pde.math_type == math_type_nonlinear;
feenox.pde.has_jacobian_M = 0;
feenox.pde.has_jacobian_b = 0;
feenox.pde.has_jacobian = feenox.pde.has_jacobian_K || feenox.pde.has_jacobian_M || feenox.pde.has_jacobian_b;
feenox.pde.symmetric_K = 1;
feenox.pde.symmetric_M = 1;
// see if we have to compute gradients
feenox.pde.compute_gradients |=
(mechanical.exx != NULL && mechanical.exx->used) ||
(mechanical.eyy != NULL && mechanical.eyy->used) ||
(mechanical.ezz != NULL && mechanical.ezz->used) ||
(mechanical.exy != NULL && mechanical.exy->used) ||
(mechanical.eyz != NULL && mechanical.eyz->used) ||
(mechanical.ezx != NULL && mechanical.ezx->used) ||
(mechanical.sigmax != NULL && mechanical.sigmax->used) ||
(mechanical.sigmay != NULL && mechanical.sigmay->used) ||
(mechanical.sigmaz != NULL && mechanical.sigmaz->used) ||
(mechanical.tauxy != NULL && mechanical.tauxy->used) ||
(mechanical.tauyz != NULL && mechanical.tauyz->used) ||
(mechanical.tauzx != NULL && mechanical.tauzx->used) ||
(mechanical.sigma1 != NULL && mechanical.sigma1->used) ||
(mechanical.sigma2 != NULL && mechanical.sigma2->used) ||
(mechanical.sigma3 != NULL && mechanical.sigma3->used) ||
(mechanical.sigma != NULL && mechanical.sigma->used) ||
(mechanical.tresca != NULL && mechanical.tresca->used);
#endif
return FEENOX_OK;
}
#ifdef HAVE_PETSC
int feenox_problem_compute_rigid_nullspace(MatNullSpace *nullspace) {
Vec vec_coords = NULL;
if (feenox.pde.K != NULL) {
petsc_call(MatCreateVecs(feenox.pde.K, NULL, &vec_coords));
} else {
feenox_check_alloc(vec_coords = feenox_problem_create_vector("coordinates"));
}
petsc_call(VecSetBlockSize(vec_coords, feenox.pde.dim));
petsc_call(VecSetUp(vec_coords));
PetscScalar *coords = NULL;
petsc_call(VecGetArray(vec_coords, &coords));
for (size_t j = feenox.pde.first_node; j < feenox.pde.last_node; j++) {
for (unsigned int d = 0; d < feenox.pde.dim; d++) {
coords[feenox.pde.mesh->node[j].index_dof[d] - feenox.pde.first_row] = feenox.pde.mesh->node[j].x[d];
}
}
petsc_call(VecRestoreArray(vec_coords, &coords));
petsc_call(MatNullSpaceCreateRigidBody(vec_coords, nullspace));
petsc_call(VecDestroy(&vec_coords));
return FEENOX_OK;
}
int feenox_problem_setup_pc_mechanical(PC pc) {
PCType pc_type = NULL;
petsc_call(PCGetType(pc, &pc_type));
if (pc_type == NULL) {
petsc_call(PCSetType(pc, (feenox.pde.pc_type != NULL) ? feenox.pde.pc_type : PCGAMG));
}
petsc_call(PCGetType(pc, &pc_type));
if (strcmp(pc_type, PCGAMG) == 0) {
if (mechanical.rigid_body_base == NULL) {
feenox_problem_compute_rigid_nullspace(&mechanical.rigid_body_base);
}
if (feenox.pde.has_stiffness) {
petsc_call(MatSetNearNullSpace(feenox.pde.K, mechanical.rigid_body_base));
}
if (feenox.pde.has_mass) {
petsc_call(MatSetNearNullSpace(feenox.pde.M, mechanical.rigid_body_base));
}
}
return FEENOX_OK;
}
int feenox_problem_setup_ksp_mechanical(KSP ksp) {
KSPType ksp_type = NULL;
petsc_call(KSPGetType(ksp, &ksp_type));
if (ksp_type == NULL) {
#ifdef PETSC_HAVE_MUMPS
// if we have mumps, let's use it only if the problem is small
// TODO: choose the threshold?
if ((feenox.pde.ksp_type == NULL && feenox.pde.pc_type == NULL && feenox.pde.size_global < 3e5) ||
(feenox.pde.ksp_type != NULL && strcasecmp(feenox.pde.ksp_type, "mumps") == 0)) {
feenox.pde.ksp_type = KSPPREONLY;
feenox.pde.pc_type = "mumps";
}
#endif
if (feenox.pde.ksp_type == NULL) {
// if mumps is not avaialable or the problem is big, we default to CG or GMRES
feenox.pde.ksp_type = (feenox.pde.math_type == math_type_linear && feenox.pde.symmetric_K && feenox.pde.symmetric_M) ? KSPCG : KSPGMRES;
}
petsc_call(KSPSetType(ksp, feenox.pde.ksp_type));
}
return FEENOX_OK;
}
int feenox_problem_setup_snes_mechanical(SNES snes) {
// TODO! set a default snes type
// SNESType snes_type = NULL;
// petsc_call(SNESGetType(snes, &snes_type));
SNESLineSearch ls;
petsc_call(SNESGetLineSearch(snes, &ls));
SNESLineSearchType ls_type;
petsc_call(SNESLineSearchGetType(ls, &ls_type));
// PETSc 3.19 is buggy and needs TSSetFromOptions already called
// that one sets the line search to bt and we want to default to basic
if (ls_type == NULL || (PETSC_VERSION_MAJOR == 3 && PETSC_VERSION_MINOR == 19)) {
petsc_call(SNESLineSearchSetType(ls, SNESLINESEARCHBASIC));
}
return FEENOX_OK;
}
#endif
feenox-1.2/src/pdes/mechanical/linearize.c 0000664 0001750 0001750 00000031330 15055303016 014255 /*------------ -------------- -------- --- ----- --- -- - -
* feenox method for stress linearization over SCLs according to ASME
*
* Copyright (C) 2017-2022 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "mechanical.h"
struct linearize_params_t {
double x1, y1, z1;
double x2, y2, z2;
double length;
function_t *function;
};
double feenox_linearization_integrand_membrane(double t_prime, void *params);
double feenox_linearization_integrand_bending(double t_prime, void *params);
double feenox_linearization_integrate(gsl_function *F, function_t *function);
int feenox_linearization_compute_and_store(function_t *total_function, const double x1[], const double x2[], double M, double MBplus, double MBminus, var_t *var_M, var_t *var_MB, var_t *var_P);
int feenox_instruction_linearize(void *arg) {
feenox_linearize_t *linearize = (feenox_linearize_t *)arg;
// this is an implicit SOLVE_PROBLEM point
if (feenox.pde.problem_solved == 0) {
feenox_call(feenox_instruction_solve_problem(NULL));
}
// http://www.eng-tips.com/faqs.cfm?fid=982
// the actual equations are in ASME VIII-div 2 sec 5
// also see the mecway manual
struct linearize_params_t params;
params.x1 = feenox_expression_eval(&linearize->x1);
params.y1 = feenox_expression_eval(&linearize->y1);
params.z1 = feenox_expression_eval(&linearize->z1);
params.x2 = feenox_expression_eval(&linearize->x2);
params.y2 = feenox_expression_eval(&linearize->y2);
params.z2 = feenox_expression_eval(&linearize->z2);
params.length = gsl_hypot3(params.x2-params.x1, params.y2-params.y1, params.z2-params.z1);
gsl_function F = {NULL, ¶ms};
// membrane stress
F.function = &feenox_linearization_integrand_membrane;
double sigmax_m = feenox_linearization_integrate(&F, mechanical.sigmax) / params.length;
double sigmay_m = feenox_linearization_integrate(&F, mechanical.sigmay) / params.length;
double sigmaz_m = feenox_linearization_integrate(&F, mechanical.sigmaz) / params.length;
double tauxy_m = feenox_linearization_integrate(&F, mechanical.tauxy) / params.length;
double tauyz_m = feenox_linearization_integrate(&F, mechanical.tauyz) / params.length;
double tauzx_m = feenox_linearization_integrate(&F, mechanical.tauzx) / params.length;
// bending stress
F.function = &feenox_linearization_integrand_bending;
double den = gsl_pow_2(params.length)/6.0;
double sigmax_b = feenox_linearization_integrate(&F, mechanical.sigmax) / den;
double sigmay_b = feenox_linearization_integrate(&F, mechanical.sigmay) / den;
double sigmaz_b = feenox_linearization_integrate(&F, mechanical.sigmaz) / den;
double tauxy_b = feenox_linearization_integrate(&F, mechanical.tauxy) / den;
double tauyz_b = feenox_linearization_integrate(&F, mechanical.tauyz) / den;
double tauzx_b = feenox_linearization_integrate(&F, mechanical.tauzx) / den;
// now we have to compose these guys
double x1[3] = {params.x1, params.y1, params.z1};
double x2[3] = {params.x2, params.y2, params.z2};
if (linearize->M != NULL || linearize->MB != NULL || linearize->P != NULL) {
double M = feenox_vonmises_from_stress_tensor(sigmax_m, sigmay_m, sigmaz_m, tauxy_m, tauyz_m, tauzx_m);
double MBplus = feenox_vonmises_from_stress_tensor(sigmax_m+sigmax_b, sigmay_m+sigmay_b, sigmaz_m+sigmaz_b, tauxy_m+tauxy_b, tauyz_m+tauyz_b, tauzx_m+tauzx_b);
double MBminus = feenox_vonmises_from_stress_tensor(sigmax_m-sigmax_b, sigmay_m-sigmay_b, sigmaz_m-sigmaz_b, tauxy_m-tauxy_b, tauyz_m-tauyz_b, tauzx_m-tauzx_b);
feenox_call(feenox_linearization_compute_and_store(mechanical.sigma, x1, x2, M, MBplus, MBminus, linearize->M, linearize->MB, linearize->P));
}
if (linearize->Mt != NULL || linearize->MBt != NULL || linearize->Pt != NULL) {
double M = feenox_tresca_from_stress_tensor(sigmax_m, sigmay_m, sigmaz_m, tauxy_m, tauyz_m, tauzx_m);
double MBplus = feenox_tresca_from_stress_tensor(sigmax_m+sigmax_b, sigmay_m+sigmay_b, sigmaz_m+sigmaz_b, tauxy_m+tauxy_b, tauyz_m+tauyz_b, tauzx_m+tauzx_b);
double MBminus = feenox_tresca_from_stress_tensor(sigmax_m-sigmax_b, sigmay_m-sigmay_b, sigmaz_m-sigmaz_b, tauxy_m-tauxy_b, tauyz_m-tauyz_b, tauzx_m-tauzx_b);
feenox_call(feenox_linearization_compute_and_store(mechanical.tresca, x1, x2, M, MBplus, MBminus, linearize->Mt, linearize->MBt, linearize->Pt));
}
if (linearize->M1 != NULL || linearize->MB1 != NULL || linearize->P1 != NULL ||
linearize->M2 != NULL || linearize->MB2 != NULL || linearize->P2 != NULL ||
linearize->M3 != NULL || linearize->MB3 != NULL || linearize->P3 != NULL) {
double M1, M2, M3;
double MBplus1, MBplus2, MBplus3;
double MBminus1, MBminus2, MBminus3;
feenox_principal_stress_from_cauchy(sigmax_m, sigmay_m, sigmaz_m, tauxy_m, tauyz_m, tauzx_m, &M1, &M2, &M3);
feenox_principal_stress_from_cauchy(sigmax_m+sigmax_b, sigmay_m+sigmay_b, sigmaz_m+sigmaz_b, tauxy_m+tauxy_b, tauyz_m+tauyz_b, tauzx_m+tauzx_b, &MBplus1, &MBplus2, &MBplus3);
feenox_principal_stress_from_cauchy(sigmax_m-sigmax_b, sigmay_m-sigmay_b, sigmaz_m-sigmaz_b, tauxy_m-tauxy_b, tauyz_m-tauyz_b, tauzx_m-tauzx_b, &MBminus1, &MBminus2, &MBminus3);
if (linearize->M1 != NULL || linearize->MB1 != NULL || linearize->P1 != NULL) {
feenox_call(feenox_linearization_compute_and_store(mechanical.sigma1, x1, x2, M1, MBplus1, MBminus1, linearize->M1, linearize->MB1, linearize->P1));
}
if (linearize->M2 != NULL || linearize->MB2 != NULL || linearize->P2 != NULL) {
feenox_call(feenox_linearization_compute_and_store(mechanical.sigma2, x1, x2, M2, MBplus2, MBminus2, linearize->M2, linearize->MB2, linearize->P2));
}
if (linearize->M3 != NULL || linearize->MB3 != NULL || linearize->P3 != NULL) {
feenox_call(feenox_linearization_compute_and_store(mechanical.sigma3, x1, x2, M3, MBplus3, MBminus3, linearize->M3, linearize->MB3, linearize->P3));
}
}
/*
if (linearize->file != NULL) {
if (linearize->file->pointer == NULL) {
feenox_call(feenox_instruction_file_open(linearize->file));
}
fprintf(linearize->file->pointer, "# # Stress linearization\n");
fprintf(linearize->file->pointer, "#\n");
fprintf(linearize->file->pointer, "# Start point: (%g, %g, %g)\n", params.x1, params.y1, params.z1);
fprintf(linearize->file->pointer, "# End point: (%g, %g, %g)\n", params.x2, params.y2, params.z2);
fprintf(linearize->file->pointer, "# Total: %s\n", total_name);
fprintf(linearize->file->pointer, "#\n");
fprintf(linearize->file->pointer, "# ## Membrane stress tensor\n");
fprintf(linearize->file->pointer, "#\n");
fprintf(linearize->file->pointer, "# $\\sigma_{x}$ = %g\n", sigmax_m);
fprintf(linearize->file->pointer, "# $\\sigma_{y}$ = %g\n", sigmay_m);
fprintf(linearize->file->pointer, "# $\\sigma_{z}$ = %g\n", sigmaz_m);
fprintf(linearize->file->pointer, "# $\\tau_{xy}$ = %g\n", tauxy_m);
fprintf(linearize->file->pointer, "# $\\tau_{yz}$ = %g\n", tauyz_m);
fprintf(linearize->file->pointer, "# $\\tau_{zx}$ = %g\n", tauzx_m);
fprintf(linearize->file->pointer, "#\n");
fprintf(linearize->file->pointer, "# ## Bending stress tensor\n");
fprintf(linearize->file->pointer, "#\n");
fprintf(linearize->file->pointer, "# $\\sigma_{x}$ = %g\n", sigmax_b);
fprintf(linearize->file->pointer, "# $\\sigma_{y}$ = %g\n", sigmay_b);
fprintf(linearize->file->pointer, "# $\\sigma_{z}$ = %g\n", sigmaz_b);
fprintf(linearize->file->pointer, "# $\\tau_{xy}$ = %g\n", tauxy_b);
fprintf(linearize->file->pointer, "# $\\tau_{yz}$ = %g\n", tauyz_b);
fprintf(linearize->file->pointer, "# $\\tau_{zx}$ = %g\n", tauzx_b);
fprintf(linearize->file->pointer, "#\n");
fprintf(linearize->file->pointer, "# ## Membrane plus bending stress tensor\n");
fprintf(linearize->file->pointer, "#\n");
fprintf(linearize->file->pointer, "# $\\sigma_{x}$ = %g\n", sigmax_m+sigmax_b);
fprintf(linearize->file->pointer, "# $\\sigma_{y}$ = %g\n", sigmay_m+sigmay_b);
fprintf(linearize->file->pointer, "# $\\sigma_{z}$ = %g\n", sigmaz_m+sigmaz_b);
fprintf(linearize->file->pointer, "# $\\tau_{xy}$ = %g\n", tauxy_m+tauxy_b);
fprintf(linearize->file->pointer, "# $\\tau_{yz}$ = %g\n", tauyz_m+tauyz_b);
fprintf(linearize->file->pointer, "# $\\tau_{zx}$ = %g\n", tauzx_m+tauzx_b);
fprintf(linearize->file->pointer, "#\n");
fprintf(linearize->file->pointer, "# ## Linearization results\n");
fprintf(linearize->file->pointer, "#\n");
fprintf(linearize->file->pointer, "# Membrane stress $M$ = %g\n", feenox_var_value(linearize->M));
fprintf(linearize->file->pointer, "# Membrane plus bending stress $MB$ = %g\n", feenox_var_value(linearize->MB));
fprintf(linearize->file->pointer, "# Peak stress $P$ = %g\n", feenox_var_value(linearize->P));
fprintf(linearize->file->pointer, "#\n");
fprintf(linearize->file->pointer, "# t_prime\tM\tMB\tT\n");
// TODO: define 50 as a constant
// TODO: choose 50
double t_prime = 0;
for (unsigned int i = 0; i <= 50; i++) {
t_prime = i/50.0;
x1[0] = params.x1 + t_prime * (params.x2 - params.x1);
x1[1] = params.y1 + t_prime * (params.y2 - params.y1);
x1[2] = params.z1 + t_prime * (params.z2 - params.z1);
if (t_prime < 0.5) {
fprintf(linearize->file->pointer, "%.2f\t%e\t%e\t%e\n", t_prime, M, M+((T1>M)?(+1):(-1))*B*(1-2*t_prime), feenox_function_eval(total_function, x1));
} else {
fprintf(linearize->file->pointer, "%.2f\t%e\t%e\t%e\n", t_prime, M, M+((T2>M)?(-1):(+1))*B*(1-2*t_prime), feenox_function_eval(total_function, x1));
}
}
}
feenox_free(total_name);
*/
return FEENOX_OK;
}
double feenox_linearization_integrand_membrane(double t, void *params) {
struct linearize_params_t *p = (struct linearize_params_t *)params;
double t_prime = t/p->length;
double x[3];
x[0] = p->x1 + t_prime * (p->x2 - p->x1);
x[1] = p->y1 + t_prime * (p->y2 - p->y1);
x[2] = p->z1 + t_prime * (p->z2 - p->z1);
return feenox_function_eval(p->function, x);
}
double feenox_linearization_integrand_bending(double t, void *params) {
struct linearize_params_t *p = (struct linearize_params_t *)params;
double t_prime = t/p->length;
double x[3];
x[0] = p->x1 + t_prime * (p->x2 - p->x1);
x[1] = p->y1 + t_prime * (p->y2 - p->y1);
x[2] = p->z1 + t_prime * (p->z2 - p->z1);
return feenox_function_eval(p->function, x) * (0.5*p->length - t);
}
double feenox_linearization_integrate(gsl_function *F, function_t *function) {
struct linearize_params_t *p = (struct linearize_params_t *)F->params;
p->function = function;
double result = 0;
double epsabs = 0;
// TODO: choose the epsresl in the input file
double epsrel = 5e-3;
size_t limit = DEFAULT_INTEGRATION_INTERVALS;
int key = GSL_INTEG_GAUSS31;
double abserr = 0;
gsl_integration_workspace *w = gsl_integration_workspace_alloc(limit);
if (w == NULL) {
feenox_runtime_error();
}
gsl_integration_qag(F, 0, p->length, epsabs, epsrel, limit, key, w, &result, &abserr);
gsl_integration_workspace_free(w);
return result;
}
int feenox_linearization_compute_and_store(function_t *total_function, const double x1[], const double x2[], double M, double MBplus, double MBminus, var_t *var_M, var_t *var_MB, var_t *var_P) {
// OJO! esto no es asi, hay que hacer un tensor que sea la diferencia
double T1 = feenox_function_eval(total_function, x1);
double T2 = feenox_function_eval(total_function, x2);
double MB = 0;
double T = 0;
// double B = 0;
if (total_function != mechanical.sigma3) {
MB = (MBplus > MBminus) ? MBplus : MBminus;
T = (T1 > T2) ? T1 : T2;
// B = MB - M;
} else {
MB = (MBplus < MBminus) ? MBplus : MBminus;
T = (T1 < T2) ? T1 : T2;
// B = M - MB;
}
double P = T - MB;
// store results
if (var_M != NULL) {
feenox_var_value(var_M) = M;
}
if (var_MB != NULL) {
feenox_var_value(var_MB) = MB;
}
if (var_P != NULL) {
feenox_var_value(var_P) = P;
}
return FEENOX_OK;
}
feenox-1.2/src/pdes/mechanical/mechanical.h 0000664 0001750 0001750 00000017524 15055303016 014375 /*------------ -------------- -------- --- ----- --- -- - -
* feenox mechanical header
*
* Copyright (C) 2021-2025 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#ifndef MECHANICAL_H
#define MECHANICAL_H
#define BC_TYPE_MECHANICAL_UNDEFINED 0
#define BC_TYPE_MECHANICAL_DISPLACEMENT 1
#define BC_TYPE_MECHANICAL_TANGENTIAL_SYMMETRY 2
#define BC_TYPE_MECHANICAL_RADIAL_SYMMETRY 3
#define BC_TYPE_MECHANICAL_MULTIDOF_EXPRESSION 4
#define BC_TYPE_MECHANICAL_PRESSURE_TENSION 16
#define BC_TYPE_MECHANICAL_PRESSURE_COMPRESSION 17
#define BC_TYPE_MECHANICAL_TRACTION 18
#define BC_TYPE_MECHANICAL_FORCE 19
typedef struct mechanical_t mechanical_t;
typedef struct mechanical_material_ctx_t mechanical_material_ctx_t;
typedef struct feenox_linearize_t feenox_linearize_t;
struct mechanical_material_ctx_t {
enum {
material_model_unknown,
material_model_elastic_isotropic,
material_model_elastic_orthotropic,
material_model_hyperelastic_svk,
material_model_hyperelastic_neohookean,
} material_model;
enum {
thermal_expansion_model_none,
thermal_expansion_model_isotropic,
thermal_expansion_model_orthotropic,
} thermal_expansion_model;
// TODO: union with pointers to specific material data
};
struct mechanical_t {
int nonlinear_geom;
int nonlinear_material;
enum {
variant_full,
variant_plane_stress,
variant_plane_strain,
variant_axisymmetric,
} variant;
// global models using the enums above
// if different volumes have different models, these are unknown and each material uses its own context
int material_model;
int thermal_expansion_model;
// isotropic properties
distribution_t E; // Young's modulus
distribution_t nu; // Poisson's ratio
distribution_t lambda; // Lame
distribution_t mu; // Lame
distribution_t K; // bulk modulus
distribution_t alpha; // (mean) thermal expansion coefficient
// orthotropic properties
distribution_t E_x, E_y, E_z; // Young's moduli
distribution_t nu_xy, nu_yz, nu_zx; // Poisson's ratios
distribution_t G_xy, G_yz, G_zx; // Shear moduli
distribution_t alpha_x, alpha_y, alpha_z; // (mean) thermal expansion coefficient
// temperature field
distribution_t T; // temperature distribution
distribution_t T_ref; // reference temperature (has to be a constant)
double T0; // evaluated T_ref
// volumetric force densityies
distribution_t f_x;
distribution_t f_y;
distribution_t f_z;
// flags to speed up things
int uniform_properties;
int constant_properties;
int uniform_expansion;
int constant_expansion;
// this one depends if we are 3D or 2D
unsigned int stress_strain_size;
// this one changes when changing the element type (even between BCs and bulk)
unsigned int n_nodes;
// holder for the rigid-body displacements
#ifdef HAVE_PETSC
MatNullSpace rigid_body_base;
#endif
// C-like virtual methods (i.e. function pointers)
// TODO: return matrix
int (*compute_material_tangent)(const double *x, material_t *material);
gsl_matrix *(*compute_PK2)(const double *x, material_t *material);
int (*compute_stress_from_strain)(node_t *node, element_t *element, unsigned int j,
double epsilonx, double epsilony, double epsilonz, double gammaxy, double gammayz, double gammazx,
double *sigmax, double *sigmay, double *sigmaz, double *tauxy, double *tauyz, double *tauzx);
gsl_vector *(*compute_thermal_strain)(const double *x, material_t *material);
int (*compute_thermal_stress)(const double *x, material_t *material, double *sigmat_x, double *sigmat_y, double *sigmat_z);
// auxiliary intermediate matrices
gsl_matrix *C_tangent; // stress-strain tangent matrix (i.e. fourth-order tensor in voigt projection 6x6 for 3d)
gsl_matrix *B_shape; // matrix with the derivatives of the shape functions 6x(3*n_nodes) for 3d
gsl_matrix *CB; // product of C_tangent times B_shape, 6x(3*n_nodes) for 3d
gsl_vector *et; // thermal strain in voigt, size 6 for 3d
gsl_vector *Cet; // product of C times et, size 6 for 3d
// non-linear stuff
gsl_matrix *eye; // 3x3 identity (the symbol I is already taken by complex.h)
gsl_matrix *grad_u; // displacement gradient
gsl_matrix *F; // deformation gradient
gsl_matrix *F_inv; // inverse deformation gradient
double J; // determinant of F
double J23; // isochoric factor
double trC; // trace of C
gsl_matrix *eps; // green-lagrange strain tensor
gsl_matrix *B; // left green-lagrange strain tensor
gsl_matrix *C; // right green-lagrange strain tensor
gsl_matrix *C_inv; // inverse right green-lagrange strain tensor
// gsl_matrix *PK1; // first piola-kirchoff stress
gsl_matrix *PK2; // second piola-kirchoff stress
gsl_vector *PK2_voigt; // PK2 in voigt notation
gsl_matrix *Sigma; // 9x9 expansion of PK2
gsl_matrix *cauchy; // cauchy stress tensor
gsl_matrix *G; // matrix with derivatives of shape functions
gsl_matrix *SigmaG; // temporary holder
// temporary things
gsl_matrix *SF;
gsl_matrix *S_ortho;
gsl_matrix *C_ortho;
gsl_matrix *invCxI;
gsl_matrix *IxinvC;
gsl_matrix *invCxinvC;
gsl_vector *invC_voigt;
gsl_matrix *invCxinvC_ikjl;
gsl_matrix *invCxinvC_iljk;
gsl_matrix *tmp1;
gsl_matrix *tmp2;
gsl_matrix *tmp3;
// double hourglass_epsilon;
var_t *ldef;
// var_t *ldef_check;
// for implicit multi-dof BCs
var_t *displ_for_bc[3];
var_t *strain_energy;
var_t *displ_max;
var_t *displ_max_x;
var_t *displ_max_y;
var_t *displ_max_z;
var_t *u_at_displ_max;
var_t *v_at_displ_max;
var_t *w_at_displ_max;
var_t *sigma_max;
var_t *sigma_max_x;
var_t *sigma_max_y;
var_t *sigma_max_z;
var_t *delta_sigma_max;
var_t *u_at_sigma_max;
var_t *v_at_sigma_max;
var_t *w_at_sigma_max;
// strains
function_t *exx;
function_t *eyy;
function_t *ezz;
function_t *exy;
function_t *eyz;
function_t *ezx;
// cauchy stresses
function_t *sigmax;
function_t *sigmay;
function_t *sigmaz;
function_t *tauxy;
function_t *tauyz;
function_t *tauzx;
function_t *sigma1; // principal stresses
function_t *sigma2;
function_t *sigma3;
function_t *sigma; // von mises
function_t *delta_sigma; // uncertainty
function_t *tresca;
feenox_linearize_t *linearizes;
};
struct feenox_linearize_t {
expr_t x1;
expr_t y1;
expr_t z1;
expr_t x2;
expr_t y2;
expr_t z2;
// TODO: ignore through thickness
// int ignore_through_thickness;
file_t *file;
// von mises
var_t *M; // membrane
var_t *MB; // membrane plus bending
var_t *P; // peak
// tresca
var_t *Mt;
var_t *MBt;
var_t *Pt;
// principal1
var_t *M1;
var_t *MB1;
var_t *P1;
// principal2
var_t *M2;
var_t *MB2;
var_t *P2;
// principal3
var_t *M3;
var_t *MB3;
var_t *P3;
feenox_linearize_t *next;
};
extern mechanical_t mechanical;
#endif /* MECHANICAL_H */
feenox-1.2/src/pdes/mechanical/methods.h 0000664 0001750 0001750 00000020473 15055303016 013751 /*------------ -------------- -------- --- ----- --- -- - -
* feenox mechanical methods
*
* Copyright (C) 2021-2025 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#ifndef MECHANICAL_METHODS_H
#define MECHANICAL_METHODS_H
// mechanical/parse.c
extern int feenox_problem_parse_problem_mechanical(const char *);
extern int feenox_problem_parse_write_post_mechanical(mesh_write_t *mesh_write, const char *);
extern int feenox_parse_linearize_stress();
// mechanical/init.c
extern int feenox_problem_parse_time_init_mechanical(void);
extern int feenox_problem_init_runtime_mechanical(void);
#ifdef HAVE_PETSC
extern int feenox_problem_setup_pc_mechanical(PC pc);
extern int feenox_problem_setup_ksp_mechanical(KSP ksp);
extern int feenox_problem_setup_snes_mechanical(SNES snes);
extern int feenox_problem_compute_rigid_nullspace(MatNullSpace *nullspace);
#endif
// mechanical/bc.c
extern int feenox_problem_bc_parse_mechanical(bc_data_t *bc_data, const char *lhs, char *rhs);
extern int feenox_problem_bc_set_mechanical_displacement(bc_data_t *bc_data, element_t *e, size_t j_global);
extern int feenox_problem_bc_set_mechanical_symmetry(bc_data_t *bc_data, element_t *e, size_t j_global);
extern int feenox_problem_bc_set_mechanical_radial(bc_data_t *bc_data, element_t *e, size_t j_global);
extern int feenox_problem_bc_set_mechanical_multifreedom(bc_data_t *bc_data, element_t *e, size_t j_global);
extern double feenox_mechanical_gsl_function_of_uvw(double x, void *params);
extern int feenox_problem_bc_set_mechanical_compression(bc_data_t *bc_data, element_t *e, unsigned int q);
extern int feenox_problem_bc_set_mechanical_tension(bc_data_t *bc_data, element_t *e, unsigned int q);
extern int feenox_problem_bc_set_mechanical_normal_stress(bc_data_t *bc_data, element_t *e, unsigned int q, signed int sign);
extern int feenox_problem_bc_set_mechanical_traction(bc_data_t *bc_data, element_t *e, unsigned int q);
extern int feenox_problem_bc_set_mechanical_force(bc_data_t *bc_data, element_t *e, unsigned int q);
// mechanical/bulk.c
extern int feenox_problem_build_allocate_aux_mechanical(unsigned int n_nodes);
extern int feenox_problem_build_volumetric_gauss_point_mechanical(element_t *, unsigned int q);
extern int feenox_problem_build_volumetric_gauss_point_mechanical_nonlinear(element_t *, unsigned int q);
// mechanical/strain.c
extern gsl_matrix *feenox_problem_mechanical_compute_gradient_displacement(const gsl_matrix *dhdx, const gsl_vector *u);
extern gsl_matrix *feenox_problem_mechanical_compute_gradient_deformation(const gsl_matrix *grad_u);
extern gsl_matrix *feenox_problem_mechanical_compute_strain_cauchy_green_left(const gsl_matrix *F);
extern gsl_matrix *feenox_problem_mechanical_compute_strain_green_lagrange(const gsl_matrix *C);
// ---- material models ---------------------------------
// -- linear elastic isotropic ------
// init
extern int feenox_mechanical_material_init_linear_elastic(material_t *material, int i);
extern int feenox_mechanical_material_setup_linear_elastic(void);
// stress-strain 4th-order tensor
extern void feenox_problem_mechanical_compute_lambda_mu(const double *x, material_t *material, double *lambda, double *mu);
extern int feenox_problem_mechanical_compute_tangent_matrix_C_linear_elastic(const double *x, material_t *material);
extern int feenox_problem_mechanical_compute_tangent_matrix_C_elastic_plane_stress(const double *x, material_t *material);
extern int feenox_problem_mechanical_compute_tangent_matrix_C_elastic_plane_strain(const double *x, material_t *material);
// stress measure
extern gsl_matrix *feenox_problem_build_mechanical_stress_measure_linear_elastic(const double *x, material_t *material);
// -- linear elastic orthotropic ------
// init
extern int feenox_mechanical_material_init_linear_elastic_orthotropic(material_t *material, int i);
extern int feenox_mechanical_material_setup_linear_elastic_orthotropic(void);
// stress-strain 4th-order tensor
extern int feenox_problem_mechanical_compute_tangent_matrix_C_elastic_orthotropic(const double *x, material_t *material);
// stress measure
// -- saint venant-kirchoff
// init
extern int feenox_mechanical_material_init_svk(material_t *material, int i);
extern int feenox_mechanical_material_setup_svk(void);
// -- neo-hookean ------
// init
extern int feenox_mechanical_material_init_neohookean(material_t *material, int i);
extern int feenox_mechanical_material_setup_neohookean(void);
// stress measure
extern gsl_matrix *feenox_problem_build_mechanical_stress_measure_neohookean(const double *x, material_t *material);
extern gsl_matrix *feenox_problem_mechanical_compute_stress_PK2_neohookean(const double *x, material_t *material);
extern int feenox_problem_mechanical_compute_tangent_matrix_C_neohookean(const double *x, material_t *material);
// stress.c
extern gsl_matrix *feenox_cauchy_stress_cauchy_from_PK2(const gsl_matrix *F, const gsl_matrix *PK2, double J);
extern int feenox_problem_mechanical_compute_stress_first_piola_kirchoff(void);
extern gsl_matrix *feenox_problem_mechanical_compute_stress_PK2_elastic(const double *x, material_t *material);
extern gsl_matrix *feenox_problem_mechanical_compute_stress_cauchy_neohookean(const double *x, material_t *material);
extern int feenox_stress_from_strain_linear_elastic(node_t *node, element_t *element, unsigned int j,
double epsilonx, double epsilony, double epsilonz, double gammaxy, double gammayz, double gammazx,
double *sigmax, double *sigmay, double *sigmaz, double *tauxy, double *tauyz, double *tauzx);
// thermal effects
extern gsl_vector *feenox_problem_mechanical_compute_thermal_strain_isotropic(const double *x, material_t *material);
extern int feenox_problem_mechanical_compute_thermal_stress_isotropic (const double *x, material_t *material, double *sigmat_x, double *sigmat_y, double *sigmat_z);
extern gsl_vector *feenox_problem_mechanical_compute_thermal_strain_orthotropic(const double *x, material_t *material);
extern int feenox_problem_mechanical_compute_thermal_stress_orthotropic (const double *x, material_t *material, double *sigmat_x, double *sigmat_y, double *sigmat_z);
// mechanical/post.c
extern int feenox_problem_solve_post_mechanical(void);
// mechanical/gradient.c
extern int feenox_problem_gradient_fill_mechanical(void);
extern int feenox_problem_gradient_properties_at_element_nodes_mechanical(element_t *element, mesh_t *mesh);
extern int feenox_problem_gradient_fluxes_at_node_alloc_mechanical(node_t *node);
extern int feenox_problem_gradient_add_elemental_contribution_to_node_mechanical(node_t *node, element_t *element, unsigned int j, double rel_weight);
extern int feenox_problem_gradient_fill_fluxes_mechanical(mesh_t *mesh, size_t j);
// mechanical/stress.c
extern int feenox_stress_from_strain_linear(node_t *node, element_t *element, unsigned int j, double epsilonx, double epsilony, double epsilonz, double gammaxy, double gammayz, double gammazx, double *sigmax, double *sigmay, double *sigmaz, double *tauxy, double *tauyx, double *tauzx);
extern int feenox_principal_stress_from_cauchy(double sigmax, double sigmay, double sigmaz, double tauxy, double tauyz, double tauzx, double *sigma1, double *sigma2, double *sigma3);
extern double feenox_vonmises_from_principal(double sigma1, double sigma2, double sigma3);
extern double feenox_vonmises_from_stress_tensor(double sigmax, double sigmay, double sigmaz, double tauxy, double tauyz, double tauzx);
extern double feenox_tresca_from_stress_tensor(double sigmax, double sigmay, double sigmaz, double tauxy, double tauyz, double tauzx);
extern int feenox_strain_energy(void);
// mechanical/linearize.c
extern int feenox_instruction_linearize(void *arg);
#endif
feenox-1.2/src/pdes/mechanical/parser.c 0000664 0001750 0001750 00000027227 15055303016 013601 /*------------ -------------- -------- --- ----- --- -- - -
* FeenoX parser for mechanical-specific keywords
*
* Copyright (C) 2022--2025 Jeremy Theler
*
* This file is part of FeenoX.
*
* FeenoX is free software: you can redistribute it and/or modify
* it under the terms "of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "../../parser/parser.h"
#include "mechanical.h"
int feenox_problem_parse_problem_mechanical(const char *token) {
///kw_pde+PROBLEM+detail * `mechanical` solves the elastic problem using a displacement-based FEM formulation.
///kw_pde+PROBLEM+detail If the mesh is two-dimensional and not `AXISYMMETRIC`, either
///kw_pde+PROBLEM+detail `plane_stress` or `plane_strain` has to be given instead of `mechanical`.
if (token != NULL) {
if (strcasecmp(token, "plane_stress") == 0) {
mechanical.variant = variant_plane_stress;
} else if (strcasecmp(token, "plane_strain") == 0) {
mechanical.variant = variant_plane_strain;
} else {
feenox_push_error_message("undefined keyword '%s'", token);
return FEENOX_ERROR;
}
} else {
// if token is NULL we have to do the parse-time initialization
feenox_call(feenox_problem_parse_time_init_mechanical());
}
return FEENOX_OK;
}
int feenox_problem_parse_write_post_mechanical(mesh_write_t *mesh_write, const char *token) {
if (strcmp(token, "all") == 0) {
feenox_call(feenox_problem_parse_write_post_mechanical(mesh_write, "displacements"));
feenox_call(feenox_problem_parse_write_post_mechanical(mesh_write, "strains"));
feenox_call(feenox_problem_parse_write_post_mechanical(mesh_write, "stresses"));
feenox_call(feenox_problem_parse_write_post_mechanical(mesh_write, "principal"));
feenox_call(feenox_problem_parse_write_post_mechanical(mesh_write, "vonmises"));
feenox_call(feenox_problem_parse_write_post_mechanical(mesh_write, "tresca"));
} else if (strcmp(token, "displacements") == 0 || strcmp(token, "displ") == 0) {
char *tokens[3] = {NULL, NULL, NULL};
for (unsigned int g = 0; g < 3; g++) {
tokens[g] = strdup((g < feenox.pde.dofs) ? feenox.pde.unknown_name[g] : "0");
}
feenox_call(feenox_add_post_field(mesh_write, 3, tokens, "displacements", field_location_nodes));
for (unsigned int g = 0; g < 3; g++) {
feenox_free(tokens[g]);
}
} else if (strcmp(token, "strains") == 0 || strcmp(token, "strain") == 0) {
/*
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
for (unsigned int m = 0; m < feenox.pde.dim; m++) {
feenox_call(feenox_add_post_field(mesh_write, 1, &feenox.pde.gradient[g][m]->name, NULL, field_location_nodes));
}
}
*/
feenox_call(feenox_add_post_field(mesh_write, 1, &mechanical.exx->name, NULL, field_location_nodes));
feenox_call(feenox_add_post_field(mesh_write, 1, &mechanical.eyy->name, NULL, field_location_nodes));
feenox_call(feenox_add_post_field(mesh_write, 1, &mechanical.exy->name, NULL, field_location_nodes));
if (feenox.pde.dim == 3) {
feenox_call(feenox_add_post_field(mesh_write, 1, &mechanical.ezz->name, NULL, field_location_nodes));
feenox_call(feenox_add_post_field(mesh_write, 1, &mechanical.eyz->name, NULL, field_location_nodes));
feenox_call(feenox_add_post_field(mesh_write, 1, &mechanical.ezx->name, NULL, field_location_nodes));
}
} else if (strcmp(token, "stresses") == 0 || strcmp(token, "stress") == 0) {
feenox_call(feenox_add_post_field(mesh_write, 1, &mechanical.sigmax->name, NULL, field_location_nodes));
feenox_call(feenox_add_post_field(mesh_write, 1, &mechanical.sigmay->name, NULL, field_location_nodes));
if (feenox.pde.dim == 3) {
feenox_call(feenox_add_post_field(mesh_write, 1, &mechanical.sigmaz->name, NULL, field_location_nodes));
}
feenox_call(feenox_add_post_field(mesh_write, 1, &mechanical.tauxy->name, NULL, field_location_nodes));
if (feenox.pde.dim == 3) {
feenox_call(feenox_add_post_field(mesh_write, 1, &mechanical.tauyz->name, NULL, field_location_nodes));
feenox_call(feenox_add_post_field(mesh_write, 1, &mechanical.tauzx->name, NULL, field_location_nodes));
}
} else if (strcmp(token, "principal") == 0) {
feenox_call(feenox_add_post_field(mesh_write, 1, &mechanical.sigma1->name, NULL, field_location_nodes));
feenox_call(feenox_add_post_field(mesh_write, 1, &mechanical.sigma2->name, NULL, field_location_nodes));
feenox_call(feenox_add_post_field(mesh_write, 1, &mechanical.sigma3->name, NULL, field_location_nodes));
} else if (strcmp(token, "vonmises") == 0) {
feenox_call(feenox_add_post_field(mesh_write, 1, &mechanical.sigma->name, NULL, field_location_nodes));
} else if (strcmp(token, "tresca") == 0) {
feenox_call(feenox_add_post_field(mesh_write, 1, &mechanical.tresca->name, NULL, field_location_nodes));
} else {
feenox_push_error_message("undefined keyword '%s' for mechanical WRITE_RESULTS", token);
return FEENOX_ERROR;
}
return FEENOX_OK;
}
int feenox_parse_linearize_stress(void) {
feenox_linearize_t *linearize = NULL;
feenox_check_alloc(linearize = calloc(1, sizeof(feenox_linearize_t)));
///kw_mechanical+LINEARIZE_STRESS+desc Compute linearized membrane and/or bending stresses according to ASME\ VIII Div\ 2 Sec\ 5.
///kw_mechanical+LINEARIZE_STRESS+usage LINEARIZE_STRESS
char *token = NULL;
while ((token = feenox_get_next_token(NULL)) != NULL) {
///kw_mechanical+LINEARIZE_STRESS+usage FROM
///kw_mechanical+LINEARIZE_STRESS+detail The stress classification line (SCL) defined by the coordinates of
///kw_mechanical+LINEARIZE_STRESS+detail the points\ $[x_1, y_1, z_1]$ and $[x_2, y_2, z_2]$.
///kw_mechanical+LINEARIZE_STRESS+detail For two-dimensional problems, the $z$ coordinate has to be given as well.
if (strcasecmp(token, "FROM") == 0) {
feenox_call(feenox_parser_expression(&linearize->x1));
feenox_call(feenox_parser_expression(&linearize->y1));
feenox_call(feenox_parser_expression(&linearize->z1));
///kw_mechanical+LINEARIZE_STRESS+usage TO @
} else if (strcasecmp(token, "TO") == 0) {
feenox_call(feenox_parser_expression(&linearize->x2));
feenox_call(feenox_parser_expression(&linearize->y2));
feenox_call(feenox_parser_expression(&linearize->z2));
///kw_mechanical+LINEARIZE_STRESS+detail The linearized membrane, membrane plus bending and peak total stresses are
///kw_mechanical+LINEARIZE_STRESS+detail stored in the variables given by the keywords `M`, `MB` and `P`, respectively.
///kw_mechanical+LINEARIZE_STRESS+detail These three variables use the von\ Mises stress intensity.
///kw_mechanical+LINEARIZE_STRESS+usage [ M ]
} else if (strcasecmp(token, "M") == 0) {
feenox_call(feenox_parser_get_or_define_variable(&linearize->M));
mechanical.sigma->used = 1;
///kw_mechanical+LINEARIZE_STRESS+usage [ MB ]
} else if (strcasecmp(token, "MB") == 0) {
feenox_call(feenox_parser_get_or_define_variable(&linearize->MB));
mechanical.sigma->used = 1;
///kw_mechanical+LINEARIZE_STRESS+usage [ P ] @
} else if (strcasecmp(token, "P") == 0) {
feenox_call(feenox_parser_get_or_define_variable(&linearize->P));
mechanical.sigma->used = 1;
///kw_mechanical+LINEARIZE_STRESS+detail Variables `Mt`, `MBt` and `Pt` use the Tresca stress intensity.
///kw_mechanical+LINEARIZE_STRESS+usage [ Mt ]
} else if (strcasecmp(token, "Mt") == 0) {
feenox_call(feenox_parser_get_or_define_variable(&linearize->Mt));
mechanical.tresca->used = 1;
///kw_mechanical+LINEARIZE_STRESS+usage [ MBt ]
} else if (strcasecmp(token, "MBt") == 0) {
feenox_call(feenox_parser_get_or_define_variable(&linearize->MBt));
mechanical.tresca->used = 1;
///kw_mechanical+LINEARIZE_STRESS+usage [ Pt ] @
} else if (strcasecmp(token, "Pt") == 0) {
feenox_call(feenox_parser_get_or_define_variable(&linearize->Pt));
mechanical.tresca->used = 1;
///kw_mechanical+LINEARIZE_STRESS+detail Variables `M1` (or 2 or 3), `MB1` (or 2 or 3) and `P1` (or 2 or 3)
///kw_mechanical+LINEARIZE_STRESS+detail use the principal stress 1 (or 2 or 3).
///kw_mechanical+LINEARIZE_STRESS+usage [ M1 ]
} else if (strcasecmp(token, "M1") == 0) {
feenox_call(feenox_parser_get_or_define_variable(&linearize->M1));
mechanical.sigma1->used = 1;
///kw_mechanical+LINEARIZE_STRESS+usage [ MB1 ]
} else if (strcasecmp(token, "MB1") == 0) {
feenox_call(feenox_parser_get_or_define_variable(&linearize->MB1));
mechanical.sigma1->used = 1;
///kw_mechanical+LINEARIZE_STRESS+usage [ P1 ] @
} else if (strcasecmp(token, "P1") == 0) {
feenox_call(feenox_parser_get_or_define_variable(&linearize->P1));
mechanical.sigma1->used = 1;
///kw_mechanical+LINEARIZE_STRESS+usage [ M2 ]
} else if (strcasecmp(token, "M2") == 0) {
feenox_call(feenox_parser_get_or_define_variable(&linearize->M2));
mechanical.sigma2->used = 1;
///kw_mechanical+LINEARIZE_STRESS+usage [ MB2 ]
} else if (strcasecmp(token, "MB2") == 0) {
feenox_call(feenox_parser_get_or_define_variable(&linearize->MB2));
mechanical.sigma2->used = 1;
///kw_mechanical+LINEARIZE_STRESS+usage [ P2 ] @
} else if (strcasecmp(token, "P2") == 0) {
feenox_call(feenox_parser_get_or_define_variable(&linearize->P2));
mechanical.sigma2->used = 1;
///kw_mechanical+LINEARIZE_STRESS+usage [ M3 ]
} else if (strcasecmp(token, "M3") == 0) {
feenox_call(feenox_parser_get_or_define_variable(&linearize->M3));
mechanical.sigma3->used = 1;
///kw_mechanical+LINEARIZE_STRESS+usage [ MB3 ]
} else if (strcasecmp(token, "MB3") == 0) {
feenox_call(feenox_parser_get_or_define_variable(&linearize->MB3));
mechanical.sigma3->used = 1;
///kw_mechanical+LINEARIZE_STRESS+usage [ P3 ] @
} else if (strcasecmp(token, "P3") == 0) {
feenox_call(feenox_parser_get_or_define_variable(&linearize->P3));
mechanical.sigma3->used = 1;
///kw_mechanical+LINEARIZE_STRESS+usage [ FILE ]
///kw_mechanical+LINEARIZE_STRESS+detail If the `FILE` keyword is given, the total, membrane and membrane plus bending
///kw_mechanical+LINEARIZE_STRESS++detail stresses are written as a function of a scalar $t \in [0,1]$.
///kw_mechanical+LINEARIZE_STRESS++detail Moreover, the individual elements of the membrane and bending stress tensors are written
///kw_mechanical+LINEARIZE_STRESS++detail within comments (i.e. lines starting with the hash symbol `#`).
//TODO: decir como se plotea y como se hace un PDF
} else if (strcasecmp(token, "FILE") == 0) {
feenox_call(feenox_parser_file(&linearize->file));
} else {
feenox_push_error_message("unknown keyword '%s'", token);
return FEENOX_ERROR;
}
}
feenox_call(feenox_add_instruction(feenox_instruction_linearize, linearize));
LL_APPEND(mechanical.linearizes, linearize);
return FEENOX_OK;
}
feenox-1.2/src/pdes/mechanical/post.c 0000664 0001750 0001750 00000010332 15055303016 013257 /*------------ -------------- -------- --- ----- --- -- - -
* feenox mechanical post-processing routines
*
* Copyright (C) 2021-2022 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "mechanical.h"
int feenox_problem_solve_post_mechanical(void) {
if (mechanical.strain_energy->used) {
feenox_call(feenox_strain_energy());
}
int uses_displ_max = (mechanical.displ_max->used ||
mechanical.displ_max_x->used ||
mechanical.displ_max_y->used ||
mechanical.displ_max_z->used ||
mechanical.u_at_displ_max->used ||
mechanical.v_at_displ_max->used ||
mechanical.w_at_displ_max->used);
int uses_sigma_max = (mechanical.sigma_max->used ||
mechanical.sigma_max_x->used ||
mechanical.sigma_max_y->used ||
mechanical.sigma_max_z->used ||
mechanical.u_at_sigma_max->used ||
mechanical.v_at_sigma_max->used ||
mechanical.w_at_sigma_max->used);
if (uses_displ_max == 0 && uses_sigma_max == 0) {
return FEENOX_OK;
}
double displ2 = 0;
double max_displ2 = 0;
double sigma_max = 0;
for (size_t j = 0; j < feenox.pde.mesh->n_nodes; j++) {
if (uses_displ_max) {
displ2 = 0;
for (unsigned int g = 0; g < feenox.pde.dofs; g++) {
displ2 += gsl_pow_2(feenox_vector_get(feenox.pde.solution[g]->vector_value, j));
}
if (displ2 >= max_displ2) {
max_displ2 = displ2;
feenox_var_value(mechanical.displ_max) = sqrt(displ2);
feenox_var_value(mechanical.displ_max_x) = feenox_vector_get(feenox.pde.solution[0]->vector_argument[0], j);
feenox_var_value(mechanical.displ_max_y) = feenox_vector_get(feenox.pde.solution[0]->vector_argument[1], j);
if (feenox.pde.dim == 3) {
feenox_var_value(mechanical.displ_max_z) = feenox_vector_get(feenox.pde.solution[0]->vector_argument[2], j);
}
feenox_var_value(mechanical.u_at_displ_max) = feenox_vector_get(feenox.pde.solution[0]->vector_value, j);
feenox_var_value(mechanical.v_at_displ_max) = feenox_vector_get(feenox.pde.solution[1]->vector_value, j);
if (feenox.pde.dim == 3) {
feenox_var_value(mechanical.w_at_displ_max) = feenox_vector_get(feenox.pde.solution[2]->vector_value, j);
}
}
}
if (uses_sigma_max) {
if (feenox_vector_get(mechanical.sigma->vector_value, j) > sigma_max) {
feenox_var_value(mechanical.sigma_max) = feenox_vector_get(mechanical.sigma->vector_value, j);
// TODO: not cache friendly!
feenox_var_value(mechanical.sigma_max_x) = feenox_vector_get(feenox.pde.solution[0]->vector_argument[0], j);
feenox_var_value(mechanical.sigma_max_y) = feenox_vector_get(feenox.pde.solution[0]->vector_argument[1], j);
if (feenox.pde.dim == 3) {
feenox_var_value(mechanical.sigma_max_z) = feenox_vector_get(feenox.pde.solution[0]->vector_argument[2], j);
}
feenox_var_value(mechanical.u_at_sigma_max) = feenox_vector_get(feenox.pde.solution[0]->vector_value, j);
feenox_var_value(mechanical.v_at_sigma_max) = feenox_vector_get(feenox.pde.solution[1]->vector_value, j);
if (feenox.pde.dim == 3) {
feenox_var_value(mechanical.w_at_sigma_max) = feenox_vector_get(feenox.pde.solution[2]->vector_value, j);
}
}
}
}
return FEENOX_OK;
}
feenox-1.2/src/pdes/mechanical/strain.c 0000664 0001750 0001750 00000004314 15055303016 013575 /*------------ -------------- -------- --- ----- --- -- - -
* feenox routines to compute strains
*
* Copyright (C) 2025 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "mechanical.h"
gsl_matrix *feenox_problem_mechanical_compute_gradient_displacement(const gsl_matrix *dhdx, const gsl_vector *u) {
gsl_matrix_set_zero(mechanical.grad_u);
for (int row = 0; row < 3; row++) {
for (int col = 0; col < 3; col++) {
for (int j = 0; j < mechanical.n_nodes; j++) {
gsl_matrix_add_to_element(mechanical.grad_u, row, col, gsl_matrix_get(dhdx, col, j) * gsl_vector_get(u, 3*j + row));
}
}
}
return mechanical.grad_u;
}
gsl_matrix *feenox_problem_mechanical_compute_gradient_deformation(const gsl_matrix *grad_u) {
// deformation gradient
// F = I + grad_u
gsl_matrix_memcpy(mechanical.F, mechanical.eye);
gsl_matrix_add(mechanical.F, grad_u);
return mechanical.F;
}
gsl_matrix *feenox_problem_mechanical_compute_strain_cauchy_green_left(const gsl_matrix *F) {
// left cauchy-green tensor
// C = Ft * F
feenox_blas_BtB(F, 1.0, mechanical.C);
return mechanical.C;
}
gsl_matrix *feenox_problem_mechanical_compute_strain_green_lagrange(const gsl_matrix *C) {
// green-lagrange strain tensor
// E = 1/2 * (C - I)
gsl_matrix_memcpy(mechanical.eps, C);
gsl_matrix_sub(mechanical.eps, mechanical.eye);
gsl_matrix_scale(mechanical.eps, 0.5);
return mechanical.eps;
}
feenox-1.2/src/pdes/mechanical/stress.c 0000664 0001750 0001750 00000012135 15055303016 013620 /*------------ -------------- -------- --- ----- --- -- - -
* feenox routines to compute stresses
*
* Copyright (C) 2021-2025 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "mechanical.h"
gsl_matrix *feenox_cauchy_stress_cauchy_from_PK2(const gsl_matrix *F, const gsl_matrix *PK2, double J) {
if (J == 0) {
J = feenox_fem_determinant(F);
}
feenox_blas_BCBt(mechanical.F, PK2, NULL, 1/J, mechanical.cauchy);
return mechanical.cauchy;
}
int feenox_principal_stress_from_cauchy(double sigmax, double sigmay, double sigmaz, double tauxy, double tauyz, double tauzx, double *sigma1, double *sigma2, double *sigma3) {
// stress invariants
// https://en.wikiversity.org/wiki/Principal_stresses
double I1 = sigmax + sigmay + sigmaz;
double I2 = sigmax*sigmay + sigmay*sigmaz + sigmaz*sigmax - gsl_pow_2(tauxy) - gsl_pow_2(tauyz) - gsl_pow_2(tauzx);
double I3 = sigmax*sigmay*sigmaz - sigmax*gsl_pow_2(tauyz) - sigmay*gsl_pow_2(tauzx) - sigmaz*gsl_pow_2(tauxy) + 2*tauxy*tauyz*tauzx;
// principal stresses
double c1 = sqrt(fabs(gsl_pow_2(I1) - 3*I2));
double phi = 1.0/3.0 * acos((2.0*gsl_pow_3(I1) - 9.0*I1*I2 + 27.0*I3)/(2.0*gsl_pow_3(c1)));
if (isnan(phi)) {
phi = 0;
}
double c2 = I1/3.0;
double c3 = 2.0/3.0 * c1;
if (sigma1 != NULL) {
*sigma1 = c2 + c3 * cos(phi);
}
if (sigma2 != NULL) {
*sigma2 = c2 + c3 * cos(phi - 2.0*M_PI/3.0);
}
if (sigma3 != NULL) {
*sigma3 = c2 + c3 * cos(phi - 4.0*M_PI/3.0);
}
return FEENOX_OK;
}
int feenox_stress_from_strain_linear(node_t *node, element_t *element, unsigned int j,
double epsilonx, double epsilony, double epsilonz, double gammaxy, double gammayz, double gammazx,
double *sigmax, double *sigmay, double *sigmaz, double *tauxy, double *tauyz, double *tauzx) {
if (mechanical.uniform_properties == 0) {
mechanical.compute_material_tangent(node->x, (element->physical_group != NULL) ? element->physical_group->material : NULL);
}
*sigmax = gsl_matrix_get(mechanical.C_tangent, 0, 0) * epsilonx + gsl_matrix_get(mechanical.C_tangent, 0, 1) * epsilony + gsl_matrix_get(mechanical.C_tangent, 0, 2) * epsilonz;
*sigmay = gsl_matrix_get(mechanical.C_tangent, 1, 0) * epsilonx + gsl_matrix_get(mechanical.C_tangent, 1, 1) * epsilony + gsl_matrix_get(mechanical.C_tangent, 1, 2) * epsilonz;
*sigmaz = gsl_matrix_get(mechanical.C_tangent, 2, 0) * epsilonx + gsl_matrix_get(mechanical.C_tangent, 2, 1) * epsilony + gsl_matrix_get(mechanical.C_tangent, 2, 2) * epsilonz;
*tauxy = gsl_matrix_get(mechanical.C_tangent, 3, 3) * gammaxy;
*tauyz = gsl_matrix_get(mechanical.C_tangent, 4, 4) * gammayz;
*tauzx = gsl_matrix_get(mechanical.C_tangent, 5, 5) * gammazx;
return FEENOX_OK;
}
double feenox_vonmises_from_principal(double sigma1, double sigma2, double sigma3) {
return sqrt(0.5*(gsl_pow_2(sigma1-sigma2) + gsl_pow_2(sigma2-sigma3) + gsl_pow_2(sigma3-sigma1)));
}
double feenox_vonmises_from_stress_tensor(double sigmax, double sigmay, double sigmaz, double tauxy, double tauyz, double tauzx) {
return sqrt(0.5*(gsl_pow_2(sigmax-sigmay) + gsl_pow_2(sigmay-sigmaz) + gsl_pow_2(sigmaz-sigmax) +
6.0 * (gsl_pow_2(tauxy) + gsl_pow_2(tauyz) + gsl_pow_2(tauzx))));
}
double feenox_tresca_from_stress_tensor(double sigmax, double sigmay, double sigmaz, double tauxy, double tauyz, double tauzx) {
double sigma1 = 0;
double sigma3 = 0;
feenox_call(feenox_principal_stress_from_cauchy(sigmax, sigmay, sigmaz, tauxy, tauyz, tauzx, &sigma1, NULL, &sigma3));
return fabs(sigma1 - sigma3);
}
int feenox_strain_energy(void) {
#ifdef HAVE_PETSC
Vec Kphi = NULL;
petsc_call(VecDuplicate(feenox.pde.phi, &Kphi));
petsc_call(MatMult(feenox.pde.K, feenox.pde.phi, Kphi));
PetscScalar e = 0;
petsc_call(VecDot(feenox.pde.phi, Kphi, &e));
petsc_call(VecDestroy(&Kphi));
feenox_var_value(mechanical.strain_energy) = 0.5*e;
/*
if (fino.problem_kind == problem_kind_axisymmetric) {
wasora_var(fino.vars.strain_energy) *= 2*M_PI;
}
*/
if (feenox_var_value(feenox_special_var(in_static))) {
if ((int)(feenox_var_value(feenox_special_var(step_static))) == 1) {
*mechanical.strain_energy->initial_static = *mechanical.strain_energy->value;
}
*mechanical.strain_energy->initial_transient = *mechanical.strain_energy->value;
}
#endif
return FEENOX_OK;
}
feenox-1.2/src/pdes/mechanical/materials/ 0000775 0001750 0001750 00000000000 15055303133 014170 5 feenox-1.2/src/pdes/mechanical/materials/elastic-plane-strain.c 0000664 0001750 0001750 00000003072 15055303016 020275 /*------------ -------------- -------- --- ----- --- -- - -
* feenox elastic isotropic plane-strain mechanical material
*
* Copyright (C) 2021-2022 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "../mechanical.h"
int feenox_problem_mechanical_compute_tangent_matrix_C_elastic_plane_strain(const double *x, material_t *material) {
double lambda, mu;
feenox_problem_mechanical_compute_lambda_mu(x, material, &lambda, &mu);
double lambda2mu = lambda + 2*mu;
gsl_matrix_set(mechanical.C_tangent, 0, 0, lambda2mu);
gsl_matrix_set(mechanical.C_tangent, 0, 1, lambda);
gsl_matrix_set(mechanical.C_tangent, 1, 0, lambda);
gsl_matrix_set(mechanical.C_tangent, 1, 1, lambda2mu);
gsl_matrix_set(mechanical.C_tangent, 2, 2, mu);
return FEENOX_OK;
}
feenox-1.2/src/pdes/mechanical/materials/elastic-plane-stress.c 0000664 0001750 0001750 00000003130 15055303016 020313 /*------------ -------------- -------- --- ----- --- -- - -
* feenox elastic isotropic plane-stress mechanical material
*
* Copyright (C) 2021-2022 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "../mechanical.h"
int feenox_problem_mechanical_compute_tangent_matrix_C_elastic_plane_stress(const double *x, material_t *material) {
double E = mechanical.E.eval(&mechanical.E, x, material);
double nu = mechanical.nu.eval(&mechanical.nu, x, material);
double c1 = E/(1-nu*nu);
double c2 = nu * c1;
gsl_matrix_set(mechanical.C_tangent, 0, 0, c1);
gsl_matrix_set(mechanical.C_tangent, 0, 1, c2);
gsl_matrix_set(mechanical.C_tangent, 1, 0, c2);
gsl_matrix_set(mechanical.C_tangent, 1, 1, c1);
gsl_matrix_set(mechanical.C_tangent, 2, 2, c1*0.5*(1-nu));
return FEENOX_OK;
}
feenox-1.2/src/pdes/mechanical/materials/expansion-isotropic.c 0000664 0001750 0001750 00000005255 15055303016 020300 /*------------ -------------- -------- --- ----- --- -- - -
* feenox thermal isotropic expansion mechanical material
*
* Copyright (C) 2022 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "../mechanical.h"
gsl_vector *feenox_problem_mechanical_compute_thermal_strain_isotropic (const double *x, material_t *material) {
double delta_T = mechanical.T.eval(&mechanical.T, x, material) - mechanical.T0;
double alpha = mechanical.alpha.eval(&mechanical.alpha, x, material);
double alpha_delta_T = alpha * delta_T;
gsl_vector_set(mechanical.et, 0, alpha_delta_T);
gsl_vector_set(mechanical.et, 1, alpha_delta_T);
if (feenox.pde.dim > 2) {
gsl_vector_set(mechanical.et, 2, alpha_delta_T);
}
return mechanical.et;
}
int feenox_problem_mechanical_compute_thermal_stress_isotropic (const double *x, material_t *material, double *sigmat_x, double *sigmat_y, double *sigmat_z) {
double delta_T = mechanical.T.eval(&mechanical.T, x, material) - mechanical.T0;
double alpha = mechanical.alpha.eval(&mechanical.alpha, x, material);
double alpha_delta_T = alpha * delta_T;
// if the material is isotropic but non uniform, we do not have the proper C matrix
if (mechanical.uniform_properties == 0 && mechanical.material_model == material_model_elastic_isotropic) {
mechanical.compute_material_tangent(x, material);
}
*sigmat_x = alpha_delta_T * (gsl_matrix_get(mechanical.C_tangent, 0, 0) + gsl_matrix_get(mechanical.C_tangent, 0, 1) + gsl_matrix_get(mechanical.C_tangent, 0, 2));
*sigmat_y = alpha_delta_T * (gsl_matrix_get(mechanical.C_tangent, 1, 0) + gsl_matrix_get(mechanical.C_tangent, 1, 1) + gsl_matrix_get(mechanical.C_tangent, 1, 2));
if (feenox.pde.dofs > 2) {
*sigmat_z = alpha_delta_T * (gsl_matrix_get(mechanical.C_tangent, 2, 0) + gsl_matrix_get(mechanical.C_tangent, 2, 1) + gsl_matrix_get(mechanical.C_tangent, 2, 2));
}
return FEENOX_OK;
}
feenox-1.2/src/pdes/mechanical/materials/expansion-orthotropic.c 0000664 0001750 0001750 00000005573 15055303016 020644 /*------------ -------------- -------- --- ----- --- -- - -
* feenox thermal orthotropic expansion mechanical material
*
* Copyright (C) 2022 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "../mechanical.h"
gsl_vector *feenox_problem_mechanical_compute_thermal_strain_orthotropic (const double *x, material_t *material) {
double delta_T = mechanical.T.eval(&mechanical.T, x, material) - mechanical.T0;
gsl_vector_set(mechanical.et, 0, mechanical.alpha_x.eval(&mechanical.alpha_x, x, material) * delta_T);
gsl_vector_set(mechanical.et, 1, mechanical.alpha_y.eval(&mechanical.alpha_y, x, material) * delta_T);
if (feenox.pde.dim > 2) {
gsl_vector_set(mechanical.et, 2, mechanical.alpha_z.eval(&mechanical.alpha_z, x, material) * delta_T);
}
return mechanical.et;
}
int feenox_problem_mechanical_compute_thermal_stress_orthotropic(const double *x, material_t *material, double *sigmat_x, double *sigmat_y, double *sigmat_z) {
double delta_T = mechanical.T.eval(&mechanical.T, x, material) - mechanical.T0;
double alpha_x = mechanical.alpha_x.eval(&mechanical.alpha_x, x, material);
double alpha_y = mechanical.alpha_y.eval(&mechanical.alpha_y, x, material);
double alpha_z = mechanical.alpha_z.eval(&mechanical.alpha_z, x, material);
// if the material is isotropic but non uniform, we do not have the proper C matrix
if (mechanical.uniform_properties == 0 && mechanical.material_model == material_model_elastic_isotropic) {
mechanical.compute_material_tangent(x, material);
}
*sigmat_x = delta_T * (alpha_x * gsl_matrix_get(mechanical.C_tangent, 0, 0) + alpha_y * gsl_matrix_get(mechanical.C_tangent, 0, 1) + alpha_z * gsl_matrix_get(mechanical.C_tangent, 0, 2));
*sigmat_y = delta_T * (alpha_x * gsl_matrix_get(mechanical.C_tangent, 1, 0) + alpha_y * gsl_matrix_get(mechanical.C_tangent, 1, 1) + alpha_z * gsl_matrix_get(mechanical.C_tangent, 1, 2));
*sigmat_z = delta_T * (alpha_x * gsl_matrix_get(mechanical.C_tangent, 2, 0) + alpha_y * gsl_matrix_get(mechanical.C_tangent, 2, 1) + alpha_z * gsl_matrix_get(mechanical.C_tangent, 2, 2));
return FEENOX_OK;
}
feenox-1.2/src/pdes/mechanical/materials/hencky.c 0000664 0001750 0001750 00000000017 15055303016 015533 // placeholder
feenox-1.2/src/pdes/mechanical/materials/linear-isotropic.c 0000664 0001750 0001750 00000013622 15055303016 017543 /*------------ -------------- -------- --- ----- --- -- - -
* feenox elastic isotropic mechanical material
*
* Copyright (C) 2021-2025 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "../mechanical.h"
int feenox_mechanical_material_init_linear_elastic(material_t *material, int i) {
// TODO: allow lambda & mu
return (mechanical.E.defined_per_group[i] && mechanical.nu.defined_per_group[i]) ? material_model_elastic_isotropic : material_model_unknown;
}
int feenox_mechanical_material_setup_linear_elastic(void) {
mechanical.uniform_properties = (mechanical.E.non_uniform == 0 && mechanical.nu.non_uniform == 0);
if (mechanical.variant == variant_full) {
mechanical.compute_material_tangent = feenox_problem_mechanical_compute_tangent_matrix_C_linear_elastic;
mechanical.compute_PK2 = feenox_problem_build_mechanical_stress_measure_linear_elastic;
// not sure which one is better
mechanical.compute_stress_from_strain = mechanical.uniform_properties ? feenox_stress_from_strain_linear : feenox_stress_from_strain_linear_elastic;
} else if (mechanical.variant == variant_plane_stress) {
mechanical.compute_material_tangent = feenox_problem_mechanical_compute_tangent_matrix_C_elastic_plane_stress;
mechanical.compute_stress_from_strain = feenox_stress_from_strain_linear_elastic;
} else if (mechanical.variant == variant_plane_strain) {
mechanical.compute_material_tangent = feenox_problem_mechanical_compute_tangent_matrix_C_elastic_plane_strain;
mechanical.compute_stress_from_strain = feenox_stress_from_strain_linear_elastic;
}
return FEENOX_OK;
}
void feenox_problem_mechanical_compute_lambda_mu(const double *x, material_t *material, double *lambda, double *mu) {
double E = mechanical.E.eval(&mechanical.E, x, material);
double nu = mechanical.nu.eval(&mechanical.nu, x, material);
*lambda = E*nu/((1+nu)*(1-2*nu));
*mu = 0.5*E/(1+nu);
return;
}
int feenox_problem_mechanical_compute_tangent_matrix_C_linear_elastic(const double *x, material_t *material) {
double lambda, mu;
feenox_problem_mechanical_compute_lambda_mu(x, material, &lambda, &mu);
double lambda2mu = lambda + 2*mu;
gsl_matrix_set(mechanical.C_tangent, 0, 0, lambda2mu);
gsl_matrix_set(mechanical.C_tangent, 0, 1, lambda);
gsl_matrix_set(mechanical.C_tangent, 0, 2, lambda);
gsl_matrix_set(mechanical.C_tangent, 1, 0, lambda);
gsl_matrix_set(mechanical.C_tangent, 1, 1, lambda2mu);
gsl_matrix_set(mechanical.C_tangent, 1, 2, lambda);
gsl_matrix_set(mechanical.C_tangent, 2, 0, lambda);
gsl_matrix_set(mechanical.C_tangent, 2, 1, lambda);
gsl_matrix_set(mechanical.C_tangent, 2, 2, lambda2mu);
gsl_matrix_set(mechanical.C_tangent, 3, 3, mu);
gsl_matrix_set(mechanical.C_tangent, 4, 4, mu);
gsl_matrix_set(mechanical.C_tangent, 5, 5, mu);
return FEENOX_OK;
}
// compute the second Piola-Kirchoff stress tensor
gsl_matrix *feenox_problem_mechanical_compute_stress_PK2_elastic(const double *x, material_t *material) {
double lambda, mu;
feenox_problem_mechanical_compute_lambda_mu(x, material, &lambda, &mu);
double lambdatrE = lambda * (gsl_matrix_get(mechanical.eps, 0, 0) + gsl_matrix_get(mechanical.eps, 1, 1) + gsl_matrix_get(mechanical.eps, 2, 2));
double twomu = 2*mu;
for (int i = 0; i < 3; i++) {
for (int j = 0; j < 3; j++) {
gsl_matrix_set(mechanical.PK2, i, j, lambdatrE * (i == j) + twomu * gsl_matrix_get(mechanical.eps, i, j));
}
}
return mechanical.PK2;
}
int feenox_stress_from_strain_linear_elastic(node_t *node, element_t *element, unsigned int j,
double epsilonx, double epsilony, double epsilonz, double gammaxy, double gammayz, double gammazx,
double *sigmax, double *sigmay, double *sigmaz, double *tauxy, double *tauyz, double *tauzx) {
double lambda, mu;
feenox_problem_mechanical_compute_lambda_mu(node->x, element->physical_group->material, &lambda, &mu);
double lambda_trE = lambda*(epsilonx + epsilony + epsilonz);
double two_mu = 2*mu;
// TODO: separate
if (mechanical.variant == variant_full || mechanical.variant == variant_plane_strain) {
// normal stresses
*sigmax = lambda_trE + two_mu * epsilonx;
*sigmay = lambda_trE + two_mu * epsilony;
*sigmaz = lambda_trE + two_mu * epsilonz;
// shear stresses
*tauxy = mu * gammaxy;
if (feenox.pde.dofs == 3) {
*tauyz = mu * gammayz;
*tauzx = mu * gammazx;
}
} else if (mechanical.variant == variant_plane_stress) {
double E = mu*(3*lambda + 2*mu)/(lambda+mu);
double nu = lambda / (2*(lambda+mu));
double c1 = E/(1-nu*nu);
double c2 = nu * c1;
*sigmax = c1 * epsilonx + c2 * epsilony;
*sigmay = c2 * epsilonx + c1 * epsilony;
*sigmaz = 0;
*tauxy = c1*0.5*(1-nu) * gammaxy;
}
return FEENOX_OK;
}
gsl_matrix *feenox_problem_build_mechanical_stress_measure_linear_elastic(const double *x, material_t *material) {
feenox_problem_mechanical_compute_stress_PK2_elastic(x, material);
if (mechanical.uniform_properties == 0) {
feenox_problem_mechanical_compute_tangent_matrix_C_linear_elastic(x, material);
}
return mechanical.PK2;
}
feenox-1.2/src/pdes/mechanical/materials/linear-orthotropic.c 0000664 0001750 0001750 00000014062 15055303016 020103 /*------------ -------------- -------- --- ----- --- -- - -
* feenox elastic orthotropic mechanical material
*
* Copyright (C) 2022 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "../mechanical.h"
int feenox_mechanical_material_init_linear_elastic_orthotropic(material_t *material, int i) {
if (mechanical.variant != variant_full) {
feenox_push_error_message("elastic orthotropic materials cannot be used in plane stress/strain");
return FEENOX_ERROR;
}
int n_ortho = mechanical.E_x.defined_per_group[i] + mechanical.E_y.defined_per_group[i] + mechanical.E_z.defined_per_group[i] +
mechanical.nu_xy.defined_per_group[i] + mechanical.nu_yz.defined_per_group[i] + mechanical.nu_zx.defined_per_group[i] +
mechanical.G_xy.defined_per_group[i] + mechanical.G_yz.defined_per_group[i] + mechanical.G_zx.defined_per_group[i];
if (n_ortho == 0) {
return 0;
}
if (n_ortho < 9) {
feenox_push_error_message("%d orthotropic properties missing for material", 9-n_ortho);
return -1;
}
return material_model_elastic_orthotropic;
}
int feenox_mechanical_material_setup_linear_elastic_orthotropic(void) {
mechanical.compute_material_tangent = feenox_problem_mechanical_compute_tangent_matrix_C_elastic_orthotropic;
mechanical.compute_stress_from_strain = feenox_stress_from_strain_linear;
return FEENOX_OK;
}
int feenox_problem_mechanical_compute_tangent_matrix_C_elastic_orthotropic(const double *x, material_t *material) {
// TODO: check ranges of validity
// E > 0
// G > 0
// | nu_ij | < sqrt(E_i/E_j)
// 1 - nu12*nu21 - nu23*nu32 - nu31*nu13 - 2*nu21*nu32*nu13 > 0
double E_x = mechanical.E_x.eval(&mechanical.E_x, x, material);
double E_y = mechanical.E_y.eval(&mechanical.E_y, x, material);
double E_z = mechanical.E_z.eval(&mechanical.E_z, x, material);
// TODO: handle engineering nu12,nu23 and nu13 (instead of nu31)
double nu_xy = mechanical.nu_xy.eval(&mechanical.nu_xy, x, material);
double nu_yz = mechanical.nu_yz.eval(&mechanical.nu_yz, x, material);
double nu_zx = mechanical.nu_zx.eval(&mechanical.nu_zx, x, material);
double G_xy = mechanical.G_xy.eval(&mechanical.G_xy, x, material);
double G_yz = mechanical.G_yz.eval(&mechanical.G_yz, x, material);
double G_zx = mechanical.G_zx.eval(&mechanical.G_zx, x, material);
if (mechanical.S_ortho == NULL) {
// reduced compliance matrix (only the normal-stress stuff)
feenox_check_alloc(mechanical.S_ortho = gsl_matrix_calloc(3, 3));
// reduced stiffness matrix
feenox_check_alloc(mechanical.C_ortho = gsl_matrix_calloc(3, 3));
}
// > if you noticed that C is called the stiffness tensor and S is called the compliance
// > tensor and wondered about it, this is not a mistake and there is no intention to confuse
// > you. It is a long-time convention that cannot be reverted anymore
// source: https://www.weizmann.ac.il/chembiophys/bouchbinder/sites/chemphys.bouchbinder/files/uploads/Courses/2016/ta5-linear_elasticity-i.pdf
// fill the 3x3 reduced compliance matrix first
// [ 1/E1 -nu21/E2 -nu31/E3 ]
// [ -nu12/E1 1/E2 -nu32/E3 ]
// [ -nu13/E1 -nu23/E2 1/E3 ]
gsl_matrix_set(mechanical.S_ortho, 0, 0, 1.0/E_x);
gsl_matrix_set(mechanical.S_ortho, 1, 1, 1.0/E_y);
gsl_matrix_set(mechanical.S_ortho, 2, 2, 1.0/E_z);
// since S is symmetric,
// nu21/E2 = nu12/E1
// nu31/E3 = nu13/E1
// nu32/E3 = nu23/E2
// but we ask for nu12, nu23 and nu31 (not nu21, nu32 nor nu13) so we use
double minus_nu_xy_over_E_x = -nu_xy/E_x;
double minus_nu_zx_over_E_z = -nu_zx/E_z;
double minus_nu_yz_over_E_y = -nu_yz/E_y;
// to set the off-diagonal (symmetric) entries
gsl_matrix_set(mechanical.S_ortho, 0, 1, minus_nu_xy_over_E_x);
gsl_matrix_set(mechanical.S_ortho, 1, 0, minus_nu_xy_over_E_x);
gsl_matrix_set(mechanical.S_ortho, 0, 2, minus_nu_zx_over_E_z);
gsl_matrix_set(mechanical.S_ortho, 2, 0, minus_nu_zx_over_E_z);
gsl_matrix_set(mechanical.S_ortho, 1, 2, minus_nu_yz_over_E_y);
gsl_matrix_set(mechanical.S_ortho, 2, 1, minus_nu_yz_over_E_y);
// compute the stiffness by inverting the 3x3 compliance
mechanical.C_ortho = feenox_fem_matrix_invert(mechanical.S_ortho, mechanical.C_ortho);
// now fill the full 6x6 C
gsl_matrix_set(mechanical.C_tangent, 0, 0, gsl_matrix_get(mechanical.C_ortho, 0, 0));
gsl_matrix_set(mechanical.C_tangent, 0, 1, gsl_matrix_get(mechanical.C_ortho, 0, 1));
gsl_matrix_set(mechanical.C_tangent, 0, 2, gsl_matrix_get(mechanical.C_ortho, 0, 2));
gsl_matrix_set(mechanical.C_tangent, 1, 0, gsl_matrix_get(mechanical.C_ortho, 1, 0));
gsl_matrix_set(mechanical.C_tangent, 1, 1, gsl_matrix_get(mechanical.C_ortho, 1, 1));
gsl_matrix_set(mechanical.C_tangent, 1, 2, gsl_matrix_get(mechanical.C_ortho, 1, 2));
gsl_matrix_set(mechanical.C_tangent, 2, 0, gsl_matrix_get(mechanical.C_ortho, 2, 0));
gsl_matrix_set(mechanical.C_tangent, 2, 1, gsl_matrix_get(mechanical.C_ortho, 2, 1));
gsl_matrix_set(mechanical.C_tangent, 2, 2, gsl_matrix_get(mechanical.C_ortho, 2, 2));
// the following subscripts have to match rows 3-5 of mechanical.B
gsl_matrix_set(mechanical.C_tangent, 3, 3, G_xy);
gsl_matrix_set(mechanical.C_tangent, 4, 4, G_yz);
gsl_matrix_set(mechanical.C_tangent, 5, 5, G_zx);
return FEENOX_OK;
}
feenox-1.2/src/pdes/mechanical/materials/mooney-rivlin.c 0000664 0001750 0001750 00000000017 15055303016 017061 // placeholder
feenox-1.2/src/pdes/mechanical/materials/neohookean.c 0000664 0001750 0001750 00000024116 15055303016 016406 /*------------ -------------- -------- --- ----- --- -- - -
* feenox neohookean mechanical material
*
* Copyright (C) 2025 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "../mechanical.h"
int feenox_mechanical_material_init_neohookean(material_t *material, int i) {
if (mechanical.variant != variant_full) {
feenox_push_error_message("hyperelastic neohookean materials cannot be used in plane stress/strain");
return FEENOX_ERROR;
}
// TO-DO: lambda & my or mu & K
return (mechanical.E.defined_per_group[i] && mechanical.nu.defined_per_group[i]) ? material_model_hyperelastic_neohookean : material_model_unknown;
}
int feenox_mechanical_material_setup_neohookean(void) {
mechanical.compute_PK2 = feenox_problem_build_mechanical_stress_measure_neohookean;
// TODO: compute cauchy from PK2?
mechanical.compute_stress_from_strain = feenox_stress_from_strain_linear;
mechanical.nonlinear_material = 1;
return FEENOX_OK;
}
gsl_matrix *feenox_problem_build_mechanical_stress_measure_neohookean(const double *x, material_t *material) {
// second piola kirchoff
feenox_problem_mechanical_compute_stress_PK2_neohookean(x, material);
// tangent matrix
feenox_problem_mechanical_compute_tangent_matrix_C_neohookean(x, material);
return mechanical.PK2;
}
gsl_matrix *feenox_problem_mechanical_compute_stress_PK2_neohookean(const double *x, material_t *material) {
// second piola-kirchoff
mechanical.J = feenox_fem_determinant(mechanical.F);
// TODO: check J > 0
mechanical.J23 = pow(mechanical.J, -2.0/3.0); // isochoric scaling
mechanical.trC = gsl_matrix_get(mechanical.C, 0, 0) + gsl_matrix_get(mechanical.C, 1, 1) + gsl_matrix_get(mechanical.C, 2, 2);
mechanical.C_inv = feenox_fem_matrix_invert(mechanical.C, mechanical.C_inv);
double lambda, mu;
feenox_problem_mechanical_compute_lambda_mu(x, material, &lambda, &mu);
double K = lambda + 2.0/3.0 * mu;
for (int i = 0; i < 3; i++) {
for (int j = 0; j < 3; j++) {
double dev_part = mu * mechanical.J23 * ((i == j ? 1.0 : 0.0) - (1.0/3.0) * mechanical.trC * gsl_matrix_get(mechanical.C_inv, i, j));
double vol_part = K * (mechanical.J - 1.0) * mechanical.J * gsl_matrix_get(mechanical.C_inv, i, j);
gsl_matrix_set(mechanical.PK2, i, j, dev_part + vol_part);
}
}
return mechanical.PK2;
}
void feenox_tensor_outer_product_voigt(const gsl_matrix *A, const gsl_matrix *B, gsl_matrix *C_voigt) {
static const int voigt_map[6][2] = {{0,0}, {1,1}, {2,2}, {0,1}, {1,2}, {0,2}};
for (int i = 0; i < 6; i++) {
for (int j = 0; j < 6; j++) {
int p = voigt_map[i][0];
int q = voigt_map[i][1];
int r = voigt_map[j][0];
int s = voigt_map[j][1];
gsl_matrix_set(C_voigt, i, j, gsl_matrix_get(A, p, q) * gsl_matrix_get(B, r, s));
}
}
return;
}
void feenox_tensor_outer_product_ikjl(const gsl_vector *A_voigt, const gsl_vector *B_voigt, gsl_matrix *C_voigt) {
// Lookup tables mapping from (row, col) in C_voigt to indices in A_voigt and B_voigt
// These tables encode the specific tensor contraction pattern IKJL
static const int A_ikjl[6][6] = {
{0, 3, 5, 0, 3, 0}, // row 0
{3, 1, 4, 3, 1, 3}, // row 1
{5, 4, 2, 5, 4, 5}, // row 2
{0, 3, 5, 0, 3, 0}, // row 3
{3, 1, 4, 3, 1, 3}, // row 4
{0, 3, 5, 0, 3, 0} // row 5
};
static const int B_ikjl[6][6] = {
{0, 3, 5, 3, 5, 5}, // row 0
{3, 1, 4, 1, 4, 4}, // row 1
{5, 4, 2, 4, 2, 2}, // row 2
{3, 1, 4, 1, 4, 4}, // row 3
{5, 4, 2, 4, 2, 2}, // row 4
{5, 4, 2, 4, 2, 2} // row 5
};
for (int i = 0; i < 6; i++) {
for (int j = 0; j < 6; j++) {
double a_val = gsl_vector_get(A_voigt, A_ikjl[i][j]);
double b_val = gsl_vector_get(B_voigt, B_ikjl[i][j]);
gsl_matrix_set(C_voigt, i, j, a_val * b_val);
}
}
return;
}
void feenox_tensor_outer_product_iljk(const gsl_vector *A_voigt, const gsl_vector *B_voigt, gsl_matrix *C_voigt) {
// Lookup tables mapping from (row, col) in C_voigt to indices in A_voigt and B_voigt
// These tables encode the specific tensor contraction pattern ILJK: C[IJ,LK] = A[IL] × B[JK]
static const int A_iljk[6][6] = {
{0, 3, 5, 3, 5, 5}, // row 0: I=0, J=0 -> A[IL] for L=0,1,2,1,2,2
{3, 1, 4, 1, 4, 4}, // row 1: I=1, J=1 -> A[IL] for L=0,1,2,1,2,2
{5, 4, 2, 4, 2, 2}, // row 2: I=2, J=2 -> A[IL] for L=0,1,2,1,2,2
{0, 3, 5, 3, 5, 5}, // row 3: I=0, J=1 -> A[IL] for L=0,1,2,1,2,2
{3, 1, 4, 1, 4, 4}, // row 4: I=1, J=2 -> A[IL] for L=0,1,2,1,2,2
{0, 3, 5, 3, 5, 5} // row 5: I=0, J=2 -> A[IL] for L=0,1,2,1,2,2
};
static const int B_iljk[6][6] = {
{0, 3, 5, 0, 3, 0}, // row 0: I=0, J=0 -> B[JK] for K=0,1,2,1,2,2
{3, 1, 4, 3, 1, 3}, // row 1: I=1, J=1 -> B[JK] for K=0,1,2,1,2,2
{5, 4, 2, 5, 4, 5}, // row 2: I=2, J=2 -> B[JK] for K=0,1,2,1,2,2
{3, 1, 4, 3, 1, 3}, // row 3: I=0, J=1 -> B[JK] for K=0,1,2,1,2,2
{5, 4, 2, 5, 4, 5}, // row 4: I=1, J=2 -> B[JK] for K=0,1,2,1,2,2
{5, 4, 2, 5, 4, 5} // row 5: I=0, J=2 -> B[JK] for K=0,1,2,1,2,2
};
for (int i = 0; i < 6; i++) {
for (int j = 0; j < 6; j++) {
double a_val = gsl_vector_get(A_voigt, A_iljk[i][j]);
double b_val = gsl_vector_get(B_voigt, B_iljk[i][j]);
gsl_matrix_set(C_voigt, i, j, a_val * b_val);
}
}
return;
}
/*
(2.0 / 3.0) * std::pow(J, -2.0 / 3.0) * mu *
(-IxinvC - invCxI + (1.0 / 3.0) * trC * invCxinvC +
(1.0 / 2.0) * trC * (invCxinvC_ikjl + invCxinvC_iljk)) +
K * J *
((2.0 * J - 1.0) * invCxinvC - (J - 1.0) * (invCxinvC_ikjl + invCxinvC_iljk));
*/
int feenox_problem_mechanical_compute_tangent_matrix_C_neohookean(const double *x, material_t *material) {
// Bulk modulus
// TODO: we already have these! think where to store them...
double lambda, mu;
feenox_problem_mechanical_compute_lambda_mu(x, material, &lambda, &mu);
double K = lambda + (2.0/3.0) * mu;
if (mechanical.invCxI == NULL) {
mechanical.invCxI = gsl_matrix_calloc(6, 6);
mechanical.IxinvC = gsl_matrix_calloc(6, 6);
mechanical.invCxinvC = gsl_matrix_calloc(6, 6);
mechanical.invC_voigt = gsl_vector_calloc(6);
mechanical.invCxinvC_ikjl = gsl_matrix_calloc(6, 6);
mechanical.invCxinvC_iljk = gsl_matrix_calloc(6, 6);
mechanical.tmp1 = gsl_matrix_calloc(6, 6);
mechanical.tmp2 = gsl_matrix_calloc(6, 6);
mechanical.tmp3 = gsl_matrix_calloc(6, 6);
}
feenox_tensor_outer_product_voigt(mechanical.C_inv, mechanical.eye, mechanical.invCxI);
feenox_tensor_outer_product_voigt(mechanical.eye, mechanical.C_inv, mechanical.IxinvC);
feenox_tensor_outer_product_voigt(mechanical.C_inv, mechanical.C_inv, mechanical.invCxinvC);
gsl_vector_set(mechanical.invC_voigt, 0, gsl_matrix_get(mechanical.C_inv, 0, 0));
gsl_vector_set(mechanical.invC_voigt, 1, gsl_matrix_get(mechanical.C_inv, 1, 1));
gsl_vector_set(mechanical.invC_voigt, 2, gsl_matrix_get(mechanical.C_inv, 2, 2));
gsl_vector_set(mechanical.invC_voigt, 3, gsl_matrix_get(mechanical.C_inv, 0, 1));
gsl_vector_set(mechanical.invC_voigt, 4, gsl_matrix_get(mechanical.C_inv, 1, 2));
gsl_vector_set(mechanical.invC_voigt, 5, gsl_matrix_get(mechanical.C_inv, 2, 0));
feenox_tensor_outer_product_ikjl(mechanical.invC_voigt, mechanical.invC_voigt, mechanical.invCxinvC_ikjl);
feenox_tensor_outer_product_iljk(mechanical.invC_voigt, mechanical.invC_voigt, mechanical.invCxinvC_iljk);
double trC = gsl_matrix_get(mechanical.C, 0, 0) + gsl_matrix_get(mechanical.C, 1, 1) + gsl_matrix_get(mechanical.C, 2, 2);
// Precompute common terms
double J = sqrt(feenox_fem_determinant(mechanical.C));
double J23 = pow(J, -2.0/3.0);
double term1_scale = (2.0/3.0) * J23 * mu;
double term2_scale = K * J;
// First part: (2/3)*J^(-2/3)*mu * [...]
// -IxinvC - invCxI
gsl_matrix_memcpy(mechanical.tmp1, mechanical.IxinvC);
gsl_matrix_scale(mechanical.tmp1, -1.0);
gsl_matrix_sub(mechanical.tmp1, mechanical.invCxI);
// + (1/3)*trC*invCxinvC
gsl_matrix_memcpy(mechanical.tmp2, mechanical.invCxinvC);
gsl_matrix_scale(mechanical.tmp2, (1.0/3.0) * trC);
gsl_matrix_add(mechanical.tmp1, mechanical.tmp2);
// + (1/2)*trC*(invCxinvC_ikjl + invCxinvC_iljk)
gsl_matrix_memcpy(mechanical.tmp2, mechanical.invCxinvC_ikjl);
gsl_matrix_add(mechanical.tmp2, mechanical.invCxinvC_iljk);
gsl_matrix_scale(mechanical.tmp2, (1.0/2.0) * trC);
gsl_matrix_add(mechanical.tmp1, mechanical.tmp2);
// Scale by term1_scale
gsl_matrix_scale(mechanical.tmp1, term1_scale);
// Second part: K*J * [...]
// (2*J-1)*invCxinvC
gsl_matrix_memcpy(mechanical.tmp2, mechanical.invCxinvC);
gsl_matrix_scale(mechanical.tmp2, (2.0*J - 1.0));
// - (J-1)*(invCxinvC_ikjl + invCxinvC_iljk)
gsl_matrix_memcpy(mechanical.tmp3, mechanical.invCxinvC_ikjl);
gsl_matrix_add(mechanical.tmp3, mechanical.invCxinvC_iljk);
gsl_matrix_scale(mechanical.tmp3, -(J - 1.0));
gsl_matrix_add(mechanical.tmp2, mechanical.tmp3);
// Scale by term2_scale
gsl_matrix_scale(mechanical.tmp2, term2_scale);
// Combine both parts
gsl_matrix_memcpy(mechanical.C_tangent, mechanical.tmp1);
gsl_matrix_add(mechanical.C_tangent, mechanical.tmp2);
return FEENOX_OK;
}
feenox-1.2/src/pdes/mechanical/materials/saint_venant-kirchoff.c 0000664 0001750 0001750 00000003601 15055303016 020536 /*------------ -------------- -------- --- ----- --- -- - -
* feenox saint venant-kirchoff mechanical material
*
* Copyright (C) 2025 Jeremy Theler
*
* This file is part of Feenox .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Feenox is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "../mechanical.h"
int feenox_mechanical_material_init_svk(material_t *material, int i) {
if (mechanical.variant != variant_full) {
feenox_push_error_message("hyperelastic SVK materials cannot be used in plane stress/strain");
return FEENOX_ERROR;
}
// TO-DO: lambda and mu
return (mechanical.E.defined_per_group[i] && mechanical.nu.defined_per_group[i]) ? material_model_hyperelastic_svk : material_model_unknown;
}
int feenox_mechanical_material_setup_svk(void) {
mechanical.uniform_properties = (mechanical.E.non_uniform == 0 && mechanical.nu.non_uniform == 0);
mechanical.compute_material_tangent = feenox_problem_mechanical_compute_tangent_matrix_C_linear_elastic;
mechanical.compute_PK2 = feenox_problem_build_mechanical_stress_measure_linear_elastic;
mechanical.compute_stress_from_strain = feenox_stress_from_strain_linear;
mechanical.nonlinear_material = 1;
return FEENOX_OK;
} feenox-1.2/src/pdes/laplace/ 0000775 0001750 0001750 00000000000 15055303133 011524 5 feenox-1.2/src/pdes/laplace/bc.c 0000664 0001750 0001750 00000007513 15055303016 012202 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for Laplace's equation: boundary conditions
*
* Copyright (C) 2021--2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "laplace.h"
int feenox_problem_bc_parse_laplace(bc_data_t *bc_data, const char *lhs, char *rhs) {
///bc_laplace+phi+usage phi=
///bc_laplace+phi+description Dirichlet essential boundary condition in which the value of\ $\phi$ is prescribed.
if (strcmp(lhs, "phi") == 0) {
bc_data->type_math = bc_type_math_dirichlet;
bc_data->set_essential = feenox_problem_bc_set_laplace_phi;
///bc_laplace+phi'+usage phi'=
///bc_laplace+phi'+description Neumann natural boundary condition in which the value of the normal outward derivative\ $\frac{\partial \phi}{\partial n}$ is prescribed.
///bc_laplace+dphidn+usage dphidn=
///bc_laplace+dphidn+description Alias for `phi'`.
} else if (strcmp(lhs, "phi'") == 0 || strcmp(lhs, "dphidn") == 0) {
bc_data->type_math = bc_type_math_neumann;
bc_data->set_natural = feenox_problem_bc_set_laplace_derivative;
} else {
feenox_push_error_message("unknown laplace boundary condition '%s'", lhs);
return FEENOX_ERROR;
}
feenox_call(feenox_expression_parse(&bc_data->expr, rhs));
bc_data->space_dependent = feenox_depends_on_space(bc_data->expr.variables);
bc_data->nonlinear = feenox_depends_on_function(bc_data->expr.functions, feenox.pde.solution[0]);
if (bc_data->nonlinear && bc_data->type_math == bc_type_math_dirichlet) {
feenox_push_error_message("essential boundary condition '%s' cannot depend on phi", rhs);
return FEENOX_ERROR;
}
return FEENOX_OK;
}
int feenox_problem_bc_set_laplace_phi(bc_data_t *this, element_t *e, size_t j_global) {
#ifdef HAVE_PETSC
feenox_call(feenox_problem_dirichlet_add(j_global, 0, feenox_expression_eval(&this->expr)));
// TODO: only in transient
// feenox.pde.dirichlet_derivatives[*k] = feenox_expression_derivative_wrt_variable(&bc_data->expr, feenox_special_var(t), feenox_special_var_value(t));
#endif
return FEENOX_OK;
}
int feenox_problem_bc_set_laplace_derivative(bc_data_t *this, element_t *e, unsigned int q) {
#ifdef HAVE_PETSC
// TODO: cache if neither space nor temperature dependent
double *x = feenox_fem_compute_x_at_gauss_if_needed_and_update_var(e, q, feenox.pde.mesh->integration, this->space_dependent);
double derivative = feenox_expression_eval(&this->expr);
feenox_call(feenox_problem_rhs_add(e, q, &derivative));
if (this->nonlinear) {
double phi = feenox_function_eval(feenox.pde.solution[0], x);
double dderivativedphi = feenox_expression_derivative_wrt_function(&this->expr, feenox.pde.solution[0], phi);
double wdet = feenox_fem_compute_w_det_at_gauss_integration(e, q, feenox.pde.mesh->integration);
gsl_matrix *H_Gc = feenox_fem_compute_H_Gc_at_gauss(e, q, feenox.pde.mesh->integration);
// mind the positive sign!
feenox_call(feenox_blas_BtB_accum(H_Gc, +wdet*dderivativedphi, feenox.fem.Jbi));
}
#endif
return FEENOX_OK;
}
feenox-1.2/src/pdes/laplace/bulk.c 0000664 0001750 0001750 00000004535 15055303016 012554 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for Laplace's equation: bulk elements
*
* Copyright (C) 2021--2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "laplace.h"
int feenox_problem_build_volumetric_gauss_point_laplace(element_t *e, unsigned int q) {
#ifdef HAVE_PETSC
double wdet = feenox_fem_compute_w_det_at_gauss(e, q);
gsl_matrix *B = feenox_fem_compute_B_at_gauss(e, q);
// laplace stiffness matrix Ki += wdet * Bt*B
feenox_call(feenox_blas_BtB_accum(B, wdet, feenox.fem.Ki));
// the material is needed for either RHS and/or mass
material_t *material = feenox_fem_get_material(e);
// right-hand side
double *x = feenox_fem_compute_x_at_gauss_if_needed(e, q, feenox.pde.mesh->integration, laplace.space_dependent_source || laplace.space_dependent_mass);
if (laplace.f.defined) {
double f = laplace.f.eval(&laplace.f, x, material);
feenox_call(feenox_problem_rhs_add(e, q, &f));
}
if (feenox.pde.has_jacobian) {
// TODO: jacobian
}
// mass matrix Ht*rho*cp*H
if (feenox.pde.has_mass) {
gsl_matrix *H_Gc = feenox_fem_compute_H_Gc_at_gauss(e, q, feenox.pde.mesh->integration);
if (laplace.alpha.defined) {
double alpha = laplace.alpha.eval(&laplace.alpha, x, material);
feenox_call(feenox_blas_BtB_accum(H_Gc, wdet*alpha, feenox.fem.Mi));
} else {
// this should have been already checked
feenox_push_error_message("no alpha found needed for Laplace's mass matrix");
return FEENOX_ERROR;
}
}
#endif
return FEENOX_OK;
}
feenox-1.2/src/pdes/laplace/init.c 0000664 0001750 0001750 00000014430 15055303016 012555 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for Laplace's equation: initialization
*
* Copyright (C) 2021--2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "laplace.h"
laplace_t laplace;
int feenox_problem_parse_time_init_laplace(void) {
///kw_pde+PROBLEM+detail * `laplace` the Laplace (or Poisson) equation, either steady state or transient
#ifdef HAVE_PETSC
// virtual methods
feenox.pde.parse_bc = feenox_problem_bc_parse_laplace;
feenox.pde.parse_write_results = feenox_problem_parse_write_post_laplace;
feenox.pde.init_before_run = feenox_problem_init_runtime_laplace;
feenox.pde.setup_ksp = feenox_problem_setup_ksp_laplace;
feenox.pde.setup_pc = feenox_problem_setup_pc_laplace;
feenox.pde.element_build_volumetric_at_gauss = feenox_problem_build_volumetric_gauss_point_laplace;
// we are FEM
feenox.mesh.default_field_location = field_location_nodes;
// laplace is a scalar problem
feenox.pde.dofs = 1;
///re_laplace+phi+description The scalar field\ $\phi(\vec{x})$ whose Laplacian is equal to zero or to\ $f(\vec{x})$.
feenox_check_alloc(feenox.pde.unknown_name = calloc(feenox.pde.dofs, sizeof(char *)));
feenox_check_alloc(feenox.pde.unknown_name[0] = strdup("phi"));
#endif
return FEENOX_OK;
}
int feenox_problem_init_runtime_laplace(void) {
#ifdef HAVE_PETSC
// we are FEM not FVM
feenox.pde.mesh->data_type = data_type_node;
feenox.pde.spatial_unknowns = feenox.pde.mesh->n_nodes;
// check if we were given an initial guess
if ((feenox.pde.initial_guess = feenox_get_function_ptr("phi_guess")) != NULL) {
if (feenox.pde.initial_guess->n_arguments != feenox.pde.dim) {
feenox_push_error_message("initial guess function phi_guess ought to have %d arguments instead of %d", feenox.pde.dim, feenox.pde.initial_condition->n_arguments);
return FEENOX_ERROR;
}
}
// check if we were given an initial solution
if ((feenox.pde.initial_condition = feenox_get_function_ptr("phi_0")) != NULL) {
if (feenox.pde.initial_condition->n_arguments != feenox.pde.dim) {
feenox_push_error_message("initial condition function phi_0 ought to have %d arguments instead of %d", feenox.pde.dim, feenox.pde.initial_condition->n_arguments);
return FEENOX_ERROR;
}
}
// initialize distributions
///pr_laplace+f+description The right hand side of the equation\ $\nabla^2 \phi=f(\vec{x})$.
///pr_laplace+f+description If not given, default is zero (i.e. Laplace).
feenox_call(feenox_distribution_init(&laplace.f, "f"));
laplace.f.non_uniform = feenox_depends_on_space(laplace.f.dependency_variables);
laplace.f.non_linear = feenox_depends_on_function(laplace.f.dependency_functions, feenox.pde.solution[0]);
///pr_laplace+alpha+description The coefficient of the temporal derivative for the transient
///pr_laplace+alpha+description equation \ $\alpha \frac{\partial \phi}{\partial t} + \nabla^2 \phi=f(\vec{x})$.
///pr_laplace+alpha+description If not given, default is one.
feenox.pde.has_mass = (feenox_var_value(feenox_special_var(end_time)) > 0 && feenox.pde.transient_type != transient_type_quasistatic);
if (feenox.pde.has_mass) {
feenox_call(feenox_distribution_init(&laplace.alpha, "alpha"));
if (laplace.alpha.defined == 0) {
// TODO: define something identically equal to one
feenox_push_error_message("'alpha' is needed for transient");
return FEENOX_ERROR;
}
if (laplace.alpha.full == 0) {
feenox_push_error_message("'alpha' is not defined over all volumes");
return FEENOX_ERROR;
}
}
laplace.alpha.non_uniform = feenox_depends_on_space(laplace.alpha.dependency_variables);
laplace.alpha.non_linear = feenox_depends_on_function(laplace.alpha.dependency_functions, feenox.pde.solution[0]);
laplace.space_dependent_source = laplace.f.non_uniform;
laplace.space_dependent_mass = laplace.alpha.non_uniform;
laplace.phi_dependent_mass = feenox_depends_on_function(laplace.alpha.dependency_functions, feenox.pde.solution[0]);
if (feenox.pde.math_type == math_type_automatic) {
feenox.pde.math_type = (laplace.phi_dependent_mass == 0 &&
laplace.phi_dependent_source == 0 &&
laplace.phi_dependent_bc == 0) ? math_type_linear : math_type_nonlinear;
}
feenox.pde.solve = (feenox_special_var_value(end_time) > 0) ? feenox_problem_solve_petsc_transient :
((feenox.pde.math_type == math_type_linear) ? feenox_problem_solve_petsc_linear :
feenox_problem_solve_petsc_nonlinear);
feenox.pde.has_stiffness = 1;
feenox.pde.has_rhs = 1;
// has_mass is above
feenox.pde.has_jacobian_K = 0;
feenox.pde.has_jacobian_M = laplace.phi_dependent_mass;
feenox.pde.has_jacobian_b = (laplace.phi_dependent_source || laplace.phi_dependent_bc);
feenox.pde.has_jacobian = feenox.pde.has_jacobian_K || feenox.pde.has_jacobian_M || feenox.pde.has_jacobian_b;
feenox.pde.symmetric_K = 1;
feenox.pde.symmetric_M = 1;
#endif
return FEENOX_OK;
}
#ifdef HAVE_PETSC
int feenox_problem_setup_pc_laplace(PC pc) {
PCType pc_type = NULL;
petsc_call(PCGetType(pc, &pc_type));
if (pc_type == NULL) {
petsc_call(PCSetType(pc, PCGAMG));
}
return FEENOX_OK;
}
int feenox_problem_setup_ksp_laplace(KSP ksp ) {
KSPType ksp_type = NULL;
petsc_call(KSPGetType(ksp, &ksp_type));
if (ksp_type == NULL) {
petsc_call(KSPSetType(ksp, KSPCG));
}
return FEENOX_OK;
}
#endif
feenox-1.2/src/pdes/laplace/laplace.h 0000664 0001750 0001750 00000002764 15055303016 013227 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for Laplace's equation: global header
*
* Copyright (C) 2021 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#ifndef LAPLACE_H
#define LAPLACE_H
typedef struct laplace_t laplace_t;
struct laplace_t {
distribution_t f;
distribution_t alpha;
// TODO: uniform instead of "space-dependent"
// TODO: constant (i.e. non-time-depedent)
int space_dependent_mass;
int phi_dependent_mass;
int space_dependent_source;
int phi_dependent_source;
int space_dependent_bc;
int phi_dependent_bc;
// caches for uniform properties
struct {
double f;
double alpha;
} cache;
};
extern laplace_t laplace;
#endif /* LAPLACE_H */
feenox-1.2/src/pdes/laplace/methods.h 0000664 0001750 0001750 00000003551 15055303016 013264 /*------------ -------------- -------- --- ----- --- -- - -
* feenox's routines for Laplace's equation: virtual methods
*
* Copyright (C) 2022-2023 Jeremy Theler
*
* This file is part of FeenoX .
*
* feenox is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#ifndef LAPLACE_METHODS_H
#define LAPLACE_METHODS_H
// laplace/init.c
extern int feenox_problem_parse_problem_laplace(const char *token);
extern int feenox_problem_parse_write_post_laplace(mesh_write_t *mesh_write, const char *token);
extern int feenox_problem_parse_time_init_laplace(void);
extern int feenox_problem_init_runtime_laplace(void);
#ifdef HAVE_PETSC
extern int feenox_problem_setup_pc_laplace(PC pc);
extern int feenox_problem_setup_ksp_laplace(KSP ksp);
#endif
// laplace/bulk.c
extern int feenox_problem_build_volumetric_gauss_point_laplace(element_t *element, unsigned int q);
// laplace/bc.c
extern int feenox_problem_bc_parse_laplace(bc_data_t *bc_data, const char *lhs, char *rhs);
extern int feenox_problem_bc_set_laplace_phi(bc_data_t *bc_data, element_t *e, size_t j_global);
extern int feenox_problem_bc_set_laplace_derivative(bc_data_t *bc_data, element_t *e, unsigned int q);
#endif
feenox-1.2/src/pdes/laplace/parser.c 0000664 0001750 0001750 00000005135 15055303016 013110 /*------------ -------------- -------- --- ----- --- -- - -
* FeenoX parser for laplace-specific keywords
*
* Copyright (C) 2023 Jeremy Theler
*
* This file is part of FeenoX.
*
* FeenoX is free software: you can redistribute it and/or modify
* it under the terms "of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "../../parser/parser.h"
#include "laplace.h"
///pb_laplace+NONE+description Laplace's equation does not need any extra keyword to `PROBLEM`.
int feenox_problem_parse_problem_laplace(const char *token) {
///kw_pde+PROBLEM+detail * `laplace` solves the Laplace (or Poisson) equation.
// no need to parse anything;
if (token != NULL) {
feenox_push_error_message("undefined keyword '%s' for laplace PROBLEM", token);
return FEENOX_ERROR;
} else {
// if token is NULL we have to do the parse-time initialization
feenox_call(feenox_problem_parse_time_init_laplace());
}
return FEENOX_OK;
}
int feenox_problem_parse_write_post_laplace(mesh_write_t *mesh_write, const char *token) {
if (strcmp(token, "all") == 0) {
feenox_call(feenox_problem_parse_write_post_laplace(mesh_write, "phi"));
feenox_call(feenox_problem_parse_write_post_laplace(mesh_write, "gradient"));
} else if (strcmp(token, "phi") == 0) {
feenox_call(feenox_add_post_field(mesh_write, 1, &feenox.pde.solution[0]->name, NULL, field_location_nodes));
} else if (strcmp(token, "grad_phi") == 0 || strcmp(token, "gradient") == 0) {
char *tokens[3] = {NULL, NULL, NULL};
for (unsigned int m = 0; m < 3; m++) {
tokens[m] = strdup((m < feenox.pde.dim) ? feenox.pde.gradient[0][m]->name : "0");
}
feenox_call(feenox_add_post_field(mesh_write, 3, tokens, "grad_phi", field_location_nodes));
for (unsigned int m = 0; m < 3; m++) {
feenox_free(tokens[m]);
}
} else {
feenox_push_error_message("undefined keyword '%s' for laplace WRITE_RESULTS", token);
return FEENOX_ERROR;
}
return FEENOX_OK;
}
feenox-1.2/src/parser/ 0000775 0001750 0001750 00000000000 15055303133 010464 5 feenox-1.2/src/parser/auxiliary.c 0000664 0001750 0001750 00000052571 15055303016 012571 /*------------ -------------- -------- --- ----- --- -- - -
* FeenoX auxiliary parsing routines
*
* Copyright (C) 2009--2021 Jeremy Theler
*
* This file is part of FeenoX.
*
* FeenoX is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "parser.h"
#include
#include
#include
#include
// reads a line from the input file and returns it "nicely-formatted"
int feenox_read_line(FILE *file_ptr) {
// ignore trailing whitespace
int c = 0;
do {
c = fgetc(file_ptr);
// if we find a newline, then there's nothing for us
if (c == '\n') {
feenox_parser.line[0] = '\0';
return 1;
}
} while (isspace(c));
int i = 0;
int in_comment = 0;
int in_brackets = 0;
int lines = 0;
while ( !((c == EOF) || (in_brackets == 0 && c == '\n')) ) {
if (in_comment == 0) {
if (feenox_parser.inside_yaml == 0 && (c == '#' || c == ';')) {
in_comment = 1;
} else if (feenox_parser.inside_yaml == 0 && c == '{') {
in_brackets = 1;
} else if (feenox_parser.inside_yaml == 0 && c == '}') {
in_brackets = 0;
} else if (feenox_parser.inside_yaml == 0 && c == '$') {
// handle commandline arguments
// check if there's an opening bracket or parenthesis
c = fgetc(file_ptr);
if (c == EOF) {
feenox_push_error_message("unexpected end of file");
return FEENOX_ERROR;
}
int argument_in_brackets = (c == '{' || c == '(');
if (argument_in_brackets == 0) {
if (ungetc(c, file_ptr) == EOF) {
return FEENOX_ERROR;
}
}
int n = 0;
if (fscanf(file_ptr, "%d", &n) != 1) {
feenox_push_error_message("failed to match $%sn%s", argument_in_brackets?"{":"", argument_in_brackets?"}":"");
return (lines==0 && i !=0 )? -1 : -lines;
}
if (argument_in_brackets == 1) {
c = fgetc(file_ptr);
if (c == EOF) {
feenox_push_error_message("unexpected end of file");
return FEENOX_ERROR;
}
if (c != '}' && c != ')') {
feenox_push_error_message("expected closing bracket for argument");
return FEENOX_ERROR;
}
}
if (feenox.optind+n >= feenox.argc) {
// call recursively so we finish reading the line
feenox_read_line(file_ptr);
// make sure that line[0] is not '\0'
if (feenox_parser.line[0] == '\0') {
feenox_parser.line[0] = ' ';
feenox_parser.line[1] = '\0';
}
return (lines==0 && i !=0 )? -1: -lines;
}
if (feenox.argv[feenox.optind+n] == NULL) {
// we need to return a negative number
return -1;
}
int j = 0;
while (feenox.argv[feenox.optind+n][j] != 0) {
// watch out!
// this cannot be put in a single line because the '\0' might come
// in line[] before evaluating the condition to get out of the while
feenox_parser.line[i++] = feenox.argv[feenox.optind+n][j++];
}
} else if (feenox_parser.inside_yaml == 0 && c == '\\') {
switch (c = fgetc(file_ptr)) {
case '"':
// if there's an escaped quote, we take away the escape char and put
// a magic marker 0x1e, afterwards in get_next_token() we change back
// the 0x1e with the unescaped quote
feenox_parser.line[i++] = 0x1e;
break;
// escape sequences
case 'a':
feenox_parser.line[i++] = '\a';
break;
case 'b':
feenox_parser.line[i++] = '\b';
break;
case 'n':
feenox_parser.line[i++] = '\n';
break;
case 'r':
feenox_parser.line[i++] = '\r';
break;
case 't':
feenox_parser.line[i++] = '\t';
break;
case 'v':
feenox_parser.line[i++] = '\v';
break;
case '\n':
// escaped newlines are taken as continuation lines
lines++;
break;
case '\\':
// this is taken into account int he default, but just in case
feenox_parser.line[i++] = '\\';
break;
// TODO: hex representation
default:
feenox_parser.line[i++] = c;
break;
}
} else if (!in_comment && c != '\n' && c != '\r' && c != EOF) {
feenox_parser.line[i++] = c;
} else if (in_brackets && c == '\n') {
feenox_parser.line[i++] = ' ';
}
}
// escape from the "in comment" state if there's a newline
if (c == '\n') {
in_comment = 0;
}
// check if we need to reallocate the input buffer
if (i >= feenox_parser.actual_buffer_size-16) {
feenox_parser.actual_buffer_size += feenox_parser.page_size;
feenox_check_alloc(feenox_parser.line = realloc(feenox_parser.line, feenox_parser.actual_buffer_size));
}
// ask what's next in futbol de primera
// count the lines here because if we get \n we go back without eating nor drinking
if ((c = fgetc(file_ptr)) == '\n') {
lines++;
}
}
feenox_parser.line[i] = '\0';
// finite-state machine for yaml:
// --- can begin/end a yaml block
// ... can only end it
if (strcmp(feenox_parser.line, "...") == 0) {
if (feenox_parser.inside_yaml == 1) {
feenox_parser.inside_yaml = 0;
feenox_parser.line[0] = '\0';
} else {
feenox_push_error_message("yaml end block '...' without opening block '---'");
return FEENOX_OK;
}
} else if (strcmp(feenox_parser.line, "---") == 0) {
feenox_parser.inside_yaml = !feenox_parser.inside_yaml;
feenox_parser.line[0] = '\0';
}
// if lines is zero but we did read something, we need to return one
// otherwise the final lines of input files not ending in \n are ignored
return (lines == 0 && i != 0) ? 1 : lines;
}
int feenox_parser_expression(expr_t *expr) {
char *token;
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected expression");
return FEENOX_ERROR;
}
if (feenox_expression_parse(expr, token) != FEENOX_OK) {
return FEENOX_ERROR;
}
return FEENOX_OK;
}
int feenox_parser_expressions(expr_t *expr[], size_t n) {
char *token;
int i;
*expr = calloc(n, sizeof(expr_t));
for (i = 0; i < n; i++) {
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected expression");
return FEENOX_ERROR;
}
feenox_call(feenox_expression_parse(&((*expr)[i]), token));
}
return FEENOX_OK;
}
int feenox_parser_match_keyword_expression(char *token, char *keyword[], expr_t *expr[], size_t n) {
int i;
int found = 0;
for (i = 0; i < n; i++) {
if (strcasecmp(token, keyword[i]) == 0) {
found = 1;
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected expression");
return FEENOX_ERROR;
}
feenox_call(feenox_expression_parse(expr[i], token));
}
}
if (found == 0) {
return FEENOX_UNHANDLED;
}
return FEENOX_OK;
}
int feenox_parser_expression_in_string(double *result) {
char *token = NULL;
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected expression");
return FEENOX_ERROR;
}
*result = feenox_expression_evaluate_in_string(token);
return FEENOX_OK;
}
int feenox_parser_expression_in_string_integer(int *result) {
char *token = NULL;
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected expression");
return FEENOX_ERROR;
}
*result = (int)feenox_expression_evaluate_in_string(token);
return FEENOX_OK;
}
int feenox_parser_expression_in_string_unsigned_integer(unsigned int *result) {
char *token = NULL;
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected expression");
return FEENOX_ERROR;
}
*result = (unsigned int)feenox_expression_evaluate_in_string(token);
return FEENOX_OK;
}
int feenox_parser_expression_in_string_sizet(size_t *result) {
char *token = NULL;
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected expression");
return FEENOX_ERROR;
}
*result = (size_t)feenox_expression_evaluate_in_string(token);
return FEENOX_OK;
}
int feenox_parser_string(char **string) {
char *token;
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected string");
return FEENOX_ERROR;
}
feenox_check_alloc(*string = strdup(token));
return FEENOX_OK;
}
int feenox_parser_string_format(char **string, int *n_args) {
char *token;
char *dummy;
*n_args = 0;
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected a string with optional printf format data");
return FEENOX_ERROR;
}
feenox_check_alloc(*string = strdup(token));
dummy = *string;
while (*dummy != '\0') {
if (*dummy == '\\') {
dummy++;
} else if (*dummy == '%' && *(dummy+1) == '%') {
dummy++;
} else if (*dummy == '%') {
if (dummy[1] == 'd') {
dummy[1] = 'g';
}
(*n_args)++;
}
dummy++;
}
return FEENOX_OK;
}
int feenox_parser_file(file_t **file) {
char *token = NULL;
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected file identifier");
return FEENOX_ERROR;
}
// "-" means stdin
if (strcmp(token, "-") == 0 || strcmp(token, "stdin") == 0) {
*file = feenox.special_files._stdin;
} else if ((*file = feenox_get_file_ptr(token)) == NULL) {
feenox_call(feenox_define_file(token, token, 0, NULL));
if ((*file = feenox_get_file_ptr(token)) == NULL) {
return FEENOX_ERROR;
}
}
return FEENOX_OK;
}
int feenox_parser_vector(vector_t **vector) {
char *token;
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected vector name");
return FEENOX_ERROR;
}
if ((*vector = feenox_get_vector_ptr(token)) == NULL) {
feenox_push_error_message("undefined vector identifier '%s'", token);
return FEENOX_ERROR;
}
return FEENOX_OK;
}
int feenox_parser_variable(var_t **var) {
char *token;
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected variable name");
return FEENOX_ERROR;
}
if ((*var = feenox_get_variable_ptr(token)) == NULL) {
feenox_push_error_message("undefined variable identifier '%s'", token);
return FEENOX_ERROR;
}
return FEENOX_OK;
}
int feenox_parser_get_or_define_variable(var_t **var) {
char *token;
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected variable name");
return FEENOX_ERROR;
}
if ((*var = feenox_get_or_define_variable_get_ptr(token)) == NULL) {
feenox_push_error_message("undefined variable identifier '%s'", token);
return FEENOX_ERROR;
}
return FEENOX_OK;
}
int feenox_parser_keywords_ints(char *keyword[], int *value, int *option) {
char *token;
int i = 0;
if ((token = feenox_get_next_token(NULL)) == NULL) {
while (keyword[i][0] != '\0') {
feenox_push_error_message("%s", keyword[i++]);
}
feenox_push_error_message("expected one of");
return FEENOX_ERROR;
}
while (keyword[i][0] != '\0') {
if (strcasecmp(token, keyword[i]) == 0) {
*option = value[i];
return FEENOX_OK;
}
i++;
}
i = 0;
while (keyword[i][0] != '\0') {
feenox_push_error_message("%s", keyword[i++]);
}
feenox_push_error_message("unknown keyword '%s', expected one of", token);
return FEENOX_ERROR;
}
/*
int feenox_parser_read_keywords_voids(char *keyword[], void *value[], void **option) {
char *token;
int i = 0;
if ((token = feenox_get_next_token(NULL)) == NULL) {
while (keyword[i][0] != '\0') {
feenox_push_error_message("%s", keyword[i++]);
}
feenox_push_error_message("expected one of");
return FEENOX_ERROR;
}
while (keyword[i][0] != '\0') {
if (strcasecmp(token, keyword[i]) == 0) {
*option = value[i];
return FEENOX_OK;
}
i++;
}
i = 0;
while (keyword[i][0] != '\0') {
feenox_push_error_message("%s", keyword[i++]);
}
feenox_push_error_message("unknown keyword '%s', expected one of", token);
return FEENOX_ERROR;
}
*/
// slightly-modified strtok() that can take into account if the next token
// starts with a quote (or not) and can read stuff between them
char *feenox_get_next_token(char *line) {
int i;
int n;
char *token;
// MAMA! lo que renegue para sacar la lectura invalida de este rutina que
// acusaba el valgrind! el chiste es asi: cuando se termina de parsear una
// linea vieja, el internal apunta a cualquier fruta (diferente de NULL)
// entonces no vale mirar que tiene. La solucion que se me ocurrio es que si
// line es diferente de NULL estamos empezando una linea nueva, eso quiere
// decir que internal apunta a fruta entonces lo hacemos igual a NULL y usamos
// los delimitadores sin comillas, porque total es una keyword
if (line != NULL) {
feenox_parser.strtok_internal = NULL;
}
if (feenox_parser.strtok_internal == NULL) {
token = strtok_r(line, UNQUOTED_DELIM, &(feenox_parser.strtok_internal));
} else {
if (*feenox_parser.strtok_internal == '"') {
token = strtok_r(line, QUOTED_DELIM, &(feenox_parser.strtok_internal));
// si es quoted, barremos token y reemplazamos el caracter 0x1E por un quote
n = strlen(token);
for (i = 0; i < n; i++) {
if (token[i] == -1 || token[i] == 0x1e) {
token[i] = '"';
}
}
} else {
token = strtok_r(line, UNQUOTED_DELIM, &(feenox_parser.strtok_internal));
}
}
// avanzamos el apuntador strtok_internal hasta el siguiente caracter no-blanco
// asi si la cadena q sigue empieza con comillas, la ve bien el if de arriba
// sino si hay muchos espacios en blanco el tipo piensa que el token esta unquoted
// el if de que no sea null saltaba solamente en windoze, ye ne se pa
if (feenox_parser.strtok_internal != NULL) {
while (*feenox_parser.strtok_internal == ' ' || *feenox_parser.strtok_internal == '\t') {
feenox_parser.strtok_internal++;
}
}
// esto casi nunca pasa, pero si nos quedamos sin tokens entonces otra vez
// internal apunta a cualquier lado
// OJO! a partir de algun update de la libc si dejamos esto tenemos segfault cuando
// algun primary keyword consume todas las keywords de la linea como PHYSICAL_ENTITY BC strings
// if (token == NULL) {
// feenox_parser.strtok_internal = NULL;
// }
return token;
}
/*
// parsea el rango de indices
int feenox_parse_range(char *string, const char left_delim, const char middle_delim, const char right_delim, expr_t *a, expr_t *b) {
char *first_bracket;
char *second_bracket;
char *colon;
if ((first_bracket = strchr(string, left_delim)) == NULL) {
feenox_push_error_message("range '%s' does not start with '%c'", string, left_delim);
return FEENOX_ERROR;
}
if ((second_bracket = strrchr(string, right_delim)) == NULL) {
feenox_push_error_message("unmatched '%c' for range in '%s'", left_delim, string);
return FEENOX_ERROR;
}
*second_bracket = '\0';
if ((colon = strchr(string, middle_delim)) == NULL) {
feenox_push_error_message("delimiter '%c' not found when giving range", middle_delim);
return FEENOX_ERROR;
}
*colon = '\0';
if (feenox_parse_expression(first_bracket+1, a) != 0) {
feenox_push_error_message("in min range expression");
return FEENOX_ERROR;
}
if (feenox_parse_expression(colon+1, b) != 0) {
feenox_push_error_message("in max range expression");
return FEENOX_ERROR;
}
*second_bracket = right_delim;;
*colon = middle_delim;
return FEENOX_OK;
}
*/
// saca los comentarios y los espacios en blanco iniciales de una linea
int feenox_strip_comments(char *line) {
int i = 0;
int j = 0;
char *buff = strdup(line);
while (isspace((int)buff[i])) {
i++;
}
while ((buff[i] != '#' && buff[i] != '\0') || (i > 0 && buff[i] == '#' && buff[i-1] == '\\')) {
if (i > 0 && buff[i] == '#' && buff[i-1] == '\\') {
j--;
}
line[j++] = buff[i++];
}
line[j] = '\0';
feenox_free(buff);
return FEENOX_OK;
}
/*
// lee una linea y eventualmente procesa los {}
int feenox_read_data_line(FILE *file_ptr, char *buffer) {
int l;
int lines = 1;
if (fgets(buffer, BUFFER_SIZE*BUFFER_SIZE, file_ptr) == NULL) {
return 0;
}
feenox_strip_comments(buffer); // limpiamos la linea
// TODO: explicar esto!
// si no tiene "{" entonces se curte
if (strchr(buffer, '{') == NULL) {
return 1;
}
do {
l = strlen(buffer);
if (fgets(buffer + l + 1, (BUFFER_SIZE*BUFFER_SIZE)-1, file_ptr) == 0) {
return FEENOX_ERROR;
}
buffer[l] = ' ';
feenox_strip_comments(buffer); // limpiamos la linea
lines++;
} while (strchr(buffer, '}') == NULL);
// feenox_strip_brackets(buffer);
return lines;
}
*/
// strips the blanks of a string (it modifies the argument string)
int feenox_strip_blanks(char *string) {
int i = 0;
int j = 0;
char *buff;
feenox_check_alloc(buff = strdup(string));
for (i = 0; i < strlen(string); i++) {
if (!isspace((int)buff[i])) {
string[j++] = buff[i];
}
}
string[j] = '\0';
feenox_free(buff);
return FEENOX_OK;
}
// this function parses a string like "f(x,y,z)"
// it creates the function and sets the arguments
// it returns the name of the function in name which should be freed
int feenox_add_function_from_string(const char *string, char **name) {
char *dummy_openpar = strchr(string, '(');
if (dummy_openpar == NULL) {
feenox_push_error_message("expecting open parenthesis in '%s'", string);
return FEENOX_ERROR;
}
*dummy_openpar = '\0';
feenox_check_alloc(*name = strdup(string));
*dummy_openpar = '(';
feenox_call(feenox_strip_blanks(*name));
char *arguments;
feenox_check_alloc(arguments = strdup(dummy_openpar));
feenox_call(feenox_strip_blanks(arguments));
size_t n_arguments;
if ((n_arguments = feenox_count_arguments(arguments, NULL)) <= 0) {
return FEENOX_ERROR;
}
char **arg_name = NULL;
feenox_call(feenox_read_arguments(arguments, n_arguments, &arg_name, NULL));
feenox_free(arguments);
*dummy_openpar = '\0';
feenox_call(feenox_define_function(*name, n_arguments));
int i;
for (i = 0; i < n_arguments; i++) {
feenox_call(feenox_function_set_argument_variable(*name, i, arg_name[i]));
}
// clean up this (partial) mess
if (arg_name != NULL) {
for (i = 0; i < n_arguments; i++) {
feenox_free(arg_name[i]);
}
feenox_free(arg_name);
}
return FEENOX_OK;
}
int feenox_add_post_field(mesh_write_t *mesh_write, unsigned int size, char **token, const char *name, field_location_t location) {
mesh_write_dist_t *mesh_write_dist = NULL;
feenox_check_alloc(mesh_write_dist = calloc(1, sizeof(mesh_write_dist_t)));
mesh_write_dist->field_location = location;
mesh_write_dist->size = size;
feenox_check_alloc(mesh_write_dist->field = calloc(mesh_write_dist->size, sizeof(function_t *)));
for (unsigned int i = 0; i < mesh_write_dist->size; i++) {
if ((mesh_write_dist->field[i] = feenox_get_function_ptr(token[i])) == NULL) {
// if there's no function with the provided name we define one
feenox_check_alloc(mesh_write_dist->field[i] = calloc(1, sizeof(function_t)));
feenox_check_alloc(mesh_write_dist->field[i]->name = strdup(token[i]));
mesh_write_dist->field[i]->type = function_type_algebraic;
mesh_write_dist->field[i]->n_arguments = 3;
mesh_write_dist->field[i]->n_arguments_given = 3;
mesh_write_dist->field[i]->var_argument = feenox.mesh.vars.arr_x;
feenox_call(feenox_expression_parse(&mesh_write_dist->field[i]->algebraic_expression, token[i]));
} else {
// mark the function as used so secondary fields such as stresses are computed
mesh_write_dist->field[i]->used = 1;
}
}
if (name != NULL) {
mesh_write_dist->name = strdup(name);
} else {
mesh_write_dist->name = strdup(mesh_write_dist->field[0]->name);
for (unsigned int i = 1; i < mesh_write_dist->size; i++) {
feenox_check_minusone(asprintf(&mesh_write_dist->name, "%s_%s", mesh_write_dist->name, mesh_write_dist->field[i]->name));
}
}
if (mesh_write->printf_format != NULL) {
feenox_check_alloc(mesh_write_dist->printf_format = strdup(mesh_write->printf_format));
}
LL_APPEND(mesh_write->mesh_write_dists, mesh_write_dist);
return FEENOX_OK;
}
feenox-1.2/src/parser/parser.h 0000664 0001750 0001750 00000011553 15055303016 012056 /*------------ -------------- -------- --- ----- --- -- - -
* FeenoX parser header
*
* Copyright (C) 2009--2021 Jeremy Theler
*
* This file is part of FeenoX.
*
* FeenoX is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with FeenoX. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#ifndef FEENOX_PARSER_H
#define FEENOX_PARSER_H
// token delimiters
#define UNQUOTED_DELIM " \t\n"
#define QUOTED_DELIM "\""
extern const char operators[];
extern const char factorseparators[];
typedef struct feenox_parser_t feenox_parser_t;
struct feenox_parser_t {
size_t page_size;
size_t actual_buffer_size;
int implicit_none;
int reading_daes;
int inside_yaml;
char *line;
char *full_line; // strtok breaks line so we keep a copy with the full one
// this is a pointer to an internal buffer to have "memory" for strtoken
// so we can parse stuff between quotation marks as a single token
char *strtok_internal;
conditional_block_t *active_conditional_block;
};
extern feenox_parser_t feenox_parser;
// parser.c
extern int feenox_parse_input_file(const char *filepath, int from, int to);
extern int feenox_parse_line(void);
extern mesh_t *feenox_parser_mesh(void);
// auxiliary.c
extern int feenox_read_line(FILE *file_ptr);
extern char *feenox_get_next_token(char *line);
extern int feenox_parser_string(char **string);
extern int feenox_parser_expression(expr_t *expr);
extern int feenox_parser_expressions(expr_t *expr[], size_t n);
extern int feenox_parser_expression_in_string(double *result);
extern int feenox_parser_expression_in_string_integer(int *result);
extern int feenox_parser_expression_in_string_unsigned_integer(unsigned int *result);
extern int feenox_parser_expression_in_string_sizet(size_t *result);
extern int feenox_parser_string_format(char **string, int *n_args);
extern int feenox_add_function_from_string(const char *string, char **name);
extern int feenox_add_post_field(mesh_write_t *mesh_write, unsigned int size, char **token, const char *name, field_location_t location);
extern int feenox_parser_file(file_t **file);
extern int feenox_parser_vector(vector_t **vector);
extern int feenox_parser_variable(var_t **var);
extern int feenox_parser_get_or_define_variable(var_t **var);
extern int feenox_parser_keywords_ints(char *keyword[], int *value, int *option);
extern int feenox_parser_match_keyword_expression(char *token, char *keyword[], expr_t *expr[], size_t n);
extern int feenox_parse_include(void);
extern int feenox_parse_default_argument_value(void);
extern int feenox_parse_abort(void);
extern int feenox_parse_implicit(void);
extern int feenox_parse_time_path(void);
extern int feenox_parse_initial_conditions(void);
extern int feenox_parse_variables(void);
extern int feenox_parse_alias(void);
extern int feenox_parse_vector(void);
extern int feenox_parse_matrix(void);
extern int feenox_parse_function(void);
extern int feenox_parse_function_data(function_t *function);
extern int feenox_parse_function_vectors(function_t *function);
extern int feenox_parse_function_mesh(function_t *function);
extern int feenox_parse_sort_vector(void);
extern int feenox_parse_file(char *mode);
extern int feenox_parse_open_close(const char *what);
extern int feenox_parse_read_data(void);
extern int feenox_parse_print(void);
extern int feenox_parse_printf(int all_ranks);
extern int feenox_parse_print_function(void);
extern int feenox_parse_print_vector(void);
extern int feenox_parse_if(void);
extern int feenox_parse_else(void);
extern int feenox_parse_endif(void);
extern int feenox_parse_phase_space(void);
extern int feenox_parse_read_mesh(void);
extern int feenox_parse_mesh_add(mesh_t *mesh);
extern int feenox_parse_write_mesh(void);
extern int feenox_parse_write_results(void);
extern int feenox_parse_physical_group(void);
extern int feenox_parse_material(void);
extern int feenox_parse_bc_add_group(bc_t *bc, const char *physical_group_name);
extern int feenox_parse_bc(void);
extern int feenox_parse_reaction(void);
extern int feenox_parse_problem(void);
extern int feenox_parse_petsc_options(void);
extern int feenox_parse_solve_problem(void);
extern int feenox_parse_integrate(void);
extern int feenox_parse_find_extrema(void);
extern int feenox_parse_fit(void);
extern int feenox_parse_dump(void);
extern int feenox_parse_solve(void);
#endif
feenox-1.2/src/parser/parser.c 0000664 0001750 0001750 00000524014 15055303016 012052 /*------------ -------------- -------- --- ----- --- -- - -
* FeenoX parser
*
* Copyright (C) 2009--2025 Jeremy Theler
*
* This file is part of FeenoX.
*
* FeenoX is free software: you can redistribute it and/or modify
* it under the terms "of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* FeenoX is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with feenox. If not, see .
*------------------- ------------ ---- -------- -- - - -
*/
#include "feenox.h"
#include "parser.h"
feenox_parser_t feenox_parser;
#include
#include
#include
#if HAVE_SYSCONF
#include
#endif
int feenox_parse_main_input_file(const char *filepath) {
// check the page size to use a reasonable buffer size
// we can ask for more if we need
#if HAVE_SYSCONF
feenox_parser.page_size = (size_t)sysconf(_SC_PAGESIZE);
#else
feenox_parser.page_size = 4096;
#endif
feenox_parser.actual_buffer_size = feenox_parser.page_size-64;
feenox_check_alloc(feenox_parser.line = malloc(feenox_parser.actual_buffer_size));
feenox_call(feenox_parse_input_file(filepath, 0, 0));
feenox_free(feenox_parser.line);
if (feenox_parser.active_conditional_block != NULL) {
feenox_push_error_message("conditional block not closed");
return FEENOX_ERROR;
}
return FEENOX_OK;
}
// parse an input file (it can be called recursively to handle INCLUDEs)
int feenox_parse_input_file(const char *filepath, int from, int to) {
FILE *input_file_stream;
int line_num, delta_line_num;
if (filepath == NULL) {
return FEENOX_OK;
} else if (strcmp(filepath, "-") == 0) {
input_file_stream = stdin;
} else {
if ((input_file_stream = feenox_fopen(filepath, "r")) == NULL) {
feenox_push_error_message("input file '%s' could not be opened: %s", filepath, strerror(errno));
return FEENOX_ERROR;
}
}
// line-by-line parser
line_num = 0;
while ((delta_line_num = feenox_read_line(input_file_stream)) != 0) {
// a negative delta_line_num indicates that the line asks for an argument $n
// which was not provided but this can occur on a line which is ignored
// by a from/to INCLUDE directive so it is not a catastrophic error
line_num += abs(delta_line_num);
if (feenox_parser.line[0] != '\0' && feenox_parser.inside_yaml == 0 && ((from == 0 || line_num >= from) && ((to == 0) || line_num <= to))) {
// we do have to process the line so if delta_line_num is negative, we complain now
if (delta_line_num < 0) {
feenox_push_error_message("input file needs at least one more argument in commandline");
return FEENOX_ERROR;
}
// the line is broken by strtok inside parse_line() and we need
// the original for assignments and equations
feenox_check_alloc(feenox_parser.full_line = strdup(feenox_parser.line));
if (feenox_parse_line() != FEENOX_OK) {
feenox_free(feenox_parser.full_line);
feenox_push_error_message("%s: %d:", filepath, line_num);
return FEENOX_ERROR;
}
feenox_free(feenox_parser.full_line);
}
}
if (strcmp(filepath, "-") != 0) {
fclose(input_file_stream);
}
return (feenox.error_level == 0) ? FEENOX_OK : FEENOX_ERROR;
}
// feenox line parser
int feenox_parse_line(void) {
char *equal_sign = NULL;
char *token = NULL;
if ((token = feenox_get_next_token(feenox_parser.line)) != NULL) {
///kw+INCLUDE+usage INCLUDE
///kw+INCLUDE+desc Include another FeenoX input file.
if (strcasecmp(token, "INCLUDE") == 0) {
feenox_call(feenox_parse_include());
return FEENOX_OK;
///kw+ABORT+usage ABORT
///kw+ABORT+desc Catastrophically abort the execution and quit FeenoX.
} else if (strcasecmp(token, "ABORT") == 0) {
feenox_call(feenox_parse_abort());
return FEENOX_OK;
///kw+DEFAULT_ARGUMENT_VALUE+usage DEFAULT_ARGUMENT_VALUE
///kw+DEFAULT_ARGUMENT_VALUE+desc Give a default value for an optional commandline argument.
} else if (strcasecmp(token, "DEFAULT_ARGUMENT_VALUE") == 0) {
feenox_call(feenox_parse_default_argument_value());
return FEENOX_OK;
///kw+IMPLICIT+usage IMPLICIT
///kw+IMPLICIT+desc Define whether implicit definition of variables is allowed or not.
} else if (strcasecmp(token, "IMPLICIT") == 0) {
feenox_call(feenox_parse_implicit());
return FEENOX_OK;
///kw_dae+TIME_PATH+usage TIME_PATH
///kw_dae+TIME_PATH+desc Force time-dependent problems to pass through specific instants of time.
} else if (strcasecmp(token, "TIME_PATH") == 0) {
feenox_call(feenox_parse_time_path());
return FEENOX_OK;
///kw_dae+INITIAL_CONDITIONS+usage INITIAL_CONDITIONS
///kw_dae+INITIAL_CONDITIONS+desc Define how initial conditions of DAE problems are computed.
} else if (strcasecmp(token, "INITIAL_CONDITIONS") == 0 || strcasecmp(token, "INITIAL_CONDITIONS_MODE") == 0) {
feenox_call(feenox_parse_initial_conditions());
return FEENOX_OK;
///kw+VAR+usage VAR
///kw+VAR+desc Explicitly define one or more scalar variables.
} else if (strcasecmp(token, "VAR") == 0 || strcasecmp(token, "VARIABLE") == 0 ||
strcasecmp(token, "VARS") == 0 || strcasecmp(token, "VARIABLES") == 0) {
feenox_call(feenox_parse_variables());
return FEENOX_OK;
///kw+ALIAS+usage ALIAS
///kw+ALIAS+desc Define a scalar alias of an already-defined identifier.
} else if (strcasecmp(token, "ALIAS") == 0) {
feenox_call(feenox_parse_alias());
return FEENOX_OK;
///kw+VECTOR+usage VECTOR
///kw+VECTOR+desc Define a vector.
} else if (strcasecmp(token, "VECTOR") == 0) {
feenox_call(feenox_parse_vector());
return FEENOX_OK;
///kw+SORT_VECTOR+usage SORT_VECTOR
///kw+SORT_VECTOR+desc Sort the elements of a vector, optionally making the same rearrangement in another vector.
} else if (strcasecmp(token, "SORT_VECTOR") == 0 || strcasecmp(token, "VECTOR_SORT") == 0) {
feenox_call(feenox_parse_sort_vector());
return FEENOX_OK;
///kw+MATRIX+usage MATRIX
///kw+MATRIX+desc Define a matrix.
} else if (strcasecmp(token, "MATRIX") == 0) {
feenox_call(feenox_parse_matrix());
return FEENOX_OK;
///kw+FUNCTION+usage FUNCTION
///kw+FUNCTION+desc Define a scalar function of one or more variables.
} else if (strcasecmp(token, "FUNCTION") == 0) {
feenox_call(feenox_parse_function());
return FEENOX_OK;
///kw+READ_DATA+desc Read data from a file (or standard output, or pipe, or queue, etc.).
///kw+READ_DATA+usage READ_DATA
} else if (strcasecmp(token, "READ_DATA") == 0) {
feenox_call(feenox_parse_read_data());
return FEENOX_OK;
///kw+PRINT+desc Write plain-text and/or formatted data to the standard output or into an output file.
///kw+PRINT+usage PRINT
} else if (strcasecmp(token, "PRINT") == 0) {
feenox_call(feenox_parse_print());
return FEENOX_OK;
///kw+PRINTF+desc Instruction akin to C's `printf`.
///kw+PRINTF+usage PRINTF
} else if (strcasecmp(token, "PRINTF") == 0) {
feenox_call(feenox_parse_printf(0));
return FEENOX_OK;
///kw+PRINTF+desc Instruction akin to C's `printf` executed locally from all MPI ranks.
///kw+PRINTF+usage PRINTF_ALL
} else if (strcasecmp(token, "PRINTF_ALL") == 0) {
feenox_call(feenox_parse_printf(1));
return FEENOX_OK;
///kw+PRINT_FUNCTION+desc Print one or more functions as a table of values of dependent and independent variables.
///kw+PRINT_FUNCTION+usage PRINT_FUNCTION
} else if (strcasecmp(token, "PRINT_FUNCTION") == 0) {
feenox_call(feenox_parse_print_function());
return FEENOX_OK;
///kw+PRINT_VECTOR+desc Print the elements of one or more vectors, one element per line.
///kw+PRINT_VECTOR+usage PRINT_VECTOR
} else if (strcasecmp(token, "PRINT_VECTOR") == 0) {
feenox_call(feenox_parse_print_vector());
return FEENOX_OK;
///kw+FILE+desc Define a file with a particularly formatted name to be used either as input or as output.
///kw+FILE+usage < FILE | OUTPUT_FILE | INPUT_FILE >
} else if (strcasecmp(token, "FILE") == 0) {
feenox_call(feenox_parse_file(NULL));
return FEENOX_OK;
} else if (strcasecmp(token, "OUTPUT_FILE") == 0) {
feenox_call(feenox_parse_file("w"));
return FEENOX_OK;
} else if (strcasecmp(token, "INPUT_FILE") == 0) {
feenox_call(feenox_parse_file("r"));
return FEENOX_OK;
///kw+OPEN+desc Explicitly open a file for input/output.
///kw+OPEN+usage OPEN
} else if (strcasecmp(token, "OPEN") == 0) {
feenox_call(feenox_parse_open_close("OPEN"));
return FEENOX_OK;
///kw+CLOSE+desc Explicitly close a file after input/output.
///kw+CLOSE+usage CLOSE
} else if (strcasecmp(token, "CLOSE") == 0) {
feenox_call(feenox_parse_open_close("CLOSE"));
return FEENOX_OK;
///kw+IF+desc Execute a set of instructions if a condition is met.
///kw+IF+usage IF expr @
///kw+IF+usage @
} else if (strcasecmp(token, "IF") == 0) {
feenox_call(feenox_parse_if());
return FEENOX_OK;
///kw+IF+usage [ ELSE @
///kw+IF+usage ] @
} else if (strcasecmp(token, "ELSE") == 0) {
feenox_call(feenox_parse_else());
return FEENOX_OK;
///kw+IF+usage ENDIF
} else if (strcasecmp(token, "ENDIF") == 0) {
feenox_call(feenox_parse_endif());
return FEENOX_OK;
///kw_dae+PHASE_SPACE+desc Ask FeenoX to solve a set of algebraic-differntial equations and define the variables, vectors and/or matrices that span the phase space.
///kw_dae+PHASE_SPACE+usage PHASE_SPACE
// ----- -----------------------------------------------------------
} else if (strcasecmp(token, "PHASE_SPACE") == 0) {
feenox_call(feenox_parse_phase_space());
return FEENOX_OK;
///kw_pde+READ_MESH+desc Read an unstructured mesh and (optionally) functions of space-time from a file.
///kw_pde+READ_MESH+usage READ_MESH
// ----- -----------------------------------------------------------
} else if (strcasecmp(token, "READ_MESH") == 0) {
feenox_call(feenox_parse_read_mesh());
return FEENOX_OK;
///kw_pde+WRITE_MESH+desc Write a mesh and/or generic functions of space-time to a post-processing file.
///kw_pde+WRITE_MESH+usage WRITE_MESH
// ----- -----------------------------------------------------------
} else if (strcasecmp(token, "WRITE_MESH") == 0) {
feenox_call(feenox_parse_write_mesh());
return FEENOX_OK;
///kw_pde+WRITE_RESULTS+desc Write the problem mesh and problem results to a file for post-processing.
///kw_pde+WRITE_RESULTS+usage WRITE_RESULTS
// ----- -----------------------------------------------------------
} else if (strcasecmp(token, "WRITE_RESULTS") == 0) {
feenox_call(feenox_parse_write_results());
return FEENOX_OK;
// description is in pdes/parse.c
} else if (strcasecmp(token, "PROBLEM") == 0) {
#ifdef HAVE_PETSC
feenox_call(feenox_parse_problem());
return FEENOX_OK;
#else
feenox_push_error_message("FeenoX is not compiled with PETSc so it cannot solve PROBLEMs");
return FEENOX_ERROR;
#endif
///kw_pde+PETSC_OPTIONS+desc Pass verbatim options to PETSc.
///kw_pde+PETSC_OPTIONS+usage PETSC_OPTIONS
// ----- -----------------------------------------------------------
} else if (strcasecmp(token, "PETSC_OPTIONS") == 0) {
feenox_call(feenox_parse_petsc_options());
return FEENOX_OK;
///kw_pde+PHYSICAL_GROUP+desc Explicitly defines a physical group of elements on a mesh.
///kw_pde+PHYSICAL_GROUP+usage PHYSICAL_GROUP
// ----- -----------------------------------------------------------
} else if (strcasecmp(token, "PHYSICAL_GROUP") == 0) {
feenox_call(feenox_parse_physical_group());
return FEENOX_OK;
///kw_pde+MATERIAL+desc Define a material its and properties to be used in volumes.
///kw_pde+MATERIAL+usage MATERIAL
// ----- -----------------------------------------------------------
} else if (strcasecmp(token, "MATERIAL") == 0) {
feenox_call(feenox_parse_material());
return FEENOX_OK;
///kw_pde+BC+desc Define a boundary condition to be applied to faces, edges and/or vertices.
///kw_pde+BC+usage BC
// ----- -----------------------------------------------------------
} else if (strcasecmp(token, "BC") == 0 || strcasecmp(token, "BOUNDARY_CONDITION") == 0) {
feenox_call(feenox_parse_bc());
return FEENOX_OK;
///kw_pde+COMPUTE_REACTION+desc Compute the reaction (force, moment, power, etc.) at selected face, edge or vertex.
///kw_pde+COMPUTE_REACTION+usage COMPUTE_REACTION
// ----- -----------------------------------------------------------
} else if (strcasecmp(token, "COMPUTE_REACTION") == 0 || strcasecmp(token, "REACTION") == 0) {
feenox_call(feenox_parse_reaction());
return FEENOX_OK;
///kw_pde+SOLVE_PROBLEM+desc Explicitly solve the PDE problem.
///kw_pde+SOLVE_PROBLEM+usage SOLVE_PROBLEM
} else if (strcasecmp(token, "SOLVE_PROBLEM") == 0) {
#ifdef HAVE_PETSC
feenox_call(feenox_parse_solve_problem());
return FEENOX_OK;
#else
feenox_push_error_message("FeenoX is not compiled with PETSc so it cannot solve PROBLEMs");
return FEENOX_ERROR;
#endif
///kw_pde+INTEGRATE+desc Spatially integrate a function or expression over a mesh (or a subset of it).
///kw_pde+INTEGRATE+usage INTEGRATE
// ----- -----------------------------------------------------------
} else if (strcasecmp(token, "INTEGRATE") == 0) {
feenox_call(feenox_parse_integrate());
return FEENOX_OK;
///kw_pde+FIND_EXTREMA+desc Find and/or compute the absolute extrema of a function or expression over a mesh (or a subset of it).
///kw_pde+FIND_EXTREMA+usage FIND_EXTREMA
// ----- -----------------------------------------------------------
} else if (strcasecmp(token, "FIND_EXTREMA") == 0) {
feenox_call(feenox_parse_find_extrema());
return FEENOX_OK;
///kw+FIT+desc Find parameters to fit an analytical function to a pointwise-defined function.
///kw+FIT+usage FIT
// ----- -----------------------------------------------------------
} else if (strcasecmp(token, "FIT") == 0) {
feenox_call(feenox_parse_fit());
return FEENOX_OK;
///kw_pde+DUMP+desc Dump raw PETSc objects used to solve PDEs into files.
///kw_pde+DUMP+usage DUMP
// ----- -----------------------------------------------------------
} else if (strcasecmp(token, "DUMP") == 0) {
feenox_call(feenox_parse_dump());
return FEENOX_OK;
///kw+SOLVE+desc Solve a (small) system of non-linear equations.
///kw+SOLVE+usage SOLVE
// ----- -----------------------------------------------------------
} else if (strcasecmp(token, "SOLVE") == 0) {
feenox_call(feenox_parse_solve());
return FEENOX_OK;
// TODO: move this to a per-physics parser
// ----- -----------------------------------------------------------
} else if (strcasecmp(token, "LINEARIZE_STRESS") == 0) {
feenox_call(feenox_parse_linearize_stress());
return FEENOX_OK;
// this should come last because there is no actual keyword apart from the equal sign
// so if we came down here, then that means that any line containing a '=' that has
// not been already processed must be one of these
// i. an algebraic function
// ii. an equation for the DAE
// iii. an assignment
// TODO: explain syntax for reference
} else if ((equal_sign = strstr(feenox_parser.full_line, ":=")) != NULL ||
(equal_sign = strstr(feenox_parser.full_line, ".=")) != NULL ||
(equal_sign = strchr(feenox_parser.full_line, '=')) != NULL) {
enum { parser_assignment, parser_dae, parser_function } type;
// first see if there is an explicit sign
switch (*equal_sign) {
case '=':
type = parser_assignment;
break;
case ':':
type = parser_function;
break;
case '.':
type = parser_dae;
break;
default:
feenox_push_error_message("unexpected character '%c'", *equal_sign);
return FEENOX_ERROR;
break;
}
*equal_sign = '\0';
char *lhs = feenox_parser.full_line;
char *rhs = equal_sign + 1 + (equal_sign[1] == '=');
// try to figure out if it is a DAE or a function automatically
if (type == parser_assignment) {
char *lhs_tmp = NULL;
feenox_check_alloc(lhs_tmp = strdup(lhs));
char *lhs_object = NULL;
lhs_object = strtok(lhs_tmp, factorseparators);
// check if it is a function
int length_full = strlen(lhs);
int length_object = strlen(lhs_object);
if (length_full > length_object && lhs[length_object] == '(') {
type = parser_function;
} else {
// check if the object belongs to the phase space
phase_object_t *phase_object = NULL;
LL_FOREACH(feenox.dae.phase_objects, phase_object) {
if ((phase_object->variable != NULL && strcmp(lhs_object, phase_object->variable->name) == 0) ||
(phase_object->variable_dot != NULL && strcmp(lhs_object, phase_object->variable_dot->name) == 0) ||
(phase_object->vector != NULL && strcmp(lhs_object, phase_object->vector->name) == 0) ||
(phase_object->vector_dot != NULL && strcmp(lhs_object, phase_object->vector_dot->name) == 0) ||
(phase_object->matrix != NULL && strcmp(lhs_object, phase_object->matrix->name) == 0) ||
(phase_object->matrix_dot != NULL && strcmp(lhs_object, phase_object->matrix_dot->name) == 0)) {
type = parser_dae;
}
}
}
feenox_free(lhs_tmp);
}
switch (type) {
case parser_assignment:
feenox_call(feenox_add_assignment(lhs, rhs));
break;
case parser_function:
{
char *name;
feenox_call(feenox_add_function_from_string(lhs, &name));
feenox_call(feenox_function_set_expression(name, rhs));
feenox_free(name);
}
break;
case parser_dae:
// TODO: handle vector/matrix DAEs
feenox_call(feenox_add_dae(lhs, rhs));
break;
}
return FEENOX_OK;
}
}
/*
// ---- SEMAPHORE ----------------------------------------------------
//kw+SEMAPHORE+desc Perform either a wait or a post operation on a named shared semaphore.
//kw+SEMAPHORE+usage [ SEMAPHORE | SEM ]
} else if ((strcasecmp(token, "SEMAPHORE") == 0) || (strcasecmp(token, "SEM") == 0)) {
struct semaphore_t *semaphore;
semaphore = calloc(1, sizeof(struct semaphore_t));
LL_APPEND(feenox.semaphores, semaphore);
//kw+SEMAPHORE+usage
if (feenox_parser_string(&semaphore->name) != FEENOX_OK) {
return FEENOX_ERROR;
}
//kw+SEMAPHORE+usage { WAIT | POST }
char *keywords[] = {"WAIT", "POST", ""};
int values[] = {feenox_sem_wait, feenox_sem_post, 0};
feenox_call(feenox_parser_keywords_ints(keywords, values, (int *)&semaphore->operation));
if (feenox_define_instruction(feenox_instruction_sem, semaphore) == NULL) {
return FEENOX_ERROR;
}
return FEENOX_OK;
// ---- READ / WRITE ----------------------------------------------------
//kw+READ+desc Read data (variables, vectors o matrices) from files or shared-memory segments.
//kw+WRITE+desc Write data (variables, vectors o matrices) to files or shared-memory segments.
//kw+WRITE+desc See the `READ` keyword for usage details.
//kw+READ+usage [ READ | WRITE ]
} else if ((strcasecmp(token, "READ") == 0) || (strcasecmp(token, "WRITE") == 0)) {
io_t *io = calloc(1, sizeof(io_t));
LL_APPEND(feenox.ios, io);
if (strcasecmp(token, "READ") == 0) {
io->direction = io_read;
} else if (strcasecmp(token, "WRITE") == 0) {
io->direction = io_write;
}
while ((token = feenox_get_next_token(NULL)) != NULL) {
// ---- SHM_OBJECT ---------------------------------------------------------
//kw+READ+usage [ SHM ]
if (strcasecmp(token, "SHM") == 0 || strcasecmp(token, "SHM_OBJECT") == 0) {
io->type = io_shm;
if (feenox_parser_string(&io->shm_name) != FEENOX_OK) {
return FEENOX_ERROR;
}
// ---- FILE_PATH ----------------------------------------------------
//kw+READ+usage [ { ASCII_FILE_PATH | BINARY_FILE_PATH } ]
} else if (strcasecmp(token, "ASCII_FILE_PATH") == 0 || strcasecmp(token, "BINARY_FILE_PATH") == 0) {
char mode[2];
if (io->direction == io_read) {
sprintf(mode, "r");
} else if (io->direction == io_write) {
sprintf(mode, "w");
}
if (strcasecmp(token, "ASCII_FILE_PATH") == 0) {
io->type = io_file_ascii;
} else if (strcasecmp(token, "BINARY_FILE_PATH") == 0) {
io->type = io_file_binary;
}
feenox_call(feenox_parser_file_path(&io->file, mode));
// ---- FILE ----------------------------------------------------
//kw+READ+usage [ { ASCII_FILE | BINARY_FILE } ]
} else if (strcasecmp(token, "ASCII_FILE") == 0 || strcasecmp(token, "BINARY_FILE") == 0) {
if (strcasecmp(token, "ASCII_FILE") == 0) {
io->type = io_file_ascii;
} else if (strcasecmp(token, "BINARY_FILE") == 0) {
io->type = io_file_binary;
}
if (feenox_parser_file(&io->file) != FEENOX_OK) {
return FEENOX_ERROR;
}
// ---- FILE ----------------------------------------------------
//kw+READ+usage [ IGNORE_NULL ]
} else if (strcasecmp(token, "IGNORE_NULL") == 0) {
io->ignorenull = 1;
} else {
//kw+READ+usage [ object_1 object_2 ... object_n ]
// cosas
io->n_things++;
io_thing_t *thing = calloc(1, sizeof(io_thing_t));
LL_APPEND(io->things, thing);
// si pusieron un corchete quieren un pedazo solamente
if ((dummy = strchr(token, '<')) != NULL) {
*dummy = '\0';
}
if ((thing->variable = feenox_get_variable_ptr(token)) != NULL) {
// manzana, despues sumamos uno al tamanio en feenox_io_init()
;
} else if ((thing->vector = feenox_get_vector_ptr(token)) != NULL) {
if (dummy != NULL) {
*dummy = '<';
feenox_call(feenox_parse_range(dummy, '<', ':', '>', &thing->expr_row_min, &thing->expr_row_max));
}
} else if ((thing->matrix = feenox_get_matrix_ptr(token)) != NULL) {
if (dummy != NULL) {
*dummy = '<';
feenox_call(feenox_parse_range(dummy, '<', ':', ';', &thing->expr_row_min, &thing->expr_row_max));
feenox_call(feenox_parse_range(strchr(dummy, ';'), ';', ':', '>', &thing->expr_col_min, &thing->expr_col_max));
}
} else {
if (feenox_parse_expression(token, &thing->expr) != FEENOX_OK) {
feenox_push_error_message("undefined keyword, variable, vector, matrix, alias or invalid expression '%s'", token);
return FEENOX_ERROR;
}
if (io->direction == io_read) {
feenox_push_error_message("expressions cannot be used in a READ instruction", token);
return FEENOX_ERROR;
}
}
}
}
if (io->type == io_undefined) {
feenox_push_error_message("undefined I/O resource type");
return FEENOX_ERROR;
}
if (feenox_define_instruction(feenox_instruction_io, io) == NULL) {
return FEENOX_ERROR;
}
return FEENOX_OK;
// ----- HISTORY -----------------------------------------------------------------
//kw+HISTORY+desc Record the time history of a variable as a function of time.
//kw+HISTORY+usage HISTORY
} else if ((strcasecmp(token, "HISTORY") == 0)) {
history_t *history;
history = calloc(1, sizeof(history_t));
LL_APPEND(feenox.histories, history);
//kw+HISTORY+usage
// el nombre de la variable
if (feenox_parser_variable(&history->variable)) {
return FEENOX_ERROR;
}
//kw+HISTORY+usage
// el nombre de la funcion
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected function name");
return FEENOX_ERROR;
}
if ((history->function = feenox_define_function(token, 1)) == NULL) {
return FEENOX_ERROR;
}
// proposed by rvignolo
// feenox_check_alloc(history->function->arg_name = malloc(1 * sizeof(char *)));
// feenox_check_alloc(history->function->arg_name[0] = strdup(feenox.special_vars.t->name));
if (feenox_define_instruction(feenox_instruction_history, history) == NULL) {
return FEENOX_ERROR;
}
return FEENOX_OK;
}
*/
feenox_push_error_message("unknown keyword '%s'", feenox_parser.line);
return FEENOX_ERROR;
}
char *feenox_get_nth_token(char *string, int n) {
char *backup;
char *token;
char *desired_token;
int i;
feenox_check_alloc_null(backup = strdup(string));
if ((token = strtok(backup, UNQUOTED_DELIM)) == NULL) {
feenox_free(backup);
return NULL;
}
i = 1;
while (i < n) {
if ((token = strtok(NULL, UNQUOTED_DELIM)) == NULL) {
feenox_free(backup);
return NULL;
}
i++;
}
feenox_check_alloc_null(desired_token = strdup(token));
feenox_free(backup);
return desired_token;
}
int feenox_parse_include(void) {
///kw+INCLUDE+detail Includes the input file located in the string `file_path` at the current location.
///kw+INCLUDE+detail The effect is the same as copying and pasting the contents of the included file
///kw+INCLUDE+detail at the location of the `INCLUDE` keyword. The path can be relative or absolute.
///kw+INCLUDE+detail Note, however, that when including files inside `IF` blocks that instructions are
///kw+INCLUDE+detail conditionally-executed but all definitions (such as function definitions) are processed at
///kw+INCLUDE+detail parse-time independently from the evaluation of the conditional.
///kw+INCLUDE+detail The included file has to be an actual file path (i.e. it cannot be a FeenoX `FILE`)
///kw+INCLUDE+detail because it needs to be resolved at parse time. Yet, the name can contain a
///kw+INCLUDE+detail commandline replacement argument such as `$1` so `INCLUDE $1.fee` will include the
///kw+INCLUDE+detail file specified after the main input file in the command line.
char *token = NULL;
char *filepath = NULL;
double xi = 0;
unsigned int from = 0;
unsigned int to = 0;
///kw+INCLUDE+usage
feenox_call(feenox_parser_string(&filepath));
while ((token = feenox_get_next_token(NULL)) != NULL) {
///kw+INCLUDE+usage [ FROM ]
///kw+INCLUDE+detail The optional `FROM` and `TO` keywords can be used to include only portions of a file.
if (strcasecmp(token, "FROM") == 0) {
feenox_call(feenox_parser_expression_in_string(&xi));
if ((from = (int)(xi)) <= 0) {
feenox_push_error_message("expected a positive line number for FROM instead of '%s'", token);
return FEENOX_ERROR;
}
///kw+INCLUDE+usage [ TO ]
} else if (strcasecmp(token, "TO") == 0) {
feenox_call(feenox_parser_expression_in_string(&xi));
if ((to = (int)(xi)) <= 0) {
feenox_push_error_message("expected a positive line number for TO instead of '%s'", token);
return FEENOX_ERROR;
}
}
}
feenox_call(feenox_parse_input_file(filepath, from, to));
feenox_free(filepath);
return FEENOX_OK;
}
int feenox_parse_default_argument_value(void) {
///kw+DEFAULT_ARGUMENT_VALUE+detail If a `$n` construction is found in the input file but the
///kw+DEFAULT_ARGUMENT_VALUE+detail commandline argument was not given, the default behavior is to
///kw+DEFAULT_ARGUMENT_VALUE+detail fail complaining that an extra argument has to be given in the
///kw+DEFAULT_ARGUMENT_VALUE+detail commandline. With this keyword, a default value can be assigned if
///kw+DEFAULT_ARGUMENT_VALUE+detail no argument is given, thus avoiding the failure and making the argument
///kw+DEFAULT_ARGUMENT_VALUE+detail optional.
///kw+DEFAULT_ARGUMENT_VALUE+detail The `` should be 1, 2, 3, etc. and `` will be expanded
///kw+DEFAULT_ARGUMENT_VALUE+detail character-by-character where the `$n` construction is.
///kw+DEFAULT_ARGUMENT_VALUE+detail Whether the resulting expression is to be interpreted as a string or as a
///kw+DEFAULT_ARGUMENT_VALUE+detail numerical expression will depend on the context.
char *token;
int n;
///kw+DEFAULT_ARGUMENT_VALUE+usage
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected argument number for DEFAULT_ARGUMENT_VALUE");
return FEENOX_ERROR;
}
if ((n = (int)feenox_expression_evaluate_in_string(token)) <= 0) {
feenox_push_error_message("expected a positive value instead of 'token", token);
return FEENOX_ERROR;
}
///kw+DEFAULT_ARGUMENT_VALUE+usage
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected value for DEFAULT_ARUGMENT_VALUE number %d", n);
return FEENOX_ERROR;
}
if ((feenox.optind+n) >= feenox.argc) {
feenox.argc = feenox.optind+n + 1;
feenox_check_alloc(feenox.argv = realloc(feenox.argv, sizeof(char *)*(feenox.argc + 1)));
feenox_check_alloc(feenox.argv[feenox.optind+n] = strdup(token));
feenox_check_alloc(feenox.argv_orig = realloc(feenox.argv_orig, sizeof(char *)*(feenox.argc + 1)));
feenox_check_alloc(feenox.argv_orig[feenox.optind+n] = strdup(token));
}
return FEENOX_OK;
}
int feenox_parse_abort(void) {
///kw+ABORT+detail Whenever the instruction `ABORT` is executed, FeenoX quits with a non-zero error leve.
///kw+ABORT+detail It does not close files nor unlock shared memory objects.
///kw+ABORT+detail The objective of this instruction is to either debug complex input files
///kw+ABORT+detail by using only parts of them or to conditionally abort the execution using `IF` clauses.
feenox_call(feenox_add_instruction(feenox_instruction_abort, NULL));
return FEENOX_OK;
}
int feenox_parse_implicit(void) {
///kw+IMPLICIT+detail By default, FeenoX allows variables (but not vectors nor matrices) to be
///kw+IMPLICIT+detail implicitly declared. To avoid introducing errors due to typos, explicit
///kw+IMPLICIT+detail declaration of variables can be forced by giving `IMPLICIT NONE`.
///kw+IMPLICIT+detail Whether implicit declaration is allowed or explicit declaration is required
///kw+IMPLICIT+detail depends on the last `IMPLICIT` keyword given, which by default is `ALLOWED`.
///kw+IMPLICIT+usage { NONE | ALLOWED }
char *keywords[] = {"NONE", "ALLOWED", ""};
int values[] = {1, 0, 0};
feenox_call(feenox_parser_keywords_ints(keywords, values, &feenox_parser.implicit_none));
return FEENOX_OK;
}
int feenox_parse_time_path(void) {
///kw_dae+TIME_PATH+detail The time step `dt` will be reduced whenever the distance between
///kw_dae+TIME_PATH+detail the current time `t` and the next expression in the list is greater
///kw_dae+TIME_PATH+detail than `dt` so as to force `t` to coincide with the expressions given.
///kw_dae+TIME_PATH+detail The list of expressions should evaluate to a sorted list of values for all times.
char *token;
///kw_dae+TIME_PATH+usage [ [ ... ] ]
while ((token = feenox_get_next_token(NULL)) != NULL) {
feenox_call(feenox_add_time_path(token));
}
// y apuntamos el current al primero
feenox.time_path_current = feenox.time_paths;
return FEENOX_OK;
}
int feenox_parse_initial_conditions(void) {
///kw_dae+INITIAL_CONDITIONS+detail In DAE problems, initial conditions may be either:
///kw_dae+INITIAL_CONDITIONS+detail @
///kw_dae+INITIAL_CONDITIONS+detail * equal to the provided expressions (`AS_PROVIDED`)@
///kw_dae+INITIAL_CONDITIONS+detail * the derivatives computed from the provided phase-space variables (`FROM_VARIABLES`)@
///kw_dae+INITIAL_CONDITIONS+detail * the phase-space variables computed from the provided derivatives (`FROM_DERIVATIVES`)@
///kw_dae+INITIAL_CONDITIONS+detail @
///kw_dae+INITIAL_CONDITIONS+detail In the first case, it is up to the user to fulfill the DAE system at\ $t = 0$.
///kw_dae+INITIAL_CONDITIONS+detail If the residuals are not small enough, a convergence error will occur.
///kw_dae+INITIAL_CONDITIONS+detail The `FROM_VARIABLES` option means calling IDA’s `IDACalcIC` routine with the parameter `IDA_YA_YDP_INIT`.
///kw_dae+INITIAL_CONDITIONS+detail The `FROM_DERIVATIVES` option means calling IDA’s `IDACalcIC` routine with the parameter IDA_Y_INIT.
///kw_dae+INITIAL_CONDITIONS+detail Wasora should be able to automatically detect which variables in phase-space are differential and
///kw_dae+INITIAL_CONDITIONS+detail which are purely algebraic. However, the `DIFFERENTIAL` keyword may be used to explicitly define them.
///kw_dae+INITIAL_CONDITIONS+detail See the [SUNDIALS documentation](https://computation.llnl.gov/casc/sundials/documentation/ida_guide.pdf) for further information.
///kw_dae+INITIAL_CONDITIONS+usage { AS_PROVIDED | FROM_VARIABLES | FROM_DERIVATIVES }
char *keywords[] = {"AS_PROVIDED",
"FROM_VARIABLES",
"FROM_DERIVATIVES", ""};
int values[] = {initial_conditions_as_provided,
initial_conditions_from_variables,
initial_conditions_from_derivatives, 0};
feenox_call(feenox_parser_keywords_ints(keywords, values, (int *)(&feenox.dae.initial_conditions_mode)));
return FEENOX_OK;
}
int feenox_parse_variables(void) {
char *token;
///kw+VAR+detail When implicit definition is allowed (see [`IMPLICIT`]), scalar variables
///kw+VAR+detail need not to be defined before being used if from the context FeenoX can tell
///kw+VAR+detail that an scalar variable is needed. For instance, when defining a function like
///kw+VAR+detail `f(x) = x^2` it is not needed to declare `x` explicitly as a scalar variable.
///kw+VAR+detail But if one wants to define a function like `g(x) = integral(f(x'), x', 0, x)` then
///kw+VAR+detail the variable `x'` needs to be explicitly defined as `VAR x'` before the integral.
///kw+VAR+usage [ ] ... [ ]
while ((token = feenox_get_next_token(NULL)) != NULL) {
feenox_call(feenox_define_variable(token));
}
return FEENOX_OK;
}
int feenox_parse_alias(void) {
///kw+ALIAS+detail The existing object can be a variable, a vector element or a matrix element.
///kw+ALIAS+detail In the first case, the name of the variable should be given as the existing object.
///kw+ALIAS+detail In the second case, to alias the second element of vector `v` to the new name `new`, `v(2)` should be given as the existing object.
///kw+ALIAS+detail In the third case, to alias second element (2,3) of matrix `M` to the new name `new`, `M(2,3)` should be given as the existing object.
char *left;
char *keyword;
char *right;
char *existing_object;
char *new_name;
char *dummy_openpar = NULL;
char *dummy_comma = NULL;
char *dummy_closepar = NULL;
char *row = NULL;
char *col = NULL;
///kw+ALIAS+usage { IS | AS }
feenox_call(feenox_parser_string(&left));
feenox_call(feenox_parser_string(&keyword));
feenox_call(feenox_parser_string(&right));
if (strcasecmp(keyword, "IS") == 0) {
new_name = left;
existing_object = right;
} else if (strcasecmp(keyword, "AS") == 0) {
new_name = right;
existing_object = left;
} else {
feenox_push_error_message("either IS or AS expected instead of '%s'", keyword);
return FEENOX_ERROR;
}
// if there are brackets they are sub-indexes
if ((dummy_openpar = strchr(existing_object, '[')) != NULL) {
dummy_comma = strchr(existing_object, ',');
if ((dummy_closepar = strrchr(existing_object, ']')) == NULL) {
feenox_push_error_message("expecting closing bracket in expression '%s'", existing_object);
}
*dummy_openpar = '\0';
*dummy_closepar = '\0';
row = dummy_openpar + 1;
if (dummy_comma != NULL) {
*dummy_comma = '\0';
col = dummy_comma + 1;
}
}
feenox_call(feenox_define_alias(new_name, existing_object, row, col));
feenox_free(left);
feenox_free(keyword);
feenox_free(right);
return FEENOX_OK;
}
int feenox_parse_vector(void) {
char *token = NULL;
char *name = NULL;
char *size = NULL;
char *function_data = NULL;
char *dummy_openpar = NULL;
char *dummy_closepar = NULL;
expr_t *datas = NULL;
///kw+VECTOR+detail A new vector of the prescribed size is defined. The size can be an expression which will be
///kw+VECTOR+detail evaluated the very first time the vector is used and then kept at that constant value.
///kw+VECTOR+usage
feenox_call(feenox_parser_string(&name));
// if there are brackets or parenthesis, the size is between them
if ((dummy_openpar = strchr(name, '[')) != NULL || (dummy_openpar = strchr(name, '(')) != NULL) {
if ((dummy_closepar = strrchr(name, ']')) == NULL && (dummy_closepar = strrchr(name, ')')) == NULL) {
feenox_push_error_message("expecting closing parenthesis in expression '%s'", name);
return FEENOX_ERROR;
}
*dummy_openpar = '\0';
*dummy_closepar = '\0';
size = dummy_openpar+1;
}
while ((token = feenox_get_next_token(NULL)) != NULL) {
///kw+VECTOR+usage SIZE
if (strcasecmp(token, "SIZE") == 0) {
feenox_call(feenox_parser_string(&size));
///kw+VECTOR+detail If the keyword `FUNCTION_DATA` is given, the elements of the vector will be synchronized
///kw+VECTOR+detail with the inpedendent values of the function, which should be point-wise defined.
///kw+VECTOR+detail The sizes of both the function and the vector should match.
///kw+VECTOR+usage [ FUNCTION_DATA ]
} else if (strcasecmp(token, "FUNCTION_DATA") == 0) {
feenox_call(feenox_parser_string(&function_data));
///kw+VECTOR+detail All elements will be initialized to zero unless `DATA` is given (which should be the last keyword of the line),
///kw+VECTOR+detail in which case the expressions will be evaluated the very first time the vector is used
///kw+VECTOR+detail and assigned to each of the elements.
///kw+VECTOR+detail If there are less elements than the vector size, the remaining values will be zero.
///kw+VECTOR+detail If there are more elements than the vector size, the values will be ignored.
///kw+VECTOR+usage [ DATA ... |
} else if (strcasecmp(token, "DATA") == 0) {
while ((token = feenox_get_next_token(NULL)) != NULL) {
expr_t *data = calloc(1, sizeof(expr_t));
feenox_call(feenox_expression_parse(data, token));
LL_APPEND(datas, data);
}
}
}
if (size == NULL) {
feenox_push_error_message("vector '%s' does not have a size", name);
return FEENOX_ERROR;
}
feenox_call(feenox_define_vector(name, size));
/*
if (function_data != NULL) {
feenox_call(feenox_vector_attach_function(name, function_data));
}
*/
if (datas != NULL) {
feenox_call(feenox_vector_attach_data(name, datas));
}
feenox_free(name);
if (dummy_openpar == NULL) {
feenox_free(size);
}
feenox_free(function_data);
return FEENOX_OK;
}
int feenox_parse_matrix(void) {
char *token = NULL;
char *name = NULL;
char *rows = NULL;
char *cols = NULL;
char *dummy_openpar = NULL;
char *dummy_comma = NULL;
char *dummy_closepar = NULL;
expr_t *datas = NULL;
///kw+MATRIX+detail A new matrix of the prescribed size is defined. The number of rows and columns can be an expression which will be
///kw+MATRIX+detail evaluated the very first time the matrix is used and then kept at those constant values.
///kw+MATRIX+usage
feenox_call(feenox_parser_string(&name));
// if there are parenthesis, the size is between them
if ((dummy_openpar = strchr(name, '(')) != NULL) {
if ((dummy_comma = strchr(name, ',')) == NULL) {
feenox_push_error_message("expecting comma in expression '%s'", name);
}
if ((dummy_closepar = strrchr(name, ')')) == NULL) {
feenox_push_error_message("expecting closing parenthesis in expression '%s'", name);
}
*dummy_openpar = '\0';
*dummy_comma = '\0';
*dummy_closepar = '\0';
rows = dummy_openpar+1;
cols = dummy_comma+1;
}
while ((token = feenox_get_next_token(NULL)) != NULL) {
///kw+MATRIX+usage ROWS
if (strcasecmp(token, "ROWS") == 0) {
feenox_call(feenox_parser_string(&rows));
///kw+MATRIX+usage COLS
} else if (strcasecmp(token, "COLS") == 0) {
feenox_call(feenox_parser_string(&cols));
///kw+MATRIX+detail All elements will be initialized to zero unless `DATA` is given (which should be the last keyword of the line),
///kw+MATRIX+detail in which case the expressions will be evaluated the very first time the matrix is used
///kw+MATRIX+detail and row-major-assigned to each of the elements.
///kw+MATRIX+detail If there are less elements than the matrix size, the remaining values will be zero.
///kw+MATRIX+detail If there are more elements than the matrix size, the values will be ignored.
///kw+MATRIX+usage [ DATA ... |
} else if (strcasecmp(token, "DATA") == 0) {
while ((token = feenox_get_next_token(NULL)) != NULL) {
expr_t *data = calloc(1, sizeof(expr_t));
feenox_call(feenox_expression_parse(data, token));
LL_APPEND(datas, data);
}
}
}
if (rows == NULL) {
feenox_push_error_message("matrix '%s' does not have a row size", name);
return FEENOX_ERROR;
}
if (cols == NULL) {
feenox_push_error_message("matrix '%s' does not have a column size", name);
return FEENOX_ERROR;
}
feenox_call(feenox_define_matrix(name, rows, cols));
if (datas != NULL) {
feenox_call(feenox_matrix_attach_data(name, datas));
}
feenox_free(name);
if (dummy_openpar == NULL) {
feenox_free(rows);
feenox_free(cols);
}
return FEENOX_OK;
}
int feenox_parse_function(void) {
///kw+FUNCTION+usage ([,var2,...,var_n]) {
///kw+FUNCTION+usage @
///kw+FUNCTION+detail The number of variables $n$ is given by the number of arguments given between parenthesis after the function name.
///kw+FUNCTION+detail The arguments are defined as new variables if they had not been already defined explicitly as scalar variables.
char *token = NULL;
feenox_call(feenox_parser_string(&token));
char *dummy_openpar = NULL;
if ((dummy_openpar = strchr(token, '(')) == NULL) {
feenox_push_error_message("expected opening parenthesis '(' after function name '%s' (no spaces allowed)", token);
return FEENOX_ERROR;
}
char *name = NULL;
feenox_call(feenox_add_function_from_string(token, &name));
function_t *function = NULL;
if ((function = feenox_get_function_ptr(name)) == NULL) {
feenox_push_error_message("unknown function '%s'", name);
return FEENOX_ERROR;
}
unsigned int *columns = NULL;
file_t *file = NULL;
while ((token = feenox_get_next_token(NULL)) != NULL) {
///kw+FUNCTION+usage = |
///kw+FUNCTION+usage @
///kw+FUNCTION+detail If the function is given as an algebraic expression, the short-hand operator `=`
///kw+FUNCTION+detail (or `:=` for compatibility with Maxima) can be used.
///kw+FUNCTION+detail That is to say, `FUNCTION f(x) = x^2` is equivalent to `f(x) = x^2` (or `f(x) := x^2`).
if (strcasecmp(token, "=") == 0 || strcasecmp(token, ":=") == 0) {
feenox_call(feenox_function_set_expression(name, token + ((token[0] == ':')? 3 : 2)));
break; // we are done with the while() over the line
///kw+FUNCTION+usage FILE { } |
///kw+FUNCTION+usage @
} else if (strcasecmp(token, "FILE") == 0) {
///kw+FUNCTION+detail If a `FILE` is given, an ASCII file containing at least $n+1$ columns is expected.
///kw+FUNCTION+detail By default, the first $n$ columns are the values of the arguments and the last column
///kw+FUNCTION+detail is the value of the function at those points.
///kw+FUNCTION+detail The order of the columns can be changed with the keyword `COLUMNS`,
///kw+FUNCTION+detail which expects $n+1$ expressions corresponding to the column numbers.
feenox_call(feenox_parser_file(&file));
file->mode = "r";
///kw+FUNCTION+usage VECTORS ... |
///kw+FUNCTION+usage @
///kw+FUNCTION+detail If `VECTORS` is given, a set of $n+1$ vectors of the same size is expected.
///kw+FUNCTION+detail The first $n$ correspond to the arguments and the last one to the function values.
} else if (strcasecmp(token, "VECTORS") == 0) {
feenox_call(feenox_parse_function_vectors(function));
///kw+FUNCTION+usage MESH |
///kw+FUNCTION+usage @
///kw+FUNCTION+detail If `MESH` is given, the function is point-wise defined over the mesh topology.
///kw+FUNCTION+detail That is to say, the independent variables (i.e. the spatial coordinates) coincide with the mesh nodes.
///kw+FUNCTION+detail The dependent variable (i.e. the function value) is set by "filling" a vector
///kw+FUNCTION+detail named `vec_f` (where `f` has to be replaced with the function name) of size equal to the number of nodes.
} else if (strcasecmp(token, "MESH") == 0) {
feenox_call(feenox_parse_function_mesh(function));
///kw+FUNCTION+usage DATA ...
///kw+FUNCTION+usage @
///kw+FUNCTION+usage }
///kw+FUNCTION+usage @
///kw+FUNCTION+detail The function can be pointwise-defined inline in the input using `DATA`.
///kw+FUNCTION+detail This should be the last keyword of the line, followed by $N=k \cdot (n+1)$ expressions
///kw+FUNCTION+detail giving\ $k$ definition points: $n$ arguments and the value of the function.
///kw+FUNCTION+detail Multiline continuation using brackets `{` and `}` can be used for a clean data organization.
} else if (strcasecmp(token, "DATA") == 0) {
feenox_call(feenox_parse_function_data(function));
///kw+FUNCTION+usage [ COLUMNS ... ]
///kw+FUNCTION+usage @
} else if (strcasecmp(token, "COLUMNS") == 0) {
if (function->n_arguments == 0) {
feenox_push_error_message("number of arguments is equal to zero");
return FEENOX_ERROR;
}
feenox_check_alloc(columns = calloc(function->n_arguments+1, sizeof(int)));
unsigned int i = 0;
double xi = 0;
for (i = 0; i < function->n_arguments+1; i++) {
feenox_call(feenox_parser_expression_in_string(&xi));
columns[i] = (unsigned int)(xi);
}
///kw+FUNCTION+detail Interpolation schemes can be given for either one or multi-dimensional functions with `INTERPOLATION`.
///kw+FUNCTION+detail Available schemes for $n=1$ are:
///kw+FUNCTION+detail @
///kw+FUNCTION+usage [ INTERPOLATION
///kw+FUNCTION+usage {
///kw+FUNCTION+usage linear |
///kw+FUNCTION+detail * linear
///kw+FUNCTION+usage polynomial |
///kw+FUNCTION+detail * polynomial, the grade is equal to the number of data minus one
///kw+FUNCTION+usage spline |
///kw+FUNCTION+detail * spline, cubic (needs at least 3 points)
///kw+FUNCTION+usage spline_periodic |
///kw+FUNCTION+detail * spline_periodic
///kw+FUNCTION+usage akima |
///kw+FUNCTION+detail * akima (needs at least 5 points)
///kw+FUNCTION+usage akima_periodic |
///kw+FUNCTION+detail * akima_periodic (needs at least 5 points)
///kw+FUNCTION+usage steffen |
///kw+FUNCTION+usage @
///kw+FUNCTION+detail * steffen, always-monotonic splines-like interpolator
///kw+FUNCTION+detail @
///kw+FUNCTION+detail Default interpolation scheme for one-dimensional functions is `DEFAULT_INTERPOLATION`.
///kw+FUNCTION+detail @
///kw+FUNCTION+detail Available schemes for $n>1$ are:
///kw+FUNCTION+detail @
///kw+FUNCTION+usage nearest |
///kw+FUNCTION+detail * nearest, $f(\vec{x})$ is equal to the value of the closest definition point
///kw+FUNCTION+usage shepard |
///kw+FUNCTION+detail * shepard, [inverse distance weighted average definition points](https://en.wikipedia.org/wiki/Inverse_distance_weighting) (might lead to inefficient evaluation)
///kw+FUNCTION+usage shepard_kd |
///kw+FUNCTION+detail * shepard_kd, [average of definition points within a kd-tree](https://en.wikipedia.org/wiki/Inverse_distance_weighting#Modified_Shepard's_method) (more efficient evaluation provided `SHEPARD_RADIUS` is set to a proper value)
///kw+FUNCTION+usage bilinear
///kw+FUNCTION+detail * bilinear, only available if the definition points configure an structured hypercube-like grid. If $n>3$, `SIZES` should be given.
///kw+FUNCTION+usage } ]
///kw+FUNCTION+usage @
} else if (strcasecmp(token, "INTERPOLATION") == 0) {
token = feenox_get_next_token(NULL);
feenox_call(feenox_function_set_interpolation(name, token));
///kw+FUNCTION+detail @
///kw+FUNCTION+usage [ INTERPOLATION_THRESHOLD ]
///kw+FUNCTION+detail For $n>1$, if the euclidean distance between the arguments and the definition points is smaller than `INTERPOLATION_THRESHOLD`, the definition point is returned and no interpolation is performed.
///kw+FUNCTION+detail Default value is square root of `DEFAULT_MULTIDIM_INTERPOLATION_THRESHOLD`.
} else if (strcasecmp(token, "INTERPOLATION_THRESHOLD") == 0) {
feenox_parser_expression(&function->expr_multidim_threshold);
///kw+FUNCTION+detail @
///kw+FUNCTION+usage [ SHEPARD_RADIUS ]
///kw+FUNCTION+detail The initial radius of points to take into account in `shepard_kd` is given by `SHEPARD_RADIUS`. If no points are found, the radius is double until at least one definition point is found.
///kw+FUNCTION+detail The radius is doubled until at least one point is found.
///kw+FUNCTION+detail Default is `DEFAULT_SHEPARD_RADIUS`.
} else if (strcasecmp(token, "SHEPARD_RADIUS") == 0) {
feenox_parser_expression(&function->expr_shepard_radius);
///kw+FUNCTION+usage [ SHEPARD_EXPONENT ]
///kw+FUNCTION+detail The exponent of the `shepard` method is given by `SHEPARD_EXPONENT`.
///kw+FUNCTION+detail Default is `DEFAULT_SHEPARD_EXPONENT`.
} else if (strcasecmp(token, "SHEPARD_EXPONENT") == 0) {
feenox_parser_expression(&function->expr_shepard_exponent);
} else {
feenox_push_error_message("unknown keyword '%s'", token);
return FEENOX_ERROR;
}
}
/*
//kw+FUNCTION+usage [ SIZES ... ]
//kw+FUNCTION+detail When requesting `bilinear` interpolation for $n>3$, the number of definition points for each argument variable has to be given with `SIZES`,
} else if (strcasecmp(token, "SIZES") == 0) {
function->expr_rectangular_mesh_size = calloc(function->n_arguments, sizeof(expr_t));
for (i = 0; i < function->n_arguments; i++) {
feenox_call(feenox_parser_expression(&function->expr_rectangular_mesh_size[i]));
}
//kw+FUNCTION+usage [ X_INCREASES_FIRST ]
//kw+FUNCTION+detail and whether the definition data is sorted with the first argument changing first (`X_INCREASES_FIRST` evaluating to non-zero) or with the last argument changing first (zero).
} else if (strcasecmp(token,"X_INCREASES_FIRST") == 0) {
feenox_call(feenox_parser_expression(&function->expr_x_increases_first));
} else {
feenox_push_error_message("unknown keyword '%s'", token);
return FEENOX_ERROR;
}
}
*/
if (file != NULL) {
feenox_call(feenox_function_set_file(name, file, columns));
}
feenox_free(columns);
feenox_free(name);
return FEENOX_OK;
}
int feenox_parse_function_data(function_t *function) {
function->type = function_type_pointwise_data;
size_t size0 = 4096/sizeof(double);
size_t size = size0;
double *buffer = NULL;
feenox_check_alloc(buffer = malloc(size * sizeof(double)));
char *token = NULL;
size_t n = 0;
while ((token = feenox_get_next_token(NULL)) != NULL) {
if (n == size) {
size += size0;
feenox_check_alloc(buffer = realloc(buffer, size*sizeof(double)));
}
expr_t *expr = NULL;
feenox_check_alloc(expr = calloc(1, sizeof(expr_t)));
feenox_call(feenox_expression_parse(expr, token));
if (expr->variables != NULL) {
feenox_push_error_message("FUNCTION DATA cannot reference variables");
return FEENOX_ERROR;
}
if (expr->variables != NULL) {
feenox_push_error_message("FUNCTION DATA cannot reference functions");
return FEENOX_ERROR;
}
buffer[n++] = feenox_expression_eval(expr);
feenox_free(expr);
}
feenox_call(function_set_buffered_data(function, buffer, n, function->n_arguments+1, NULL));
feenox_free(buffer);
return FEENOX_OK;
}
int feenox_parse_function_vectors(function_t *function) {
function->type = function_type_pointwise_data;
feenox_check_alloc(function->vector_argument = calloc(function->n_arguments, sizeof(vector_t *)));
// feenox_check_alloc(function->data_argument = calloc(function->n_arguments, sizeof(double *)));
unsigned int i = 0;
for (i = 0; i < function->n_arguments; i++) {
feenox_call(feenox_parser_vector(&function->vector_argument[i]));
}
feenox_call(feenox_parser_vector(&function->vector_value));
return FEENOX_OK;
}
int feenox_parse_function_mesh(function_t *function) {
// TODO: cells
function->type = function_type_pointwise_mesh_node;
if ((function->mesh = feenox_parser_mesh()) == NULL) {
return FEENOX_ERROR;
}
if (function->n_arguments != function->mesh->dim) {
feenox_push_error_message("function '%s' has %d arguments and mesh '%s' has %d dimensions", function->name, function->n_arguments, function->mesh->file->name, function->mesh->dim);
return FEENOX_ERROR;
}
feenox_call(feenox_create_pointwise_function_vectors(function));
return FEENOX_OK;
}
int feenox_parse_sort_vector(void) {
char *token;
sort_vector_t *sort_vector = calloc(1, sizeof(sort_vector_t));
///kw+SORT_VECTOR+usage
feenox_call(feenox_parser_vector(&sort_vector->v1));
while ((token = feenox_get_next_token(NULL)) != NULL) {
///kw+SORT_VECTOR+detail This instruction sorts the elements of `` into either ascending or descending numerical order.
///kw+SORT_VECTOR+detail If `` is given, the same rearrangement is made on it.
///kw+SORT_VECTOR+detail Default is ascending order.
///kw+SORT_VECTOR+usage [ ASCENDING | DESCENDING ]
if (strcasecmp(token, "ASCENDING") == 0 || strcasecmp(token, "ASCENDING_ORDER") == 0) {
sort_vector->descending = 0;
} else if (strcasecmp(token, "DESCENDING") == 0 || strcasecmp(token, "DESCENDING_ORDER") == 0) {
sort_vector->descending = 1;
///kw+SORT_VECTOR+usage [ ]
} else if ((sort_vector->v2 = feenox_get_vector_ptr(token)) != NULL) {
continue;
} else {
feenox_push_error_message("unknown keyword or vector identifier '%s'", token);
return FEENOX_ERROR;
}
}
feenox_call(feenox_add_instruction(feenox_instruction_sort_vector, sort_vector));
return FEENOX_OK;
}
int feenox_parse_file(char *default_mode) {
char *token = NULL;
char *name = NULL;
char *format = NULL;
char *mode = NULL;
char **arg = NULL;
int n_args = 0;
///kw+FILE+usage
if (feenox_parser_string(&name) != FEENOX_OK) {
return FEENOX_ERROR;
}
///kw+FILE+detail For reading or writing into files with a fixed path, this instruction is usually not needed as
///kw+FILE+detail the `FILE` keyword of other instructions (such as `PRINT` or `MESH`) can take a fixed-string path as an argument.
///kw+FILE+detail However, if the file name changes as the execution progresses (say because one file for each step is needed),
///kw+FILE+detail then an explicit `FILE` needs to be defined with this keyword and later referenced by the given name.
while ((token = feenox_get_next_token(NULL)) != NULL) {
///kw+FILE+usage PATH
///kw+FILE+usage expr_1 expr_2 ... expr_n
///kw+FILE+detail The path should be given as a `printf`-like format string followed by the expressions which should be
///kw+FILE+detail evaluated in order to obtain the actual file path. The expressions will always be floating-point expressions,
///kw+FILE+detail but the particular integer specifier `%d` is allowed and internally transformed to `%.0f`.
if (strcasecmp(token, "PATH") == 0) {
feenox_call(feenox_parser_string_format(&format, &n_args));
if (n_args != 0) {
arg = calloc(n_args, sizeof(char *));
int i;
for (i = 0; i < n_args; i++) {
feenox_call(feenox_parser_string(&arg[i]));
}
}
///kw+FILE+detail The file can be explicitly defined and `INPUT`, `OUTPUT` or a certain `fopen()` mode can be given (i.e. "a").
///kw+FILE+detail If not explicitly given, the nature of the file will be taken from context, i.e. `FILE`s in `PRINT`
///kw+FILE+detail will be `OUTPUT` and `FILE`s in `FUNCTION` will be `INPUT`.
///kw+FILE+usage [ INPUT | OUTPUT | APPEND | MODE ]
} else if (strcasecmp(token, "MODE") == 0) {
feenox_call(feenox_parser_string(&mode));
} else if (strcasecmp(token, "INPUT") == 0) {
feenox_check_alloc(mode = strdup("r"));
} else if (strcasecmp(token, "OUTPUT") == 0) {
feenox_check_alloc(mode = strdup("w"));
} else if (strcasecmp(token, "APPEND") == 0) {
feenox_check_alloc(mode = strdup("a"));
///kw+FILE+detail This keyword just defines the `FILE`, it does not open it.
///kw+FILE+detail The file will be actually opened (and eventually closed) automatically.
///kw+FILE+detail In the rare case where the automated opening and closing does not fit the expected workflow,
///kw+FILE+detail the file can be explicitly opened or closed with the instructions `FILE_OPEN` and `FILE_CLOSE`.
} else {
feenox_push_error_message("unknown keyword '%s'", token);
return FEENOX_ERROR;
}
}
// the custom mode takes precedence over the argument's mode
if (mode == NULL) {
mode = default_mode;
}
feenox_call(feenox_define_file(name, format, n_args, mode));
for (int i = 0; i < n_args; i++) {
feenox_call(feenox_file_set_path_argument(name, i, arg[i]));
}
feenox_free(format);
if (mode != default_mode) {
feenox_free(mode);
}
feenox_free(name);
return FEENOX_OK;
}
int feenox_parse_open_close(const char *what) {
char *token = NULL;
char *name = NULL;
char *mode = NULL;
///kw+OPEN+usage
///kw+CLOSE+usage
if (feenox_parser_string(&name) != FEENOX_OK) {
return FEENOX_ERROR;
}
///kw+OPEN+detail The given `` can be either a fixed-string path or an already-defined `FILE`.
///kw+CLOSE+detail The given `` can be either a fixed-string path or an already-defined `FILE`.
if (strcmp(what, "OPEN") == 0) {
while ((token = feenox_get_next_token(NULL)) != NULL) {
///kw+OPEN+detail The mode is only taken into account if the file is not already defined.
///kw+OPEN+detail Default is write `w`.
///kw+OPEN+usage [ MODE ]
if (strcasecmp(token, "MODE") == 0) {
feenox_call(feenox_parser_string(&mode));
}
}
}
file_t *file;
if ((file = feenox_get_file_ptr(name)) == NULL) {
feenox_call(feenox_define_file(name, name, 0, mode));
if ((file = feenox_get_file_ptr(name)) == NULL) {
return FEENOX_ERROR;
}
}
// to add an instruction from the API one needs to pass a string and not a file_t
if (strcmp(what, "OPEN") == 0) {
feenox_call(feenox_add_instruction(feenox_instruction_file_open, file));
} else if (strcmp(what, "CLOSE") == 0) {
feenox_call(feenox_add_instruction(feenox_instruction_file_close, file));
}
return FEENOX_OK;
}
int feenox_parse_read_data(void) {
read_data_t *read_data = NULL;
feenox_check_alloc(read_data = calloc(1, sizeof(read_data_t)));
char *token = NULL;
while ((token = feenox_get_next_token(NULL)) != NULL) {
if (strcasecmp(token, "FILE") == 0 || strcasecmp(token, "FILE_PATH") == 0) {
///kw+READ_DATA+usage FILE { | }
feenox_call(feenox_parser_file(&read_data->file));
if (read_data->file->mode == NULL) {
feenox_check_alloc(read_data->file->mode = strdup("r"));
}
} else {
///kw+READ_DATA+usage [ [ [...] [ [...] ] ] ]
if ((read_data->variable = feenox_get_variable_ptr(token)) == NULL) {
if ((read_data->vector = feenox_get_vector_ptr(token)) == NULL) {
feenox_push_error_message("unknown symbol '%s'", token);
return FEENOX_ERROR;
}
}
}
}
feenox_call(feenox_add_instruction(feenox_instruction_read_data, read_data));
return FEENOX_OK;
}
int feenox_parse_print(void) {
// I don't expect anybody to want to use this PRINT instruction through the API
// so we just parse and define everything here
print_t *print = NULL;
feenox_check_alloc(print = calloc(1, sizeof(print_t)));
char *keywords[] = {"SKIP_STEP", "SKIP_STATIC_STEP", "SKIP_TIME", "SKIP_HEADER_STEP", ""};
expr_t *expressions[] = {
&print->skip_step,
&print->skip_static_step,
&print->skip_time,
&print->skip_header_step,
NULL
};
///kw+PRINT+detail Each argument `object` which is not a keyword of the `PRINT` instruction will be part of the output.
///kw+PRINT+detail Objects can be either a matrix, a vector or any valid scalar algebraic expression.
///kw+PRINT+detail If the given object cannot be solved into a valid matrix, vector or expression, it is treated as a string literal
///kw+PRINT+detail if `IMPLICIT` is `ALLOWED`, otherwise a parser error is raised.
///kw+PRINT+detail To explicitly interpret an object as a literal string even if it resolves to a valid numerical expression,
///kw+PRINT+detail it should be prefixed with the `TEXT` keyword such as `PRINT TEXT 1+1` that would print `1+1` instead of `2`.
///kw+PRINT+detail Objects and string literals can be mixed and given in any order.
///kw+PRINT+detail Hashes `#` appearing literal in text strings have to be quoted to prevent the parser to treat them as comments
///kw+PRINT+detail within the FeenoX input file and thus ignoring the rest of the line, like `PRINT "\# this is a printed comment"`.
///kw+PRINT+detail Whenever an argument starts with a porcentage sign `%`, it is treated as a C `printf`-compatible format
///kw+PRINT+detail specifier and all the objects that follow it are printed using the given format until a new format definition is found.
///kw+PRINT+detail The objects are treated as double-precision floating point numbers, so only floating point formats should be given.
///kw+PRINT+detail See the `printf(3)` man page for further details. The default format is `DEFAULT_PRINT_FORMAT`.
///kw+PRINT+detail Matrices, vectors, scalar expressions, format modifiers and string literals can be given in any desired order,
///kw+PRINT+detail and are processed from left to right.
///kw+PRINT+detail Vectors are printed element-by-element in a single row.
///kw+PRINT+detail See `PRINT_VECTOR` to print one or more vectors with one element per line (i.e. vertically).
///kw+PRINT+detail Matrices are printed element-by-element in a single line using row-major ordering if mixed
///kw+PRINT+detail with other objects but in the natural row and column fashion
///kw+PRINT+detail if it is the only given object in the `PRINT` instruction.
///kw+PRINT+usage [ ... ]
///kw+PRINT+usage [ TEXT ... TEXT ]
///kw+PRINT+usage @
int n = 0;
char *token = NULL;
while ((token = feenox_get_next_token(NULL)) != NULL) {
///kw+PRINT+usage [ FILE { | } ]
///kw+PRINT+detail If the `FILE` keyword is not provided, default is to write to `stdout`.
if (strcasecmp(token, "FILE") == 0 || strcasecmp(token, "FILE_PATH") == 0) {
feenox_call(feenox_parser_file(&print->file));
// we don't have the file name because it was already consumed by the above call
// and we do not expect the PRINT instruction to be used from the API
// so we directly access the internals of the structure
if (print->file->mode == NULL) {
feenox_check_alloc(print->file->mode = strdup("w"));
}
///kw+PRINT+usage [ HEADER ]
} else if (strcasecmp(token, "HEADER") == 0) {
print->header = 1;
///kw+PRINT+detail If the `HEADER` keyword is given, a single line containing the literal text
///kw+PRINT+detail given for each object is printed at the very first time the `PRINT` instruction is
///kw+PRINT+detail processed, starting with a hash `#` character.
///kw+PRINT+usage [ NONEWLINE ]
} else if (strcasecmp(token, "NONEWLINE") == 0) {
///kw+PRINT+detail If the `NONEWLINE` keyword is not provided, default is to write a newline `\n` character after
///kw+PRINT+detail all the objects are processed.
///kw+PRINT+detail Otherwise, if the last token to be printed is a numerical value, a separator string will be printed but not the newline `\n` character.
///kw+PRINT+detail If the last token is a string, neither the separator nor the newline will be printed.
print->nonewline = 1;
///kw+PRINT+usage [ SEP ]
///kw+PRINT+detail The `SEP` keyword expects a string used to separate printed objects.
///kw+PRINT+detail To print objects without any separation in between give an empty string like `SEP ""`.
///kw+PRINT+detail The default is a tabulator character 'DEFAULT_PRINT_SEPARATOR' character.
} else if (strcasecmp(token, "SEP") == 0 || strcasecmp(token, "SEPARATOR") == 0) {
feenox_call(feenox_parser_string(&print->separator));
///kw+PRINT+detail To print an empty line write `PRINT` without arguments.
///kw+PRINT+usage @
///kw+PRINT+usage [ SKIP_STEP ]
///kw+PRINT+detail By default the `PRINT` instruction is evaluated every step.
///kw+PRINT+detail If the `SKIP_STEP` (`SKIP_STATIC_STEP`) keyword is given, the instruction is processed
///kw+PRINT+detail only every the number of transient (static) steps that results in evaluating the expression,
///kw+PRINT+detail which may not be constant.
///kw+PRINT+detail The `SKIP_HEADER_STEP` keyword works similarly for the optional `HEADER` but
///kw+PRINT+detail by default it is only printed once. The `SKIP_TIME` keyword use time advancements
///kw+PRINT+detail to choose how to skip printing and may be useful for non-constant time-step problems.
///kw+PRINT+usage [ SKIP_STATIC_STEP ]
///kw+PRINT+usage [ SKIP_TIME ]
///kw+PRINT+usage [ SKIP_HEADER_STEP ]
} else if ((n = feenox_parser_match_keyword_expression(token, keywords, expressions, sizeof(expressions)/sizeof(expr_t *))) != FEENOX_UNHANDLED) {
if (n == FEENOX_ERROR) {
return FEENOX_ERROR;
}
} else {
///kw+PRINT+usage @
// see the objects above
print_token_t *print_token = NULL;
feenox_check_alloc(print_token = calloc(1, sizeof(print_token_t)));
matrix_t *matrix = NULL;
vector_t *vector = NULL;
if (token[0] == '%') {
feenox_check_alloc(print_token->format = strdup(token));
} else if (strcasecmp(token, "STRING") == 0 || strcasecmp(token, "TEXT") == 0) {
if (feenox_parser_string(&print_token->text) != FEENOX_OK) {
return FEENOX_ERROR;
}
} else if ((matrix = feenox_get_matrix_ptr(token)) != NULL) {
feenox_check_alloc(print_token->text = strdup(token)); // nos quedamos con el texto para el header
print_token->matrix = matrix;
matrix->used = 1;
} else if ((vector = feenox_get_vector_ptr(token)) != NULL) {
print_token->text = strdup(token); // nos quedamos con el texto para el header
print_token->vector = vector;
vector->used = 1;
} else {
if (feenox_expression_parse(&print_token->expression, token) != FEENOX_OK) {
// let the not-resolved expressions to be casted as string literals
// only if implicit is allowed
if (feenox_parser.implicit_none) {
feenox_push_error_message("implicit definition is not allowed and expression '%s' is invalid", token);
return FEENOX_ERROR;
} else {
print_token->expression.items = NULL;
feenox_check_alloc(print_token->text = strdup(token));
feenox_pop_error_message();
}
} else {
feenox_check_alloc(print_token->text = strdup(token)); // text for the header
}
}
LL_APPEND(print->tokens, print_token);
}
}
// default separator
if (print->separator == NULL) {
feenox_check_alloc(print->separator = strdup(DEFAULT_PRINT_SEPARATOR));
}
// default file is stdout
if (print->file == NULL) {
print->file = feenox.special_files._stdout;
}
LL_APPEND(feenox.prints, print);
feenox_call(feenox_add_instruction(feenox_instruction_print, print));
return FEENOX_OK;
}
int feenox_parse_printf(int all_ranks) {
// I don't expect anybody to want to use this PRINT instruction through the API
// so we just parse and define everything here
printf_t *printf = NULL;
feenox_check_alloc(printf = calloc(1, sizeof(printf_t)));
printf->all_ranks = all_ranks;
///kw+PRINTF+detail The `format_string` should be a `printf`-like string containing double-precision
///kw+PRINTF+detail format specifiers. A matching number of expressions should be given.
///kw+PRINTF+detail No newline is written if not explicitly asked for in the format string with `\n`.
///kw+PRINTF+detail Do not ask for string literals `%s`.
///kw+PRINTF+detail As always, to get a literal `%` use `%%` in the format string.
///kw+PRINTF+usage format_string [ expr_1 [ expr_2 [ ... ] ] ]
char *token = NULL;
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected format string for PRINTF");
return FEENOX_ERROR;
}
feenox_check_alloc(printf->format_string = strdup(token));
// count the number of needed expressions
int i = 0;
while (printf->format_string[i] != '\0') {
if (printf->format_string[i] == '%') {
if (printf->format_string[i+1] != '%') {
if (printf->format_string[i+1] == 's') {
feenox_push_error_message("string format '%s' not supported in PRINTF");
return FEENOX_ERROR;
} else if (printf->format_string[i+1] == 'd') {
// everything is a double but just in case
printf->format_string[i+1] = 'g';
}
printf->n_args++;
} else {
i++;
}
}
i++;
}
feenox_check_alloc(printf->expressions = calloc(printf->n_args, sizeof(expr_t)));
for (int n = 0; n < printf->n_args; n++) {
if ((token = feenox_get_next_token(NULL)) == NULL) {
feenox_push_error_message("expected %d expressions in PRINTF", printf->n_args);
return FEENOX_ERROR;
}
feenox_call(feenox_expression_parse(&printf->expressions[n], token));
}
// default file is stdout
if (printf->file == NULL) {
printf->file = feenox.special_files._stdout;
}
LL_APPEND(feenox.printfs, printf);
feenox_call(feenox_add_instruction(feenox_instruction_printf, printf));
return FEENOX_OK;
}
int feenox_parse_print_function(void) {
char *token;
print_function_t *print_function = NULL;
feenox_check_alloc(print_function = calloc(1, sizeof(print_function_t)));
while ((token = feenox_get_next_token(NULL)) != NULL) {
///kw+PRINT_FUNCTION+detail Each argument should be either a function or an expression.
///kw+PRINT_FUNCTION+detail The output of this instruction consists of\ $n+k$ columns,
///kw+PRINT_FUNCTION+detail where\ $n$ is the number of arguments of the first function of the list
///kw+PRINT_FUNCTION+detail and\ $k$ is the number of functions and expressions given.
///kw+PRINT_FUNCTION+detail The first\ $n$ columns are the arguments (independent variables) and
///kw+PRINT_FUNCTION+detail the last\ $k$ one has the evaluated functions and expressions.
///kw+PRINT_FUNCTION+detail The columns are separated by a tabulator, which is the format that most
///kw+PRINT_FUNCTION+detail plotting tools understand.
///kw+PRINT_FUNCTION+detail Only function names without arguments are expected.
///kw+PRINT_FUNCTION+detail All functions should have the same number of arguments.
///kw+PRINT_FUNCTION+detail Expressions can involve the arguments of the first function.
///kw+PRINT_FUNCTION+usage [ { function | expr } ... { function | expr } ]
///kw+PRINT_FUNCTION+usage @
///kw+PRINT_FUNCTION+usage [ FILE { | } ]
///kw+PRINT_FUNCTION+detail If the `FILE` keyword is not provided, default is to write to `stdout`.
if (strcasecmp(token, "FILE") == 0 || strcasecmp(token, "FILE_PATH") == 0) {
feenox_call(feenox_parser_file(&print_function->file));
if (print_function->file->mode == NULL) {
feenox_check_alloc(print_function->file->mode = strdup("w"));
}
///kw+PRINT_FUNCTION+usage [ HEADER ]
///kw+PRINT_FUNCTION+detail If `HEADER` is given, the output is prepended with a single line containing the
///kw+PRINT_FUNCTION+detail names of the arguments and the names of the functions, separated by tabs.
///kw+PRINT_FUNCTION+detail The header starts with a hash\ `#` that usually acts as a comment and is ignored
///kw+PRINT_FUNCTION+detail by most plotting tools.
} else if (strcasecmp(token, "HEADER") == 0) {
print_function->header = 1;
///kw+PRINT_FUNCTION+usage @
///kw+PRINT_FUNCTION+usage [ MIN ... ]
///kw+PRINT_FUNCTION+detail If there is no explicit range where to evaluate the functions and the first function
///kw+PRINT_FUNCTION+detail is point-wise defined, they are evalauted at the points of definition of the first one.
///kw+PRINT_FUNCTION+detail The range can be explicitly given as a product of\ $n$ ranges\ $[x_{i,\min},x_{i,\max}]$
///kw+PRINT_FUNCTION+detail for $i=1,\dots,n$.
///kw+PRINT_FUNCTION+detail The values $x_{i,\min}$ and $x_{i,\max}$ are given with the `MIN` _and_ `MAX` keywords.
} else if (strcasecmp(token, "MIN") == 0) {
if (print_function->first_function == NULL) {
feenox_push_error_message("MIN before actual function, cannot determine number of arguments");
return FEENOX_ERROR;
}
if (feenox_parser_expressions(&print_function->range.min, print_function->first_function->n_arguments) != FEENOX_OK) {
return FEENOX_ERROR;
}
///kw+PRINT_FUNCTION+usage [ MAX ... ]
} else if (strcasecmp(token, "MAX") == 0) {
if (print_function->first_function == NULL) {
feenox_push_error_message("MAX before actual function, cannot determine number of arguments");
return FEENOX_ERROR;
}
if (feenox_parser_expressions(&print_function->range.max, print_function->first_function->n_arguments) != FEENOX_OK) {
return FEENOX_ERROR;
}
///kw+PRINT_FUNCTION+detail The discretization steps of the ranges are given by either `STEP` that gives\ $\delta x$ _or_
///kw+PRINT_FUNCTION+detail `NSTEPS` that gives the number of steps.
///kw+PRINT_FUNCTION+usage @
///kw+PRINT_FUNCTION+usage [ STEP