Thread Subject: Simscape Variable coefficient for Convective Heat Transfer ( ssc_build)

 Subject: Simscape Variable coefficient for Convective Heat Transfer ( ssc_build) From: Ricardo Pereira Date: 7 Sep, 2012 09:50:08 Message: 1 of 1 Hello I´m modelling a PV/T with Matlab_2012a Simscape for Mac. I think that there is a way to have variable heat transfer coefficient in the convective heat transfer model of Simscape. I tried to set the coefficient to a variable, as I saw on another thread, but I got an error with the ssc_build. I followed the instructions as I saw on: http://www.mathworks.com/matlabcentral/newsreader/view_thread/298382 My script was: ------------------------------------------------------------------------------------------- component convection < foundation.thermal.branch % Convective Heat Transfer % The block represents an energy transfer by convection between two % bodies by means of fluid motion. The transfer is governed by the Newton % law of cooling and is directly proportional to the convection heat % transfer coefficient, surface area, and the temperature difference. % % Connections A and B are thermal conserving ports associated % with the points between which the energy transport by convection takes % place. The block positive direction is from port A to port B. This means % that the heat flow is positive if it flows from A to B. % Copyright 2005-2008 The MathWorks, Inc.     inputs     heat_tr_coeff = { 20, 'W/(m^2*K)' }; % heat_tr_coeff: left   end        parameters     area = { 1e-4, 'm^2' }; % Area   end           function setup     % Parameter range checking     if area <= 0       pm_error('simscape:GreaterThanZero','Area')     end     if heat_tr_coeff <= 0       pm_error('simscape:GreaterThanZero','Heat transfer coefficient')     end   end   equations     Q == area * heat_tr_coeff * T;   end end -----------------------------------------------------------------------------------------------------------   And the ERROR was: ---------------------------------------------------------------------------------------------------------- >> ssc_build Generating Simulink library 'foundation_lib' in the MATLAB package parent directory '/Applications/MATLAB_R2012a.app/toolbox/physmod/simscape/library/m' ... Failed to generate 'foundation_lib' Caused by:     'foundation' is a MathWorks' provided MATLAB package. Building MathWorks'     provided libraries is not supported.  ----------------------------------------------------------------------------------------------------------- Anyone could help me to solve this error? Thanks

Everyone's Tags:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.