Ignore:
Timestamp:
08/19/11 18:04:03 (14 years ago)
Author:
Eric.Larour
Message:

Major rewrite of the code so that IoModel now has a parameters dataset, which gets
loaded with all the int,char and double objects in the input file.
This is a lot more flexible, as anyone can add a field to the model, and it will
automatically appear in the IoModel parameters dataset.

Not debugged with respect to nightly runs yet. Trying to get the whole change finished.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk/src/c/modules/AverageOntoPartitionx/AverageOntoPartitionx.cpp

    r9320 r9356  
    2424        int     dummy;
    2525
    26         int     qmu_npart;
     26        int     npart;
    2727        double *qmu_part  = NULL;
    2828        int     numberofvertices;
     
    3939        /*Some parameters: */
    4040        numberofvertices=vertices->NumberOfVertices();
    41         parameters->FindParam(&qmu_npart,QmuNPartEnum);
     41        parameters->FindParam(&npart,NpartEnum);
    4242
    4343        /*average onto the separate areas. The result will be a npart sized vector. */
    4444
    4545        /*allocate: */
    46         partition_contributions=NewVec(qmu_npart);
    47         partition_areas=NewVec(qmu_npart);
    48         vec_average=NewVec(qmu_npart);
     46        partition_contributions=NewVec(npart);
     47        partition_areas=NewVec(npart);
     48        vec_average=NewVec(npart);
    4949
    5050        /*loop on each element, and add contribution of the element to the partition (surface weighted average): */
Note: See TracChangeset for help on using the changeset viewer.