# How i can write transient condition in a pde thermal model?

3 views (last 30 days)
giuseppe sasso on 30 Jan 2020
Answered: giuseppe sasso on 31 Jan 2020
hi, i wolud like to know , about pde thermal model, how i can write internal heat source or bounday conditions that depends of space or time when they are with exponent.
for example , how i can write 2*t^2 using state.time ? and y^2 using region.y ?
is this correct?
handlename=@(region,state) region.y.^2 * 2 * region.state.^2
or is region.state.^region.state to express the dipendens of t^2
and how i can write when i have a function that depends just of space , usign always handle ?
best regards,
GS

Ravi Kumar on 30 Jan 2020
Example: If you want to write y^2 - 2*t^2, you write:
handlename=@(region,state) region.y.^2 - 2 * state.time^2
Yes, if it depends on just space you still write a function handle that uses only region data:
Example: If you want to write 2*x^2+3*y^3, then you can write it as:
handlename=@(region,state) 2*region.x.^2 +3*region.y.^3
Regards,
Ravi

giuseppe sasso on 31 Jan 2020
thank you so much for the answer.
so, when i'm using handle to express a t^2 is "state.time.^2" not "state.time.^state.time" right?? i will use .^ if i'm using vector, right?
when i have function that depends only of time i will write "handle=@(region,state)(1+region.y-region.y)*state.time" , correct?
when i have function that depends only of space i will write "handle=@(region,state) region.y" , coorect? have i however put the term "state" inside brackets?
best regards,
GS