From a8304e146e9fbab0bc2263b90bcfd93a23aecc93 Mon Sep 17 00:00:00 2001 From: "Bryan W. Weber" Date: Fri, 18 Jul 2014 14:35:05 +0000 Subject: [PATCH] [Matlab] Fix small bugs. Add clear method to Transport, qdot and vdot to Wall. --- interfaces/matlab/toolbox/1D/@Domain1D/set.m | 4 ---- .../matlab/toolbox/1D/@Domain1D/setTransientTolerances.m | 2 +- interfaces/matlab/toolbox/@Interface/concentrations.m | 4 ++-- interfaces/matlab/toolbox/@Transport/clear.m | 3 +++ interfaces/matlab/toolbox/@Wall/qdot.m | 3 +++ interfaces/matlab/toolbox/@Wall/vdot.m | 3 +++ interfaces/matlab/toolbox/@XML_Node/addChild.m | 4 ++-- interfaces/matlab/toolbox/@XML_Node/nChildren.m | 4 ++-- 8 files changed, 16 insertions(+), 11 deletions(-) create mode 100644 interfaces/matlab/toolbox/@Transport/clear.m create mode 100644 interfaces/matlab/toolbox/@Wall/qdot.m create mode 100644 interfaces/matlab/toolbox/@Wall/vdot.m diff --git a/interfaces/matlab/toolbox/1D/@Domain1D/set.m b/interfaces/matlab/toolbox/1D/@Domain1D/set.m index 44db158b8..bc984e093 100644 --- a/interfaces/matlab/toolbox/1D/@Domain1D/set.m +++ b/interfaces/matlab/toolbox/1D/@Domain1D/set.m @@ -35,10 +35,6 @@ while length(property_argin) >= 2, setTemperature(a, val); case 'T' setTemperature(a, val); - case 'MassFractions' - setMassFractions(a, val); - case 'Y' - setMassFractions(a, val); case 'mdot' setMdot(a, val); case 'MassFlux' diff --git a/interfaces/matlab/toolbox/1D/@Domain1D/setTransientTolerances.m b/interfaces/matlab/toolbox/1D/@Domain1D/setTransientTolerances.m index 85a54ec90..89a2c7c8a 100644 --- a/interfaces/matlab/toolbox/1D/@Domain1D/setTransientTolerances.m +++ b/interfaces/matlab/toolbox/1D/@Domain1D/setTransientTolerances.m @@ -1,4 +1,4 @@ -function setSteadyTolerances(d, component, rtol, atol) +function setTransientTolerances(d, component, rtol, atol) % SETSTEADYTOLERANCES - % diff --git a/interfaces/matlab/toolbox/@Interface/concentrations.m b/interfaces/matlab/toolbox/@Interface/concentrations.m index 857f008be..e16fd10c4 100644 --- a/interfaces/matlab/toolbox/@Interface/concentrations.m +++ b/interfaces/matlab/toolbox/@Interface/concentrations.m @@ -1,14 +1,14 @@ function c = concentrations(s) % CONCENTRATIONS - Surface concentrations % -c = surfmethods(thermo_hndl(s), 101); +c = surfmethods(thermo_hndl(s), 103); if nargout == 0 figure set(gcf, 'Name', 'Concentrations') bar(c); colormap(summer); nm = speciesNames(s); - set(gca,'XTickLabel', nm); + set(gca, 'XTickLabel', nm); xlabel('Species Name'); ylabel('Concentration [kmol/m2]'); title('Surface Species Concentrations'); diff --git a/interfaces/matlab/toolbox/@Transport/clear.m b/interfaces/matlab/toolbox/@Transport/clear.m new file mode 100644 index 000000000..d8a20cc54 --- /dev/null +++ b/interfaces/matlab/toolbox/@Transport/clear.m @@ -0,0 +1,3 @@ +function clear(tr) + +trans_get(tr.id, 0) diff --git a/interfaces/matlab/toolbox/@Wall/qdot.m b/interfaces/matlab/toolbox/@Wall/qdot.m new file mode 100644 index 000000000..6d5d1391f --- /dev/null +++ b/interfaces/matlab/toolbox/@Wall/qdot.m @@ -0,0 +1,3 @@ +function q = qdot(w, t) + +q = wallmethods(22, wall_hndl(w), t); diff --git a/interfaces/matlab/toolbox/@Wall/vdot.m b/interfaces/matlab/toolbox/@Wall/vdot.m new file mode 100644 index 000000000..ec1f1ec73 --- /dev/null +++ b/interfaces/matlab/toolbox/@Wall/vdot.m @@ -0,0 +1,3 @@ +function v = vdot(w, t) + +v = wallmethods(21, wall_hndl(w), t); diff --git a/interfaces/matlab/toolbox/@XML_Node/addChild.m b/interfaces/matlab/toolbox/@XML_Node/addChild.m index 573376e13..59745f6ef 100644 --- a/interfaces/matlab/toolbox/@XML_Node/addChild.m +++ b/interfaces/matlab/toolbox/@XML_Node/addChild.m @@ -1,3 +1,3 @@ -function n = addChild(root, id) +function n = addChild(root, id, val) % -n = ctmethods(10, 10, root.id, id); +n = ctmethods(10, 11, root.id, id, val); diff --git a/interfaces/matlab/toolbox/@XML_Node/nChildren.m b/interfaces/matlab/toolbox/@XML_Node/nChildren.m index b8d4bd223..a76484d5c 100644 --- a/interfaces/matlab/toolbox/@XML_Node/nChildren.m +++ b/interfaces/matlab/toolbox/@XML_Node/nChildren.m @@ -1,3 +1,3 @@ -function n = nChildren(root, id) +function n = nChildren(root) % -n = ctmethods(10, 10, root.id, id); +n = ctmethods(10, 10, root.id);