Study Matlab Script

1 minute read

Workflow Overview

graph TB node1(Load Variables From Workspace) click node1 "#1" node1(Load Variables From Workspace) --> node2(Obtain 2-Point Statistics) click node2 "#2" node2(Obtain 2-Point Statistics) --> node3(PCA) click node3 "#3" node3(PCA) --> node4(Function Estimation) click node4 "#4"


Obtain the direct to Project-Pages publish function here.

Load Variables From Workspace

Loading the microstructures and the effective property.

1
2
3
4
load GDL200Volumes.mat
load MPL290Volumes.mat
load EffectiveProperty290MPL200GDLinThatOrder.mat

Obtain 2-Point Statistics

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
GG = zeros(490,49^3);

for i=1:290
    current = MPL{i};
    GGcurrent = TwoPointMaster('full','auto',25,current);
    GG(i,:) = GGcurrent(:)/numel(current);
    PP(i)=GGcurrent(25,25,25)/numel(current);
end

for i=1:200
    current = GDL{i};
    GGcurrent = TwoPointMaster('full','auto',25,current);
    GG(i+290,:) = GGcurrent(:)/numel(current);
    PP(i+290)=GGcurrent(25,25,25)/numel(current);
end

PCA

Via SVD:

1
2
3
[PC1,Var1,Basis1]=PCAConstruct(GG,10);
scatter(PC1(:,1),PC1(:,2),30,[ones(290,1);2*ones(200,1)],'filled'); colormap jet;

Function Estimation

Using Multivariate Polynomial Regression

1
2
reg = MultiPolyRegress(PC1(:,1:2),R,3,'figure')
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
reg = 

           FitParameters: '-----------------'
             PowerMatrix: [10x2 double]
                  Scores: [490x10 double]
    PolynomialExpression: [10x2 table]
            Coefficients: [10x1 double]
                    yhat: [490x1 double]
               Residuals: [490x1 double]
           GoodnessOfFit: '-----------------'
                 RSquare: 0.9572
                     MAE: 0.0571
                  MAESTD: 0.0561
           Normalization: '1-to-1 (Default)'
      LOOCVGoodnessOfFit: '-----------------'
               CVRSquare: 0.9556
                   CVMAE: 0.0583
                CVMAESTD: 0.0570
         CVNormalization: '1-to-1 (Default)'



Published with MATLABĀ® R2014b