Let $ G$ be a connected graph with $ n$ vertices and $ m$ edges such that each edge is contained in at least one triangle. Find the minimum value of $ m$.
1. **Define the problem and notation:**
   Let \( G \) be a connected graph with \( n \) vertices and \( m \) edges such that each edge is contained in at least one triangle. We aim to find the minimum value of \( m \).

2. **Propose the minimum function:**
   The proposed minimum function is \( f(n) = \left\lfloor \frac{3n-2}{2} \right\rfloor \), where \( \left\lfloor x \right\rfloor \) denotes the integer part of \( x \). This can be expressed as:
   \[
   f(2n) = 3n - 1 \quad \text{and} \quad f(2n+1) = 3n \quad \text{for all} \quad n \geq 3.
   \]

3. **Construct examples for odd and even \( n \):**
   - For \( k = 2n + 1 \), consider a graph with vertices \( A, B_1, B_2, \ldots, B_{2n} \) and edges \( AB_i \) for all \( i \) and \( B_{2i-1}B_{2i} \) for \( i = 1, \ldots, n \). This graph has \( 3n \) edges, so \( f(2n+1) \leq 3n \).
   - For \( k = 2n \), start from the above graph with \( 2n-1 \) vertices, add a vertex \( X \) and edges \( XA \) and \( XB \) for some edge \( AB \). This results in \( 3n-1 \) edges, so \( f(2n) \leq 3n-1 \).

4. **Base cases:**
   - Clearly, \( f(3) = 3 \) and \( f(4) = 5 \).

5. **Degree constraints:**
   - Each vertex in a good graph has a degree of at least 2 because each edge must belong to a triangle.

6. **Induction hypothesis:**
   - Assume \( f(k) \) is given by \( \left\lfloor \frac{3k-2}{2} \right\rfloor \) for all \( k \leq 2n \).

7. **Induction step for \( 2n+1 \):**
   - Consider a good graph \( G \) with \( 2n+1 \) vertices and \( f(2n+1) \) edges. Let \( X \) be a vertex with degree 2, and \( XAB \) a triangle in \( G \).
   - Assume \( f(2n+1) \leq 3n-1 \). Deleting \( X \) and edges \( XA \) and \( XB \) leaves a graph \( G' \) with \( 2n \) vertices and at most \( 3n-3 \) edges.
   - Since \( f(2n) = 3n-1 \), \( G' \) is not good. The edge \( AB \) does not belong to a triangle anymore. If \( A \) or \( B \) is connected to another vertex, say \( AC \), then adding edge \( BC \) results in a good graph \( G'' \) with \( 2n \) vertices and at most \( 3n-2 \) edges, contradicting \( f(2n) = 3n-1 \).
   - Thus, \( f(2n+1) \geq 3n \), so \( f(2n+1) = 3n \).

8. **Induction step for \( 2n+2 \):**
   - Consider a good graph \( G \) with \( 2n+2 \) vertices and \( f(2n+2) \) edges. Let \( X \) be a vertex with degree 2, and \( XAB \) a triangle in \( G \).
   - Assume \( f(2n+2) \leq 3n+1 \). Deleting \( X \) and edges \( XA \) and \( XB \) leaves a graph \( G' \) with \( 2n+1 \) vertices and at most \( 3n-1 \) edges.
   - Since \( f(2n+1) = 3n \), \( G' \) is not good. The edge \( AB \) does not belong to a triangle anymore. If \( A \) has degree 1 in \( G' \), deleting \( A \) and edge \( AB \) leaves a good graph \( G'' \) with \( 2n \) vertices and at most \( 3n-2 \) edges, contradicting \( f(2n) = 3n-1 \).
   - Thus, \( A \) and \( B \) have degree at least 2 in \( G' \). Deleting edge \( AB \) results in a graph \( G''' \) with \( 2n \) vertices and at most \( 3n-2 \) edges. Since \( f(2n) = 3n-1 \), \( G''' \) cannot be good.
   - \( G''' \) must be disconnected, with two components of orders \( a \) and \( b \) such that \( a + b = 2n+1 \). Using the induction hypothesis, \( 3n-2 \geq f(a) + f(b) = 3x-1 + 3y = 3n-1 \), a contradiction.
   - Therefore, \( f(2n+2) \geq 3n+2 \), and we are done.

\(\blacksquare\)

The final answer is \( \boxed{ \left\lfloor \frac{3n-2}{2} \right\rfloor } \).