simulkade / JFVM.jl

A simple finite volume tool for Julia
Other
43 stars 13 forks source link

"full" not defined in reshapeCell and reshapeInternalCell #8

Open SA8416 opened 3 years ago

SA8416 commented 3 years ago

Attempts to use reshapeCell or reshapeInternalCell result in an error of:

ERROR: LoadError: UndefVarError: full not defined
Stacktrace:
 [1] reshapeCell(m::MeshStructure, phi::CellValue)
   @ JFVM D:\Programs\Julia-1.6.1\.julia\packages\JFVM\v1vqd\src\JFVMtools.jl:330

my temporary (and quite poor) workaround to this is:

Ti = internalCells(T)
        Ti = [Ti[1,1:end]';Ti;Ti[end,1:end]']
        Ti = [Ti[1:end,1] Ti Ti[1:end,end]]
        T = createCellVariable(m,Ti)

So that I may use the cellvariable T (which is a solution from solving a PDE) in functions that are dependant on T, but return errors when operating on the ghost values of T.

I will look into a better fix & branch it later this week.

Thanks.

simulkade commented 3 years ago

Hi @SA8416 , Thanks for reporting this issue. One quick solution is to replace full, which is deprecated in Julia 1.0, with Matrix. Now it should be fixed with the new commit. Please let me know if it does not work.