Start

Creating Variables

Creating Variables

COMSOL Tips Featured Image
How crating variables in COMSOL Multiphysics

In this tip we will see how we can create variables in COMSOL Multiphysics. A variable is essentially defined by an expression of other variables, dependent variables, user input parameters, or entered values.

You can use variables for many important purposes, including the following:

  • To add a quantity for plotting and results evaluation.
  • To simplify the writing and readability of expressions.
  • To make evaluation of long expressions more efficient, especially if an expression occurs in several places.

All variables in the Physics Builder are tensors that are first declared and then defined. You typically do the declaration once in a central place.

In this tip we would to create a variable as follow:

NameExpressionUnitDescription
u_meanU*t^2/sqrt(t^4-0.07[s^2]*t^2+0.0016[s^4])m/sInlet Mean Velocity

How:

  1. In the Home toolbar, click Variables and choose Global Variables.
  2. In the Settings window for Variables, locate the Variables section.
  3. In the table, enter the information which you want. In this tip, they are the data which is given in the table above.

We can see the section in the COMSOL Multiphysics software interface.



Mohsen
Mohsen Website
Mechanical Engineer (M.Sc.), with more than 8 years, since 2011, of experience in simulation, analysis, modeling, software courses teaching, academic and industrial research and development. Read more about me

Leave a Reply

Your email address will not be published. Required fields are marked *