A transmission-line-matrix (TLM) node equivalent, the TLM-based finite-difference-time-domain (FDTD) method, has been recently proposed to allow the simulation of electromagnetic fields in a FDTD fashion. As a result, modeling and simulation techniques developed for the conventional FDTD scheme can be directly implemented into the TLM-based algorithm. In this article the nonlinear modeling scheme accomplished with a Z transform is adapted and implemented in the proposed TLM-based FDTD method, to simulate the electromagnetic behaviors in optical media with nonlinear polarization, such as Kerr and Raman effects. Numerical results are presented for one-dimensional calculation of propagation of femtosecond electromagnetic solitons that retain the optical carriers. The results are in good agreement with those obtained from the conventional FDTD simulation. In conclusion, the TLM-based FDTD method is found to be robust and flexible in 2D and 3D modeling. © 1996 John Wiley & Sons, Inc.