solve or inv starts

This commit is contained in:
Youmu Liu
2026-01-13 18:25:25 +08:00
parent ad3b2212fa
commit f133cc9147
11 changed files with 103 additions and 147 deletions
+7 -7
View File
@@ -35,14 +35,14 @@ using System.Numerics;
using System.Text;
using System.Threading.Tasks;
using T = double;
using T = float;
namespace StgSharp
{
internal static partial class Program
{
private static int sideLength = 400;
private static int sideLength = 20;
internal static unsafe void TestMatrix(
)
@@ -76,21 +76,21 @@ namespace StgSharp
Console.WriteLine("===================================================");
MatrixCompute.Mul(n, m, p);
/**/
for (int i = 0; i < 400; i++)
for (int i = 0; i < 20; i++)
{
if (i % 4 == 0) {
Console.WriteLine();
}
for (int j = 0; j < 30; j++)
for (int j = 0; j < 20; j++)
{
string extra = j % 4 == 3 ? " " : " ";
string extra = j % 4 == 3 ? " " : ",";
T value = p[j, i];
// value = T.Abs(value) < 1e-6 ? 0 : value;
// Console.Write($"{p.GetElementOffset(j,i)}{extra}");
Console.Write($"{p.GetElementOffset(j,i)}{extra}");
Console.Write($"{value:000}{extra}");
// Console.Write($"{value:000}{extra}");
}
Console.WriteLine();
}