Hi everyone,
I am using this code as reference.
https://comet-fenics.readthedocs.io/en/latest/demo/elastodynamics/demo_elastodynamics.py.html
In this code, there is a place where I can define the loading depending on time.
Here, a JIT-compiled expression is used.
p0 = 1.
cutoff_Tc = T/5
# Define the loading as an expression depending on t
p = Expression((“0”, “t <= tc ? p0*t/tc : 0”, “0”), t=0, tc=cutoff_Tc, p0=p0, degree=0)
What I want to do is import a csv data file that depends on time something like this
|Time|Value|
|0.002001|0.000934685|
|0.002668|0.000979293|
|0.003335|0.0010239|
|0.004002|0.00106851|
|0.004669|0.0010239|
|0.005336|0.000934685|
I thought I can use How to Import csv data file to FEniCS? this answer but, I’m not sure if this answers my question.
To use a JIT-compiled expression I need to write it in C++ which I haven’t learned much about.
I am happy about any kind of help. Thanks in advance!