Discussion Closed This discussion was created more than 6 months ago and has been closed. To start a new discussion with a link back to this one, click here.

Time dependent function and stationary study

Please login with a confirmed email address before reporting spam

There is a time dependent fuction in my model. However, in the study, the step 1 is stationary study and the next step of time dependent study is based on the solvution of the stationary study. So is there any way to solve the error of stationary study calculation due to the existence of the time dependent function? The system keeps showing undefined variable 't'


3 Replies Last Post May 4, 2023, 9:18 a.m. EDT
Magnus Ringh COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 2 years ago Feb 13, 2023, 8:20 a.m. EST

Hi Yu,

A Stationary study step does not depend on time, but you can add a parameter t defined as some time to be able to solve equations using time-dependent settings as a stationary solution for that time.

Best regards,

Magnus

Hi Yu, A **Stationary** study step does not depend on time, but you can add a parameter `t` defined as some time to be able to solve equations using time-dependent settings as a stationary solution for that time. Best regards, Magnus

Please login with a confirmed email address before reporting spam

Posted: 2 years ago May 3, 2023, 8:13 p.m. EDT

Magnus, I'm not sure how to implement this. Can you post a sample .mph or a screenshot showing the setup?

Magnus, I'm not sure how to implement this. Can you post a sample .mph or a screenshot showing the setup?

Magnus Ringh COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 2 years ago May 4, 2023, 9:18 a.m. EDT

Magnus, I'm not sure how to implement this. Can you post a sample .mph or a screenshot showing the setup?

Hi Sean,

If you have an expression with "t" somewhere in your model and want to solve it using a stationary solver, you can then simply add a parameter or constant t and give it a value, such as 0. You can use a Parameters node, or you can define it as a constant in the Stationary Solver settings (see the attached screenshot).

Best regards,

Magnus

>Magnus, I'm not sure how to implement this. Can you post a sample .mph or a screenshot showing the setup? Hi Sean, If you have an expression with "t" somewhere in your model and want to solve it using a stationary solver, you can then simply add a parameter or constant `t` and give it a value, such as 0. You can use a **Parameters** node, or you can define it as a constant in the **Stationary Solver** settings (see the attached screenshot). Best regards, Magnus

Note that while COMSOL employees may participate in the discussion forum, COMSOL® software users who are on-subscription should submit their questions via the Support Center for a more comprehensive response from the Technical Support team.