We want to be able to test a number of values for the ratio of the radii of the frustum which will be much easier once we can get Matlab to automate running our COMSOL model. I have been able to output the COMSOL model to a .m file and was able to figure out a way to export the Umax value we want to Matlab (see the attached .m file).
The model ran in Matlab after debugging it for a short while and returned the same result as the COMSOL model had by itself. I setup a script to loop over some values of RatioRadii and feed them to the model. The first value it fed to the model worked and returned 1.2099e-10 J for RatioRadii=0.1, but for RatioRadii=0.2 the model had a
meshing error. I am going to have to see if there is some way we can modify the mesh to fix this error. When I briefly looked into it today, I found that for several RatioRadii which I tried, the object could be meshed for certain finenesses, but not others. I am going to spend tomorrow working on the first progress report, but after that is done I will
work on fixing this meshing error.
function [Umax] = model(ratioRadii)
% ratioRadii must be a scalar
% Model exported on Jul 1 2013, 17:08 by COMSOL 188.8.131.52.
model = ModelUtil.create('Model');
function [RatioRValues,UmaxValues] = looper
% Iterates over a range of RatioRValues
UmaxValues = [UmaxValues model_7_1_13(r)];