To detect tensile and compressive stresses in a 3D stress state, understanding the strain is crucial, as positive strain indicates tension and negative strain indicates compression. The discussion highlights the importance of the stress tensor, which comprises normal and shear stresses, and suggests using the deviator stress tensor to analyze the stress state. The conversation also emphasizes the need for a scalar parameter to differentiate between tensile and compressive responses, particularly in pressure-dependent materials like soil and rock. Additionally, the loading history and pore pressure effects in geotechnical materials are significant factors in stress analysis. A comprehensive understanding of rock and soil mechanics is essential for developing accurate failure criteria and modeling erosion in these materials.