How to define a sloping boundary?

Asked by Jingchi Yu

As we know, if I want to define a boundary of a box, I can use some codes like"wherezero(x[0])"

On this basis, if I want to define a sloping boundary like the hypotenuse of the triangle,how can I do that?

Waiting your answer all the time~Thx~

Question information

Language:
English Edit question
Status:
Solved
For:
esys-escript Edit question
Assignee:
No assignee Edit question
Solved by:
Adam Ellery
Solved:
Last query:
Last reply:
Revision history for this message
Best Adam Ellery (aellery) said :
#1

Hi Jingchi,

For a line defined by the equation y=a*x+b, you can use the expression along the lines "whereZero(x[1]-(a*x[0]+b))".

- Adam

Revision history for this message
Jingchi Yu (yujc-17) said :
#2

Thanks Adam Ellery, that solved my question.