Changeset 4202 for issm/trunk


Ignore:
Timestamp:
06/24/10 15:24:24 (15 years ago)
Author:
Mathieu Morlighem
Message:

Fixed matlab readdata

Location:
issm/trunk/src/m/classes/public
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk/src/m/classes/public/ReadData.m

    r4196 r4202  
    2727        elseif type==3,
    2828                N=fread(fid,1,'int');
    29                 field=fread(fid,M*N,'double');
     29                field=fread(fid,[M N],'double');
     30        else
     31                error(['cannot read data of type ' num2str(type) ]);
    3032        end
    3133
  • issm/trunk/src/m/classes/public/isresultconsistent.m

    r3994 r4202  
    2626
    2727%DIAGNOSTIC
    28 if analysis_type==DiagnosticAnalysisEnum() & md.control_analysis==0,
     28if analysis_type==DiagnosticSolutionEnum() & md.control_analysis==0,
    2929
    3030        if (md.dim==3)
     
    5959
    6060%CONTROL
    61 if analysis_type==DiagnosticAnalysisEnum() & md.control_analysis==1,
     61if analysis_type==DiagnosticSolutionEnum() & md.control_analysis==1,
    6262
    6363        if ~md.cm_gradient,
     
    118118
    119119%THERMAL
    120 if analysis_type==ThermalAnalysisEnum(),
     120if analysis_type==ThermalSolutionEnum(),
    121121
    122122        for iter=1:length(md.results.ThermalAnalysis)
     
    154154end
    155155
    156 if analysis_type==TransientAnalysisEnum(),
     156if (analysis_type==Transient2DSolutionEnum() | analysis_type==Transient3DSolutionEnum()),
    157157
    158158        for iter=1:length(md.results.TransientAnalysis)
  • issm/trunk/src/m/classes/public/loadresultsfromdisk.m

    r3923 r4202  
    2020        %load results onto model
    2121        structure=parseresultsfromdisk(filename);
    22         md.results.(structure.analysis_type)=structure;
     22        md.results.(structure.SolutionType)=structure;
    2323
    2424        %recover analysis_type from results
    25         md.analysis_type=structure(1).analysis_type;
     25        md.analysis_type=structure(1).SolutionType;
    2626        if isscalar(md.sub_analysis_type),
    2727                md.sub_analysis_type=EnumAsString(md.sub_analysis_type);
     
    3030        %Check result is consistent, only if it exists
    3131        disp(sprintf('%s\n','checking result consistency'));
    32         if ~isresultconsistent(md,structure(1).analysis_type),
     32        if ~isresultconsistent(md,structure(1).SolutionType),
    3333                %it would be very cruel to use an error, it would kill the computed results (although they are not consistent...)
    3434                disp('!! results not consistent correct the model !!')
Note: See TracChangeset for help on using the changeset viewer.