Last change
on this file since 154 was
154,
checked in by dkearney, 19 years ago
|
modified matlab bindings and tests.
includes all popular functions available in RpLibrary? and RpUnits
compile and run, but not all tests work as they should
some of these functions will be removed soon because the id field is
no longer a valid argument. path ids should be incorporated in paths from now on.
|
File size:
944 bytes
|
Line | |
---|
1 | % ---------------------------------------------------------------------- |
---|
2 | % TEST: Matlab's Rappture Library Test Functions. |
---|
3 | % |
---|
4 | % [err] = test_convert_dbl(fromVal, toUnitsName) |
---|
5 | % |
---|
6 | % |
---|
7 | % ====================================================================== |
---|
8 | % AUTHOR: Derrick Kearney, Purdue University |
---|
9 | % Copyright (c) 2004-2005 Purdue Research Foundation |
---|
10 | % |
---|
11 | % See the file "license.terms" for information on usage and |
---|
12 | % redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES. |
---|
13 | % ====================================================================== |
---|
14 | |
---|
15 | function [err] = test_convert_dbl(fromVal, toUnitsName) |
---|
16 | err = 1; |
---|
17 | disp(sprintf('\n\nTESTING rpUnitsConvertDbl: convert %s to %s\n', fromVal, toUnitsName)); |
---|
18 | |
---|
19 | [retVal,err] = rpUnitsConvertDbl(fromVal, toUnitsName); |
---|
20 | if ~err |
---|
21 | disp(sprintf('%s = %e\n',fromVal,retVal)); |
---|
22 | else |
---|
23 | disp(sprintf('Error within rpUnitsConvertDbl function\n')); |
---|
24 | end |
---|
25 | return |
---|
Note: See
TracBrowser
for help on using the repository browser.