janhardo

935 Reputation

13 Badges

11 years, 360 days
B. Ed math

MaplePrimes Activity


These are replies submitted by janhardo

@Harry Garst 


groeten Jan

@Harry Garst 
I tried some examples , much more need to be  tested.
matrixcalus_module_6-5-2026.mw

@Harry Garst 

I've created a MatrixCalculus module and focused on statistics as well. 
Attached a list of the features, but I have no idea if it works with real-world examples.

overzicht_mogelijkeheden_MatricCalculus_module.mw

@Harry Garst 

That doesn't surprise me at all; in Maple, too, there are ongoing developments in the mathematical topics that are implemented in the software.
That will always be the case as new mathematical knowledge is developed for theoretical or practical applications

AI is a great tool for researchers to ask questions.

I’ve also been working on that VEC operator and created a module for it that works structurally the same way as the Kronecker module.
I have no idea what the application is yet, but Kronecker products are also used in it.
Just for curosity. 

Groeten Jan

@Harry Garst 
I can do that for public use, why  not?

 groeten  Jan

How do I evaluate a simplified expression and determine the dimension matrix from module code?

kroneckerproducts_module_with_dimensioncheckDEF_5-5-2026_.mw

Examine the mixed Kronecker expression ?
kroneckerproducts_module_with_dimensioncheck__4-5-2026.mw

Module has dimensioncheck for numeric use and symbolic use a dimension warning

Check this in Linear Algebra 
Your example is correct , because  X and Y do have the right dimensions

Experiment with dimensions  

restart;
with(LinearAlgebra):

# =========================================================
# Kies afmetingen zodat de regel geldt:
#   X is een kolomvector (n×1)
#   Y is een rijvector   (1×m)
# =========================================================
# A : p × n          (p willekeurig)
# X : n × 1          (kolomvector)
# Y : 1 × m          (rijvector)
# B : m × q          (q willekeurig)
p := 3;
n := 2;
m := 4;
q := 2;

A := Matrix(p, n, symbol = a);
X := Matrix(n, 1, symbol = x);
Y := Matrix(1, m, symbol = y);
B := Matrix(m, q, symbol = b);

# Linker- en rechterlid van de identiteit
L := A . (KroneckerProduct(X, Y)) . B;
R := KroneckerProduct(A . X, Y . B);

# Verschil (moet een nulmatrix zijn)
Verschil := simplify(L - R);
print(Verschil);

@Harry Garst 

This mixed Kronecker expression is a special case; the same seems to apply to the module code
The module code does not yet check the dimensions of the simplified expressions, but it could.(i  add this later)

The question you’re asking is a tricky one, but hopefully this answer will be helpful
You can use the procedure to check the input for dimensions, and with this knowledge, you can also check this in a linear algebra package.

gemixed_produkt_expressie_voorwaarden_dimensie_controle_en_uitleg_3-5-2026.mw

@Harry Garst 

You try to check rule 7 ...
I used the Kron notation, easier to read

Download vraag-_Is_this_correct_mprimes_3-5-2026.mw


 

 

restart;
with(plots): with(plottools):

# ------------------------------------------------------------
# 1. PRINT THE MATHEMATICAL DERIVATION
# ------------------------------------------------------------
print("Why does stacking these triangles produce a logarithmic spiral?");
print("Definition: Z(0) = 8, Z(1) = 8*(1/4 + I*sqrt(3)/4) = 2+2*I*sqrt(3)");
print("Recurrence: Z(n) = Z(n-1) * (1/4 + I*sqrt(3)/4)");
print("Modulus of the factor = 1/2, argument = Pi/3 (60°)");
print("So |Z(n)| = 8*(1/2)^n, arg(Z(n)) = n*Pi/3");
print("In polar coordinates: r = 8*(1/2)^n, theta = n*Pi/3");
print("Eliminate n: n = 3*theta/Pi -> r = 8*exp(-(3*ln(2)/Pi)*theta)");
print("This is a logarithmic spiral. The vertices Z(n) lie exactly on this spiral.\n");

# ------------------------------------------------------------
# 2. DEFINE THE COMPLEX VERTICES Z(n)
# ------------------------------------------------------------
Z := n -> evalf(8 * (1/4 + I*sqrt(3)/4)^n):   # numeric values for plotting

# ------------------------------------------------------------
# 3. PLOT THE LOGARITHMIC SPIRAL (red, thick) through the vertices
# ------------------------------------------------------------
r0 := 8: b := -3*ln(2)/Pi:
spiral := polarplot(r0*exp(b*theta), theta=0..8*Pi,
                    color="Red", thickness=3, scaling=constrained,
                    axes=boxed, labels=["Re(z)", "Im(z)"]):
# ------------------------------------------------------------
# 4. PREPARE THE TRIANGLES (original definition, animated)
# ------------------------------------------------------------
Triangle := i -> polygon([[0,0], [Re(Z(i-1)), Im(Z(i-1))], [Re(Z(i)), Im(Z(i))]]):

frame := proc(n::posint)
    local i, colors;
    colors := ["Red","Green","Blue","Yellow","Magenta","Cyan"];
    display(seq(Triangle(i), i=1..n),
            color=[seq(colors[(i-1 mod 6)+1], i=1..n)],
            transparency=0.5);   # semi-transparent to see the spiral
end proc:

# Create the animation (first 6 frames)
animation := display(seq(frame(i), i=1..6), insequence, scaling=constrained):

# ------------------------------------------------------------
# 5. PLOT THE VERTICES AS BLACK DOTS (to show they lie on the spiral)
# ------------------------------------------------------------
vertices := [seq([Re(Z(n)), Im(Z(n))], n=0..6)]:
vertex_plot := pointplot(vertices, symbol=solidcircle, symbolsize=7, color="Green"):

# ------------------------------------------------------------
# 6. COMBINE EVERYTHING IN A LARGE DISPLAY
# ------------------------------------------------------------
final_plot := display(animation, spiral, vertex_plot,
                      scaling=constrained, size=[1800,900],
                      title="Logarithmic spiral through the vertices of stacked triangles",
                      titlefont=[Times,16]):

# Show the final plot
final_plot;

"Why does stacking these triangles produce a logarithmic spiral?"

 

"Definition: Z(0) = 8, Z(1) = 8*(1/4 + I*sqrt(3)/4) = 2+2*I*sqrt(3)"

 

"Recurrence: Z(n) = Z(n-1) * (1/4 + I*sqrt(3)/4)"

 

"Modulus of the factor = 1/2, argument = Pi/3 (60°)"

 

"So |Z(n)| = 8*(1/2)^n, arg(Z(n)) = n*Pi/3"

 

"In polar coordinates: r = 8*(1/2)^n, theta = n*Pi/3"

 

"Eliminate n: n = 3*theta/Pi -> r = 8*exp(-(3*ln(2)/Pi)*theta)"

 

"This is a logarithmic spiral. The vertices Z(n) lie exactly on this spiral.
"

 

 

 

 


 

Download logaritmic_spiral_in_complex_planeDEF_3-5-2026.mw

@C_R 

Interesting, thanks for  geodesics_AI.mw

1 2 3 4 5 6 7 Last Page 2 of 87