Changeset 22069


Ignore:
Timestamp:
09/12/17 15:18:30 (8 years ago)
Author:
schlegel
Message:

CHG: allow dakota to sample element vectors

Location:
issm/trunk-jpl/src
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk-jpl/src/m/classes/qmu.m

    r20690 r22069  
    6565                        end
    6666                        if ~isempty(md.qmu.partition),
    67                                 if numel(md.qmu.partition)~=md.mesh.numberofvertices,
    68                                         md = checkmessage(md,['user supplied partition for qmu analysis should have size md.mesh.numberofvertices x 1 ']);
     67                                if numel(md.qmu.partition)~=md.mesh.numberofvertices & numel(md.qmu.partition)~=md.mesh.numberofelements,
     68                                        md = checkmessage(md,['user supplied partition for qmu analysis should have size md.mesh.numberofvertices x 1 or md.mesh.numberofelements x 1']);
    6969                                end
    7070                                if min(md.qmu.partition)~=0,
  • issm/trunk-jpl/src/m/modules/MeshPartition.m

    r20875 r22069  
    1 function [element_partitioning, node_partitioning] = MeshPartition(md.mesh,numpartitions);
     1function [element_partitioning, node_partitioning] = MeshPartition(md,numpartitions)
    22%MESHPARTITION - Partition mesh according to the number of areas, using Metis library.
    33%
  • issm/trunk-jpl/src/m/partition/partitioner.m

    r21905 r22069  
    9090elseif strcmpi(package,'linear'),
    9191
    92         part=1:1:md.mesh.numberofvertices;
     92        if npart==md.mesh.numberofelements | md.qmu.numberofpartitions==md.mesh.numberofelements
     93                part=1:1:md.mesh.numberofelements;
     94                disp('Linear partitioner requesting partitions on elements');
     95        else
     96                part=1:1:md.mesh.numberofvertices;
     97        end
    9398
    9499elseif strcmpi(package,'metis'),
    95100
    96         [element_partitioning,part]=MeshPartition(md.mesh,md.qmu.numberofpartitions);
     101        [element_partitioning,part]=MeshPartition(md,md.qmu.numberofpartitions);
    97102
    98103else
  • issm/trunk-jpl/src/wrappers/MeshPartition/MeshPartition.cpp

    r21932 r22069  
    5656                FetchData(&numberoflayers,mxGetAssignedField(MESH,0,"numberoflayers"));
    5757        }
    58         else if(strcmp(mxGetClassName(MESH),"mesh2dhorizontal")==0){
     58        else if(strcmp(mxGetClassName(MESH),"mesh2d")==0){
    5959                meshelementtype = TriaEnum;
    6060                numberoflayers=1;
Note: See TracChangeset for help on using the changeset viewer.