Figure 1. Two possible cocamidopropyl betaine (CAPB) structures

Cocamidopropyl betaine has two structures based upon pH: cationic and zwitterionic.