YES

We show the termination of the TRS R:

  a__f(f(a())) -> a__f(g(f(a())))
  mark(f(X)) -> a__f(X)
  mark(a()) -> a()
  mark(g(X)) -> g(mark(X))
  a__f(X) -> f(X)

-- SCC decomposition.

Consider the dependency pair problem (P, R), where P consists of

p1: a__f#(f(a())) -> a__f#(g(f(a())))
p2: mark#(f(X)) -> a__f#(X)
p3: mark#(g(X)) -> mark#(X)

and R consists of:

r1: a__f(f(a())) -> a__f(g(f(a())))
r2: mark(f(X)) -> a__f(X)
r3: mark(a()) -> a()
r4: mark(g(X)) -> g(mark(X))
r5: a__f(X) -> f(X)

The estimated dependency graph contains the following SCCs:

  {p3}


-- Reduction pair.

Consider the dependency pair problem (P, R), where P consists of

p1: mark#(g(X)) -> mark#(X)

and R consists of:

r1: a__f(f(a())) -> a__f(g(f(a())))
r2: mark(f(X)) -> a__f(X)
r3: mark(a()) -> a()
r4: mark(g(X)) -> g(mark(X))
r5: a__f(X) -> f(X)

The set of usable rules consists of

  (no rules)

Take the monotone reduction pair:

  lexicographic combination of reduction pairs:
  
    1. lexicographic path order with precedence:
    
      precedence:
      
        g > mark#
      
      argument filter:
    
        pi(mark#) = [1]
        pi(g) = [1]
    
    2. lexicographic path order with precedence:
    
      precedence:
      
        g > mark#
      
      argument filter:
    
        pi(mark#) = [1]
        pi(g) = [1]
    
    3. lexicographic path order with precedence:
    
      precedence:
      
        g > mark#
      
      argument filter:
    
        pi(mark#) = [1]
        pi(g) = [1]
    

The next rules are strictly ordered:

  p1
  r1, r2, r3, r4, r5

We remove them from the problem.  Then no dependency pair remains.