mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-27 00:57:50 +00:00
Import of femlab port. femlab solves PDEs in 2D using the
finite element method. PR: 4531 Submitted by: Pedro Giffuni <giffunip@asme.org>
This commit is contained in:
parent
4ed6a89e13
commit
2b4ca0d2c4
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=7925
43
math/femlab/Makefile
Normal file
43
math/femlab/Makefile
Normal file
@ -0,0 +1,43 @@
|
||||
# New ports collection makefile for: femlab
|
||||
# Version required: v1.1
|
||||
# Date created: 19 June 1997
|
||||
# Whom: Pedro Giffuni
|
||||
#
|
||||
# $Id: Makefile,v 1.3 1997/01/19 02:47:27 obrien Exp $
|
||||
#
|
||||
|
||||
DISTNAME= femlab-2d-v1.1
|
||||
PKGNAME= femlab-1.1
|
||||
CATEGORIES= math cad
|
||||
MASTER_SITES= ftp://ftp.md.chalmers.se/pub/Femlab/ \
|
||||
ftp://ftp.ifs.hr/pub/SciUtil/
|
||||
|
||||
MAINTAINER= giffunip@asme.org
|
||||
|
||||
BUILD_DEPENDS= ${PREFIX}/lib/libsx.a:${PORTSDIR}/X11/libsx
|
||||
|
||||
WRKSRC= ${WRKDIR}/${PKGNAME}
|
||||
USE_X11= yes
|
||||
|
||||
FEMLAB_HOME= ${PREFIX}/lib/X11/femlab
|
||||
|
||||
do-install:
|
||||
${MKDIR} ${FEMLAB_HOME}/bin
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/source/femlab ${FEMLAB_HOME}/bin
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/fsource/meshgen ${FEMLAB_HOME}/bin
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/fsource/poisson ${FEMLAB_HOME}/bin
|
||||
${MKDIR} ${FEMLAB_HOME}/config
|
||||
${INSTALL_DATA} ${WRKSRC}/config/modules ${FEMLAB_HOME}/config
|
||||
${SED} -e "s|@@FEMLAB_HOME@@|${FEMLAB_HOME}|" <${FILESDIR}/femlab.sh >${PREFIX}/bin/femlab
|
||||
chmod +x ${PREFIX}/bin/femlab
|
||||
|
||||
post-install:
|
||||
.if !defined(NOPORTDOCS)
|
||||
${MKDIR} ${PREFIX}/share/examples/femlab
|
||||
${INSTALL_MAN} ${WRKSRC}/examples/*.fem ${PREFIX}/share/examples/femlab
|
||||
${MKDIR} ${PREFIX}/share/doc/femlab
|
||||
${INSTALL_MAN} ${WRKSRC}/docs/manual.dvi ${PREFIX}/share/doc/femlab
|
||||
${INSTALL_MAN} ${WRKSRC}/docs/manual.ps ${PREFIX}/share/doc/femlab
|
||||
.endif
|
||||
|
||||
.include <bsd.port.mk>
|
1
math/femlab/distinfo
Normal file
1
math/femlab/distinfo
Normal file
@ -0,0 +1 @@
|
||||
MD5 (femlab-2d-v1.1.tar.gz) = 8a296c529c222c4b6115e1ea749bf76d
|
6
math/femlab/files/femlab.sh
Normal file
6
math/femlab/files/femlab.sh
Normal file
@ -0,0 +1,6 @@
|
||||
#!/bin/sh
|
||||
|
||||
FEMLAB_HOME=@@FEMLAB_HOME@@
|
||||
export FEMLAB_HOME
|
||||
|
||||
exec ${FEMLAB_HOME}/bin/femlab
|
31
math/femlab/files/patch-aa
Normal file
31
math/femlab/files/patch-aa
Normal file
@ -0,0 +1,31 @@
|
||||
*** source/Imakefile.orig Tue Sep 2 10:38:18 1997
|
||||
--- source/Imakefile Tue Sep 2 10:39:42 1997
|
||||
***************
|
||||
*** 17,29 ****
|
||||
|
||||
OBJS = $(SRCS:.c=.o)
|
||||
|
||||
! CC = gcc -O
|
||||
CDEBUGFLAGS =
|
||||
EXTRA_INCLUDES = -I../include
|
||||
#
|
||||
# Change next line to the location of the libsx library
|
||||
#
|
||||
! EXTRA_LOAD_FLAGS = -L/users/math/martenl/projects/lib
|
||||
LOCAL_LIBRARIES = -lfreq -lsx -lm XawClientLibs
|
||||
DEPLIBS = XawClientDepLibs
|
||||
|
||||
--- 17,29 ----
|
||||
|
||||
OBJS = $(SRCS:.c=.o)
|
||||
|
||||
! CC = gcc -O2
|
||||
CDEBUGFLAGS =
|
||||
EXTRA_INCLUDES = -I../include
|
||||
#
|
||||
# Change next line to the location of the libsx library
|
||||
#
|
||||
! EXTRA_LOAD_FLAGS = -L$(X11BASE)
|
||||
LOCAL_LIBRARIES = -lfreq -lsx -lm XawClientLibs
|
||||
DEPLIBS = XawClientDepLibs
|
||||
|
55
math/femlab/files/patch-ab
Normal file
55
math/femlab/files/patch-ab
Normal file
@ -0,0 +1,55 @@
|
||||
*** source/graph.c.orig Sat Sep 13 16:23:18 1997
|
||||
--- source/graph.c Sat Sep 13 16:39:13 1997
|
||||
***************
|
||||
*** 608,614 ****
|
||||
void getDrawingScale()
|
||||
{
|
||||
float xoff, yoff;
|
||||
! float scl;
|
||||
int width, height;
|
||||
int ww;
|
||||
int nx, ny, id;
|
||||
--- 608,614 ----
|
||||
void getDrawingScale()
|
||||
{
|
||||
float xoff, yoff;
|
||||
! float iscl; /* inverse scale */
|
||||
int width, height;
|
||||
int ww;
|
||||
int nx, ny, id;
|
||||
***************
|
||||
*** 630,645 ****
|
||||
width = width / nx;
|
||||
height = height / ny;
|
||||
|
||||
! if(state > HAVE_NOTHING){
|
||||
! scl = 1./max(xmax-xmin,ymax-ymin);
|
||||
! xoff = -scl*(xmin+.5*(xmax-xmin)-.5/scl);
|
||||
! yoff = -scl*(ymin+.5*(ymax-ymin)-.5/scl);
|
||||
|
||||
! xoff = - xmin*scl*.85;
|
||||
! yoff = - ymin*scl*.85;
|
||||
|
||||
ww = min(width, height);
|
||||
! Xscl = (int) ((float)ww * 0.85 * scl);
|
||||
Xxoff = (int) ww * xoff ;
|
||||
Xyoff = (int) ww * yoff;
|
||||
Xxoff += (int) (width - ( Xscl*xmax +Xxoff))/2 + (id+nx-1)%nx *width;
|
||||
--- 630,646 ----
|
||||
width = width / nx;
|
||||
height = height / ny;
|
||||
|
||||
! iscl = max(xmax-xmin,ymax-ymin);
|
||||
|
||||
! if((state > HAVE_NOTHING) && (iscl != 0.0)){
|
||||
! xoff = .5-(xmin+.5*(xmax-xmin))/iscl;
|
||||
! yoff = .5-(ymin+.5*(ymax-ymin))/iscl;
|
||||
!
|
||||
! xoff = - xmin*.85/iscl;
|
||||
! yoff = - ymin*.85/iscl;
|
||||
|
||||
ww = min(width, height);
|
||||
! Xscl = (int) ((float)ww * 0.85 / iscl);
|
||||
Xxoff = (int) ww * xoff ;
|
||||
Xyoff = (int) ww * yoff;
|
||||
Xxoff += (int) (width - ( Xscl*xmax +Xxoff))/2 + (id+nx-1)%nx *width;
|
1
math/femlab/pkg-comment
Normal file
1
math/femlab/pkg-comment
Normal file
@ -0,0 +1 @@
|
||||
Interactive program for solving partial differential equations in 2D
|
21
math/femlab/pkg-descr
Normal file
21
math/femlab/pkg-descr
Normal file
@ -0,0 +1,21 @@
|
||||
Femlab is built up by several different programs. Currently the
|
||||
X11-interface, a meshgenerator and one solver. These programs communicate
|
||||
with each other with two ASCII files called "area.scratch" and
|
||||
"solu.scratch". The programs reside in FEMLAB_HOME/bin. These allows you
|
||||
to for instance run the solver directly from the csh as a batch job. The
|
||||
aim is to provide more solvers for different applications, such as 2D
|
||||
incompressible flow problems, transient problems etc. It should also be
|
||||
possible to use the X11 interface for your own applications.
|
||||
+---------------------------------------+
|
||||
| |
|
||||
| Authors: |
|
||||
| Peter Hansbo |
|
||||
| Marten Levenstam |
|
||||
| Dep. of Mathematics |
|
||||
| Chalmers University of Technology |
|
||||
| S-412 96 Goteborg |
|
||||
| SWEDEN |
|
||||
| femlab@math.chalmers.se |
|
||||
| |
|
||||
| \|/ |
|
||||
+----------------( )--------------------+
|
19
math/femlab/pkg-plist
Normal file
19
math/femlab/pkg-plist
Normal file
@ -0,0 +1,19 @@
|
||||
bin/femlab
|
||||
lib/X11/femlab/config/modules
|
||||
lib/X11/femlab/bin/femlab
|
||||
lib/X11/femlab/bin/meshgen
|
||||
lib/X11/femlab/bin/poisson
|
||||
share/doc/femlab/manual.dvi
|
||||
share/doc/femlab/manual.ps
|
||||
share/examples/femlab/capacitor.fem
|
||||
share/examples/femlab/convection.fem
|
||||
share/examples/femlab/man.fem
|
||||
share/examples/femlab/pot-cyl.fem
|
||||
share/examples/femlab/soap.fem
|
||||
share/examples/femlab/spark-plug.fem
|
||||
share/examples/femlab/torsion.fem
|
||||
@dirrm lib/X11/femlab/config
|
||||
@dirrm lib/X11/femlab/bin
|
||||
@dirrm lib/X11/femlab
|
||||
@dirrm share/doc/femlab
|
||||
@dirrm share/examples/femlab
|
Loading…
Reference in New Issue
Block a user