Changeset 1209 for trunk/examples/app-fermi
- Timestamp:
- Nov 5, 2008, 12:38:42 PM (16 years ago)
- Location:
- trunk/examples/app-fermi/matlab
- Files:
-
- 3 edited
- 3 moved
Legend:
- Unmodified
- Added
- Removed
-
trunk/examples/app-fermi/matlab/Makefile.example
r1139 r1209 9 9 sed s/YOURAPPNAME/$^/ < run_app.patch | patch run_$^.sh 10 10 chmod +x run_$^.sh 11 # mv $^ $^.ctf run_$^.sh ../bin 12 # mv readme.txt ../bin/$^.readme 13 # LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/apps/rappture/lib `pwd`/../bin/run_$^.sh /apps/matlab/mcr `pwd`/driver.xml `pwd`/../data 14 simsim --tool tool.xml --driver-only driver.${APPNAME} 15 LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/apps/rappture/lib `pwd`/run_$^.sh /apps/matlab/mcr `pwd`/driver.${APPNAME} 16 rm -f run*.xml driver.${APPNAME} 11 mv $^ $^.ctf run_$^.sh ../bin 12 mv readme.txt ../bin/$^.readme 13 simsim --tool tool.xml --values default --nosim --driver driver.$^ 14 LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/apps/rappture/lib `pwd`/../bin/run_$^.sh /apps/matlab/mcr `pwd`/driver.$^ 15 rm -f run*.xml driver.$^ 17 16 @echo "Install Successful" 18 17 … … 25 24 run_${APPNAME}.sh \ 26 25 mccExcludedFiles.log \ 26 ${APPNAME}.readme \ 27 27 readme.txt \ 28 28 ${APPNAME}_mcr 29 29 30 30 distclean: clean 31 #rm -rf ../bin/*31 rm -rf ../bin/* -
trunk/examples/app-fermi/matlab/Makefile.in
r1082 r1209 1 1 2 2 bindir = @bindir@ 3 datadir 4 datarootdir 3 datadir = @datadir@ 4 datarootdir = @datarootdir@ 5 5 exec_prefix = @exec_prefix@ 6 6 includedir = @includedir@ … … 8 8 mandir = @mandir@ 9 9 prefix = @prefix@ 10 srcdir 10 srcdir = @srcdir@ 11 11 12 destdir 12 destdir = $(prefix)/examples/app-fermi/matlab 13 13 14 INSTALL = @INSTALL@ 15 MKDIR_P = @MKDIR_P@ 14 INSTALL = @INSTALL@ 15 MKDIR_P = @MKDIR_P@ 16 MCC = @MCC@ 16 17 17 FILES = \ 18 MCC_FLAGS = -m -R -nojvm 19 INCLUDES = -I ../../../lang/matlab 20 MCC_SWITCHES = $(MCC_FLAGS) $(INCLUDES) 21 VPATH = $(srcdir) 22 23 APPNAME = fermi 24 25 FILES = \ 18 26 $(srcdir)/tool.xml \ 19 $(srcdir)/fermi.m 27 $(srcdir)/Makefile.example \ 28 ${APPNAME}.ctf 20 29 21 all: 30 ${APPNAME}: fermi_main.m fermi.m 31 $(MCC) $(MCC_SWITCHES) -o $@ $^ 22 32 23 install: 33 all: ${APPNAME} 34 35 install: ${APPNAME} 36 sed s/YOURAPPNAME/$^/ < $(srcdir)/run_app.patch | patch run_$^.sh 24 37 $(MKDIR_P) $(destdir) 25 38 for i in $(FILES) ; do \ 26 39 $(INSTALL) -m 444 $$i $(destdir) ; \ 27 40 done 41 $(INSTALL) -m 444 readme.txt $(destdir)/$^.readme 42 $(INSTALL) -m 555 run_$^.sh $^ $(destdir) 43 $(bindir)/simsim --tool $(srcdir)/tool.xml --values default --nosim --driver driver.$^ 44 LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:$(libdir) $(destdir)/run_$^.sh /apps/matlab/mcr driver.$^ 45 rm -f run*.xml driver.$^ 46 @echo "Install Successful" 28 47 29 48 clean: 49 rm -rf ${APPNAME} \ 50 ${APPNAME}_main.c \ 51 ${APPNAME}.ctf \ 52 ${APPNAME}.prj \ 53 ${APPNAME}_mcc_component_data.c \ 54 run_${APPNAME}.sh \ 55 mccExcludedFiles.log \ 56 readme.txt \ 57 ${APPNAME}_mcr 30 58 31 59 distclean: clean 32 60 $(RM) Makefile 33 -
trunk/examples/app-fermi/matlab/fermi.m
r665 r1209 1 1 % ---------------------------------------------------------------------- 2 % EXAMPLE: Fermi-Dirac function in Octave.2 % EXAMPLE: Fermi-Dirac function in Matlab. 3 3 % 4 4 % This script represents a newly written application with rappture … … 8 8 % AUTHOR: Michael McLennan, Purdue University 9 9 % AUTHOR: Derrick Kearney, Purdue University 10 % Copyright (c) 2004-200 7Purdue Research Foundation10 % Copyright (c) 2004-2008 Purdue Research Foundation 11 11 % 12 12 % See the file "license.terms" for information on usage and … … 14 14 % ====================================================================== 15 15 16 % get out input file from the command line 17 % invoke this script with the following command: 18 % matlab -nodisplay -r infile=\'driver1234.xml\',fermi 19 % the above command sets variable infile to the name 'driver1234.xml' 16 function retVal=fermi; 20 17 21 % infile = 'driver31619.xml' 22 23 % open our xml input file. 24 lib = rpLib(infile); 18 % We open the xml file in the main function and make lib global 19 global lib; 25 20 26 21 % retrieve user specified data out of the input file … … 56 51 rpLibResult(lib); 57 52 58 quit;53 retVal = 0; -
trunk/examples/app-fermi/matlab/tool.xml
r572 r1209 3 3 <tool> 4 4 <about>Press Simulate to view results.</about> 5 <command> matlab -nodisplay -r infile='@driver',path('@tool',path),fermi</command>5 <command>@tool/run_fermi.sh /apps/matlab/mcr @driver</command> 6 6 </tool> 7 7 <input>
Note: See TracChangeset
for help on using the changeset viewer.