# Issue with boundary values

**URL:** <https://community.freefem.org/t/issue-with-boundary-values/275>\
**Category:** General Discussion\
**Created:** [February 26, 2020, 12:38pm UTC](https://community.freefem.org/t/issue-with-boundary-values/275 "2020-02-26T12:38:20Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mordokkai](https://avatars.discourse-cdn.com/v4/letter/m/f6c823/32.png) [@Mordokkai](https://community.freefem.org/u/Mordokkai)\
**Post date:** [February 26, 2020, 12:38pm UTC](https://community.freefem.org/t/issue-with-boundary-values/275/1 "2020-02-26T12:38:20Z")

</div>

Hi all,

I don’t understand the error with this code:

func real z1(){  
return 10.;  
}  
problem heat(u,v) = int2d(fm)(dx(u)\*dx(v) + dy(u)_dy(v)) - int2d(fm)(myHeat_v)  
+ on(0, u=z1);  
Error message:  
Impossible to cast \<11Polymorphic\> in . (it concerns the boundary values).

And is it possible to do a function for the boundary values like:  
func real z1(){  
return tab[x][y];  
}

Thanks in advance,

Sylvain

---

<div class="post-metadata">

**Author:** ![Mordokkai](https://avatars.discourse-cdn.com/v4/letter/m/f6c823/32.png) [@Mordokkai](https://community.freefem.org/u/Mordokkai)\
**Post date:** [February 28, 2020, 9:13am UTC](https://community.freefem.org/t/issue-with-boundary-values/275/2 "2020-02-28T09:13:32Z")

</div>

It has been solved

Sylvain
