nnutil.jl:
ARGS[1]: nntype: 
         piecewise piecewise2 ae_scale
ARGS[2]: idx
         number of nn hidden layers 1, 2, 3



NNLearn.jl: Direct learn
i.e. julia NNLearn.jl piecewise 3 

NNPreLSfit.jl: estimate stress by assuming it is constant in each element and direct fit
i.e. julia NNPreLSfit.jl piecewise 3

Train_NNTrussPull_Plasticity.jl: Train nn from indirect data (can restart from NNPreLSfit results)
i.e. julia Train_NNTrussPull_Plasticity.jl piecewise 3

Test_NNTrussPull_Plasticity.jl Test tid=3, need to change ite number
i.e. julia Test_NNTrussPull_Plasticity.jl piecewise 3





To reproduce plots in the paper, 

./GenerateData.sh
./NNLearn.sh
./NNLearn_Plot.sh

The true parameters 
rho = 8000kg/m^3       E=200GPa   sigmaY=0.3GPa    K=200/9GPa     L=1m      A0=0.005m^2  T=0.2s   F =sin(pi*t/T) * (0.4*tid + 1.6) 10^6 N

we use unit kg, m, ms, Pa=kg/m s^2 = 1/10^6 kg/m ms^2,   N =kg m/s^2= 1/10^6 kg/m ms^2
rho = 8000     E=200e3    sigmaY=0.3e3    K=200/9e3     L=1      A0=0.005  T=200   F=sin(pi*t/T) * (0.4*tid + 1.6)

Scaling about NN
strain_scale = 1e-3  stress_scale = 100   (stress_scale/strain_scale ~ E,   strain/strain_scale ~ 1)

Transition function
\tilde{sigmaY}=0.1e3
H = sigmoid(stress^2 - \tilde{sigmaY}^2) ~ (10^4)

  










