diff --git a/stack/maxima/contrib/validators.mac b/stack/maxima/contrib/validators.mac
index 14472483a6bf2743bd5fcbe766bfa82c79c26c16..8c94f0807d5dc322d965f7ecc098706ea14a2811 100644
--- a/stack/maxima/contrib/validators.mac
+++ b/stack/maxima/contrib/validators.mac
@@ -31,6 +31,15 @@ validate_underscore(ex) := if is(sposition("_", string(ex)) = false) then ""
 /* Add in unit-test cases using STACK's s_test_case function.  At least two please! */
 /* Place test cases in validators_test.mac                                          */
 
+/* The student may not use a user-defined function, or arrays, anywhere in their input. */
+validate_nofunctions(ex):= block([op1,opp],
+  if atom(ex) then return(""),
+  op1:ev(op(ex)),
+  opp:apply(properties, [op1]),
+  if ev(emptyp(opp) or is(opp=[noun]),simp) then return(sconcat("User-defined functions are not permitted in this input. In your answer ", stack_disp(op1, "i"), " appears to be used as a function. ")),
+  apply(sconcat, map(validate_nofunctions, args(ex)))
+);
+
 /* The student may only use single-character variable names in their answer. */
 /* This is intended for use when Insert Stars is turned off, but we still want to indicate to students that they may have forgotten a star */
 validate_all_one_letter_variables(ex) := if not(is(ev(lmax(map(lambda([ex2],slength(string(ex2))),listofvars(ex))),simp)>1)) then ""
diff --git a/stack/maxima/contrib/validators_test.mac b/stack/maxima/contrib/validators_test.mac
index 2c700dbc08266fae8d9fa8674aeb5c8197181c51..3a59409ad8090ff205cd8c912c7fab385883358f 100644
--- a/stack/maxima/contrib/validators_test.mac
+++ b/stack/maxima/contrib/validators_test.mac
@@ -23,6 +23,14 @@
 /*                                                              */
 /****************************************************************/
 
+
+s_test_case(validate_nofunctions(1+a1), "");
+s_test_case(validate_nofunctions(sin(n*x)), "");
+s_test_case(validate_nofunctions(-b#pm#sqrt(b^2-4*a*c)), "");
+s_test_case(validate_nofunctions(x(2)), "User-defined functions are not permitted in this input. In your answer \\(x\\) appears to be used as a function. ");
+s_test_case(validate_nofunctions(3*x(t)^2), "User-defined functions are not permitted in this input. In your answer \\(x\\) appears to be used as a function. ");
+s_test_case(validate_nofunctions(1+f(x+1)), "User-defined functions are not permitted in this input. In your answer \\(f\\) appears to be used as a function. ");
+s_test_case(validate_nofunctions(x(2)*y(3)), "User-defined functions are not permitted in this input. In your answer \\(x\\) appears to be used as a function. User-defined functions are not permitted in this input. In your answer \\(y\\) appears to be used as a function. ");
 s_test_case(validate_underscore(1+a1), "");
 s_test_case(validate_underscore(1+a_1), "Underscore characters are not permitted in this input.");