File size: 3,462 Bytes
d22f9ea
 
 
 
 
 
 
 
 
 
 
 
bbb6cc7
d22f9ea
 
 
bbb6cc7
 
d22f9ea
 
 
 
bbb6cc7
 
 
 
 
 
 
 
 
 
 
d22f9ea
 
bbb6cc7
d22f9ea
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
bbb6cc7
 
d22f9ea
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
# Same strain, different stress

![Two zero-strain states](example/material-memory.png)

The material returns to zero total strain twice. Its stress does not return to
the same value: **−481.3 MPa at A, +551.1 MPa at B**. Plastic strain has changed
between the two states. A model that sees only the current strain and material
parameters cannot distinguish them.

## Run it

```sh
pip install numpy matplotlib huggingface_hub
python show_material_memory.py
```

Download [the script](show_material_memory.py) first. It fetches a **4.5 KB training
excerpt**, checks its SHA-256, and produces a PNG, a CSV
containing all 121 states, and a JSON evidence record. The figure displays
states 0–60 so the two returns are easy to follow. No solver, GPU, model weights
or paid service is required.

The excerpt contains the four unchanged arrays used here, including the complete
strain tensors. It is a lossless copy from the pinned original shard, not a new
simulation or an extra dataset sample. Source provenance stays in the output.

For offline use, also download [the small excerpt](example/training-history-00252.npz):

```sh
python show_material_memory.py --sample training-history-00252.npz
```

Already have the original data? Install `h5py` to read its HDF5 shard:

```sh
pip install h5py
python show_material_memory.py --shard data/t2_material_loading_memory_v1/shards/part-00002.h5
```

## What the figure means

This is synthetic J2 plasticity under prescribed **proportional deviatoric
strain**, not a uniaxial tensile test. The vertical axis uses the dataset's
signed equivalent stress, not the always-positive von Mises stress. The
horizontal loading-state index is not physical time.

The example uses training trajectory `00252`, the first training member of the
symmetric-cyclic J2 cohort. A and B are its first two noninitial returns to zero
strain (states 36 and 60); they were not chosen by maximizing the stress gap.
All nine components of their total-strain tensors match within `1e-12`. Their
accumulated equivalent plastic strains are approximately 0.01042 and 0.02210.
The input data are unchanged; no interpolation, training or neural prediction
is performed. This demonstrates why history matters, not DENIM accuracy.

Try a prediction before running: will B have the same stress as A, zero stress,
or stress of the opposite sign? Then inspect the CSV to trace how it got there.

## 中文

材料两次回到零应变,应力却分别为 **−481.3 MPa 和 +551.1 MPa**。
原因是中间发生了塑性变形,材料内部状态已经改变。只告诉模型“现在的应变”,
不足以确定此刻的应力,还需要加载历史或内部状态。

这是合成材料点数据中的一个训练样本,不是实测数据,也不是 DENIM 的预测结果。
运行脚本只需下载 4.5 KB 的训练样本摘录,即可生成图、完整历程表和校验记录。
摘录与原数据逐项一致,不新增样本。图中使用有符号等效应力;加载步
不是实际时间。没有读取封存测试集,也没有修改训练、验证或测试划分。

[Explore the interactive lab](https://lab.haoming-luo.com/material-memory/) ·
[DENIM model](https://huggingface.co/HaomingLuo/AgentFEM-DENIM) ·
[AgentFEM](https://github.com/haoming-luo/agentfem)

Data: Haoming Luo / AgentFEM, CC BY 4.0. Code: Apache-2.0, see `CODE_LICENSE`.
Pinned source revision and checksum are included in the script and JSON output.