Skip to content
Snippets Groups Projects
Commit 49d1d60c authored by Colin Eles's avatar Colin Eles
Browse files

added directory for examples as well as some examples pulled from FPGA...

added directory for examples as well as some examples pulled from FPGA presentation, added example for quadratic roots problem solved using predicate subtyping which typechecks and appears to give proper answers when compared to matlab roots fcn

git-svn-id: https://groke.mcmaster.ca/svn/grad/colin/trunk/TableTool@6762 57e6efec-57d4-0310-aeb1-a6c144bb1a8b
parent 75ad1ede
No related branches found
No related tags found
No related merge requests found
...@@ -10,8 +10,26 @@ ...@@ -10,8 +10,26 @@
% Author: Colin Eles elesc@mcmaster.ca % Author: Colin Eles elesc@mcmaster.ca
% Organization: McMaster Centre for Software Certification % Organization: McMaster Centre for Software Certification
function string = pvs_check_for_imports(object) function string = pvs_check_for_imports(object)
[string,found] = object.pvs_check_for_imports_g(object.data.Grid2,{}); [string,found] = object.pvs_check_for_imports_g(object.data.Grid2,{});
[string2,found2] = object.pvs_check_for_imports_g(object.data.Grid1,found); [string2,found2] = object.pvs_check_for_imports_g(object.data.Grid1,found);
% check for imports in the inputs field
hashtable = {{'sqrt', 'reals@sqrt'} {'sin', 'trig@trig_basic'} {'cos', 'trig@trig_basic'} {'tan', 'trig@trig_basic'}};
for k=1:size(hashtable,2)
if ~isempty(regexp(object.data.function_inputs,hashtable{k}(1),'once'))
if (~any(ismember(found,hashtable{k}(1))))
string = [string 'IMPORTING ' char(hashtable{k}(2)) sprintf('\n')];
found = [found hashtable{k}(1)];
end
end
end
string = [string string2]; string = [string string2];
end end
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment