Skip to main content
1-Visitor
October 1, 2018
Question

Units problems with program block

  • October 1, 2018
  • 2 replies
  • 2751 views

Hello everyone,

 

I'm trying to program a 2D finite difference in time domain problem. However, I can't run the program, since the units do not seem to match. Has anyone an idea of how to disable these units or maybe could tell me what did I do wrong ? Because I don't know if I did mistakes in my program or if units stand as the only problem.

 

Thanks in advance !

 

Cyril

This topic has been closed for replies.

2 replies

25-Diamond I
October 1, 2018

Look for example at your function k(). You are trying to add a dimensionless "d" and and expression with dimension temperature^2. That can't work.

CyrilD1-VisitorAuthor
1-Visitor
October 1, 2018

d is just a coefficient imposed in the evolution of k with temperature, how could I defined it another way ?

23-Emerald I
October 1, 2018

You have to make unit balance.  Put correct units into your constants:

Capture.PNG

21-Topaz II
October 1, 2018

All constants and variables must be dimensionless or all with dimension. You can not just size some. You can not name a variable in the program, with the same name as the program. (Delta T is defined as a constant, instead in the program you use it as an indexed variable)