Page 1 of 1

Re: problem with long input in MATC?

Posted: 04 Nov 2018, 21:57
by annier
Hi sage12,
the MATC expression has a length limit of 128 characters (viewtopic.php?f=3&t=110).
For expressions longer than 128 characters, we have to formulate a function (the function feature in elmer has no limit in length) and link it as a function in MATC expression, as shown in the following examples.
1. In, viewtopic.php?f=3&t=4070 ,

Code: Select all

Heat Source = Variable Coordinate 1, Coordinate 2, Time; Real MATC    "test(tx)"
and function test(x) is defined in the solver input file. Moreover, we can utilize functions for longer expressions in connection to material properties (can be found from the post illustrated in case of Ja(t) function used as $ Ja(0) for current density 3, in the same link).
2. In, https://github.com/anilkunwar/elmerfem/ ... oKthml.sif,

Code: Select all

Heat conductivity(3,3) = Variable Coordinate 1, Coordinate 2
  Real MATC "test(tx)"
and function test(x) is defined in the solver input file.


The name of the function is arbitrary:
anyfuncname(y), where y is arbitrarily chosen (= it can be any alphabet), and within MATC expression, it is written as : anyfuncname(tx)




Yours Sincerely,
Anil Kunwar

Re: problem with long input in MATC?

Posted: 05 Nov 2018, 12:02
by mzenker
Hi,

at a first glance, your condition seems like a table would be easier? You can use tables of any length, even from external files.

HTH,

Matthias

Re: problem with long input in MATC?

Posted: 03 Dec 2018, 09:24
by ReneeDegutis
annier wrote:
04 Nov 2018, 21:57
Hi sage12,
the MATC expression has a length limit of 128 characters (viewtopic.php?f=3&t=110).
For expressions longer than 128 characters, we have to formulate a function (the function feature in elmer has no limit in length) and link it as a function in MATC expression, as shown in the following examples.
1. In, viewtopic.php?f=3&t=4070 ,

Code: Select all

Heat Source = Variable Coordinate 1, Coordinate 2, Time; Real MATC    "test(tx)"
and function test(x) is defined in the solver input file. Moreover, we can utilize functions for longer expressions in connection to material properties (can be found from the post illustrated in case of Ja(t) function used as $ Ja(0) for current density 3, in the same link).
2. In, https://github.com/anilkunwar/elmerfem/ ... oKwritemyessayin6hoursthml.sif,

Code: Select all

Heat conductivity(3,3) = Variable Coordinate 1, Coordinate 2
  Real MATC "test(tx)"
and function test(x) is defined in the solver input file.


The name of the function is arbitrary:
anyfuncname(y), where y is arbitrarily chosen (= it can be any alphabet), and within MATC expression, it is written as : anyfuncname(tx)




Yours Sincerely,
Anil Kunwar


Hello Anil,

How does the the thermal conductivity tensor change due to the length? Is there a specific way to apply the changes using the table?

Thanks,
Renee