How to Add a New Variable
From KratosWiki
(Difference between revisions)
Line 5: | Line 5: | ||
KRATOS_DEFINE_VARIABLE(double, DIVPROJ) | KRATOS_DEFINE_VARIABLE(double, DIVPROJ) | ||
+ | |||
+ | 2. '''Create''' & '''Register''' | ||
+ | it is done in '''.../kratos/sources/variables.cpp'' | ||
+ | |||
+ | KRATOS_CREATE_VARIABLE(double, DIVPROJ) | ||
+ | KRATOS_REGISTER_VARIABLE(double, DIVPROJ) |
Revision as of 13:47, 5 December 2008
If you need to add a new variable to Kratos which doesn`t exist 3 passes are needed
1. define the variable it is done in .../kratos/includes/variables.h
KRATOS_DEFINE_VARIABLE(double, DIVPROJ)
2. Create & Register it is done in '.../kratos/sources/variables.cpp
KRATOS_CREATE_VARIABLE(double, DIVPROJ) KRATOS_REGISTER_VARIABLE(double, DIVPROJ)