Mechomatic
Mechanical
- Apr 23, 2013
- 50
Hello all-
I've recently installed GNU Octave 3.6.4 on my Windows XP workstation and have been plugging along smoothly on a heat transfer FEA problem. I'm getting a syntax error back from Octave but I can't understand why. Attached is a folder of the .m files needed for the script (bathdrain.m). If somebody more familiarw ith the program could point me in the right direction, I would very much appreciate it! Here's the error that Octave spits out at me:
parse error near line 104 of file C:\Program Files\Octave-3.6.4\share\octave\3.6.4\m\bathdrain.m
syntax error
>>> C(i,nodematnum(m,n+7*(o-1)))= k*2*z(m,n+7*(o-1))*dx^2/dz + k*(xu(m,n+7*(o-1))+xd(m,n+7*(o-1))+...*dx^2;
The arrow indicating where the error occurs is under the 1 shown bold and underlined.
The script is finding the temperature profile of a steel plate subjected to forced convection in cold air, free convection, and forced convection in hot water. I set up a cell array to model the mesh nodes and converted it to a matrix, then am using the cell array indices m, n, and o to map the adjacent node temperatures. In the error, matrix "nodematnum" is a matrix relating a unique index number to each actual node (empty nodes are numbered 1 and used a cell padding so that matrix indices work when running the loops to create a coefficient matrix).
I'm not sure why it's getting a syntax error on the 1, but if somebody who's more knowledgeable could set me straight, I'd appreciate it!
I've recently installed GNU Octave 3.6.4 on my Windows XP workstation and have been plugging along smoothly on a heat transfer FEA problem. I'm getting a syntax error back from Octave but I can't understand why. Attached is a folder of the .m files needed for the script (bathdrain.m). If somebody more familiarw ith the program could point me in the right direction, I would very much appreciate it! Here's the error that Octave spits out at me:
parse error near line 104 of file C:\Program Files\Octave-3.6.4\share\octave\3.6.4\m\bathdrain.m
syntax error
>>> C(i,nodematnum(m,n+7*(o-1)))= k*2*z(m,n+7*(o-1))*dx^2/dz + k*(xu(m,n+7*(o-1))+xd(m,n+7*(o-1))+...*dx^2;
The arrow indicating where the error occurs is under the 1 shown bold and underlined.
The script is finding the temperature profile of a steel plate subjected to forced convection in cold air, free convection, and forced convection in hot water. I set up a cell array to model the mesh nodes and converted it to a matrix, then am using the cell array indices m, n, and o to map the adjacent node temperatures. In the error, matrix "nodematnum" is a matrix relating a unique index number to each actual node (empty nodes are numbered 1 and used a cell padding so that matrix indices work when running the loops to create a coefficient matrix).
I'm not sure why it's getting a syntax error on the 1, but if somebody who's more knowledgeable could set me straight, I'd appreciate it!