Changeset 24933


Ignore:
Timestamp:
05/30/20 22:13:21 (5 years ago)
Author:
Mathieu Morlighem
Message:

CHG: cleaning up NDOFx

Location:
issm/trunk-jpl/src/c
Files:
21 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk-jpl/src/c/analyses/AdjointHorizAnalysis.cpp

    r24716 r24933  
    25022502        for(i=0;i<numnodes;i++){
    25032503                if(domaintype!=Domain2DverticalEnum){
    2504                         lambdax[i]=values[i*NDOF2+0];
    2505                         lambday[i]=values[i*NDOF2+1];
     2504                        lambdax[i]=values[i*2+0];
     2505                        lambday[i]=values[i*2+1];
    25062506                }
    25072507                else {lambdax[i]=values[i];lambday[i]=0;}
  • issm/trunk-jpl/src/c/analyses/BalancethicknessAnalysis.cpp

    r24335 r24933  
    424424}/*}}}*/
    425425void           BalancethicknessAnalysis::GetB(IssmDouble* B,Element* element,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    426         /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*NDOF2.
     426        /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*2.
    427427         * For node i, Bi can be expressed in the actual coordinate system
    428428         * by:
     
    431431         * where N is the finiteelement function for node i.
    432432         *
    433          * We assume B_prog has been allocated already, of size: 2x(NDOF1*numnodes)
     433         * We assume B_prog has been allocated already, of size: 2x(1*numnodes)
    434434         */
    435435
     
    451451}/*}}}*/
    452452void           BalancethicknessAnalysis::GetBprime(IssmDouble* Bprime,Element* element,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    453         /*Compute B'  matrix. B'=[B1' B2' B3'] where Bi' is of size 3*NDOF2.
     453        /*Compute B'  matrix. B'=[B1' B2' B3'] where Bi' is of size 3*2.
    454454         * For node i, Bi' can be expressed in the actual coordinate system
    455455         * by:
     
    458458         * where N is the finiteelement function for node i.
    459459         *
    460          * We assume B' has been allocated already, of size: 3x(NDOF2*numnodes)
     460         * We assume B' has been allocated already, of size: 3x(2*numnodes)
    461461         */
    462462
  • issm/trunk-jpl/src/c/analyses/DamageEvolutionAnalysis.cpp

    r24713 r24933  
    667667}/*}}}*/
    668668void           DamageEvolutionAnalysis::GetB(IssmDouble* B,Element* element,int dim,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    669         /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*NDOF2.
     669        /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*2.
    670670         * For node i, Bi can be expressed in the actual coordinate system
    671671         * by:
     
    674674         * where N is the finiteelement function for node i.
    675675         *
    676          * We assume B_prog has been allocated already, of size: 2x(NDOF1*numnodes)
     676         * We assume B_prog has been allocated already, of size: 2x(1*numnodes)
    677677         */
    678678
     
    695695}/*}}}*/
    696696void           DamageEvolutionAnalysis::GetBprime(IssmDouble* Bprime,Element* element,int dim,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    697         /*Compute B'  matrix. B'=[B1' B2' B3'] where Bi' is of size 3*NDOF2.
     697        /*Compute B'  matrix. B'=[B1' B2' B3'] where Bi' is of size 3*2.
    698698         * For node i, Bi' can be expressed in the actual coordinate system
    699699         * by:
     
    702702         * where N is the finiteelement function for node i.
    703703         *
    704          * We assume B' has been allocated already, of size: 3x(NDOF2*numnodes)
     704         * We assume B' has been allocated already, of size: 3x(2*numnodes)
    705705         */
    706706
  • issm/trunk-jpl/src/c/analyses/EnthalpyAnalysis.cpp

    r24918 r24933  
    12881288}/*}}}*/
    12891289void           EnthalpyAnalysis::GetBAdvec(IssmDouble* B,Element* element,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    1290         /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 5*NDOF1.
     1290        /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 5*1.
    12911291         * For node i, Bi' can be expressed in the actual coordinate system
    12921292         * by:
     
    12961296         * where h is the interpolation function for node i.
    12971297         *
    1298          * We assume B has been allocated already, of size: 3x(NDOF1*NUMNODESP1)
     1298         * We assume B has been allocated already, of size: 3x(1*NUMNODESP1)
    12991299         */
    13001300
     
    13171317}/*}}}*/
    13181318void           EnthalpyAnalysis::GetBAdvecprime(IssmDouble* B,Element* element,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    1319         /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 5*NDOF1.
     1319        /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 5*1.
    13201320         * For node i, Bi' can be expressed in the actual coordinate system
    13211321         * by:
     
    13251325         * where h is the interpolation function for node i.
    13261326         *
    1327          * We assume B has been allocated already, of size: 3x(NDOF1*numnodes)
     1327         * We assume B has been allocated already, of size: 3x(1*numnodes)
    13281328         */
    13291329
     
    15091509}/*}}}*/
    15101510void           EnthalpyAnalysis::GetBConduct(IssmDouble* B,Element* element,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    1511         /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 5*NDOF1.
     1511        /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 5*1.
    15121512         * For node i, Bi' can be expressed in the actual coordinate system
    15131513         * by:
     
    15171517         * where h is the interpolation function for node i.
    15181518         *
    1519          * We assume B has been allocated already, of size: 3x(NDOF1*numnodes)
     1519         * We assume B has been allocated already, of size: 3x(1*numnodes)
    15201520         */
    15211521
  • issm/trunk-jpl/src/c/analyses/FreeSurfaceBaseAnalysis.cpp

    r24861 r24933  
    335335}/*}}}*/
    336336void           FreeSurfaceBaseAnalysis::GetB(IssmDouble* B,Element* element,int dim,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    337         /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*NDOF2.
     337        /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*2.
    338338         * For node i, Bi can be expressed in the actual coordinate system
    339339         * by:
     
    342342         * where N is the finiteelement function for node i.
    343343         *
    344          * We assume B_prog has been allocated already, of size: 2x(NDOF1*numnodes)
     344         * We assume B_prog has been allocated already, of size: 2x(1*numnodes)
    345345         */
    346346
     
    363363}/*}}}*/
    364364void           FreeSurfaceBaseAnalysis::GetBprime(IssmDouble* Bprime,Element* element,int dim,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    365         /*Compute B'  matrix. B'=[B1' B2' B3'] where Bi' is of size 3*NDOF2.
     365        /*Compute B'  matrix. B'=[B1' B2' B3'] where Bi' is of size 3*2.
    366366         * For node i, Bi' can be expressed in the actual coordinate system
    367367         * by:
     
    370370         * where N is the finiteelement function for node i.
    371371         *
    372          * We assume B' has been allocated already, of size: 3x(NDOF2*numnodes)
     372         * We assume B' has been allocated already, of size: 3x(2*numnodes)
    373373         */
    374374
  • issm/trunk-jpl/src/c/analyses/FreeSurfaceTopAnalysis.cpp

    r24335 r24933  
    307307}/*}}}*/
    308308void           FreeSurfaceTopAnalysis::GetB(IssmDouble* B,Element* element,int dim,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    309         /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*NDOF2.
     309        /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*2.
    310310         * For node i, Bi can be expressed in the actual coordinate system
    311311         * by:
     
    314314         * where N is the finiteelement function for node i.
    315315         *
    316          * We assume B_prog has been allocated already, of size: 2x(NDOF1*numnodes)
     316         * We assume B_prog has been allocated already, of size: 2x(1*numnodes)
    317317         */
    318318
     
    335335}/*}}}*/
    336336void           FreeSurfaceTopAnalysis::GetBprime(IssmDouble* Bprime,Element* element,int dim,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    337         /*Compute B'  matrix. B'=[B1' B2' B3'] where Bi' is of size 3*NDOF2.
     337        /*Compute B'  matrix. B'=[B1' B2' B3'] where Bi' is of size 3*2.
    338338         * For node i, Bi' can be expressed in the actual coordinate system
    339339         * by:
     
    342342         * where N is the finiteelement function for node i.
    343343         *
    344          * We assume B' has been allocated already, of size: 3x(NDOF2*numnodes)
     344         * We assume B' has been allocated already, of size: 3x(2*numnodes)
    345345         */
    346346
  • issm/trunk-jpl/src/c/analyses/GLheightadvectionAnalysis.cpp

    r24861 r24933  
    246246
    247247void           GLheightadvectionAnalysis::GetB(IssmDouble* B,Element* element,int dim,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    248         /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*NDOF2.
     248        /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*2.
    249249         * For node i, Bi can be expressed in the actual coordinate system
    250250         * by:
     
    253253         * where N is the finiteelement function for node i.
    254254         *
    255          * We assume B_prog has been allocated already, of size: 2x(NDOF1*numnodes)
     255         * We assume B_prog has been allocated already, of size: 2x(1*numnodes)
    256256         */
    257257
     
    274274}/*}}}*/
    275275void           GLheightadvectionAnalysis::GetBprime(IssmDouble* Bprime,Element* element,int dim,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    276         /*Compute B'  matrix. B'=[B1' B2' B3'] where Bi' is of size 3*NDOF2.
     276        /*Compute B'  matrix. B'=[B1' B2' B3'] where Bi' is of size 3*2.
    277277         * For node i, Bi' can be expressed in the actual coordinate system
    278278         * by:
     
    281281         * where N is the finiteelement function for node i.
    282282         *
    283          * We assume B' has been allocated already, of size: 3x(NDOF2*numnodes)
     283         * We assume B' has been allocated already, of size: 3x(2*numnodes)
    284284         */
    285285
  • issm/trunk-jpl/src/c/analyses/HydrologyDCEfficientAnalysis.cpp

    r24385 r24933  
    384384}/*}}}*/
    385385void HydrologyDCEfficientAnalysis::GetB(IssmDouble* B,Element* element,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    386         /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*NDOF2.
     386        /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*2.
    387387         * For node i, Bi can be expressed in the actual coordinate system
    388388         * by:
     
    391391         * where N is the finiteelement function for node i.
    392392         *
    393          * We assume B has been allocated already, of size: 3x(NDOF2*numnodes)
     393         * We assume B has been allocated already, of size: 3x(2*numnodes)
    394394         */
    395395
  • issm/trunk-jpl/src/c/analyses/HydrologyDCInefficientAnalysis.cpp

    r24861 r24933  
    473473}/*}}}*/
    474474void HydrologyDCInefficientAnalysis::GetB(IssmDouble* B,Element* element,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    475         /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*NDOF2.
     475        /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*2.
    476476         * For node i, Bi can be expressed in the actual coordinate system
    477477         * by:
     
    480480         * where N is the finiteelement function for node i.
    481481         *
    482          * We assume B has been allocated already, of size: 3x(NDOF2*numnodes)
     482         * We assume B has been allocated already, of size: 3x(2*numnodes)
    483483         */
    484484
  • issm/trunk-jpl/src/c/analyses/HydrologyShreveAnalysis.cpp

    r24861 r24933  
    287287}/*}}}*/
    288288void           HydrologyShreveAnalysis::GetB(IssmDouble* B,Element* element,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    289         /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*NDOF2.
     289        /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*2.
    290290         * For node i, Bi can be expressed in the actual coordinate system
    291291         * by:
     
    294294         * where N is the finiteelement function for node i.
    295295         *
    296          * We assume B_prog has been allocated already, of size: 2x(NDOF1*numnodes)
     296         * We assume B_prog has been allocated already, of size: 2x(1*numnodes)
    297297         */
    298298
     
    314314}/*}}}*/
    315315void           HydrologyShreveAnalysis::GetBprime(IssmDouble* Bprime,Element* element,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    316         /*Compute B'  matrix. B'=[B1' B2' B3'] where Bi' is of size 3*NDOF2.
     316        /*Compute B'  matrix. B'=[B1' B2' B3'] where Bi' is of size 3*2.
    317317         * For node i, Bi' can be expressed in the actual coordinate system
    318318         * by:
     
    321321         * where N is the finiteelement function for node i.
    322322         *
    323          * We assume B' has been allocated already, of size: 3x(NDOF2*numnodes)
     323         * We assume B' has been allocated already, of size: 3x(2*numnodes)
    324324         */
    325325
  • issm/trunk-jpl/src/c/analyses/StressbalanceAnalysis.cpp

    r24861 r24933  
    18151815}/*}}}*/
    18161816void           StressbalanceAnalysis::GetBSSA(IssmDouble* B,Element* element,int dim,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    1817         /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*NDOF2.
     1817        /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*2.
    18181818         * For node i, Bi can be expressed in the actual coordinate system
    18191819         * by:
     
    18241824         * where N is the finiteelement function for node i.
    18251825         *
    1826          * We assume B has been allocated already, of size: 3x(NDOF2*numnodes)
     1826         * We assume B has been allocated already, of size: 3x(2*numnodes)
    18271827         */
    18281828
     
    18921892}/*}}}*/
    18931893void           StressbalanceAnalysis::GetBSSAprime(IssmDouble* Bprime,Element* element,int dim,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    1894         /*Compute B'  matrix. B'=[B1' B2' B3'] where Bi' is of size 3*NDOF2.
     1894        /*Compute B'  matrix. B'=[B1' B2' B3'] where Bi' is of size 3*2.
    18951895         * For node i, Bi' can be expressed in the actual coordinate system
    18961896         * by:
     
    19011901         * where hNis the finiteelement function for node i.
    19021902         *
    1903          * We assume B' has been allocated already, of size: 3x(NDOF2*numnodes)
     1903         * We assume B' has been allocated already, of size: 3x(2*numnodes)
    19041904         */
    19051905
     
    28072807}/*}}}*/
    28082808void           StressbalanceAnalysis::GetBHO(IssmDouble* B,Element* element,int dim,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    2809         /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 5*NDOF2.
     2809        /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 5*2.
    28102810         * For node i, Bi can be expressed in the actual coordinate system
    28112811         * by:
     
    28192819         * where h is the interpolation function for node i.
    28202820         *
    2821          * We assume B has been allocated already, of size: 5x(NDOF2*numnodes)
     2821         * We assume B has been allocated already, of size: 5x(2*numnodes)
    28222822         */
    28232823
     
    28922892}/*}}}*/
    28932893void           StressbalanceAnalysis::GetBHOprime(IssmDouble* Bprime,Element* element,int dim,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    2894         /*Compute B'  matrix. B'=[B1' B2' B3'] where Bi' is of size 3*NDOF2.
     2894        /*Compute B'  matrix. B'=[B1' B2' B3'] where Bi' is of size 3*2.
    28952895         * For node i, Bi' can be expressed in the actual coordinate system
    28962896         * by:
     
    29012901         * where hNis the finiteelement function for node i.
    29022902         *
    2903          * We assume B' has been allocated already, of size: 3x(NDOF2*numnodes)
     2903         * We assume B' has been allocated already, of size: 3x(2*numnodes)
    29042904         */
    29052905
     
    30653065        int vnumnodes = element->NumberofNodesVelocity();
    30663066        int pnumnodes = element->NumberofNodesPressure();
    3067         int numdof    = vnumnodes*NDOF3 + pnumnodes*NDOF1;
     3067        int numdof    = vnumnodes*3 + pnumnodes*1;
    30683068
    30693069        /*Prepare coordinate system list*/
     
    45444544}/*}}}*/
    45454545void           StressbalanceAnalysis::GetBFS(IssmDouble* B,Element* element,int dim,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    4546         /*Compute B  matrix. B=[Bv1 Bv2 ... Bp1 Bp2 ...] where Bvi is of size 3*NDOF3.
     4546        /*Compute B  matrix. B=[Bv1 Bv2 ... Bp1 Bp2 ...] where Bvi is of size 3*3.
    45474547         * For node i, Bvi can be expressed in the actual coordinate system
    45484548         * by:     Bvi=[ dphi/dx          0        ]
     
    47164716}/*}}}*/
    47174717void           StressbalanceAnalysis::GetBFSprime(IssmDouble* Bprime,Element* element,int dim,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    4718         /*      Compute B'  matrix. B'=[B1' B2' B3' B4' B5' B6' Bb'] where Bi' is of size 3*NDOF2.
     4718        /*      Compute B'  matrix. B'=[B1' B2' B3' B4' B5' B6' Bb'] where Bi' is of size 3*2.
    47194719         *      For node i, Bi' can be expressed in the actual coordinate system
    47204720         *      by:
     
    48294829}/*}}}*/
    48304830void           StressbalanceAnalysis::GetBFSprimeUzawa(IssmDouble* Bprime,Element* element,int dim,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    4831         /*      Compute B'  matrix. B'=[B1' B2' B3' B4' B5' B6'] where Bi' is of size 3*NDOF2.
     4831        /*      Compute B'  matrix. B'=[B1' B2' B3' B4' B5' B6'] where Bi' is of size 3*2.
    48324832         *      For node i, Bi' can be expressed in the actual coordinate system
    48334833         *      by:
     
    48654865}/*}}}*/
    48664866void           StressbalanceAnalysis::GetBFSprimevel(IssmDouble* Bprime,Element* element,int dim,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    4867         /*      Compute B'  matrix. B'=[B1' B2' B3' B4' B5' B6' Bb'] where Bi' is of size 3*NDOF2.
     4867        /*      Compute B'  matrix. B'=[B1' B2' B3' B4' B5' B6' Bb'] where Bi' is of size 3*2.
    48684868         *      For node i, Bi' can be expressed in the actual coordinate system
    48694869         *      by:
     
    49504950}/*}}}*/
    49514951void           StressbalanceAnalysis::GetBFSvel(IssmDouble* B,Element* element,int dim,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    4952         /*Compute B  matrix. B=[Bv1 Bv2 ... Bp1 Bp2 ...] where Bvi is of size 3*NDOF3.
     4952        /*Compute B  matrix. B=[Bv1 Bv2 ... Bp1 Bp2 ...] where Bvi is of size 3*3.
    49534953         * For node i, Bvi can be expressed in the actual coordinate system
    49544954         * by:     Bvi=[ dphi/dx          0        ]
     
    67176717}/*}}}*/
    67186718void           StressbalanceAnalysis::GetBprimeSSAFS(IssmDouble* Bprime,Element* element,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    6719         /*Compute Bprime  matrix. Bprime=[Bprime1 Bprime2 Bprime3 Bprime4 Bprime5 Bprime6] where Bprimei is of size 5*NDOF2.
     6719        /*Compute Bprime  matrix. Bprime=[Bprime1 Bprime2 Bprime3 Bprime4 Bprime5 Bprime6] where Bprimei is of size 5*2.
    67206720         * For node i, Bprimei can be expressed in the actual coordinate system
    67216721         * by:
     
    67256725         * where h is the interpolation function for node i.
    67266726         *
    6727          * We assume Bprime has been allocated already, of size: 5x(NDOF2*NUMNODESP1)
     6727         * We assume Bprime has been allocated already, of size: 5x(2*NUMNODESP1)
    67286728         */
    67296729
     
    67666766}/*}}}*/
    67676767void           StressbalanceAnalysis::GetBprimeSSAFSTria(IssmDouble* Bprime,Element* element,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    6768         /*Compute Bprime  matrix. Bprime=[Bprime1 Bprime2 Bprime3] where Bprimei is of size 3*NDOF2.
     6768        /*Compute Bprime  matrix. Bprime=[Bprime1 Bprime2 Bprime3] where Bprimei is of size 3*2.
    67696769         * For node i, Bprimei can be expressed in the actual coordinate system
    67706770         * by:
     
    67756775         * where N is the finiteelement function for node i.
    67766776         *
    6777          * We assume Bprime has been allocated already, of size: 3x(NDOF2*numnodes)
     6777         * We assume Bprime has been allocated already, of size: 3x(2*numnodes)
    67786778         */
    67796779
     
    68016801}/*}}}*/
    68026802void           StressbalanceAnalysis::GetBSSAFS(IssmDouble* B,Element* element,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    6803         /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 5*NDOF2.
     6803        /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 5*2.
    68046804         * For node i, Bi can be expressed in the actual coordinate system
    68056805         * by:
     
    68106810         * where h is the interpolation function for node i.
    68116811         *
    6812          * We assume B has been allocated already, of size: 5x(NDOF2*NUMNODESP1)
     6812         * We assume B has been allocated already, of size: 5x(2*NUMNODESP1)
    68136813         */
    68146814
     
    68596859}/*}}}*/
    68606860void           StressbalanceAnalysis::GetBSSAFSTria(IssmDouble* B,Element* element,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    6861         /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*NDOF2.
     6861        /*Compute B  matrix. B=[B1 B2 B3] where Bi is of size 3*2.
    68626862         * For node i, Bi can be expressed in the actual coordinate system
    68636863         * by:
     
    68676867         * where N is the finiteelement function for node i.
    68686868         *
    6869          * We assume B has been allocated already, of size: 3x(NDOF2*numnodes)
     6869         * We assume B has been allocated already, of size: 3x(2*numnodes)
    68706870         */
    68716871
     
    68916891}/*}}}*/
    68926892void           StressbalanceAnalysis::GetBSSAHO(IssmDouble* B,Element* element,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    6893         /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 3*NDOF2.
     6893        /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 3*2.
    68946894         * For node i, Bi can be expressed in the actual coordinate system
    68956895         * by:
     
    68996899         * where h is the interpolation function for node i.
    69006900         *
    6901          * We assume B has been allocated already, of size: 5x(NDOF2*NUMNODESP1)
     6901         * We assume B has been allocated already, of size: 5x(2*NUMNODESP1)
    69026902         */
    69036903
  • issm/trunk-jpl/src/c/analyses/StressbalanceSIAAnalysis.cpp

    r24861 r24933  
    589589        /*Ok, we have vx and vy in values, fill in vx and vy arrays: */
    590590        for(i=0;i<numnodes;i++){
    591                 vx[i]=values[i*NDOF2+0];
    592                 vy[i]=values[i*NDOF2+1];
     591                vx[i]=values[i*2+0];
     592                vy[i]=values[i*2+1];
    593593
    594594                /*Check solution*/
  • issm/trunk-jpl/src/c/analyses/ThermalAnalysis.cpp

    r24861 r24933  
    746746}/*}}}*/
    747747void           ThermalAnalysis::GetBAdvec(IssmDouble* B,Element* element,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    748         /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 5*NDOF1.
     748        /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 5*1.
    749749         * For node i, Bi' can be expressed in the actual coordinate system
    750750         * by:
     
    754754         * where h is the interpolation function for node i.
    755755         *
    756          * We assume B has been allocated already, of size: 3x(NDOF1*NUMNODESP1)
     756         * We assume B has been allocated already, of size: 3x(1*NUMNODESP1)
    757757         */
    758758
     
    775775}/*}}}*/
    776776void           ThermalAnalysis::GetBAdvecprime(IssmDouble* B,Element* element,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    777         /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 5*NDOF1.
     777        /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 5*1.
    778778         * For node i, Bi' can be expressed in the actual coordinate system
    779779         * by:
     
    783783         * where h is the interpolation function for node i.
    784784         *
    785          * We assume B has been allocated already, of size: 3x(NDOF1*numnodes)
     785         * We assume B has been allocated already, of size: 3x(1*numnodes)
    786786         */
    787787
     
    804804}/*}}}*/
    805805void           ThermalAnalysis::GetBConduct(IssmDouble* B,Element* element,IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    806         /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 5*NDOF1.
     806        /*Compute B  matrix. B=[B1 B2 B3 B4 B5 B6] where Bi is of size 5*1.
    807807         * For node i, Bi' can be expressed in the actual coordinate system
    808808         * by:
     
    812812         * where h is the interpolation function for node i.
    813813         *
    814          * We assume B has been allocated already, of size: 3x(NDOF1*numnodes)
     814         * We assume B has been allocated already, of size: 3x(1*numnodes)
    815815         */
    816816
  • issm/trunk-jpl/src/c/classes/Elements/Penta.cpp

    r24861 r24933  
    26862686void       Penta::InputUpdateFromSolutionOneDofCollapsed(IssmDouble* solution,int enum_type){/*{{{*/
    26872687
    2688         const int  numdof   = NDOF1*NUMVERTICES;
    2689         const int  numdof2d = NDOF1*NUMVERTICES2D;
     2688        const int  numdof   = NUMVERTICES;
     2689        const int  numdof2d = NUMVERTICES2D;
    26902690
    26912691        IssmDouble  values[numdof];
     
    27262726void       Penta::InputUpdateFromVector(IssmDouble* vector, int name, int type){/*{{{*/
    27272727
    2728         const int   numdof         = NDOF1 *NUMVERTICES;
     2728        const int   numdof         = NUMVERTICES;
    27292729        int        *doflist        = NULL;
    27302730        IssmDouble  values[numdof];
  • issm/trunk-jpl/src/c/classes/Elements/PentaRef.cpp

    r22078 r24933  
    191191void PentaRef::GetJacobian(IssmDouble* J, IssmDouble* xyz_list,Gauss* gauss_in){/*{{{*/
    192192        /*The Jacobian is constant over the element, discard the gaussian points.
    193          * J is assumed to have been allocated of size NDOF2xNDOF2.*/
     193         * J is assumed to have been allocated of size 2x2.*/
    194194
    195195        IssmDouble A1,A2,A3;  // area coordinates
     
    235235        j_const_reciprocal=SQRT3/12;
    236236
    237         J[NDOF3*0+0] = 0.25*(x1-x2-x4+x5)*zi+0.25*(-x1+x2-x4+x5);
    238         J[NDOF3*1+0] = j_const_reciprocal*(x1+x2-2*x3-x4-x5+2*x6)*zi+j_const_reciprocal*(-x1-x2+2*x3-x4-x5+2*x6);
    239         J[NDOF3*2+0] = j_const_reciprocal*(x1+x2-2*x3-x4-x5+2*x6)*eta+0.25*(x1-x2-x4+x5)*xi +0.25*(-x1+x5-x2+x4);
    240 
    241         J[NDOF3*0+1] = 0.25*(y1-y2-y4+y5)*zi+0.25*(-y1+y2-y4+y5);
    242         J[NDOF3*1+1] = j_const_reciprocal*(y1+y2-2*y3-y4-y5+2*y6)*zi+j_const_reciprocal*(-y1-y2+2*y3-y4-y5+2*y6);
    243         J[NDOF3*2+1] = j_const_reciprocal*(y1+y2-2*y3-y4-y5+2*y6)*eta+0.25*(y1-y2-y4+y5)*xi+0.25*(y4-y1+y5-y2);
    244 
    245         J[NDOF3*0+2] = 0.25*(z1-z2-z4+z5)*zi+0.25*(-z1+z2-z4+z5);
    246         J[NDOF3*1+2] = j_const_reciprocal*(z1+z2-2*z3-z4-z5+2*z6)*zi+j_const_reciprocal*(-z1-z2+2*z3-z4-z5+2*z6);
    247         J[NDOF3*2+2] = j_const_reciprocal*(z1+z2-2*z3-z4-z5+2*z6)*eta+0.25*(z1-z2-z4+z5)*xi+0.25*(-z1+z5-z2+z4);
     237        J[3*0+0] = 0.25*(x1-x2-x4+x5)*zi+0.25*(-x1+x2-x4+x5);
     238        J[3*1+0] = j_const_reciprocal*(x1+x2-2*x3-x4-x5+2*x6)*zi+j_const_reciprocal*(-x1-x2+2*x3-x4-x5+2*x6);
     239        J[3*2+0] = j_const_reciprocal*(x1+x2-2*x3-x4-x5+2*x6)*eta+0.25*(x1-x2-x4+x5)*xi +0.25*(-x1+x5-x2+x4);
     240
     241        J[3*0+1] = 0.25*(y1-y2-y4+y5)*zi+0.25*(-y1+y2-y4+y5);
     242        J[3*1+1] = j_const_reciprocal*(y1+y2-2*y3-y4-y5+2*y6)*zi+j_const_reciprocal*(-y1-y2+2*y3-y4-y5+2*y6);
     243        J[3*2+1] = j_const_reciprocal*(y1+y2-2*y3-y4-y5+2*y6)*eta+0.25*(y1-y2-y4+y5)*xi+0.25*(y4-y1+y5-y2);
     244
     245        J[3*0+2] = 0.25*(z1-z2-z4+z5)*zi+0.25*(-z1+z2-z4+z5);
     246        J[3*1+2] = j_const_reciprocal*(z1+z2-2*z3-z4-z5+2*z6)*zi+j_const_reciprocal*(-z1-z2+2*z3-z4-z5+2*z6);
     247        J[3*2+2] = j_const_reciprocal*(z1+z2-2*z3-z4-z5+2*z6)*eta+0.25*(z1-z2-z4+z5)*xi+0.25*(-z1+z5-z2+z4);
    248248}
    249249/*}}}*/
     
    10901090void PentaRef::GetSegmentJacobianDeterminant(IssmDouble*  Jdet, IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    10911091        /*The Jacobian determinant is constant over the element, discard the gaussian points.
    1092          * J is assumed to have been allocated of size NDOF2xNDOF2.*/
     1092         * J is assumed to have been allocated of size 2x2.*/
    10931093
    10941094        IssmDouble x1=xyz_list[3*0+0];
     
    11061106void PentaRef::GetTriaJacobianDeterminant(IssmDouble*  Jdet, IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    11071107        /*The Jacobian determinant is constant over the element, discard the gaussian points.
    1108          * J is assumed to have been allocated of size NDOF2xNDOF2.*/
     1108         * J is assumed to have been allocated of size 2x2.*/
    11091109
    11101110        IssmDouble x1=xyz_list[3*0+0];
  • issm/trunk-jpl/src/c/classes/Elements/SegRef.cpp

    r20515 r24933  
    9393void SegRef::GetJacobianDeterminant(IssmDouble*  Jdet, IssmDouble* xyz_list,GaussSeg* gauss){/*{{{*/
    9494        /*The Jacobian determinant is constant over the element, discard the gaussian points.
    95          * J is assumed to have been allocated of size NDOF2xNDOF2.*/
     95         * J is assumed to have been allocated of size 1.*/
    9696
    9797        /*Call Jacobian routine to get the jacobian:*/
  • issm/trunk-jpl/src/c/classes/Elements/TetraRef.cpp

    r20515 r24933  
    110110        IssmDouble z4=xyz_list[3*3+2];
    111111
    112         J[NDOF3*0+0] = x2-x1;
    113         J[NDOF3*0+1] = y2-y1;
    114         J[NDOF3*0+2] = z2-z1;
    115 
    116         J[NDOF3*1+0] = x3-x1;
    117         J[NDOF3*1+1] = y3-y1;
    118         J[NDOF3*1+2] = z3-z1;
    119 
    120         J[NDOF3*2+0] = x4-x1;
    121         J[NDOF3*2+1] = y4-y1;
    122         J[NDOF3*2+2] = z4-z1;
     112        J[3*0+0] = x2-x1;
     113        J[3*0+1] = y2-y1;
     114        J[3*0+2] = z2-z1;
     115
     116        J[3*1+0] = x3-x1;
     117        J[3*1+1] = y3-y1;
     118        J[3*1+2] = z3-z1;
     119
     120        J[3*2+0] = x4-x1;
     121        J[3*2+1] = y4-y1;
     122        J[3*2+2] = z4-z1;
    123123}
    124124/*}}}*/
    125125void TetraRef::GetJacobianDeterminant(IssmDouble*  Jdet, IssmDouble* xyz_list,GaussTetra* gauss){/*{{{*/
    126126        /*The Jacobian determinant is constant over the element, discard the gaussian points.
    127          * J is assumed to have been allocated of size NDOF2xNDOF2.*/
     127         * J is assumed to have been allocated of size 2x2.*/
    128128        IssmDouble J[3][3];
    129129
     
    139139void TetraRef::GetJacobianDeterminantFace(IssmDouble*  Jdet, IssmDouble* xyz_list,GaussTetra* gauss){/*{{{*/
    140140        /*The Jacobian determinant is constant over the element, discard the gaussian points.
    141          * J is assumed to have been allocated of size NDOF2xNDOF2.*/
     141         * J is assumed to have been allocated of size 2x2.*/
    142142
    143143        IssmDouble x1=xyz_list[3*0+0];
  • issm/trunk-jpl/src/c/classes/Elements/TriaRef.cpp

    r24240 r24933  
    9090void TriaRef::GetJacobian(IssmDouble* J, IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    9191        /*The Jacobian is constant over the element, discard the gaussian points.
    92          * J is assumed to have been allocated of size NDOF2xNDOF2.*/
     92         * J is assumed to have been allocated of size 2x2.*/
    9393
    9494        IssmDouble x1 = xyz_list[3*0+0];
     
    107107void TriaRef::GetJacobianDeterminant(IssmDouble* Jdet, IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    108108        /*The Jacobian determinant is constant over the element, discard the gaussian points.
    109          * J is assumed to have been allocated of size NDOF2xNDOF2.*/
     109         * J is assumed to have been allocated of size 2x2.*/
    110110        IssmDouble J[2][2];
    111111
     
    121121void TriaRef::GetJacobianDeterminant3D(IssmDouble* Jdet, IssmDouble* xyz_list,Gauss* gauss){/*{{{*/
    122122        /*The Jacobian determinant is constant over the element, discard the gaussian points.
    123          * J is assumed to have been allocated of size NDOF2xNDOF2.*/
     123         * J is assumed to have been allocated of size 2x2.*/
    124124        IssmDouble J[2][2];
    125125
  • issm/trunk-jpl/src/c/classes/Loads/Penpair.cpp

    r23959 r24933  
    290290ElementMatrix* Penpair::PenaltyCreateKMatrixMasstransport(IssmDouble kmax){/*{{{*/
    291291
    292         const int numdof=NUMVERTICES*NDOF1;
     292        const int numdof=NUMVERTICES*1;
    293293        IssmDouble penalty_factor;
    294294
  • issm/trunk-jpl/src/c/classes/Loads/Riftfront.cpp

    r24861 r24933  
    431431ElementMatrix* Riftfront::PenaltyCreateKMatrixStressbalanceHoriz(IssmDouble kmax){/*{{{*/
    432432
    433         const int   numdof = NDOF2*NUMVERTICES;
     433        const int   numdof = 2*NUMVERTICES;
    434434        IssmDouble  thickness;
    435435        IssmDouble  h[2];
  • issm/trunk-jpl/src/c/shared/Numerics/constants.h

    r24593 r24933  
    1111const double PI=3.141592653589793238462643383279502884197169399375105820974944592308; // Macro definition conflicts with Dakota's declaration of PI
    1212
    13 #define NDOF1 1
    14 #define NDOF2 2
    15 #define NDOF3 3
    16 #define NDOF4 4
    17 
    18 // /*Windows specific typefefs: */
    19 // #ifdef _INTEL_WIN_
    20 //
    21 // #ifndef NAN
    22 // //For reference, for Intel compile on win64
    23 // //#define NAN 0.0/0.0
    24 // #define NAN (INFINITY-INFINITY)
    25 // #endif
    26 //
    27 // #ifndef INFINITY
    28 // //For reference, for Intel compile on win64
    29 // //#define INFINITY 1.0/0.0
    30 // #define INFINITY (DBL_MAX+DBL_MAX)
    31 // #endif
    32 //
    33 // #endif /*_INTEL_WIN_*/
    34 
    3513#endif /*_ISSM_CONSTANTS_H_*/
Note: See TracChangeset for help on using the changeset viewer.